From bb08844dac0e56274ae05ca97999fdf0d7acf06f Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:25:14 +0530 Subject: [PATCH 001/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 52 +++++++++++++++++++++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 53 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8b6d607f1..bfc2a59a7 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,58 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +# [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) + + +### Bug Fixes + +* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) +* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +* progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) +* **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) +* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) + + +* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) + + +### Features + +* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) + + +### BREAKING CHANGES + +* New chat key ecnryption + +* feat: chat key encryption v2 + +New encryption version for pgp keys +* Signer is required in ui-web + +* refactor: add signer in ApproveRequest + +* fix: revert dev from localhost + +* feat: auto uprade keys + +* test: tests for upgrade User + +* test: test for send chat message + +* test: rename tests + +* test: text formating fix + + + ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 2b97a3a71..8a2ea231e 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.0.2", + "version": "1.0.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 12ba2f72c0a5c237bc4c564f2a9ca05cca01ac22 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:25:52 +0530 Subject: [PATCH 002/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 8989ee359..60aae7fc4 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -103,4 +103,3 @@ const CONFIG = { }; export default CONFIG; - From b0d4776f829c84510fda537ad50489165e518ff8 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:26:02 +0530 Subject: [PATCH 003/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 53 +++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index bfc2a59a7..43b2dbc03 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -5,6 +5,59 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) +### Bug Fixes + +* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +* **component:** dummy ([12ba2f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/12ba2f72c0a5c237bc4c564f2a9ca05cca01ac22)) +* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) +* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +* progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) +* **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) +* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) + + +* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) + + +### Features + +* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) + + +### BREAKING CHANGES + +* New chat key ecnryption + +* feat: chat key encryption v2 + +New encryption version for pgp keys +* Signer is required in ui-web + +* refactor: add signer in ApproveRequest + +* fix: revert dev from localhost + +* feat: auto uprade keys + +* test: tests for upgrade User + +* test: test for send chat message + +* test: rename tests + +* test: text formating fix + + + +# [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) + + ### Bug Fixes * **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) From 3c7037b8876b3ff58fc3c4602813a71b02325fb7 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:27:29 +0530 Subject: [PATCH 004/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 60aae7fc4..51e13990a 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -103,3 +103,5 @@ const CONFIG = { }; export default CONFIG; + + From 3df2a3f56e8e60403c519122f3ada0ca6922d0ed Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:27:38 +0530 Subject: [PATCH 005/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 43b2dbc03..8c1bebc46 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) + + +### Bug Fixes + +* **component:** dummy ([3c7037b](https://github.com/ethereum-push-notification-service/push-sdk/commit/3c7037b8876b3ff58fc3c4602813a71b02325fb7)) + + + # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 8a2ea231e..d84316bd3 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.0.0", + "version": "1.0.1", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 2e57a603ccc90b889d65c862d2a0cc295ad68870 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:27:56 +0530 Subject: [PATCH 006/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8c1bebc46..8191fa64b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -11,6 +11,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) + + +### Bug Fixes + +* **component:** dummy ([3c7037b](https://github.com/ethereum-push-notification-service/push-sdk/commit/3c7037b8876b3ff58fc3c4602813a71b02325fb7)) + + + # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) From 59b6cec5562b571a36ee3eca27d880f237705bca Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:28:30 +0530 Subject: [PATCH 007/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 51e13990a..60aae7fc4 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -103,5 +103,3 @@ const CONFIG = { }; export default CONFIG; - - From 09e71294a0b94f7b6f9e0f5aeae30493357463e9 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:28:40 +0530 Subject: [PATCH 008/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8191fa64b..b611cd524 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) + + +### Bug Fixes + +* **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) + + + ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index d84316bd3..2b97a3a71 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.0.1", + "version": "1.0.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From bef586f0754400334994d1f6079b1b1a77380edd Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:10 +0530 Subject: [PATCH 009/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 60aae7fc4..51e13990a 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -103,3 +103,5 @@ const CONFIG = { }; export default CONFIG; + + From 422e8c222464a15e8f5be3988ff72ddc7eaffe3d Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:18 +0530 Subject: [PATCH 010/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index b611cd524..aa9b86e24 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -5,6 +5,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) +### Bug Fixes + +* **component:** dummy ([bef586f](https://github.com/ethereum-push-notification-service/push-sdk/commit/bef586f0754400334994d1f6079b1b1a77380edd)) +* **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) + + + +## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) + + ### Bug Fixes * **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) From 40f1c57cb26e9efcace0f9ad2ceb577c70dac11e Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:48 +0530 Subject: [PATCH 011/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 51e13990a..60aae7fc4 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -103,5 +103,3 @@ const CONFIG = { }; export default CONFIG; - - From ca9c88ab064d968c9c01641461be3a2500b99712 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:56 +0530 Subject: [PATCH 012/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index aa9b86e24..91e627c8a 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.0.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.2...restapi-1.0.3) (2023-04-04) + + +### Bug Fixes + +* **component:** dummy ([40f1c57](https://github.com/ethereum-push-notification-service/push-sdk/commit/40f1c57cb26e9efcace0f9ad2ceb577c70dac11e)) + + + ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 2b97a3a71..4063a24a3 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.0.2", + "version": "1.0.3", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 3e699b07071fe53499d8116bab108ff5a00d8a85 Mon Sep 17 00:00:00 2001 From: aman035 Date: Wed, 5 Apr 2023 00:51:50 +0530 Subject: [PATCH 013/298] fix: success progressHook --- packages/restapi/src/lib/helpers/crypto.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/packages/restapi/src/lib/helpers/crypto.ts b/packages/restapi/src/lib/helpers/crypto.ts index e80609001..c8f4e77e7 100644 --- a/packages/restapi/src/lib/helpers/crypto.ts +++ b/packages/restapi/src/lib/helpers/crypto.ts @@ -219,6 +219,12 @@ export const decryptPGPKey = async (options: decryptPgpKeyProps) => { }); } } + progressHook?.({ + progressId: 'PUSH-DECRYPT-02', + progressTitle: 'Push Profile Unlocked', + progressInfo: 'Unlocking push profile', + level: 'SUCCESS', + }); return privateKey; } catch (err) { // Report Progress From 2b9df346e315673e7dfa9c3982bf50b63f17a45a Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:54:36 +0530 Subject: [PATCH 014/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 91e627c8a..834c98265 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.0.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.3...restapi-1.0.4) (2023-04-04) + + +### Bug Fixes + +* success progressHook ([3e699b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3e699b07071fe53499d8116bab108ff5a00d8a85)) + + + ## [1.0.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.2...restapi-1.0.3) (2023-04-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 4063a24a3..e4fc92092 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.0.3", + "version": "1.0.4", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From fa731877d3751714143bfa4e947899c858676cdc Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 17:49:16 +0530 Subject: [PATCH 015/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.1.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 15 +++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 834c98265..d22dace22 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,21 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +# [1.1.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.4...restapi-1.1.0) (2023-04-05) + + +### Bug Fixes + +* remove unnecessary log ([#289](https://github.com/ethereum-push-notification-service/push-sdk/issues/289)) ([7ac6be3](https://github.com/ethereum-push-notification-service/push-sdk/commit/7ac6be3b99ab1c36fa18e701b7656ff483834456)) +* success progressHook ([#291](https://github.com/ethereum-push-notification-service/push-sdk/issues/291)) ([9fd5b5a](https://github.com/ethereum-push-notification-service/push-sdk/commit/9fd5b5a0a64d922b299e8e33543c0ba500147fbc)) + + +### Features + +* **sendnotification:** add additionalMeta field to payload ([#235](https://github.com/ethereum-push-notification-service/push-sdk/issues/235)) ([6d9d60b](https://github.com/ethereum-push-notification-service/push-sdk/commit/6d9d60b2532bf408aaed708a8bbf753aeab13296)), closes [#234](https://github.com/ethereum-push-notification-service/push-sdk/issues/234) + + + ## [1.0.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.3...restapi-1.0.4) (2023-04-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index e4fc92092..34ee23589 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.0.4", + "version": "1.1.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ade2b43808063a096f69acdf63a0fee9ab7aed92 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 6 Apr 2023 18:44:30 +0530 Subject: [PATCH 016/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 14 ++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d22dace22..2eb829205 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,20 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +# [1.2.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.1.0...restapi-1.2.0) (2023-04-06) + + +### Bug Fixes + +* **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) + + +### Features + +* local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([2b09806](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b09806d28f1c8d2f74e163691fc2bcc60f26116)) + + + # [1.1.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.4...restapi-1.1.0) (2023-04-05) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 34ee23589..26a8f0da6 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.1.0", + "version": "1.2.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ee9c434e97bb31177aaa2d2eee1c46b94c35440f Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 6 Apr 2023 18:44:48 +0530 Subject: [PATCH 017/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 2eb829205..52cf1dfb6 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -16,6 +16,20 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +# [1.2.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.1.0...restapi-1.2.0) (2023-04-06) + + +### Bug Fixes + +* **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) + + +### Features + +* local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([2b09806](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b09806d28f1c8d2f74e163691fc2bcc60f26116)) + + + # [1.1.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.4...restapi-1.1.0) (2023-04-05) From a6915b6a0212af1d5245867922eb73e70c930c23 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:26:02 +0530 Subject: [PATCH 018/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 53 +++++++++++++++++++++++++++++++++++ 1 file changed, 53 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 52cf1dfb6..1af49a8b3 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -153,6 +153,59 @@ New encryption version for pgp keys +# [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) + + +### Bug Fixes + +* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +* **component:** dummy ([12ba2f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/12ba2f72c0a5c237bc4c564f2a9ca05cca01ac22)) +* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) +* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +* progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) +* **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) +* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) + + +* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) + + +### Features + +* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) + + +### BREAKING CHANGES + +* New chat key ecnryption + +* feat: chat key encryption v2 + +New encryption version for pgp keys +* Signer is required in ui-web + +* refactor: add signer in ApproveRequest + +* fix: revert dev from localhost + +* feat: auto uprade keys + +* test: tests for upgrade User + +* test: test for send chat message + +* test: rename tests + +* test: text formating fix + + + # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) From 2af4079a91664832fa72d9eb7a3ae3f9536bdefc Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:27:29 +0530 Subject: [PATCH 019/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 050b26852..d6959e6dd 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -128,3 +128,5 @@ const CONFIG = { }; export default CONFIG; + + From 617a4cf4402bde574aee59dfb212f32fe7ce8b8d Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:28:30 +0530 Subject: [PATCH 020/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index d6959e6dd..050b26852 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -128,5 +128,3 @@ const CONFIG = { }; export default CONFIG; - - From 9b53717f8aa4f67d2a991033dc3ab04b9672b2d2 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:10 +0530 Subject: [PATCH 021/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 050b26852..d6959e6dd 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -128,3 +128,5 @@ const CONFIG = { }; export default CONFIG; + + From 44bf6d3d29eea3f66a1be12d5568d711b0157cb8 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:18 +0530 Subject: [PATCH 022/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 1af49a8b3..68e2f9c32 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -73,6 +73,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) + + +### Bug Fixes + +* **component:** dummy ([bef586f](https://github.com/ethereum-push-notification-service/push-sdk/commit/bef586f0754400334994d1f6079b1b1a77380edd)) +* **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) + + + ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) From 61cfc0cfa3fac4c3ee754b837bd6e562b9ee2faf Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:48 +0530 Subject: [PATCH 023/298] fix(component): dummy --- packages/restapi/src/lib/config.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index d6959e6dd..050b26852 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -128,5 +128,3 @@ const CONFIG = { }; export default CONFIG; - - From 1c31050f93e1945b444470ba8644c237ceee2188 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:29:56 +0530 Subject: [PATCH 024/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 68e2f9c32..154485db6 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -63,6 +63,7 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +<<<<<<< HEAD ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) @@ -73,6 +74,8 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +======= +>>>>>>> ca9c88a (ci(restapi): 🎉 cut release to restapi-v1.0.3) ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) From d9e9f157a5c141b346bb67697b5fdc72ebe0c158 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 5 Apr 2023 00:54:36 +0530 Subject: [PATCH 025/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.0.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 35 +---------------------------------- 1 file changed, 1 insertion(+), 34 deletions(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 154485db6..2d055f231 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -59,31 +59,21 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ### Bug Fixes -* **component:** dummy ([40f1c57](https://github.com/ethereum-push-notification-service/push-sdk/commit/40f1c57cb26e9efcace0f9ad2ceb577c70dac11e)) - - -<<<<<<< HEAD ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) ### Bug Fixes -* **component:** dummy ([bef586f](https://github.com/ethereum-push-notification-service/push-sdk/commit/bef586f0754400334994d1f6079b1b1a77380edd)) -* **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) -======= ->>>>>>> ca9c88a (ci(restapi): 🎉 cut release to restapi-v1.0.3) + ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) ### Bug Fixes -* **component:** dummy ([bef586f](https://github.com/ethereum-push-notification-service/push-sdk/commit/bef586f0754400334994d1f6079b1b1a77380edd)) -* **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) - ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) @@ -91,27 +81,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ### Bug Fixes -* **component:** dummy ([59b6cec](https://github.com/ethereum-push-notification-service/push-sdk/commit/59b6cec5562b571a36ee3eca27d880f237705bca)) - - ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) ### Bug Fixes -* **component:** dummy ([3c7037b](https://github.com/ethereum-push-notification-service/push-sdk/commit/3c7037b8876b3ff58fc3c4602813a71b02325fb7)) - - ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) ### Bug Fixes -* **component:** dummy ([3c7037b](https://github.com/ethereum-push-notification-service/push-sdk/commit/3c7037b8876b3ff58fc3c4602813a71b02325fb7)) - - # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) @@ -119,8 +100,6 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ### Bug Fixes * **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** dummy ([12ba2f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/12ba2f72c0a5c237bc4c564f2a9ca05cca01ac22)) -* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) * **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) * **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) * **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) @@ -172,8 +151,6 @@ New encryption version for pgp keys ### Bug Fixes * **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** dummy ([12ba2f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/12ba2f72c0a5c237bc4c564f2a9ca05cca01ac22)) -* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) * **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) * **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) * **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) @@ -225,7 +202,6 @@ New encryption version for pgp keys ### Bug Fixes * **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) * **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) * **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) * **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) @@ -276,17 +252,12 @@ New encryption version for pgp keys ### Bug Fixes -* **component:** dummy commit ([14b8824](https://github.com/ethereum-push-notification-service/push-sdk/commit/14b882466e36fe165af696c91a2c99bcbb0b6ecc)) - - ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) ### Bug Fixes -* **component:** dummy commit ([88e6d5e](https://github.com/ethereum-push-notification-service/push-sdk/commit/88e6d5e83f16dd23649991abd04776df2c37911d)) - # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) @@ -295,8 +266,6 @@ New encryption version for pgp keys ### Bug Fixes * **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** dummy commit ([e5d19b8](https://github.com/ethereum-push-notification-service/push-sdk/commit/e5d19b8c6aa4cd72f872d6c27577295324e3b8e1)) -* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) * **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) * **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) * **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) @@ -346,8 +315,6 @@ New encryption version for pgp keys ### Bug Fixes * **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** dummy commit ([e5d19b8](https://github.com/ethereum-push-notification-service/push-sdk/commit/e5d19b8c6aa4cd72f872d6c27577295324e3b8e1)) -* **component:** dummy commit ([#282](https://github.com/ethereum-push-notification-service/push-sdk/issues/282)) ([af10b66](https://github.com/ethereum-push-notification-service/push-sdk/commit/af10b6681c8365b9b16fb3cde8bfa88a26408fa1)) * **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) * **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) * **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) From 93c2cf45f10d5c18fa646ac3015a81f142f17511 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 7 Apr 2023 15:00:13 +0530 Subject: [PATCH 026/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 2d055f231..dec831077 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.0...restapi-1.2.1) (2023-04-07) + + +### Bug Fixes + +* added types for chat fn ([#298](https://github.com/ethereum-push-notification-service/push-sdk/issues/298)) ([1c944b2](https://github.com/ethereum-push-notification-service/push-sdk/commit/1c944b237909e393f6ae72c76138411076c62b13)) +* **component:** dummy ([61cfc0c](https://github.com/ethereum-push-notification-service/push-sdk/commit/61cfc0cfa3fac4c3ee754b837bd6e562b9ee2faf)) +* **component:** dummy ([9b53717](https://github.com/ethereum-push-notification-service/push-sdk/commit/9b53717f8aa4f67d2a991033dc3ab04b9672b2d2)) +* **component:** dummy ([617a4cf](https://github.com/ethereum-push-notification-service/push-sdk/commit/617a4cf4402bde574aee59dfb212f32fe7ce8b8d)) +* **component:** dummy ([2af4079](https://github.com/ethereum-push-notification-service/push-sdk/commit/2af4079a91664832fa72d9eb7a3ae3f9536bdefc)) + + + # [1.2.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.1.0...restapi-1.2.0) (2023-04-06) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 26a8f0da6..98388ef21 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.0", + "version": "1.2.1", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 639b4d2de728ef289da5889b51fd45e003156699 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 7 Apr 2023 15:04:24 +0530 Subject: [PATCH 027/298] fix: local for local development (#295) Co-Authored-By: aman035 --- packages/restapi/CHANGELOG.md | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index dec831077..12fc660d8 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -8,10 +8,7 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ### Bug Fixes * added types for chat fn ([#298](https://github.com/ethereum-push-notification-service/push-sdk/issues/298)) ([1c944b2](https://github.com/ethereum-push-notification-service/push-sdk/commit/1c944b237909e393f6ae72c76138411076c62b13)) -* **component:** dummy ([61cfc0c](https://github.com/ethereum-push-notification-service/push-sdk/commit/61cfc0cfa3fac4c3ee754b837bd6e562b9ee2faf)) -* **component:** dummy ([9b53717](https://github.com/ethereum-push-notification-service/push-sdk/commit/9b53717f8aa4f67d2a991033dc3ab04b9672b2d2)) -* **component:** dummy ([617a4cf](https://github.com/ethereum-push-notification-service/push-sdk/commit/617a4cf4402bde574aee59dfb212f32fe7ce8b8d)) -* **component:** dummy ([2af4079](https://github.com/ethereum-push-notification-service/push-sdk/commit/2af4079a91664832fa72d9eb7a3ae3f9536bdefc)) + From d5433a93de34e69953ca88e602d264b234708727 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 7 Apr 2023 15:14:56 +0530 Subject: [PATCH 028/298] fix: version update --- packages/restapi/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 98388ef21..554f6a0c6 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -30,3 +30,4 @@ "mocha": "^10.2.0" } } + From 6d6f04199fe3d28e23276287ba631cccb46054b1 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 7 Apr 2023 19:58:41 +0530 Subject: [PATCH 029/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 14 ++++++++++++++ packages/restapi/package.json | 3 +-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 12fc660d8..9d3759390 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,20 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.1...restapi-1.2.2) (2023-04-07) + + +### Bug Fixes + +* local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([639b4d2](https://github.com/ethereum-push-notification-service/push-sdk/commit/639b4d2de728ef289da5889b51fd45e003156699)) +* main merge ([0be9604](https://github.com/ethereum-push-notification-service/push-sdk/commit/0be9604eacf003db0cc4244f41d5e9c533f7613a)) +* remove hardcoded values ([#299](https://github.com/ethereum-push-notification-service/push-sdk/issues/299)) ([02a4e20](https://github.com/ethereum-push-notification-service/push-sdk/commit/02a4e2077a2ee4fb010d619d04acffc1881a2c0c)) +* signerType ([#303](https://github.com/ethereum-push-notification-service/push-sdk/issues/303)) ([20eb15a](https://github.com/ethereum-push-notification-service/push-sdk/commit/20eb15af4bc3286e5836845e299326352af0ce34)) +* version update ([d5433a9](https://github.com/ethereum-push-notification-service/push-sdk/commit/d5433a93de34e69953ca88e602d264b234708727)) +* version update ([#302](https://github.com/ethereum-push-notification-service/push-sdk/issues/302)) ([82bd4f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/82bd4f7882f8782f8d19a1daf97e5366ce26c5de)) + + + ## [1.2.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.0...restapi-1.2.1) (2023-04-07) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 554f6a0c6..7928e276f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.1", + "version": "1.2.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" @@ -30,4 +30,3 @@ "mocha": "^10.2.0" } } - From aef8084145af7816fbbaf64a9a3832d1324a4af5 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 18 Apr 2023 20:27:18 +0530 Subject: [PATCH 030/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 9d3759390..8d2fee118 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.2...restapi-1.2.3) (2023-04-18) + + +### Bug Fixes + +* git merge ([87a31a1](https://github.com/ethereum-push-notification-service/push-sdk/commit/87a31a142b80e3305d5986e9f6b5734d9345b7d0)) + + + ## [1.2.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.1...restapi-1.2.2) (2023-04-07) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c76a6da67..fc16dae18 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.2", + "version": "1.2.3", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 9562adc60a5749a308e34e83eb1819fc5da2d669 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 19 Apr 2023 17:23:34 +0530 Subject: [PATCH 031/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8d2fee118..b641cb659 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.3...restapi-1.2.4) (2023-04-19) + + +### Bug Fixes + +* chamged signerType from ethers.wallet ([#315](https://github.com/ethereum-push-notification-service/push-sdk/issues/315)) ([385b3dd](https://github.com/ethereum-push-notification-service/push-sdk/commit/385b3ddf2e2aa22b687a5094ba5cfec0e13da63b)) +* fix videoCall Notif ([#310](https://github.com/ethereum-push-notification-service/push-sdk/issues/310)) ([069783e](https://github.com/ethereum-push-notification-service/push-sdk/commit/069783e2cbe77723e335affb2f2668c785aeace6)) + + + ## [1.2.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.2...restapi-1.2.3) (2023-04-18) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index fc16dae18..1822d4e96 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.3", + "version": "1.2.4", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From bc3413392d16cc34c5646e9f121dcb165e70eafe Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 27 Apr 2023 12:51:11 +0530 Subject: [PATCH 032/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 18 ++++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index b641cb659..c03e5fd48 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,24 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.4...restapi-1.2.5) (2023-04-27) + + +### Bug Fixes + +* nft compatibility ([#326](https://github.com/ethereum-push-notification-service/push-sdk/issues/326)) ([80650e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/80650e65f490e08df30c17c9e5dadc0b513b1f46)) + + + +## [1.2.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.4...restapi-1.2.5) (2023-04-27) + + +### Bug Fixes + +* nft compatibility ([#326](https://github.com/ethereum-push-notification-service/push-sdk/issues/326)) ([80650e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/80650e65f490e08df30c17c9e5dadc0b513b1f46)) + + + ## [1.2.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.3...restapi-1.2.4) (2023-04-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 1822d4e96..e9e8e7466 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.4", + "version": "1.2.5", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 294fe70a588aaa9152ad6e02cf74877fdd34ae88 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 27 Apr 2023 17:17:27 +0530 Subject: [PATCH 033/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index c03e5fd48..ee0376069 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.5...restapi-1.2.6) (2023-04-27) + + +### Bug Fixes + +* add chat.chat to exports ([#331](https://github.com/ethereum-push-notification-service/push-sdk/issues/331)) ([289c774](https://github.com/ethereum-push-notification-service/push-sdk/commit/289c774074cecd6998b0bda39bee4e779ee9daa3)) + + + ## [1.2.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.4...restapi-1.2.5) (2023-04-27) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index e9e8e7466..6cdc41952 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.5", + "version": "1.2.6", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 934b4a3aa1039931d61a911b3d6179607a15dcb7 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 27 Apr 2023 18:17:36 +0530 Subject: [PATCH 034/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index ee0376069..53bb4fa96 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.6...restapi-1.2.7) (2023-04-27) + + +### Bug Fixes + +* Merge branch 'deployment' ([0d184dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/0d184dc75d8680ac8a77f1124204af86befac82c)) +* senderType is optional param ([#329](https://github.com/ethereum-push-notification-service/push-sdk/issues/329)) ([ed3d6e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/ed3d6e611975da054d5e1b3809e614450a563cd5)) + + + ## [1.2.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.5...restapi-1.2.6) (2023-04-27) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 6cdc41952..39bb48962 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.6", + "version": "1.2.7", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 8434cfaf82f9ef7a2d84847701e20d210d2d7250 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 27 Apr 2023 18:36:16 +0530 Subject: [PATCH 035/298] =?UTF-8?q?ci(socket):=20=F0=9F=8E=89=20cut=20rele?= =?UTF-8?q?ase=20to=20socket-v0.5.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/socket/CHANGELOG.md | 15 +++++++++++++++ packages/socket/package.json | 2 +- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/packages/socket/CHANGELOG.md b/packages/socket/CHANGELOG.md index 848699b26..608a00bc2 100644 --- a/packages/socket/CHANGELOG.md +++ b/packages/socket/CHANGELOG.md @@ -2,6 +2,21 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +# [0.5.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/socket-0.4.1...socket-0.5.0) (2023-04-27) + + +### Bug Fixes + +* **component:** env type in demo react and uiweb ([#225](https://github.com/ethereum-push-notification-service/push-sdk/issues/225)) ([ff1113a](https://github.com/ethereum-push-notification-service/push-sdk/commit/ff1113adb226aee4c9f6ccdfa488e59b47ca9b9e)) +* **component:** group chat socket event ([#251](https://github.com/ethereum-push-notification-service/push-sdk/issues/251)) ([17f0892](https://github.com/ethereum-push-notification-service/push-sdk/commit/17f0892570a6f2318d515a7d6e297a71463fe490)) + + +### Features + +* add local env to socket config file ([#334](https://github.com/ethereum-push-notification-service/push-sdk/issues/334)) ([db4171e](https://github.com/ethereum-push-notification-service/push-sdk/commit/db4171e57bcba2b86f798072fc37d9f082236ad0)) + + + ## [0.4.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/socket-0.4.1...socket-0.4.2) (2023-03-22) diff --git a/packages/socket/package.json b/packages/socket/package.json index 583aa4647..18bd79d85 100644 --- a/packages/socket/package.json +++ b/packages/socket/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/socket", - "version": "0.4.2", + "version": "0.5.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 1421658ec40b18780a62163f013ad0c53d66f805 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 27 Apr 2023 18:42:48 +0530 Subject: [PATCH 036/298] fix: test commit --- packages/uiweb/src/lib/components/chat/AddressInfo.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/uiweb/src/lib/components/chat/AddressInfo.tsx b/packages/uiweb/src/lib/components/chat/AddressInfo.tsx index f27c7ad98..4034e6125 100644 --- a/packages/uiweb/src/lib/components/chat/AddressInfo.tsx +++ b/packages/uiweb/src/lib/components/chat/AddressInfo.tsx @@ -107,3 +107,4 @@ const Span = styled.span` letter-spacing: -0.019em; color: ${(props: any): string => props.theme.textColorPrimary || '#000'}; `; + From 974a07fb76202b9d17a3898daf53b424b2142971 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 1 May 2023 13:51:10 +0530 Subject: [PATCH 037/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 53bb4fa96..2e81d52db 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.7...restapi-1.2.8) (2023-05-01) + + +### Bug Fixes + +* error ProgressHook added ([#336](https://github.com/ethereum-push-notification-service/push-sdk/issues/336)) ([3f7295f](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f7295f7811c15e5b9f3ba74a69ffcbe3fb6d829)) + + + ## [1.2.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.6...restapi-1.2.7) (2023-04-27) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 39bb48962..bb36058ea 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.7", + "version": "1.2.8", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 7f72fdb2ba9702fae54afab150e4f8e6f6a5c232 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 1 May 2023 14:31:13 +0530 Subject: [PATCH 038/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.0.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 40 +++++++++++++++++++++++++++++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 41 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 2f1c821ae..e05bb866d 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,46 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +# [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.5.0...uiweb-1.0.0) (2023-05-01) + + +### Bug Fixes + +* chamged signerType from ethers.wallet ([#315](https://github.com/ethereum-push-notification-service/push-sdk/issues/315)) ([385b3dd](https://github.com/ethereum-push-notification-service/push-sdk/commit/385b3ddf2e2aa22b687a5094ba5cfec0e13da63b)) +* **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) +* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +* signerType ([#303](https://github.com/ethereum-push-notification-service/push-sdk/issues/303)) ([20eb15a](https://github.com/ethereum-push-notification-service/push-sdk/commit/20eb15af4bc3286e5836845e299326352af0ce34)) +* upgraded rest api package in webui ([#338](https://github.com/ethereum-push-notification-service/push-sdk/issues/338)) ([b4cc0b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/b4cc0b0104d6a16279680118364c085eab7d74b2)) + + +* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) + + +### BREAKING CHANGES + +* New chat key ecnryption + +* feat: chat key encryption v2 + +New encryption version for pgp keys +* Signer is required in ui-web + +* refactor: add signer in ApproveRequest + +* fix: revert dev from localhost + +* feat: auto uprade keys + +* test: tests for upgrade User + +* test: test for send chat message + +* test: rename tests + +* test: text formating fix + + + # [0.5.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.4.3...uiweb-0.5.0) (2023-03-07) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 28354cead..888dde41b 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.5.0", + "version": "1.0.0", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From de824a4bce1de11f18e7bfea80f46bea6eb574d1 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 1 May 2023 14:31:35 +0530 Subject: [PATCH 039/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.0.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 40 +++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index e05bb866d..ffe029ffa 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -42,6 +42,46 @@ New encryption version for pgp keys +# [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.5.0...uiweb-1.0.0) (2023-05-01) + + +### Bug Fixes + +* chamged signerType from ethers.wallet ([#315](https://github.com/ethereum-push-notification-service/push-sdk/issues/315)) ([385b3dd](https://github.com/ethereum-push-notification-service/push-sdk/commit/385b3ddf2e2aa22b687a5094ba5cfec0e13da63b)) +* **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) +* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +* signerType ([#303](https://github.com/ethereum-push-notification-service/push-sdk/issues/303)) ([20eb15a](https://github.com/ethereum-push-notification-service/push-sdk/commit/20eb15af4bc3286e5836845e299326352af0ce34)) +* upgraded rest api package in webui ([#338](https://github.com/ethereum-push-notification-service/push-sdk/issues/338)) ([b4cc0b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/b4cc0b0104d6a16279680118364c085eab7d74b2)) + + +* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) + + +### BREAKING CHANGES + +* New chat key ecnryption + +* feat: chat key encryption v2 + +New encryption version for pgp keys +* Signer is required in ui-web + +* refactor: add signer in ApproveRequest + +* fix: revert dev from localhost + +* feat: auto uprade keys + +* test: tests for upgrade User + +* test: test for send chat message + +* test: rename tests + +* test: text formating fix + + + # [0.5.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.4.3...uiweb-0.5.0) (2023-03-07) From f7ecc4debead2f849ec856e5bdfb94ca6ff19eb0 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 1 May 2023 15:13:54 +0530 Subject: [PATCH 040/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.0.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 10 ++++++++++ packages/uiweb/package.json | 3 +-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index ffe029ffa..fea8965b1 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.0...uiweb-1.0.1) (2023-05-01) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([ec73af8](https://github.com/ethereum-push-notification-service/push-sdk/commit/ec73af85df847159c440a834905015d7937ffd9e)) +* upgrade rest API ([#339](https://github.com/ethereum-push-notification-service/push-sdk/issues/339)) ([0c85519](https://github.com/ethereum-push-notification-service/push-sdk/commit/0c85519b0a9d2a17bd85fb5bccba5c20953d3612)) + + + # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.5.0...uiweb-1.0.0) (2023-05-01) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 440a65a68..89acb815b 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.0.0", + "version": "1.0.1", "publishConfig": { "registry": "https://registry.npmjs.org/" }, @@ -16,4 +16,3 @@ "@pushprotocol/socket": "^0.4.2" } } - From 496952ac8faab02c82ee11be8e8925a1fb01cd01 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 12:58:00 +0530 Subject: [PATCH 041/298] fix: added ci-version-beta --- packages/restapi/project.json | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/packages/restapi/project.json b/packages/restapi/project.json index 03ca264a6..a42008d52 100644 --- a/packages/restapi/project.json +++ b/packages/restapi/project.json @@ -38,6 +38,15 @@ "postTargets": ["restapi:build", "restapi:ci-publish"] } }, + "ci-version-beta": { + "executor": "@jscutlery/semver:version", + "options": { + "preset": "angular", + "commitMessageFormat": "ci(${projectName}): 🎉 cut release to ${projectName}-v${version}", + "postTargets": ["restapi:build", "restapi:ci-publish"], + "preid": "beta" + } + }, "ci-publish": { "executor": "@nrwl/workspace:run-commands", "options": { From 2f282ce60003733fc95ce239a6c1a2d6c24616cc Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 12:59:11 +0530 Subject: [PATCH 042/298] fix: added ci-version-beta --- packages/restapi/project.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/restapi/project.json b/packages/restapi/project.json index a42008d52..7019b9692 100644 --- a/packages/restapi/project.json +++ b/packages/restapi/project.json @@ -42,7 +42,7 @@ "executor": "@jscutlery/semver:version", "options": { "preset": "angular", - "commitMessageFormat": "ci(${projectName}): 🎉 cut release to ${projectName}-v${version}", + "commitMessageFormat": "ci(${projectName}): 🎉 cut beta release to ${projectName}-v${version}", "postTargets": ["restapi:build", "restapi:ci-publish"], "preid": "beta" } From fc6f0692e81111de4b46232b085c45a2c5a30d33 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 13:10:05 +0530 Subject: [PATCH 043/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v1.2.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 2e81d52db..15fb66363 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.8...restapi-1.2.9) (2023-05-02) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([2b3993c](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b3993c673fcf11a39acd7a6663b6e6996fc26b6)) +* remove autoupgarde for v4 ([#344](https://github.com/ethereum-push-notification-service/push-sdk/issues/344)) ([3a4bef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3a4bef0750abb5bdb5ab9e96c9cc76e2269afa3c)) + + + ## [1.2.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.7...restapi-1.2.8) (2023-05-01) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index bb36058ea..aa04f9e90 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.8", + "version": "1.2.9", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 55429e54fc9df054dab955796ae4e34da8dd25ec Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 13:13:27 +0530 Subject: [PATCH 044/298] fix: added releaseType --- packages/restapi/project.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/restapi/project.json b/packages/restapi/project.json index 7019b9692..ca6f65668 100644 --- a/packages/restapi/project.json +++ b/packages/restapi/project.json @@ -44,6 +44,7 @@ "preset": "angular", "commitMessageFormat": "ci(${projectName}): 🎉 cut beta release to ${projectName}-v${version}", "postTargets": ["restapi:build", "restapi:ci-publish"], + "releaseType": "prerelease", "preid": "beta" } }, From 9237cb8761cf0a06e8d2f43fba891fe7b81de69c Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 16:27:41 +0530 Subject: [PATCH 045/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-beta.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 15fb66363..20368b110 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-beta.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.9...restapi-0.0.1-beta.0) (2023-05-02) + + +### Bug Fixes + +* added ci-version-beta ([2f282ce](https://github.com/ethereum-push-notification-service/push-sdk/commit/2f282ce60003733fc95ce239a6c1a2d6c24616cc)) +* added ci-version-beta ([496952a](https://github.com/ethereum-push-notification-service/push-sdk/commit/496952ac8faab02c82ee11be8e8925a1fb01cd01)) +* added release type ([28d7181](https://github.com/ethereum-push-notification-service/push-sdk/commit/28d71818c766b7057d4b1b8f629c8a4d01378db0)) +* added releaseType ([55429e5](https://github.com/ethereum-push-notification-service/push-sdk/commit/55429e54fc9df054dab955796ae4e34da8dd25ec)) + + + ## [1.2.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.8...restapi-1.2.9) (2023-05-02) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index aa04f9e90..49e570667 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.9", + "version": "0.0.1-beta.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 9d3080c2099f3645966876e5e3e38dcabbaffd4e Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 16:28:51 +0530 Subject: [PATCH 046/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-beta.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 20368b110..67cb16def 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -14,6 +14,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [0.0.1-beta.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.9...restapi-0.0.1-beta.0) (2023-05-02) + + +### Bug Fixes + +* added ci-version-beta ([2f282ce](https://github.com/ethereum-push-notification-service/push-sdk/commit/2f282ce60003733fc95ce239a6c1a2d6c24616cc)) +* added ci-version-beta ([496952a](https://github.com/ethereum-push-notification-service/push-sdk/commit/496952ac8faab02c82ee11be8e8925a1fb01cd01)) +* added release type ([28d7181](https://github.com/ethereum-push-notification-service/push-sdk/commit/28d71818c766b7057d4b1b8f629c8a4d01378db0)) +* added releaseType ([55429e5](https://github.com/ethereum-push-notification-service/push-sdk/commit/55429e54fc9df054dab955796ae4e34da8dd25ec)) + + + ## [1.2.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.8...restapi-1.2.9) (2023-05-02) From 1a67c50a9740427f93be977088afce47753a2cfb Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 16:46:49 +0530 Subject: [PATCH 047/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.10?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 67cb16def..12021d5c9 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.0...restapi-1.2.10) (2023-05-02) + + +### Bug Fixes + +* add password validation ([#345](https://github.com/ethereum-push-notification-service/push-sdk/issues/345)) ([863f48f](https://github.com/ethereum-push-notification-service/push-sdk/commit/863f48f9cbb3022e01f8715005cc8cd0fa96d0a8)) +* Merge branch 'main' into deployment ([a3cf078](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3cf078f37d31859ae83129d2b704639bbaab62b)) + + + ## [0.0.1-beta.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.9...restapi-0.0.1-beta.0) (2023-05-02) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 49e570667..e9fd82b90 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-beta.0", + "version": "1.2.10", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 80248d0e1ff09d4605372660d72bc6451795f7d4 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 2 May 2023 16:47:39 +0530 Subject: [PATCH 048/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.10?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 12021d5c9..1fff29a8d 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -12,6 +12,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.0...restapi-1.2.10) (2023-05-02) + + +### Bug Fixes + +* add password validation ([#345](https://github.com/ethereum-push-notification-service/push-sdk/issues/345)) ([863f48f](https://github.com/ethereum-push-notification-service/push-sdk/commit/863f48f9cbb3022e01f8715005cc8cd0fa96d0a8)) +* Merge branch 'main' into deployment ([a3cf078](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3cf078f37d31859ae83129d2b704639bbaab62b)) + + + ## [0.0.1-beta.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.9...restapi-0.0.1-beta.0) (2023-05-02) From d7a80e1b4174fe20eb8c04f72ee233c09445cbe9 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 4 May 2023 16:37:49 +0530 Subject: [PATCH 049/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-beta.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 4 ++++ packages/restapi/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 1fff29a8d..9efeee6a9 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-beta.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.10...restapi-0.0.1-beta.1) (2023-05-04) + + + ## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.0...restapi-1.2.10) (2023-05-02) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index e9fd82b90..bec9e611f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.10", + "version": "0.0.1-beta.1", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 5fa872312339f23fffd30687df8c7ae3df727939 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Thu, 4 May 2023 18:42:17 +0530 Subject: [PATCH 050/298] Add wallet to wallet video call methods (#309) * feat(video): add create and request method * feat(video): add simple-peer dependency * feat(video): add acceptRequest method * feat(video): add establish and end methods * refactor(video): wrap video methods in a class * feat(video): add video audio toggle functions * fix(video): add pgp private key in send video call notification --- packages/restapi/package.json | 11 +- packages/restapi/src/lib/index.ts | 4 +- packages/restapi/src/lib/types/index.ts | 52 + packages/restapi/src/lib/video/Video.ts | 408 ++++++++ .../restapi/src/lib/video/helpers/isJSON.ts | 9 + .../src/lib/video/helpers/mediaToggle.ts | 23 + .../helpers/sendVideoCallNotification.ts | 95 ++ packages/restapi/src/lib/video/index.ts | 1 + packages/restapi/yarn.lock | 889 +++--------------- 9 files changed, 716 insertions(+), 776 deletions(-) create mode 100644 packages/restapi/src/lib/video/Video.ts create mode 100644 packages/restapi/src/lib/video/helpers/isJSON.ts create mode 100644 packages/restapi/src/lib/video/helpers/mediaToggle.ts create mode 100644 packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts create mode 100644 packages/restapi/src/lib/video/index.ts diff --git a/packages/restapi/package.json b/packages/restapi/package.json index bec9e611f..332368835 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -12,7 +12,8 @@ "@metamask/eth-sig-util": "^5.0.2", "buffer": "^6.0.3", "crypto-js": "^4.1.1", - "openpgp": "^5.5.0" + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1" }, "scripts": { "test": "TS_NODE_PROJECT='./tsconfig.mocha.json' NODE_OPTIONS='--loader ts-node/esm' mocha -r ts-node/register 'tests/**/*.test.ts' --timeout 120000 --require tests/root.ts --serial" @@ -21,12 +22,12 @@ "@types/chai": "^4.3.4", "@types/chai-as-promised": "^7.1.5", "@types/crypto-js": "^4.1.1", + "@types/mocha": "^10.0.1", "chai": "^4.3.7", + "chai-as-promised": "^7.1.1", + "mocha": "^10.2.0", "mocha-typescript": "^1.1.17", "ts-node": "^10.9.1", - "typescript": "^5.0.2", - "@types/mocha": "^10.0.1", - "chai-as-promised": "^7.1.1", - "mocha": "^10.2.0" + "typescript": "^5.0.2" } } diff --git a/packages/restapi/src/lib/index.ts b/packages/restapi/src/lib/index.ts index a86fb48c3..e6d504b46 100644 --- a/packages/restapi/src/lib/index.ts +++ b/packages/restapi/src/lib/index.ts @@ -4,6 +4,7 @@ import * as user from './user'; import * as utils from './utils'; import * as payloads from './payloads'; import * as chat from './chat'; +import * as video from "./video" export * from './types'; @@ -13,5 +14,6 @@ export { user, utils, payloads, - chat + chat, + video } \ No newline at end of file diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 661ac2868..8a8a2eaa4 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -319,3 +319,55 @@ export type MessageWithCID = { encryptedSecret: string; verificationProof?: string; }; + +export type IMediaStream = MediaStream | undefined; + +export type VideoCallInfoType ={ + senderAddress: string; // address which initiated the call + receiverAddress: string; // address which will receive the call + /* + callStatus + 0 - call not initiated + 1 - call initiated by the caller address + 2 - call recieved by the receiver address + 3 - call is established + 4 - call ended + */ + callStatus: number; + chatId:string; +}; + +export type VideoRequestInputOptions = { + library: any; + chainId: number; + senderAddress: string; + recipientAddress: string; + chatId: string; + onRecieveMessage: (message: string) => void; + env?: ENV; + pgpPrivateKey:string | null; +}; + +export type VideoRequestReturnOptions = { + sendMessage: (message: string) => void; +}; + +export type VideoAcceptRequestInputOptions = { + signalData: any; + library: any; + chainId: number; + senderAddress: string; + recipientAddress: string; + chatId: string; + onRecieveMessage: (message: string) => void; + env?: ENV; + pgpPrivateKey:string | null; +}; + +export type VideoAcceptRequestReturnOptions = { + sendMessage: (message: string) => void; +}; + +export type VideoEstablishInputOptions = { + signalData: any; +}; diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts new file mode 100644 index 000000000..da2b39123 --- /dev/null +++ b/packages/restapi/src/lib/video/Video.ts @@ -0,0 +1,408 @@ +import * as React from 'react'; +// eslint-disable-next-line @typescript-eslint/ban-ts-comment +// @ts-ignore +import * as Peer from 'simple-peer'; + +import Constants, { ENV } from '../constants'; +import sendVideoCallNotification from './helpers/sendVideoCallNotification'; +import { + restartAudioStream, + restartVideoStream, + stopAudioStream, + stopVideoStream, +} from './helpers/mediaToggle'; +import isJSON from './helpers/isJSON'; + +import { + IMediaStream, + SignerType, + VideoAcceptRequestInputOptions, + VideoAcceptRequestReturnOptions, + VideoCallInfoType, + VideoEstablishInputOptions, + VideoRequestInputOptions, + VideoRequestReturnOptions, +} from '../types'; + +export class Video { + // user related info + private signer: SignerType | undefined = undefined; + private chainId: number | undefined = undefined; + private env: ENV = Constants.ENV.PROD; + + // storing the peer instance + private peerInstance: Peer.Instance | undefined = undefined; + + // variables for video call state handling + localStream: IMediaStream; + setLocalStream: React.Dispatch>; + incomingStream: IMediaStream; + setIncomingStream: React.Dispatch< + React.SetStateAction + >; + videoCallInfo: VideoCallInfoType; + setVideoCallInfo: React.Dispatch>; + isVideoOn: boolean; + setIsVideoOn: React.Dispatch>; + isAudioOn: boolean; + setIsAudioOn: React.Dispatch>; + isIncomingVideoOn: boolean; + setIsIncomingVideoOn: React.Dispatch>; + isIncomingAudioOn: boolean; + setIsIncomingAudioOn: React.Dispatch>; + + constructor({ + localStream, + setLocalStream, + incomingStream, + setIncomingStream, + videoCallInfo, + setVideoCallInfo, + isVideoOn, + setIsVideoOn, + isAudioOn, + setIsAudioOn, + isIncomingVideoOn, + setIsIncomingVideoOn, + isIncomingAudioOn, + setIsIncomingAudioOn, + }: { + localStream: IMediaStream; + setLocalStream: React.Dispatch< + React.SetStateAction + >; + incomingStream: IMediaStream; + setIncomingStream: React.Dispatch< + React.SetStateAction + >; + videoCallInfo: VideoCallInfoType; + setVideoCallInfo: React.Dispatch>; + isVideoOn: boolean; + setIsVideoOn: React.Dispatch>; + isAudioOn: boolean; + setIsAudioOn: React.Dispatch>; + isIncomingVideoOn: boolean; + setIsIncomingVideoOn: React.Dispatch>; + isIncomingAudioOn: boolean; + setIsIncomingAudioOn: React.Dispatch>; + }) { + this.localStream = localStream; + this.setLocalStream = setLocalStream; + this.incomingStream = incomingStream; + this.setIncomingStream = setIncomingStream; + this.videoCallInfo = videoCallInfo; + this.setVideoCallInfo = setVideoCallInfo; + this.isVideoOn = isVideoOn; + this.setIsVideoOn = setIsVideoOn; + this.isAudioOn = isAudioOn; + this.setIsAudioOn = setIsAudioOn; + this.isIncomingVideoOn = isIncomingVideoOn; + this.setIsIncomingVideoOn = setIsIncomingVideoOn; + this.isIncomingAudioOn = isIncomingAudioOn; + this.setIsIncomingAudioOn = setIsIncomingAudioOn; + } + + create = async () => { + try { + const localStream = await navigator.mediaDevices.getUserMedia({ + video: true, + audio: true, + }); + + this.setLocalStream(localStream); + this.setIsAudioOn(true); + this.setIsVideoOn(true); + } catch (err) { + console.log('Error in creating local stream', err); + } + }; + + request = async ( + options: VideoRequestInputOptions + ): Promise => { + const { + library, + chainId, + senderAddress, // notification sender + recipientAddress, // notification receiver + chatId, + onRecieveMessage, + env = Constants.ENV.PROD, + pgpPrivateKey=null, + } = options || {}; + + const signer: SignerType = await library.getSigner(senderAddress); + + const peer = new Peer({ + initiator: true, + trickle: false, + stream: this.localStream, + }); + + peer.on('signal', (data: any) => { + // sending notification to the recipientAddress with video call signaling data + sendVideoCallNotification( + { signer, chainId, pgpPrivateKey }, + { + senderAddress, + recipientAddress, + status: 1, + chatId, + signalingData: data, + env, + + } + ); + }); + + // set videoCallInfo state with status 1 (call initiated) + this.setVideoCallInfo({ + senderAddress: senderAddress, + receiverAddress: recipientAddress, + callStatus: 1, + chatId, + }); + + peer.on('connect', () => { + peer.send('initial message from caller'); + peer.send( + JSON.stringify({ type: 'isVideoOn', isVideoOn: this.isVideoOn }) + ); + peer.send( + JSON.stringify({ type: 'isAudioOn', isAudioOn: this.isAudioOn }) + ); + }); + + peer.on('data', (data: any) => { + if (isJSON(data)) { + const parsedData = JSON.parse(data); + if (parsedData.type === 'isVideoOn') { + console.log('IS VIDEO ON', parsedData.isVideoOn); + this.setIsIncomingVideoOn(parsedData.isVideoOn); + } + if (parsedData.type === 'isAudioOn') { + console.log('IS AUDIO ON', parsedData.isAudioOn); + this.setIsIncomingAudioOn(parsedData.isAudioOn); + } + if (parsedData.type === 'endLocalStream') { + console.log('END LOCAL STREAM', parsedData.endLocalStream); + window.location.reload(); + } + } else { + console.log('received a message', data); + onRecieveMessage(data); + } + }); + + peer.on('stream', (currentStream: MediaStream) => { + this.setIncomingStream(currentStream); + }); + + const sendMessage = (message: string): void => { + peer.send(message); + }; + + this.peerInstance = peer; + this.signer = signer; + this.chainId = chainId; + this.env = env; + return { + sendMessage, + }; + }; + + acceptRequest = async ( + options: VideoAcceptRequestInputOptions + ): Promise => { + const { + signalData, + library, + chainId, + senderAddress, // notification sender + recipientAddress, // notification receiver + chatId, + onRecieveMessage, + env = Constants.ENV.PROD, + pgpPrivateKey=null, + } = options || {}; + + const signer: SignerType = await library.getSigner(senderAddress); + + const peer = new Peer({ + initiator: false, + trickle: false, + stream: this.localStream, + }); + + peer.signal(signalData); + + peer.on('signal', (data: any) => { + sendVideoCallNotification( + { signer, chainId, pgpPrivateKey }, + { + senderAddress, + recipientAddress, + status: 2, + chatId, + signalingData: data, + env, + } + ); + }); + + // set videoCallInfo state with status 2 (call received) + this.setVideoCallInfo({ + senderAddress: senderAddress, + receiverAddress: recipientAddress, + callStatus: 2, + chatId, + }); + + peer.on('connect', () => { + peer.send('initial message from receiver'); + peer.send( + JSON.stringify({ type: 'isVideoOn', isVideoOn: this.isVideoOn }) + ); + peer.send( + JSON.stringify({ type: 'isAudioOn', isAudioOn: this.isAudioOn }) + ); + + // set videoCallInfo state with status 3 (call established) for the receiver's end + this.setVideoCallInfo((oldVideoCallInfo) => ({ + ...oldVideoCallInfo, + callStatus: 3, + })); + }); + + peer.on('data', (data: any) => { + if (isJSON(data)) { + const parsedData = JSON.parse(data); + if (parsedData.type === 'isVideoOn') { + console.log('IS VIDEO ON', parsedData.isVideoOn); + this.setIsIncomingVideoOn(parsedData.isVideoOn); + } + if (parsedData.type === 'isAudioOn') { + console.log('IS AUDIO ON', parsedData.isAudioOn); + this.setIsIncomingAudioOn(parsedData.isAudioOn); + } + if (parsedData.type === 'endLocalStream') { + console.log('END LOCAL STREAM', parsedData.endLocalStream); + window.location.reload(); + } + } else { + console.log('received a message', data); + onRecieveMessage(data); + } + }); + + peer.on('stream', (currentStream: MediaStream) => { + this.setIncomingStream(currentStream); + }); + + const sendMessage = (message: string): void => { + peer.send(message); + }; + + this.peerInstance = peer; + this.signer = signer; + this.chainId = chainId; + this.env = env; + return { + sendMessage, + }; + }; + + establish = (options: VideoEstablishInputOptions): void => { + const { signalData } = options || {}; + if (this.peerInstance) { + this.peerInstance.signal(signalData); + + // set videoCallInfo state with status 3 (call established) for the caller's end + this.setVideoCallInfo((oldVideoCallInfo) => ({ + ...oldVideoCallInfo, + callStatus: 3, + })); + } else { + throw new Error('Peer instance is undefined'); + } + }; + + end = (): void => { + try { + if (this.videoCallInfo.callStatus === 3) { + this.peerInstance?.send( + JSON.stringify({ type: 'endLocalStream', endLocalStream: true }) + ); + this.peerInstance?.destroy(); + + // ending the local stream + if (this.localStream) { + console.log('END LOCAL STREAM'); + this.localStream.getTracks().forEach((track) => track.stop()); + } + } + if (this.videoCallInfo.callStatus === 2 || this.videoCallInfo.callStatus === 1) { + if (!this.signer) throw new Error('signer not valid'); + if (!this.chainId) throw new Error('chainId not valid'); + if (!this.env) throw new Error('env is not valid'); + + // for disconnecting during status 1 + // send a notif to the other computer signaling status:4 + // sendVideoCallNotification( + // { signer: this.signer, chainId: this.chainId }, + // { + // senderAddress: this.videoCallInfo.senderAddress, + // recipientAddress: this.videoCallInfo.receiverAddress, + // status: 4, + // chatId: this.videoCallInfo.chatId, + // signalingData: null, + // env: this.env, + // } + // ); + window.location.reload(); + } + } catch (error) { + console.log('error occured', error); + } + }; + + // functions for toggling local audio and video + + toggleVideo = (): void => { + if (this.videoCallInfo.callStatus === 3) { + this.peerInstance?.send( + JSON.stringify({ type: 'isVideoOn', isVideoOn: !this.isVideoOn }) + ); + } + + if (this.isVideoOn === false && this.localStream) { + console.log('INITIALIZE LOCAL STREAM'); + restartVideoStream(this.localStream); + this.setIsVideoOn(true); + } + if (this.isVideoOn === true && this.localStream) { + console.log('STOP LOCAL STREAM'); + stopVideoStream(this.localStream); + this.setIsVideoOn(false); + } + }; + + toggleAudio = (): void => { + if (this.videoCallInfo.callStatus === 3) { + this.peerInstance?.send( + JSON.stringify({ type: 'isAudioOn', isAudioOn: !this.isAudioOn }) + ); + } + + if (this.isAudioOn === false && this.localStream) { + console.log('INITIALIZE LOCAL STREAM'); + restartAudioStream(this.localStream); + this.setIsAudioOn(true); + } + if (this.isAudioOn === true && this.localStream) { + console.log('STOP LOCAL STREAM'); + stopAudioStream(this.localStream); + this.setIsAudioOn(false); + } + }; +} diff --git a/packages/restapi/src/lib/video/helpers/isJSON.ts b/packages/restapi/src/lib/video/helpers/isJSON.ts new file mode 100644 index 000000000..899622946 --- /dev/null +++ b/packages/restapi/src/lib/video/helpers/isJSON.ts @@ -0,0 +1,9 @@ +const isJSON = (inputStr: string) => { + try { + return JSON.parse(inputStr) && !!inputStr; + } catch (e) { + return false; + } +}; + +export default isJSON; diff --git a/packages/restapi/src/lib/video/helpers/mediaToggle.ts b/packages/restapi/src/lib/video/helpers/mediaToggle.ts new file mode 100644 index 000000000..6fbdd6cab --- /dev/null +++ b/packages/restapi/src/lib/video/helpers/mediaToggle.ts @@ -0,0 +1,23 @@ +export const restartVideoStream = (stream: MediaStream): void => { + console.log('RESTART LOCAL STREAM'); + const vidTracks = stream.getVideoTracks(); + vidTracks.forEach((track) => (track.enabled = true)); +}; + +export const stopVideoStream = (stream: MediaStream): void => { + console.log('STOP LOCAL STREAM'); + const vidTracks = stream.getVideoTracks(); + vidTracks.forEach((track) => (track.enabled = false)); +}; + +export const restartAudioStream = (stream: MediaStream): void => { + console.log('RESTART AUDIO'); + const audTracks = stream.getAudioTracks(); + audTracks.forEach((track) => (track.enabled = true)); +}; + +export const stopAudioStream = (stream: MediaStream): void => { + console.log('STOP AUDIO'); + const audTracks = stream.getAudioTracks(); + audTracks.forEach((track) => (track.enabled = false)); +}; diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts new file mode 100644 index 000000000..8ace78558 --- /dev/null +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -0,0 +1,95 @@ +import { getConnectedUser, getWallet } from '../../chat/helpers'; +import Constants, { ENV } from '../../constants'; +import { getCAIPWithChainId } from '../../helpers'; +import { sendNotification } from '../../payloads'; +import { SignerType } from '../../types'; + +interface VideoCallInfoType { + recipientAddress: string; + senderAddress: string; + chatId: string; + signalingData: any; + /* + callStatus + 0 - call not initiated + 1 - call initiated by the caller address + 2 - call recieved by the receiver address + 3 - call is established + 4 - call ended + */ + status: 1 | 2 | 3 | 4; + env?: ENV; +} + +interface UserInfoType { + signer: SignerType; + chainId: number; + pgpPrivateKey: string | null; +} + +interface videoPayloadType { + recipientAddress: string; + senderAddress: string; + chatId: string; + signalingData?: any; + status: number; +} + +const sendVideoCallNotification = async ( + { signer, chainId, pgpPrivateKey=null, }: UserInfoType, + { + recipientAddress, + senderAddress, + chatId, + signalingData = null, + status, + env = Constants.ENV.PROD, + }: VideoCallInfoType +) => { + try { + const videoPayload: videoPayloadType = { + recipientAddress, + senderAddress, + chatId, + signalingData, + status, + }; + + const senderAddressInCaip = getCAIPWithChainId(senderAddress, chainId); + const recipientAddressInCaip = getCAIPWithChainId( + recipientAddress, + chainId + ); + + const wallet = getWallet({ account: senderAddress, signer }); + const connectedUser = await getConnectedUser(wallet, pgpPrivateKey, env); + + await sendNotification({ + senderType: 1, // for chat notification + signer, + pgpPrivateKey: connectedUser.privateKey!, + chatId, + type: 3, + identityType: 2, + hidden: true, + notification: { + title: 'VideoCall', + body: 'VideoCall', + }, + payload: { + title: 'VideoCall', + body: 'VideoCall', + cta: '', + img: '', + additionalMeta: videoPayload, + }, + recipients: recipientAddressInCaip, + channel: senderAddressInCaip, + env, + }); + } catch (err) { + console.log('Error occured while sending notification for video call', err); + } +}; + +export default sendVideoCallNotification; diff --git a/packages/restapi/src/lib/video/index.ts b/packages/restapi/src/lib/video/index.ts new file mode 100644 index 000000000..b157270a0 --- /dev/null +++ b/packages/restapi/src/lib/video/index.ts @@ -0,0 +1 @@ +export * from './Video'; diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index 45c29f2e4..b0df125c3 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -3,32 +3,25 @@ "@chainsafe/as-sha256@^0.3.1": - "integrity" "sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg==" - "resolved" "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" - "version" "0.3.1" + version "0.3.1" + resolved "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" + integrity sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg== "@chainsafe/persistent-merkle-tree@^0.4.2": - "integrity" "sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ==" - "resolved" "https://registry.npmjs.org/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz" - "version" "0.4.2" + version "0.4.2" + resolved "https://registry.npmjs.org/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz" + integrity sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ== dependencies: "@chainsafe/as-sha256" "^0.3.1" "@chainsafe/ssz@0.9.4": - "integrity" "sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ==" - "resolved" "https://registry.npmjs.org/@chainsafe/ssz/-/ssz-0.9.4.tgz" - "version" "0.9.4" + version "0.9.4" + resolved "https://registry.npmjs.org/@chainsafe/ssz/-/ssz-0.9.4.tgz" + integrity sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ== dependencies: "@chainsafe/as-sha256" "^0.3.1" "@chainsafe/persistent-merkle-tree" "^0.4.2" - "case" "^1.6.3" - -"@cspotcode/source-map-support@^0.8.0": - "integrity" "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==" - "resolved" "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz" - "version" "0.8.1" - dependencies: - "@jridgewell/trace-mapping" "0.3.9" + case "^1.6.3" "@cspotcode/source-map-support@^0.8.0": version "0.8.1" @@ -38,378 +31,18 @@ "@jridgewell/trace-mapping" "0.3.9" "@ethereumjs/rlp@^4.0.1": - "integrity" "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==" - "resolved" "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz" - "version" "4.0.1" + version "4.0.1" + resolved "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz" + integrity sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw== "@ethereumjs/util@^8.0.0": - "integrity" "sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw==" - "resolved" "https://registry.npmjs.org/@ethereumjs/util/-/util-8.0.5.tgz" - "version" "8.0.5" + version "8.0.5" + resolved "https://registry.npmjs.org/@ethereumjs/util/-/util-8.0.5.tgz" + integrity sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw== dependencies: "@chainsafe/ssz" "0.9.4" "@ethereumjs/rlp" "^4.0.1" - "ethereum-cryptography" "^1.1.2" - -"@ethersproject/abi@^5.7.0", "@ethersproject/abi@5.7.0": - "integrity" "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==" - "resolved" "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/abstract-provider@^5.7.0", "@ethersproject/abstract-provider@5.7.0": - "integrity" "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==" - "resolved" "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/networks" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/web" "^5.7.0" - -"@ethersproject/abstract-signer@^5.7.0", "@ethersproject/abstract-signer@5.7.0": - "integrity" "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - -"@ethersproject/address@^5.7.0", "@ethersproject/address@5.7.0": - "integrity" "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==" - "resolved" "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/rlp" "^5.7.0" - -"@ethersproject/base64@^5.7.0", "@ethersproject/base64@5.7.0": - "integrity" "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - -"@ethersproject/basex@^5.7.0", "@ethersproject/basex@5.7.0": - "integrity" "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==" - "resolved" "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - -"@ethersproject/bignumber@^5.7.0", "@ethersproject/bignumber@5.7.0": - "integrity" "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==" - "resolved" "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "bn.js" "^5.2.1" - -"@ethersproject/bytes@^5.7.0", "@ethersproject/bytes@5.7.0": - "integrity" "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==" - "resolved" "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/constants@^5.7.0", "@ethersproject/constants@5.7.0": - "integrity" "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==" - "resolved" "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - -"@ethersproject/contracts@5.7.0": - "integrity" "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==" - "resolved" "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abi" "^5.7.0" - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - -"@ethersproject/hash@^5.7.0", "@ethersproject/hash@5.7.0": - "integrity" "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==" - "resolved" "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/base64" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/hdnode@^5.7.0", "@ethersproject/hdnode@5.7.0": - "integrity" "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==" - "resolved" "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/basex" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/pbkdf2" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - "@ethersproject/signing-key" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/wordlists" "^5.7.0" - -"@ethersproject/json-wallets@^5.7.0", "@ethersproject/json-wallets@5.7.0": - "integrity" "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==" - "resolved" "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/hdnode" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/pbkdf2" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/random" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "aes-js" "3.0.0" - "scrypt-js" "3.0.1" - -"@ethersproject/keccak256@^5.7.0", "@ethersproject/keccak256@5.7.0": - "integrity" "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==" - "resolved" "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "js-sha3" "0.8.0" - -"@ethersproject/logger@^5.7.0", "@ethersproject/logger@5.7.0": - "integrity" "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" - "resolved" "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz" - "version" "5.7.0" - -"@ethersproject/networks@^5.7.0", "@ethersproject/networks@5.7.1": - "integrity" "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz" - "version" "5.7.1" - dependencies: - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/pbkdf2@^5.7.0", "@ethersproject/pbkdf2@5.7.0": - "integrity" "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==" - "resolved" "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - -"@ethersproject/properties@^5.7.0", "@ethersproject/properties@5.7.0": - "integrity" "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==" - "resolved" "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/providers@5.7.2": - "integrity" "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==" - "resolved" "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz" - "version" "5.7.2" - dependencies: - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/base64" "^5.7.0" - "@ethersproject/basex" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/networks" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/random" "^5.7.0" - "@ethersproject/rlp" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/web" "^5.7.0" - "bech32" "1.1.4" - "ws" "7.4.6" - -"@ethersproject/random@^5.7.0", "@ethersproject/random@5.7.0": - "integrity" "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/rlp@^5.7.0", "@ethersproject/rlp@5.7.0": - "integrity" "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==" - "resolved" "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/sha2@^5.7.0", "@ethersproject/sha2@5.7.0": - "integrity" "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==" - "resolved" "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "hash.js" "1.1.7" - -"@ethersproject/signing-key@^5.7.0", "@ethersproject/signing-key@5.7.0": - "integrity" "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==" - "resolved" "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "bn.js" "^5.2.1" - "elliptic" "6.5.4" - "hash.js" "1.1.7" - -"@ethersproject/solidity@5.7.0": - "integrity" "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==" - "resolved" "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/strings@^5.7.0", "@ethersproject/strings@5.7.0": - "integrity" "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==" - "resolved" "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/transactions@^5.7.0", "@ethersproject/transactions@5.7.0": - "integrity" "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/rlp" "^5.7.0" - "@ethersproject/signing-key" "^5.7.0" - -"@ethersproject/units@5.7.0": - "integrity" "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==" - "resolved" "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/wallet@5.7.0": - "integrity" "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==" - "resolved" "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/hdnode" "^5.7.0" - "@ethersproject/json-wallets" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/random" "^5.7.0" - "@ethersproject/signing-key" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/wordlists" "^5.7.0" - -"@ethersproject/web@^5.7.0", "@ethersproject/web@5.7.1": - "integrity" "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==" - "resolved" "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz" - "version" "5.7.1" - dependencies: - "@ethersproject/base64" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/wordlists@^5.7.0", "@ethersproject/wordlists@5.7.0": - "integrity" "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==" - "resolved" "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@jridgewell/resolve-uri@^3.0.3": - "integrity" "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==" - "resolved" "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz" - "version" "3.1.0" - -"@jridgewell/sourcemap-codec@^1.4.10": - "integrity" "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" - "resolved" "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz" - "version" "1.4.14" - -"@jridgewell/trace-mapping@0.3.9": - "integrity" "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==" - "resolved" "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz" - "version" "0.3.9" - dependencies: - "@jridgewell/resolve-uri" "^3.0.3" - "@jridgewell/sourcemap-codec" "^1.4.10" + ethereum-cryptography "^1.1.2" "@jridgewell/resolve-uri@^3.0.3": version "3.1.0" @@ -430,45 +63,45 @@ "@jridgewell/sourcemap-codec" "^1.4.10" "@metamask/eth-sig-util@^5.0.2": - "integrity" "sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q==" - "resolved" "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" - "version" "5.0.2" + version "5.0.2" + resolved "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" + integrity sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q== dependencies: "@ethereumjs/util" "^8.0.0" - "bn.js" "^4.11.8" - "ethereum-cryptography" "^1.1.2" - "ethjs-util" "^0.1.6" - "tweetnacl" "^1.0.3" - "tweetnacl-util" "^0.15.1" - -"@noble/hashes@~1.2.0", "@noble/hashes@1.2.0": - "integrity" "sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==" - "resolved" "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz" - "version" "1.2.0" - -"@noble/secp256k1@~1.7.0", "@noble/secp256k1@1.7.1": - "integrity" "sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==" - "resolved" "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" - "version" "1.7.1" + bn.js "^4.11.8" + ethereum-cryptography "^1.1.2" + ethjs-util "^0.1.6" + tweetnacl "^1.0.3" + tweetnacl-util "^0.15.1" + +"@noble/hashes@1.2.0", "@noble/hashes@~1.2.0": + version "1.2.0" + resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz" + integrity sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ== + +"@noble/secp256k1@1.7.1", "@noble/secp256k1@~1.7.0": + version "1.7.1" + resolved "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" + integrity sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw== "@scure/base@~1.1.0": - "integrity" "sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA==" - "resolved" "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" + integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== "@scure/bip32@1.1.5": - "integrity" "sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==" - "resolved" "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz" - "version" "1.1.5" + version "1.1.5" + resolved "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz" + integrity sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw== dependencies: "@noble/hashes" "~1.2.0" "@noble/secp256k1" "~1.7.0" "@scure/base" "~1.1.0" "@scure/bip39@1.1.1": - "integrity" "sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==" - "resolved" "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz" + integrity sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg== dependencies: "@noble/hashes" "~1.2.0" "@scure/base" "~1.1.0" @@ -584,10 +217,13 @@ argparse@^2.0.1: asn1.js@^5.0.0: version "5.4.1" - resolved "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz" + resolved "https://registry.yarnpkg.com/asn1.js/-/asn1.js-5.4.1.tgz#11a980b84ebb91781ce35b0fdc2ee294e3783f07" integrity sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA== dependencies: - "color-convert" "^1.9.0" + bn.js "^4.0.0" + inherits "^2.0.1" + minimalistic-assert "^1.0.0" + safer-buffer "^2.1.0" assertion-error@^1.1.0: version "1.1.0" @@ -646,7 +282,8 @@ buffer@^6.0.3: resolved "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== dependencies: - "color-convert" "^2.0.1" + base64-js "^1.3.1" + ieee754 "^1.2.1" camelcase@^4.1.0: version "4.1.0" @@ -793,7 +430,7 @@ crypto-js@^4.1.1: resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== -debug@4.3.4: +debug@4.3.4, debug@^4.3.2: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== @@ -839,6 +476,11 @@ end-of-stream@^1.1.0: dependencies: once "^1.4.0" +err-code@^3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/err-code/-/err-code-3.0.1.tgz#a444c7b992705f2b120ee320b09972eef331c920" + integrity sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA== + escalade@^3.1.1: version "3.1.1" resolved "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" @@ -854,353 +496,23 @@ escape-string-regexp@^1.0.5: resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== -"argparse@^2.0.1": - "integrity" "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==" - "resolved" "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" - "version" "2.0.1" - -"asn1.js@^5.0.0": - "integrity" "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==" - "resolved" "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz" - "version" "5.4.1" - dependencies: - "bn.js" "^4.0.0" - "inherits" "^2.0.1" - "minimalistic-assert" "^1.0.0" - "safer-buffer" "^2.1.0" - -"assertion-error@^1.1.0": - "integrity" "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" - "resolved" "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz" - "version" "1.1.0" - -"balanced-match@^1.0.0": - "integrity" "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" - "resolved" "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" - "version" "1.0.2" - -"base64-js@^1.3.1": - "integrity" "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==" - "resolved" "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" - "version" "1.5.1" - -"bech32@1.1.4": - "integrity" "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" - "resolved" "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz" - "version" "1.1.4" - -"binary-extensions@^2.0.0": - "integrity" "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==" - "resolved" "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz" - "version" "2.2.0" - -"bn.js@^4.0.0", "bn.js@^4.11.8", "bn.js@^4.11.9": - "integrity" "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" - "resolved" "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" - "version" "4.12.0" - -"bn.js@^5.2.1": - "integrity" "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" - "resolved" "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" - "version" "5.2.1" - -"brace-expansion@^1.1.7": - "integrity" "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==" - "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" - "version" "1.1.11" - dependencies: - "balanced-match" "^1.0.0" - "concat-map" "0.0.1" - -"brace-expansion@^2.0.1": - "integrity" "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==" - "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "balanced-match" "^1.0.0" - -"braces@~3.0.2": - "integrity" "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==" - "resolved" "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" - "version" "3.0.2" - dependencies: - "fill-range" "^7.0.1" - -"brorand@^1.1.0": - "integrity" "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" - "resolved" "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" - "version" "1.1.0" - -"browser-stdout@1.3.1": - "integrity" "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" - "resolved" "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz" - "version" "1.3.1" - -"buffer@^6.0.3": - "integrity" "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==" - "resolved" "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" - "version" "6.0.3" - dependencies: - "base64-js" "^1.3.1" - "ieee754" "^1.2.1" - -"camelcase@^4.1.0": - "integrity" "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==" - "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz" - "version" "4.1.0" - -"camelcase@^6.0.0": - "integrity" "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==" - "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz" - "version" "6.3.0" - -"case@^1.6.3": - "integrity" "sha512-mzDSXIPaFwVDvZAHqZ9VlbyF4yyXRuX6IvB06WvPYkqJVO24kX1PPhv9bfpKNFZyxYFmmgo03HUiD8iklmJYRQ==" - "resolved" "https://registry.npmjs.org/case/-/case-1.6.3.tgz" - "version" "1.6.3" - -"chai@^4.3.7": - "integrity" "sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A==" - "resolved" "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz" - "version" "4.3.7" - dependencies: - "assertion-error" "^1.1.0" - "check-error" "^1.0.2" - "deep-eql" "^4.1.2" - "get-func-name" "^2.0.0" - "loupe" "^2.3.1" - "pathval" "^1.1.1" - "type-detect" "^4.0.5" - -"chalk@^2.4.1": - "integrity" "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==" - "resolved" "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" - "version" "2.4.2" - dependencies: - "ansi-styles" "^3.2.1" - "escape-string-regexp" "^1.0.5" - "supports-color" "^5.3.0" - -"chalk@^4.1.0": - "integrity" "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==" - "resolved" "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" - "version" "4.1.2" - dependencies: - "ansi-styles" "^4.1.0" - "supports-color" "^7.1.0" - -"check-error@^1.0.2": - "integrity" "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==" - "resolved" "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz" - "version" "1.0.2" - -"chokidar@3.5.3": - "integrity" "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==" - "resolved" "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz" - "version" "3.5.3" - dependencies: - "anymatch" "~3.1.2" - "braces" "~3.0.2" - "glob-parent" "~5.1.2" - "is-binary-path" "~2.1.0" - "is-glob" "~4.0.1" - "normalize-path" "~3.0.0" - "readdirp" "~3.6.0" - optionalDependencies: - "fsevents" "~2.3.2" - -"cliui@^4.0.0": - "integrity" "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==" - "resolved" "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" - "version" "4.1.0" - dependencies: - "string-width" "^2.1.1" - "strip-ansi" "^4.0.0" - "wrap-ansi" "^2.0.0" - -"cliui@^7.0.2": - "integrity" "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==" - "resolved" "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz" - "version" "7.0.4" - dependencies: - "string-width" "^4.2.0" - "strip-ansi" "^6.0.0" - "wrap-ansi" "^7.0.0" - -"code-point-at@^1.0.0": - "integrity" "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==" - "resolved" "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" - "version" "1.1.0" - -"color-convert@^1.9.0": - "integrity" "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==" - "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" - "version" "1.9.3" - dependencies: - "color-name" "1.1.3" - -"color-convert@^2.0.1": - "integrity" "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==" - "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "color-name" "~1.1.4" - -"color-name@~1.1.4": - "integrity" "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" - "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" - "version" "1.1.4" - -"color-name@1.1.3": - "integrity" "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" - "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" - "version" "1.1.3" - -"concat-map@0.0.1": - "integrity" "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" - "resolved" "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" - "version" "0.0.1" - -"create-require@^1.1.0": - "integrity" "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==" - "resolved" "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz" - "version" "1.1.1" - -"cross-spawn@^6.0.0", "cross-spawn@^6.0.5": - "integrity" "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==" - "resolved" "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" - "version" "6.0.5" - dependencies: - "nice-try" "^1.0.4" - "path-key" "^2.0.1" - "semver" "^5.5.0" - "shebang-command" "^1.2.0" - "which" "^1.2.9" - -"crypto-js@^4.1.1": - "integrity" "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" - "resolved" "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" - "version" "4.1.1" - -"debug@4.3.4": - "integrity" "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==" - "resolved" "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" - "version" "4.3.4" - dependencies: - "ms" "2.1.2" - -"decamelize@^1.1.1": - "integrity" "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==" - "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" - "version" "1.2.0" - -"decamelize@^4.0.0": - "integrity" "sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==" - "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" - "version" "4.0.0" - -"deep-eql@^4.1.2": - "integrity" "sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==" - "resolved" "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz" - "version" "4.1.3" - dependencies: - "type-detect" "^4.0.0" - -"diff@^4.0.1": - "integrity" "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" - "resolved" "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz" - "version" "4.0.2" - -"diff@5.0.0": - "integrity" "sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==" - "resolved" "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" - "version" "5.0.0" - -"elliptic@6.5.4": - "integrity" "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==" - "resolved" "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz" - "version" "6.5.4" - dependencies: - "bn.js" "^4.11.9" - "brorand" "^1.1.0" - "hash.js" "^1.0.0" - "hmac-drbg" "^1.0.1" - "inherits" "^2.0.4" - "minimalistic-assert" "^1.0.1" - "minimalistic-crypto-utils" "^1.0.1" - -"emoji-regex@^8.0.0": - "integrity" "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" - "resolved" "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" - "version" "8.0.0" - -"end-of-stream@^1.1.0": - "integrity" "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==" - "resolved" "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz" - "version" "1.4.4" - dependencies: - "once" "^1.4.0" - -"escalade@^3.1.1": - "integrity" "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==" - "resolved" "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" - "version" "3.1.1" - -"escape-string-regexp@^1.0.5": - "integrity" "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==" - "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" - "version" "1.0.5" - -"escape-string-regexp@4.0.0": - "integrity" "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" - "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" - "version" "4.0.0" - -"ethereum-cryptography@^1.1.2": - "integrity" "sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==" - "resolved" "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz" - "version" "1.2.0" +ethereum-cryptography@^1.1.2: + version "1.2.0" + resolved "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz" + integrity sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw== dependencies: "@noble/hashes" "1.2.0" "@noble/secp256k1" "1.7.1" "@scure/bip32" "1.1.5" "@scure/bip39" "1.1.1" -"ethers@^5.6.8": - "integrity" "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==" - "resolved" "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz" - "version" "5.7.2" - dependencies: - "@ethersproject/abi" "5.7.0" - "@ethersproject/abstract-provider" "5.7.0" - "@ethersproject/abstract-signer" "5.7.0" - "@ethersproject/address" "5.7.0" - "@ethersproject/base64" "5.7.0" - "@ethersproject/basex" "5.7.0" - "@ethersproject/bignumber" "5.7.0" - "@ethersproject/bytes" "5.7.0" - "@ethersproject/constants" "5.7.0" - "@ethersproject/contracts" "5.7.0" - "@ethersproject/hash" "5.7.0" - "@ethersproject/hdnode" "5.7.0" - "@ethersproject/json-wallets" "5.7.0" - "@ethersproject/keccak256" "5.7.0" - "@ethersproject/logger" "5.7.0" - "@ethersproject/networks" "5.7.1" - "@ethersproject/pbkdf2" "5.7.0" - "@ethersproject/properties" "5.7.0" - "@ethersproject/providers" "5.7.2" - "@ethersproject/random" "5.7.0" - "@ethersproject/rlp" "5.7.0" - "@ethersproject/sha2" "5.7.0" - "@ethersproject/signing-key" "5.7.0" - "@ethersproject/solidity" "5.7.0" - "@ethersproject/strings" "5.7.0" - "@ethersproject/transactions" "5.7.0" - "@ethersproject/units" "5.7.0" - "@ethersproject/wallet" "5.7.0" - "@ethersproject/web" "5.7.1" - "@ethersproject/wordlists" "5.7.0" +ethjs-util@^0.1.6: + version "0.1.6" + resolved "https://registry.yarnpkg.com/ethjs-util/-/ethjs-util-0.1.6.tgz#f308b62f185f9fe6237132fb2a9818866a5cd536" + integrity sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w== + dependencies: + is-hex-prefixed "1.0.0" + strip-hex-prefix "1.0.0" execa@^1.0.0: version "1.0.0" @@ -1252,6 +564,11 @@ fsevents@~2.3.2: resolved "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz" integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== +get-browser-rtc@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz#d1494e299b00f33fc8e9d6d3343ba4ba99711a2c" + integrity sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ== + get-caller-file@^1.0.1: version "1.0.3" resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz" @@ -1321,9 +638,9 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.1: +inherits@2, inherits@^2.0.1, inherits@^2.0.3: version "2.0.4" - resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== invert-kv@^2.0.0: @@ -1469,7 +786,7 @@ mimic-fn@^2.0.0: minimalistic-assert@^1.0.0: version "1.0.1" - resolved "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" + resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== minimatch@5.0.1: @@ -1572,8 +889,7 @@ openpgp@^5.5.0: resolved "https://registry.npmjs.org/openpgp/-/openpgp-5.5.0.tgz" integrity sha512-SpwcJnxrK9Y0HRM6KxSFqkAEOSWEabCH/c8dII/+y2e5f6KvuDG5ZE7JXaPBaVJNE4VUZZeTphxXDoZD0KOHrw== dependencies: - "is-hex-prefixed" "1.0.0" - "strip-hex-prefix" "1.0.0" + asn1.js "^5.0.0" os-locale@^3.1.0: version "3.1.0" @@ -1670,6 +986,11 @@ pump@^3.0.0: end-of-stream "^1.1.0" once "^1.3.1" +queue-microtask@^1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" + integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== + randombytes@^2.1.0: version "2.1.0" resolved "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz" @@ -1677,6 +998,15 @@ randombytes@^2.1.0: dependencies: safe-buffer "^5.1.0" +readable-stream@^3.6.0: + version "3.6.2" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" + integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + readdirp@~3.6.0: version "3.6.0" resolved "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" @@ -1694,14 +1024,14 @@ require-main-filename@^1.0.1: resolved "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz" integrity sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug== -safe-buffer@^5.1.0: +safe-buffer@^5.1.0, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== safer-buffer@^2.1.0: version "2.1.2" - resolved "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" + resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== semver@^5.5.0: @@ -1738,6 +1068,19 @@ signal-exit@^3.0.0: resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== +simple-peer@^9.11.1: + version "9.11.1" + resolved "https://registry.yarnpkg.com/simple-peer/-/simple-peer-9.11.1.tgz#9814d5723f821b778b7fb011bdefcbd1e788e6cc" + integrity sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw== + dependencies: + buffer "^6.0.3" + debug "^4.3.2" + err-code "^3.0.1" + get-browser-rtc "^1.1.0" + queue-microtask "^1.2.3" + randombytes "^2.1.0" + readable-stream "^3.6.0" + string-width@^1.0.1: version "1.0.2" resolved "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" @@ -1764,6 +1107,13 @@ string-width@^4.1.0, string-width@^4.2.0: is-fullwidth-code-point "^3.0.0" strip-ansi "^6.0.1" +string_decoder@^1.1.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" + integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== + dependencies: + safe-buffer "~5.2.0" + strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" @@ -1795,13 +1145,7 @@ strip-hex-prefix@1.0.0: resolved "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz" integrity sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A== dependencies: - "cross-spawn" "^6.0.0" - "get-stream" "^4.0.0" - "is-stream" "^1.1.0" - "npm-run-path" "^2.0.0" - "p-finally" "^1.0.0" - "signal-exit" "^3.0.0" - "strip-eof" "^1.0.0" + is-hex-prefixed "1.0.0" strip-json-comments@3.1.1: version "3.1.1" @@ -1875,6 +1219,11 @@ typescript@^5.0.2: resolved "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz" integrity sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw== +util-deprecate@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" + integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== + v8-compile-cache-lib@^3.0.1: version "3.0.1" resolved "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz" From 7aa9bffb9eab35428eafb159ba8c5c5aa2d0e171 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 4 May 2023 18:56:28 +0530 Subject: [PATCH 051/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-beta.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 9efeee6a9..9fc060054 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-beta.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-beta.2) (2023-05-04) + + +### Bug Fixes + +* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) + + + ## [0.0.1-beta.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.10...restapi-0.0.1-beta.1) (2023-05-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 332368835..24a498037 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-beta.1", + "version": "0.0.1-beta.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 627c7f4963830f61c867c153d98823ac55a50934 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 4 May 2023 18:56:48 +0530 Subject: [PATCH 052/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-beta.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 9fc060054..b20e37cc2 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -11,6 +11,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [0.0.1-beta.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-beta.2) (2023-05-04) + + +### Bug Fixes + +* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) + + + ## [0.0.1-beta.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.10...restapi-0.0.1-beta.1) (2023-05-04) From 87f08c5d7d604660ab705767fdf35770b7a19aaa Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 4 May 2023 19:17:57 +0530 Subject: [PATCH 053/298] Alpha deployment (#357) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.1 * ci(restapi): 🎉 cut release to restapi-v1.0.1 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * fix: success progressHook * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.1.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * fix(component): dummy * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.2.1 * fix: local for local development (#295) Co-Authored-By: aman035 * fix: version update * ci(restapi): 🎉 cut release to restapi-v1.2.2 * ci(restapi): 🎉 cut release to restapi-v1.2.3 * ci(restapi): 🎉 cut release to restapi-v1.2.4 * ci(restapi): 🎉 cut release to restapi-v1.2.5 * ci(restapi): 🎉 cut release to restapi-v1.2.6 * ci(restapi): 🎉 cut release to restapi-v1.2.7 * ci(socket): 🎉 cut release to socket-v0.5.0 * fix: test commit * ci(restapi): 🎉 cut release to restapi-v1.2.8 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.1 * fix: added ci-version-beta * fix: added ci-version-beta * ci(restapi): 🎉 cut beta release to restapi-v1.2.9 * fix: added releaseType * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.1 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.2 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.2 --------- Co-authored-by: aman035 --- packages/restapi/CHANGELOG.md | 18 ++++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 9efeee6a9..b20e37cc2 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,24 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-beta.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-beta.2) (2023-05-04) + + +### Bug Fixes + +* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) + + + +## [0.0.1-beta.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-beta.2) (2023-05-04) + + +### Bug Fixes + +* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) + + + ## [0.0.1-beta.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.10...restapi-0.0.1-beta.1) (2023-05-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 332368835..24a498037 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-beta.1", + "version": "0.0.1-beta.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 69763b8da2cf3e92bb85908e4f46a72b650c9dba Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Thu, 4 May 2023 19:36:07 +0530 Subject: [PATCH 054/298] fix: added pagination and deprecation tag (#346) --- .../demoreact/src/app/ChatTest/GetChats.tsx | 31 +++++++++++++++ .../src/app/ChatTest/GetRequests.tsx | 37 ++++++++++++++++-- packages/restapi/src/lib/chat/chats.ts | 19 ++++++++-- .../restapi/src/lib/chat/helpers/inbox.ts | 38 +++++++++++++++---- packages/restapi/src/lib/chat/requests.ts | 32 ++++++++++++---- packages/restapi/src/lib/types/index.ts | 2 + 6 files changed, 137 insertions(+), 22 deletions(-) diff --git a/packages/demoreact/src/app/ChatTest/GetChats.tsx b/packages/demoreact/src/app/ChatTest/GetChats.tsx index 0b0709fef..5cedb91cd 100644 --- a/packages/demoreact/src/app/ChatTest/GetChats.tsx +++ b/packages/demoreact/src/app/ChatTest/GetChats.tsx @@ -17,10 +17,21 @@ const GetChatsTest = () => { const [getChatsResponse, setGetChatsResponse] = useState(''); const [toDecrypt, setToDecrypt] = useState(false); const [account, setAccount] = useState(acc); + const [page, setPage] = useState(1); + const [limit, setLimit] = useState(10); + const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; + const updatePage = (e: React.SyntheticEvent) => { + setPage(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateLimit = (e: React.SyntheticEvent) => { + setLimit(parseInt((e.target as HTMLInputElement).value)); + }; + const updateToDecrypt = (e: React.SyntheticEvent) => { setToDecrypt((e.target as HTMLInputElement).checked); }; @@ -43,6 +54,8 @@ const GetChatsTest = () => { pgpPrivateKey: pvtkey, toDecrypt, env, + page, + limit, }); setGetChatsResponse(response); @@ -71,6 +84,24 @@ const GetChatsTest = () => { style={{ width: 400, height: 30 }} /> + + + + + + + + { const [getRequestsResponse, setGetRequestsResponse] = useState(''); const [toDecrypt, setToDecrypt] = useState(false); const [account, setAccount] = useState(acc); + const [page, setPage] = useState(1); + const [limit, setLimit] = useState(10); - const updateToDecrypt = (e: React.SyntheticEvent) => { - setToDecrypt((e.target as HTMLInputElement).checked); - }; const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; + + const updatePage = (e: React.SyntheticEvent) => { + setPage(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateLimit = (e: React.SyntheticEvent) => { + setLimit(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateToDecrypt = (e: React.SyntheticEvent) => { + setToDecrypt((e.target as HTMLInputElement).checked); + }; const testGetRequests = async () => { try { setLoading(true); @@ -44,6 +55,8 @@ const GetRequestsTest = () => { pgpPrivateKey: pvtkey, toDecrypt, env, + page, + limit, }); setGetRequestsResponse(response); @@ -81,6 +94,24 @@ const GetRequestsTest = () => { style={{ width: 400, height: 30 }} /> + + + + + + + + get requests diff --git a/packages/restapi/src/lib/chat/chats.ts b/packages/restapi/src/lib/chat/chats.ts index 3b41360d1..20cc2624b 100644 --- a/packages/restapi/src/lib/chat/chats.ts +++ b/packages/restapi/src/lib/chat/chats.ts @@ -1,8 +1,8 @@ import axios from 'axios'; -import { getAPIBaseUrls, isValidETHAddress, walletToPCAIP10 } from '../helpers'; +import { getAPIBaseUrls, isValidETHAddress } from '../helpers'; import Constants, { ENV } from '../constants'; import { IFeeds } from '../types'; -import { getInboxLists, getUserDID } from './helpers'; +import { getInboxLists, getUserDID, addDeprecatedInfo } from './helpers'; export type ChatsOptionsType = { account: string; @@ -11,6 +11,14 @@ export type ChatsOptionsType = { * If true, the method will return decrypted message content in response */ toDecrypt?: boolean; + /** + * page index - default 1 + */ + page?: number; + /** + * no of items per page - default 10 - max 30 + */ + limit?: number; /** * Environment variable */ @@ -26,19 +34,22 @@ export const chats = async (options: ChatsOptionsType): Promise => { pgpPrivateKey, env = Constants.ENV.PROD, toDecrypt = false, + page = 1, + limit = 10, } = options || {}; if (!isValidETHAddress(account)) { throw new Error(`Invalid address!`); } const user = await getUserDID(account, env); const API_BASE_URL = getAPIBaseUrls(env); - const apiEndpoint = `${API_BASE_URL}/v1/chat/users/${user}/chats`; + const apiEndpoint = `${API_BASE_URL}/v1/chat/users/${user}/chats?page=${page}&limit=${limit}`; const requestUrl = `${apiEndpoint}`; try { const response = await axios.get(requestUrl); const chats: IFeeds[] = response.data.chats; + const updatedChats = addDeprecatedInfo(chats); const feeds: IFeeds[] = await getInboxLists({ - lists: chats, + lists: updatedChats, user: user, toDecrypt, pgpPrivateKey, diff --git a/packages/restapi/src/lib/chat/helpers/inbox.ts b/packages/restapi/src/lib/chat/helpers/inbox.ts index 7c039014b..6a6d58aff 100644 --- a/packages/restapi/src/lib/chat/helpers/inbox.ts +++ b/packages/restapi/src/lib/chat/helpers/inbox.ts @@ -1,4 +1,4 @@ -import Constants, {ENV} from '../../constants'; +import Constants, { ENV } from '../../constants'; import { decryptMessage, pCAIP10ToWallet } from '../../helpers'; import { IFeeds, IMessageIPFS, IUser } from '../../types'; import { get as getUser } from '../../user'; @@ -10,13 +10,13 @@ type InboxListsType = { user: string; //caip10 toDecrypt: boolean; pgpPrivateKey?: string; - env?: ENV; + env?: ENV; }; type DecryptConverationType = { messages: IMessageIPFS[]; connectedUser: IUser; //caip10 pgpPrivateKey?: string; - env?: ENV; + env?: ENV; }; export const getInboxLists = async ( @@ -49,10 +49,14 @@ export const getInboxLists = async ( sigType: '', signature: '', toCAIP10: '', - toDID: '' - } + toDID: '', + }; } - feeds.push({ ...list, msg: message, groupInformation: list.groupInformation }); + feeds.push({ + ...list, + msg: message, + groupInformation: list.groupInformation, + }); } if (toDecrypt) @@ -92,8 +96,28 @@ export const decryptConversation = async (options: DecryptConverationType) => { signatureValidationPubliKey: signatureValidationPubliKey, pgpPrivateKey, message: message, - }); + }); } } return messages; }; + +export const addDeprecatedInfo = (chats: IFeeds[]): IFeeds[] => { + return Object.values( + chats.reduce((acc: any, curr: IFeeds) => { + const didWithoutTimestamp = curr.did.split(':').slice(0, 5).join(':'); + acc[didWithoutTimestamp] = acc[didWithoutTimestamp] || []; + acc[didWithoutTimestamp].push(curr); + return acc; + }, {}) + ).flatMap((group: any) => { + const highestTimestampObj = group.reduce((acc: any, curr: IFeeds) => + curr.did.split(':')[5] > acc.did.split(':')[5] ? curr : acc + ); + return group.map((obj: IFeeds) => + obj.did === highestTimestampObj.did || obj.did.startsWith('eip155:') + ? obj + : { ...obj, deprecated: true, deprecatedCode: 'NFT Owner Changed' } + ); + }); +}; diff --git a/packages/restapi/src/lib/chat/requests.ts b/packages/restapi/src/lib/chat/requests.ts index 45575ccb7..773539de7 100644 --- a/packages/restapi/src/lib/chat/requests.ts +++ b/packages/restapi/src/lib/chat/requests.ts @@ -1,8 +1,8 @@ import axios from 'axios'; -import { getAPIBaseUrls, isValidETHAddress, walletToPCAIP10 } from '../helpers'; -import Constants, {ENV} from '../constants'; +import { getAPIBaseUrls, isValidETHAddress } from '../helpers'; +import Constants, { ENV } from '../constants'; import { IFeeds } from '../types'; -import { getInboxLists, getUserDID } from './helpers'; +import { addDeprecatedInfo, getInboxLists, getUserDID } from './helpers'; export type RequestOptionsType = { account: string; @@ -11,6 +11,14 @@ export type RequestOptionsType = { * If true, the method will return decrypted message content in response */ toDecrypt?: boolean; + /** + * page index - default 1 + */ + page?: number; + /** + * no of items per page - default 10 - max 30 + */ + limit?: number; /** * Environment variable */ @@ -18,24 +26,32 @@ export type RequestOptionsType = { }; /** - * The first time an address wants to send a message to another peer, the address sends an intent request. This first message shall not land in this peer Inbox but in its Request box. + * The first time an address wants to send a message to another peer, the address sends an intent request. This first message shall not land in this peer Inbox but in its Request box. * This function will return all the chats that landed on the address' Request box. The user can then approve the request or ignore it for now. */ export const requests = async ( options: RequestOptionsType ): Promise => { - const { account, pgpPrivateKey, env = Constants.ENV.PROD, toDecrypt = false } = options || {}; + const { + account, + pgpPrivateKey, + env = Constants.ENV.PROD, + toDecrypt = false, + page = 1, + limit = 10, + } = options || {}; const user = await getUserDID(account, env); const API_BASE_URL = getAPIBaseUrls(env); - const apiEndpoint = `${API_BASE_URL}/v1/chat/users/${user}/requests`; + const apiEndpoint = `${API_BASE_URL}/v1/chat/users/${user}/requests?page=${page}&limit=${limit}`; try { if (!isValidETHAddress(user)) { throw new Error(`Invalid address!`); } const response = await axios.get(apiEndpoint); const requests: IFeeds[] = response.data.requests; + const updatedRequests = addDeprecatedInfo(requests); const Feeds: IFeeds[] = await getInboxLists({ - lists: requests, + lists: updatedRequests, user, toDecrypt, pgpPrivateKey, @@ -47,4 +63,4 @@ export const requests = async ( console.error(`[Push SDK] - API ${requests.name}: `, err); throw Error(`[Push SDK] - API ${requests.name}: ${err}`); } -}; \ No newline at end of file +}; diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 8a8a2eaa4..8be33dfbe 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -149,6 +149,8 @@ export interface IFeeds { cid?: string; chatId?: string; groupInformation?: GroupDTO; + deprecated?: boolean; // scope only at sdk level + deprecatedCode?: string; // scope only at sdk level } export interface IUser { did: string; From 008e6d08d75fdacf19f1674cc2b8bd82091fa31f Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Thu, 4 May 2023 19:36:17 +0530 Subject: [PATCH 055/298] fix: eip191v2 signatures for create and auth.update (#353) --- .../restapi/src/lib/chat/helpers/crypto.ts | 11 +++-- .../restapi/src/lib/chat/helpers/service.ts | 49 +++++++++++++++---- 2 files changed, 45 insertions(+), 15 deletions(-) diff --git a/packages/restapi/src/lib/chat/helpers/crypto.ts b/packages/restapi/src/lib/chat/helpers/crypto.ts index 8eba063e5..2e04ad277 100644 --- a/packages/restapi/src/lib/chat/helpers/crypto.ts +++ b/packages/restapi/src/lib/chat/helpers/crypto.ts @@ -1,6 +1,5 @@ import * as PGP from './pgp'; import * as AES from './aes'; -import { ethers } from 'ethers'; import { IConnectedUser, IFeeds, @@ -281,7 +280,8 @@ export const getEncryptedRequest = async ( export const getEip191Signature = async ( wallet: walletType, - message: string + message: string, + version: 'v1' | 'v2' = 'v1' ) => { if (!wallet?.signer) { console.warn('This method is deprecated. Provide signer in the function'); @@ -289,9 +289,10 @@ export const getEip191Signature = async ( return { signature: 'xyz', sigType: 'a' }; } const _signer = wallet?.signer; - // sign a message using EIP191 - const signedMessage = await _signer?.signMessage(message); - return { verificationProof: `eip191:${signedMessage}` }; + // EIP191 signature + const signature = await _signer?.signMessage(message); + const sigType = version === 'v1' ? 'eip191' : 'eip191v2'; + return { verificationProof: `${sigType}:${signature}` }; }; export const getEip712Signature = async ( diff --git a/packages/restapi/src/lib/chat/helpers/service.ts b/packages/restapi/src/lib/chat/helpers/service.ts index 77655d27f..69e6aca56 100644 --- a/packages/restapi/src/lib/chat/helpers/service.ts +++ b/packages/restapi/src/lib/chat/helpers/service.ts @@ -56,18 +56,33 @@ export const createUserService = async (options: CreateUserOptionsType) => { did: walletToPCAIP10(user), publicKey, encryptedPrivateKey, + + // DEPRECATED in eip191v2 + + // encryptionType, + // name: '', + // encryptedPassword: encryptedPassword, + // nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, + }; + + const hash = generateHash(data); + + const signatureObj = await getEip191Signature(wallet!, hash, 'v2'); + + // NOTE - To be removed after backend route changes + const updatedData = { + caip10: walletToPCAIP10(user), + did: walletToPCAIP10(user), + publicKey, + encryptedPrivateKey, encryptionType, name: '', encryptedPassword: encryptedPassword, nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, }; - const hash = generateHash(data); - - const signatureObj = await getEip191Signature(wallet!, hash); - const body = { - ...data, + ...updatedData, ...signatureObj, }; @@ -110,18 +125,32 @@ export const authUpdateUserService = async (options: CreateUserOptionsType) => { caip10: walletToPCAIP10(user), publicKey, encryptedPrivateKey, + + // DEPRECATED in eip191v2 + + // encryptionType, + // name, + // encryptedPassword, + // nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, + }; + + const hash = generateHash(data); + + const signatureObj = await getEip191Signature(wallet!, hash, 'v2'); + + // NOTE - To be removed after backend route changes + const updatedData = { + caip10: walletToPCAIP10(user), + publicKey, + encryptedPrivateKey, encryptionType, name, encryptedPassword, nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, }; - const hash = generateHash(data); - - const signatureObj = await getEip191Signature(wallet!, hash); - const body = { - ...data, + ...updatedData, ...signatureObj, }; From 31daee3a5aa913705d1dec8210c0412cd89c94c9 Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Thu, 4 May 2023 19:39:32 +0530 Subject: [PATCH 056/298] fix: changed Definitions for auth.update and upgrade (#351) * fix: changed Definitions for auth.update and upgrade * fix: chnaged demoreact * fix: revert code no --- .../{UpgradeUser.tsx => AuthUpdateUser.tsx} | 69 ++++++- .../demoreact/src/app/ChatTest/ChatTest.tsx | 4 +- packages/demoreact/src/app/app.tsx | 4 +- packages/restapi/src/lib/constants.ts | 8 + .../restapi/src/lib/user/auth.updateUser.ts | 194 ++++++++++++------ packages/restapi/src/lib/user/upgradeUser.ts | 110 ++-------- 6 files changed, 223 insertions(+), 166 deletions(-) rename packages/demoreact/src/app/ChatTest/{UpgradeUser.tsx => AuthUpdateUser.tsx} (62%) diff --git a/packages/demoreact/src/app/ChatTest/UpgradeUser.tsx b/packages/demoreact/src/app/ChatTest/AuthUpdateUser.tsx similarity index 62% rename from packages/demoreact/src/app/ChatTest/UpgradeUser.tsx rename to packages/demoreact/src/app/ChatTest/AuthUpdateUser.tsx index d970e135c..46202cb21 100644 --- a/packages/demoreact/src/app/ChatTest/UpgradeUser.tsx +++ b/packages/demoreact/src/app/ChatTest/AuthUpdateUser.tsx @@ -8,7 +8,6 @@ import { import Loader from '../components/Loader'; import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; -import { walletToPCAIP10 } from '../helpers'; import ChatTest from './ChatTest'; import { ethers } from 'ethers'; @@ -19,13 +18,16 @@ type ProgressHookType = { level: 'INFO' | 'SUCCESS' | 'WARN' | 'ERROR'; }; -const UpgradeUserTest = () => { +const AuthUpdateUserTest = () => { const { account: acc, library } = useContext(Web3Context); const { env, isCAIP } = useContext(EnvContext); const [isLoading, setLoading] = useState(false); const [connectedUser, setConnectedUser] = useState({}); const [progress, setProgress] = useState(null); const [account, setAccount] = useState(acc); + const [pgpPrivKey, setPgpPrivKey] = useState(''); + const [pgpPubKey, setPgpPubKey] = useState(''); + const [pgpEncVersion, setPgpEncVersion] = useState(''); const [password, setPassword] = useState('#TestPassword1'); const handleProgress = (progress: ProgressHookType) => { setProgress(progress); @@ -34,6 +36,18 @@ const UpgradeUserTest = () => { setAccount((e.target as HTMLInputElement).value); }; + const updatePgpPrivKey = (e: React.SyntheticEvent) => { + setPgpPrivKey((e.target as HTMLInputElement).value); + }; + + const updatePgpPubKey = (e: React.SyntheticEvent) => { + setPgpPubKey((e.target as HTMLInputElement).value); + }; + + const updatePgpEncVersion = (e: React.SyntheticEvent) => { + setPgpEncVersion((e.target as HTMLInputElement).value); + }; + const updatePassword = (e: React.SyntheticEvent) => { setPassword((e.target as HTMLInputElement).value); }; @@ -46,8 +60,11 @@ const UpgradeUserTest = () => { case 0: { const librarySigner = await library.getSigner(); - response = await PushAPI.user.upgrade({ + response = await PushAPI.user.auth.update({ signer: librarySigner, + pgpPrivateKey: pgpPrivKey, + pgpPublicKey: pgpPubKey, + pgpEncryptionVersion: pgpEncVersion as any, account: account, env, additionalMeta: { @@ -63,11 +80,18 @@ const UpgradeUserTest = () => { const walletPvtKey = ''; const Pkey = `0x${walletPvtKey}`; const pvtKeySigner = new ethers.Wallet(Pkey); - response = await PushAPI.user.create({ + response = await PushAPI.user.auth.update({ signer: pvtKeySigner, + pgpPrivateKey: pgpPrivKey, + pgpPublicKey: pgpPubKey, + pgpEncryptionVersion: pgpEncVersion as any, account: account, env, - progressHook: handleProgress, + additionalMeta: { + NFTPGP_V1: { + password: password, + }, + }, }); } break; @@ -86,11 +110,38 @@ const UpgradeUserTest = () => { return (
-

Upgrade User Test page ( For NFT transfers or upgradation to v3 )

+

Auth Update User Test page

+ + + + + + + + + + + + { testCreateUser(0)}> - Create user with address & library signer + Auth Update user with address & library signer testCreateUser(1)}> - Create user with private key signer + Auth Update user with private key signer {progress && ( @@ -141,4 +192,4 @@ const UpgradeUserTest = () => { ); }; -export default UpgradeUserTest; +export default AuthUpdateUserTest; diff --git a/packages/demoreact/src/app/ChatTest/ChatTest.tsx b/packages/demoreact/src/app/ChatTest/ChatTest.tsx index 20d1d9e6f..a40716305 100644 --- a/packages/demoreact/src/app/ChatTest/ChatTest.tsx +++ b/packages/demoreact/src/app/ChatTest/ChatTest.tsx @@ -35,8 +35,8 @@ const ChatTest = () => { USER.CREATE - - USER.UPGRADE + + USER.AUTH.UPDATE CHAT.SEND diff --git a/packages/demoreact/src/app/app.tsx b/packages/demoreact/src/app/app.tsx index fe2ca08c3..bc86ddc73 100644 --- a/packages/demoreact/src/app/app.tsx +++ b/packages/demoreact/src/app/app.tsx @@ -30,7 +30,7 @@ import CreateGroupTest from './ChatTest/CreateGroupTest'; import UpdateGroupTest from './ChatTest/UpdateGroupTest'; import GetGroupTest from './ChatTest/GetGroupTest'; import GetUsersBatchTest from './ChatTest/GetUsersBatchTest'; -import UpgradeUserTest from './ChatTest/UpgradeUser'; +import AuthUpdateUserTest from './ChatTest/AuthUpdateUser'; import { Buffer } from 'buffer'; import { ENV } from './helpers'; @@ -235,7 +235,7 @@ export function App() { } /> } /> } /> - } /> + } /> } /> } /> } /> diff --git a/packages/restapi/src/lib/constants.ts b/packages/restapi/src/lib/constants.ts index 58b551ab1..a9f6374c4 100644 --- a/packages/restapi/src/lib/constants.ts +++ b/packages/restapi/src/lib/constants.ts @@ -8,8 +8,16 @@ export enum ENV { LOCAL = 'local', } +export enum ENCRYPTION_TYPE { + PGP_V1 = 'x25519-xsalsa20-poly1305', + PGP_V2 = 'aes256GcmHkdfSha256', + PGP_V3 = 'eip191-aes256-gcm-hkdf-sha256', + NFTPGP_V1 = 'pgpv1:nft', +} + const Constants = { ENV, + ENCRYPTION_TYPE, PAGINATION: { INITIAL_PAGE: 1, LIMIT: 10, diff --git a/packages/restapi/src/lib/user/auth.updateUser.ts b/packages/restapi/src/lib/user/auth.updateUser.ts index 7d259cff2..3034f3d6c 100644 --- a/packages/restapi/src/lib/user/auth.updateUser.ts +++ b/packages/restapi/src/lib/user/auth.updateUser.ts @@ -1,89 +1,157 @@ -import axios from 'axios'; import { authUpdateUserService, getAccountAddress, getWallet, } from '../chat/helpers'; -import Constants, { ENV } from '../constants'; -import { getAPIBaseUrls, isValidETHAddress, walletToPCAIP10 } from '../helpers'; -import { SignerType, IUser, ProgressHookType } from '../types'; +import Constants, { ENV, ENCRYPTION_TYPE } from '../constants'; +import { + encryptPGPKey, + isValidETHAddress, + preparePGPPublicKey, + walletToPCAIP10, +} from '../helpers'; +import { + SignerType, + IUser, + ProgressHookType, + encryptedPrivateKeyType, + encryptedPrivateKeyTypeV2, +} from '../types'; +import { get } from './getUser'; + +//used only in progressHook to abstract encryption algotrithms +enum ENCRYPTION_TYPE_VERSION { + 'x25519-xsalsa20-poly1305' = 'PGP_V1', + 'aes256GcmHkdfSha256' = 'PGP_V2', + 'eip191-aes256-gcm-hkdf-sha256' = 'PGP_V3', + 'pgpv1:nft' = 'NFTPGP_V1', +} -/** - * Used for updating the encryption keys of a Push Profile - */ export type AuthUpdateProps = { - encryptedPgpPrivateKey: string; + pgpPrivateKey: string; // decrypted pgp priv key + pgpEncryptionVersion: ENCRYPTION_TYPE; signer: SignerType; + pgpPublicKey: string; account?: string; - pgpPublicKey?: string; - name?: string; env?: ENV; + additionalMeta?: { + NFTPGP_V1?: { + password: string; //new nft profile password + }; + }; progressHook?: (progress: ProgressHookType) => void; }; +/** + * Updation of encryption keys of a Push Profile to a specific version + */ export const update = async (options: AuthUpdateProps): Promise => { const { - env = Constants.ENV.PROD, - account = null, + pgpPrivateKey, + pgpEncryptionVersion, signer, - encryptedPgpPrivateKey, - pgpPublicKey = null, - name = null, + pgpPublicKey, + account = null, + env = Constants.ENV.PROD, + additionalMeta, progressHook, } = options || {}; - if (signer == null) { - throw new Error(`Signer is necessary!`); - } + try { + const wallet = getWallet({ account, signer }); + const address = await getAccountAddress(wallet); - const wallet = getWallet({ account, signer }); - const address = await getAccountAddress(wallet); + if (!isValidETHAddress(address)) { + throw new Error(`Invalid address!`); + } - if (!isValidETHAddress(address)) { - throw new Error(`Invalid address!`); - } + const caip10 = walletToPCAIP10(address); + const user = await get({ account: caip10, env: env }); - const caip10 = walletToPCAIP10(address); - const API_BASE_URL = getAPIBaseUrls(env); - const requestUrl = `${API_BASE_URL}/v1/users/?caip10=${caip10}`; - const user = (await axios.get(requestUrl)).data; + if (!user || !user.encryptedPrivateKey) { + throw new Error('User not Found!'); + } - if (!user || !user.did) { - throw new Error('User not Found!'); - } + // Report Progress + progressHook?.({ + progressId: 'PUSH-AUTH-UPDATE-01', + progressTitle: 'Generating New Profile Signature', + progressInfo: `Trying to Update Push Chat Keys to ${ENCRYPTION_TYPE_VERSION[pgpEncryptionVersion]} version. Please sign the message to continue.`, + level: 'INFO', + }); - const { version: encryptionType } = JSON.parse(encryptedPgpPrivateKey); - - const body = { - user: user.did, - wallet, - name: name ? name : '', - encryptedPassword: null, - nftOwner: - encryptionType === Constants.ENC_TYPE_V4 - ? walletToPCAIP10((await signer?.getAddress()) as string) - : null, // check for nft, - publicKey: pgpPublicKey ? pgpPublicKey : user.publicKey, - encryptedPrivateKey: encryptedPgpPrivateKey, - encryptionType: encryptionType, - env, - }; + const signedPublicKey = await preparePGPPublicKey( + pgpEncryptionVersion, + pgpPublicKey, + wallet + ); + + // Report Progress + progressHook?.({ + progressId: 'PUSH-AUTH-UPDATE-02', + progressTitle: 'Generating New Encrypted Profile', + progressInfo: `Trying to Update Push Chat Keys to ${ENCRYPTION_TYPE_VERSION[pgpEncryptionVersion]} version. Encrypting Push Chat Keys with specified version. Please sign the message to continue.`, + level: 'INFO', + }); + + const encryptedPgpPrivateKey: encryptedPrivateKeyType = await encryptPGPKey( + pgpEncryptionVersion, + pgpPrivateKey, + wallet, + additionalMeta + ); - // Report Progress - progressHook?.({ - progressId: 'PUSH-UPDATE-01', - progressTitle: 'Syncing Updated Profile', - progressInfo: - 'Please sign the message to continue. Steady lads, chat is almost ready!', - level: 'INFO', - }); - const updatedUser = await authUpdateUserService(body); - // Report Progress - progressHook?.({ - progressId: 'PUSH-UPDATE-02', - progressTitle: 'Update Completed, Welcome to Push Chat', - progressInfo: '', - level: 'SUCCESS', - }); - return updatedUser; + if (pgpEncryptionVersion === ENCRYPTION_TYPE.NFTPGP_V1) { + const encryptedPassword: encryptedPrivateKeyTypeV2 = await encryptPGPKey( + ENCRYPTION_TYPE.PGP_V3, + additionalMeta?.NFTPGP_V1?.password as string, + wallet, + additionalMeta + ); + encryptedPgpPrivateKey.encryptedPassword = encryptedPassword; + } + + const body = { + user: user.did, + wallet, + name: user.name ? user.name : '', + encryptedPassword: null, + nftOwner: + pgpEncryptionVersion === ENCRYPTION_TYPE.NFTPGP_V1 + ? walletToPCAIP10((await signer?.getAddress()) as string) + : null, // check for nft, + publicKey: signedPublicKey, + encryptedPrivateKey: JSON.stringify(encryptedPgpPrivateKey), + encryptionType: pgpEncryptionVersion, + env, + }; + + // Report Progress + progressHook?.({ + progressId: 'PUSH-AUTH-UPDATE-03', + progressTitle: 'Syncing Updated Profile', + progressInfo: + 'Please sign the message to continue. Steady lads, chat is almost ready!', + level: 'INFO', + }); + + const updatedUser = await authUpdateUserService(body); + + // Report Progress + progressHook?.({ + progressId: 'PUSH-AUTH-UPDATE-04', + progressTitle: 'Update Completed, Welcome to Push Chat', + progressInfo: '', + level: 'SUCCESS', + }); + return updatedUser; + } catch (err) { + progressHook?.({ + progressId: 'PUSH-ERROR-00', + progressTitle: 'Non Specific Error', + progressInfo: `[Push SDK] - API - Error - API auth.update User() -: ${err}`, + level: 'ERROR', + }); + throw Error(`[Push SDK] - API - Error - API auth.update User() -: ${err}`); + } }; diff --git a/packages/restapi/src/lib/user/upgradeUser.ts b/packages/restapi/src/lib/user/upgradeUser.ts index ffad7da49..94e7da209 100644 --- a/packages/restapi/src/lib/user/upgradeUser.ts +++ b/packages/restapi/src/lib/user/upgradeUser.ts @@ -1,19 +1,7 @@ import { getAccountAddress, getWallet } from '../chat/helpers'; import Constants, { ENV } from '../constants'; -import { - isValidETHAddress, - encryptPGPKey, - preparePGPPublicKey, - decryptPGPKey, - isValidCAIP10NFTAddress, -} from '../helpers'; -import { - SignerType, - encryptedPrivateKeyType, - IUser, - ProgressHookType, - encryptedPrivateKeyTypeV2, -} from '../types'; +import { isValidETHAddress, decryptPGPKey } from '../helpers'; +import { SignerType, IUser, ProgressHookType } from '../types'; import { update } from './auth.updateUser'; import { get } from './getUser'; @@ -28,12 +16,9 @@ export type UpgradeUserProps = { }; progressHook?: (progress: ProgressHookType) => void; }; + /** - * Used for Upgrading Push Profile keys. - * Current Upgrade Cases - * 1. ENC_TYPE_V1 -> ENC_TYPE_V3 - * 2. ENC_TYPE_V2 -> ENC_TYPE_V3 - * 3. ENC_TYPE_V4 -> ENC_TYPE_V4 ( chat continuation on NFT Transfer ) + * Upgrades the Push Profile keys from current version to recommended version * @param options * @returns */ @@ -41,16 +26,12 @@ export const upgrade = async (options: UpgradeUserProps): Promise => { const { env = Constants.ENV.PROD, account = null, - signer = null, + signer, additionalMeta, progressHook, } = options || {}; try { - if (signer == null) { - throw new Error(`Signer is necessary!`); - } - const wallet = getWallet({ account, signer }); const address = await getAccountAddress(wallet); @@ -60,39 +41,19 @@ export const upgrade = async (options: UpgradeUserProps): Promise => { const user: IUser = await get({ account: address, env: env }); - // user not found or already at latest encryption scheme - if ( - !user || - !user.encryptedPrivateKey || - user.encryptionType === Constants.ENC_TYPE_V3 - ) { - return user; + if (!user || !user.encryptedPrivateKey) { + throw new Error('User Not Found!'); } - const caip10 = user.did; - let encryptionType: string; + const recommendedPgpEncryptionVersion = Constants.ENCRYPTION_TYPE.PGP_V3; - if (isValidCAIP10NFTAddress(user.did)) { - encryptionType = Constants.ENC_TYPE_V4; - } else { - encryptionType = Constants.ENC_TYPE_V3; + if ( + user.encryptionType === recommendedPgpEncryptionVersion || + user.encryptionType === Constants.ENCRYPTION_TYPE.NFTPGP_V1 + ) { + return user; } - // Report Progress - progressHook?.({ - progressId: 'PUSH-UPGRADE-01', - progressTitle: 'Generating New Profile Signature', - progressInfo: - 'Trying to Upgrade Push Chat Keys to latest version. Please sign the message to continue.', - level: 'INFO', - }); - - const publicKey: string = await preparePGPPublicKey( - encryptionType, - user.publicKey, - wallet - ); - // Report Progress progressHook?.({ progressId: 'PUSH-UPGRADE-02', @@ -101,7 +62,7 @@ export const upgrade = async (options: UpgradeUserProps): Promise => { 'Trying to Upgrade Push Chat Keys to latest version. Please sign the message to continue.', level: 'INFO', }); - const privateKey = await decryptPGPKey({ + const pgpPrivateKey = await decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: signer, env, @@ -109,46 +70,15 @@ export const upgrade = async (options: UpgradeUserProps): Promise => { additionalMeta, }); - // Report Progress - progressHook?.({ - progressId: 'PUSH-UPGRADE-03', - progressTitle: 'Generating Encrypted New Profile', - progressInfo: - 'Trying to Upgrade Push Chat Keys to latest version. Encrypting Push Chat Keys with latest version. Please sign the message to continue.', - level: 'INFO', - }); - - const encryptedPrivateKey: encryptedPrivateKeyType = await encryptPGPKey( - encryptionType, - privateKey, - wallet, - additionalMeta - ); - - if (encryptionType === Constants.ENC_TYPE_V4) { - const encryptedPassword: encryptedPrivateKeyTypeV2 = await encryptPGPKey( - Constants.ENC_TYPE_V3, - additionalMeta?.NFTPGP_V1?.password as string, - wallet, - additionalMeta - ); - encryptedPrivateKey.encryptedPassword = encryptedPassword; - } - - // Report Progress - progressHook?.({ - progressId: 'PUSH-UPGRADE-04', - progressTitle: 'Syncing New Profile', - progressInfo: - 'Please sign the message to continue. Steady lads, chat is almost ready!', - level: 'INFO', - }); const upgradedUser = await update({ - encryptedPgpPrivateKey: JSON.stringify(encryptedPrivateKey), + pgpPrivateKey, // decrypted pgp priv key + pgpEncryptionVersion: recommendedPgpEncryptionVersion, signer, - account: caip10, - pgpPublicKey: publicKey, + pgpPublicKey: user.publicKey, + account: user.did, env, + additionalMeta: additionalMeta, + progressHook: progressHook, }); // Report Progress progressHook?.({ From 0f44637c85051cd7a02aa1cd9abd88fdc4756605 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 4 May 2023 19:41:09 +0530 Subject: [PATCH 057/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index b20e37cc2..054e45164 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.2...restapi-0.0.1-alpha.0) (2023-05-04) + + +### Bug Fixes + +* added pagination and deprecation tag ([#346](https://github.com/ethereum-push-notification-service/push-sdk/issues/346)) ([69763b8](https://github.com/ethereum-push-notification-service/push-sdk/commit/69763b8da2cf3e92bb85908e4f46a72b650c9dba)) +* change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) +* changed Definitions for auth.update and upgrade ([#351](https://github.com/ethereum-push-notification-service/push-sdk/issues/351)) ([31daee3](https://github.com/ethereum-push-notification-service/push-sdk/commit/31daee3a5aa913705d1dec8210c0412cd89c94c9)) +* eip191v2 signatures for create and auth.update ([#353](https://github.com/ethereum-push-notification-service/push-sdk/issues/353)) ([008e6d0](https://github.com/ethereum-push-notification-service/push-sdk/commit/008e6d08d75fdacf19f1674cc2b8bd82091fa31f)) +* Merge branch 'main' into alpha ([477bae4](https://github.com/ethereum-push-notification-service/push-sdk/commit/477bae4fdc4e86374615f0f67c41c570a567b9fe)) + + + ## [0.0.1-beta.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-beta.2) (2023-05-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 24a498037..c5491b66f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-beta.2", + "version": "0.0.1-alpha.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From d39c703bcda6d332717a5e9b1af6ab574be9d991 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Mon, 8 May 2023 16:42:54 +0530 Subject: [PATCH 058/298] fix: sendVideoNotification and end video call logic (#367) * feat(video): add create and request method * feat(video): add simple-peer dependency * feat(video): add acceptRequest method * feat(video): add establish and end methods * refactor(video): wrap video methods in a class * feat(video): add video audio toggle functions * fix(video): add pgp private key in send video call notification * fix(video): fix end call logic and remove hidden ppt from send video call notifications --- packages/restapi/src/lib/video/Video.ts | 36 +++++++++---------- .../helpers/sendVideoCallNotification.ts | 1 - 2 files changed, 17 insertions(+), 20 deletions(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index da2b39123..4510a4410 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -28,6 +28,7 @@ export class Video { // user related info private signer: SignerType | undefined = undefined; private chainId: number | undefined = undefined; + private pgpPrivateKey: string | null = null; private env: ENV = Constants.ENV.PROD; // storing the peer instance @@ -150,7 +151,6 @@ export class Video { chatId, signalingData: data, env, - } ); }); @@ -205,6 +205,7 @@ export class Video { this.peerInstance = peer; this.signer = signer; this.chainId = chainId; + this.pgpPrivateKey = pgpPrivateKey; this.env = env; return { sendMessage, @@ -306,6 +307,7 @@ export class Video { this.peerInstance = peer; this.signer = signer; this.chainId = chainId; + this.pgpPrivateKey = pgpPrivateKey; this.env = env; return { sendMessage, @@ -341,24 +343,20 @@ export class Video { this.localStream.getTracks().forEach((track) => track.stop()); } } - if (this.videoCallInfo.callStatus === 2 || this.videoCallInfo.callStatus === 1) { - if (!this.signer) throw new Error('signer not valid'); - if (!this.chainId) throw new Error('chainId not valid'); - if (!this.env) throw new Error('env is not valid'); - - // for disconnecting during status 1 - // send a notif to the other computer signaling status:4 - // sendVideoCallNotification( - // { signer: this.signer, chainId: this.chainId }, - // { - // senderAddress: this.videoCallInfo.senderAddress, - // recipientAddress: this.videoCallInfo.receiverAddress, - // status: 4, - // chatId: this.videoCallInfo.chatId, - // signalingData: null, - // env: this.env, - // } - // ); + if (this.videoCallInfo.callStatus === 1 || this.videoCallInfo.callStatus === 2) { + // for disconnecting during status 1, 2 + // send a notif to the other user signaling status=4 + sendVideoCallNotification( + { signer: this.signer!, chainId: this.chainId!, pgpPrivateKey: this.pgpPrivateKey }, + { + senderAddress: this.videoCallInfo.senderAddress, + recipientAddress: this.videoCallInfo.receiverAddress, + status: 4, + chatId: this.videoCallInfo.chatId, + signalingData: null, + env: this.env, + } + ); window.location.reload(); } } catch (error) { diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts index 8ace78558..96baf55b2 100644 --- a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -71,7 +71,6 @@ const sendVideoCallNotification = async ( chatId, type: 3, identityType: 2, - hidden: true, notification: { title: 'VideoCall', body: 'VideoCall', From 58a22218bb082c664b0c92be0b7a3bbd5ef1c8e6 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 8 May 2023 16:45:18 +0530 Subject: [PATCH 059/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 054e45164..ee6301b2f 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.0...restapi-0.0.1-alpha.1) (2023-05-08) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([1223c60](https://github.com/ethereum-push-notification-service/push-sdk/commit/1223c60b0f179b26537992a776155aefffd7b5ef)) +* sendVideoNotification and end video call logic ([#367](https://github.com/ethereum-push-notification-service/push-sdk/issues/367)) ([d39c703](https://github.com/ethereum-push-notification-service/push-sdk/commit/d39c703bcda6d332717a5e9b1af6ab574be9d991)) + + + ## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.2...restapi-0.0.1-alpha.0) (2023-05-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c5491b66f..323be270d 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.0", + "version": "0.0.1-alpha.1", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 318aed6a78070d947525eccb7a1c28c44c9d09df Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 8 May 2023 16:58:15 +0530 Subject: [PATCH 060/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 9efeee6a9..1ae036cd3 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-1.2.11) (2023-05-08) + + + +## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-1.2.10) (2023-05-08) + + + +## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-alpha.0) (2023-05-08) + + + ## [0.0.1-beta.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.10...restapi-0.0.1-beta.1) (2023-05-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index bec9e611f..b691892b2 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-beta.1", + "version": "1.2.11", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From a14362ba8f5b0428e1e300472980a30f55074cc0 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 8 May 2023 17:04:23 +0530 Subject: [PATCH 061/298] fix: linkedListHash test cases removed & CI version corrected --- packages/restapi/project.json | 4 ++-- packages/restapi/tests/lib/user/createUser.test.ts | 3 --- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/restapi/project.json b/packages/restapi/project.json index ca6f65668..90d27ba83 100644 --- a/packages/restapi/project.json +++ b/packages/restapi/project.json @@ -44,8 +44,8 @@ "preset": "angular", "commitMessageFormat": "ci(${projectName}): 🎉 cut beta release to ${projectName}-v${version}", "postTargets": ["restapi:build", "restapi:ci-publish"], - "releaseType": "prerelease", - "preid": "beta" + "version": "prerelease", + "preid": "alpha" } }, "ci-publish": { diff --git a/packages/restapi/tests/lib/user/createUser.test.ts b/packages/restapi/tests/lib/user/createUser.test.ts index 2e2d19293..0419a09a2 100644 --- a/packages/restapi/tests/lib/user/createUser.test.ts +++ b/packages/restapi/tests/lib/user/createUser.test.ts @@ -62,7 +62,6 @@ describe('Create Push Profile', () => { expect(user.about).to.be.null; expect(user.name).to.be.null; expect(user.numMsg).to.be.equal(0); - expect(user.linkedListHash).to.be.equal(''); }); it('Push Profile V3', async () => { const user = await create({ @@ -88,7 +87,6 @@ describe('Create Push Profile', () => { expect(user.about).to.be.null; expect(user.name).to.be.null; expect(user.numMsg).to.be.equal(0); - expect(user.linkedListHash).to.be.equal(''); }); it('Push Profile V4 ( NFT Profile )', async () => { const user = await create({ @@ -114,6 +112,5 @@ describe('Create Push Profile', () => { expect(user.about).to.be.null; expect(user.name).to.be.null; expect(user.numMsg).to.be.equal(0); - expect(user.linkedListHash).to.be.equal(''); }); }); From 42a810295573b3ebfdb535ec19723eac2144583e Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 8 May 2023 17:15:01 +0530 Subject: [PATCH 062/298] fix: update name to beta --- packages/restapi/project.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/restapi/project.json b/packages/restapi/project.json index 377672e06..90d27ba83 100644 --- a/packages/restapi/project.json +++ b/packages/restapi/project.json @@ -38,7 +38,7 @@ "postTargets": ["restapi:build", "restapi:ci-publish"] } }, - "ci-version-alpha": { + "ci-version-beta": { "executor": "@jscutlery/semver:version", "options": { "preset": "angular", From eec215c1897ec97bc0df3d0ed041b94838468c45 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 8 May 2023 18:26:02 +0530 Subject: [PATCH 063/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 1ae036cd3..f9f4106cb 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.11...restapi-1.2.12) (2023-05-08) + + +### Bug Fixes + +* change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) +* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) + + + ## [1.2.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-1.2.11) (2023-05-08) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index b691892b2..c94743a1c 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.11", + "version": "1.2.12", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 21a7b7ab2826179e0fe1e389a1775803859f04ca Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 8 May 2023 18:40:50 +0530 Subject: [PATCH 064/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index f9f4106cb..760b90567 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -12,6 +12,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [1.2.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.11...restapi-1.2.12) (2023-05-08) + + +### Bug Fixes + +* change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) +* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) + + + ## [1.2.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-1.2.11) (2023-05-08) From 643eb54475f4b89dc2be3fa040dd11a6907ba6a7 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 10 May 2023 12:03:52 +0530 Subject: [PATCH 065/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 760b90567..7ca2db1d1 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.12...restapi-1.2.13) (2023-05-10) + + +### Bug Fixes + +* eip191v2 signatures for create and auth.update ([#359](https://github.com/ethereum-push-notification-service/push-sdk/issues/359)) ([48abaf6](https://github.com/ethereum-push-notification-service/push-sdk/commit/48abaf667dce2a1140c3622451c1c5b49d153c00)) +* Merge branch 'main' into deployment ([52cab60](https://github.com/ethereum-push-notification-service/push-sdk/commit/52cab60eedbc71d74697adbcd69133d1b93d0f5a)) + + + ## [1.2.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.11...restapi-1.2.12) (2023-05-08) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c94743a1c..11f2eca89 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.12", + "version": "1.2.13", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 3cb81d1c9ac4533d4f1af1686d1497f463b334f9 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Wed, 10 May 2023 17:55:47 +0530 Subject: [PATCH 066/298] Modify video class (#379) * feat(video): add create and request method * feat(video): add simple-peer dependency * feat(video): add acceptRequest method * feat(video): add establish and end methods * refactor(video): wrap video methods in a class * feat(video): add video audio toggle functions * fix(video): add pgp private key in send video call notification * fix(video): fix end call logic and remove hidden ppt from send video call notifications * refactor(video): combine all the states in the Video class to single state --- packages/restapi/package.json | 1 + packages/restapi/src/lib/types/index.ts | 71 +- packages/restapi/src/lib/video/Video.ts | 641 ++++++++++-------- .../helpers/sendVideoCallNotification.ts | 30 +- packages/restapi/yarn.lock | 5 + 5 files changed, 417 insertions(+), 331 deletions(-) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 446e1d12d..7e300c2a0 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -12,6 +12,7 @@ "@metamask/eth-sig-util": "^5.0.2", "buffer": "^6.0.3", "crypto-js": "^4.1.1", + "immer": "^10.0.2", "openpgp": "^5.5.0", "simple-peer": "^9.11.1" }, diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 8be33dfbe..e58c6d9fd 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -322,21 +322,50 @@ export type MessageWithCID = { verificationProof?: string; }; -export type IMediaStream = MediaStream | undefined; +export type IMediaStream = MediaStream | null; -export type VideoCallInfoType ={ - senderAddress: string; // address which initiated the call - receiverAddress: string; // address which will receive the call - /* - callStatus - 0 - call not initiated - 1 - call initiated by the caller address - 2 - call recieved by the receiver address - 3 - call is established - 4 - call ended - */ - callStatus: number; - chatId:string; +export enum VideoCallStatus { + UNINITIALIZED, + INITIALIZED, + RECEIVED, + CONNECTED, + DISCONNECTED, +} + +export type PeerData = { + stream: IMediaStream; + audio: boolean | null; + video: boolean | null; + address: string; + status: VideoCallStatus; +}; + +export type VideoCallData = { + meta: { + chatId: string; + initiator: { + address: string; + signal: any; + }; + broadcast?: { + livepeerInfo: any; + hostAddress: string; + coHostAddress: string; + }; + }; + local: { + stream: IMediaStream; + audio: boolean | null; + video: boolean | null; + address: string; + }; + // incoming: PeerData | [PeerData]; + incoming: PeerData; +}; + +export type VideoCreateInputOptions = { + video: boolean; + audio: boolean; }; export type VideoRequestInputOptions = { @@ -347,11 +376,7 @@ export type VideoRequestInputOptions = { chatId: string; onRecieveMessage: (message: string) => void; env?: ENV; - pgpPrivateKey:string | null; -}; - -export type VideoRequestReturnOptions = { - sendMessage: (message: string) => void; + pgpPrivateKey: string | null; }; export type VideoAcceptRequestInputOptions = { @@ -363,13 +388,9 @@ export type VideoAcceptRequestInputOptions = { chatId: string; onRecieveMessage: (message: string) => void; env?: ENV; - pgpPrivateKey:string | null; -}; - -export type VideoAcceptRequestReturnOptions = { - sendMessage: (message: string) => void; + pgpPrivateKey: string | null; }; -export type VideoEstablishInputOptions = { +export type VideoConnectInputOptions = { signalData: any; }; diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 4510a4410..d6fc58b0e 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -1,7 +1,7 @@ -import * as React from 'react'; // eslint-disable-next-line @typescript-eslint/ban-ts-comment // @ts-ignore import * as Peer from 'simple-peer'; +import { produce } from 'immer'; import Constants, { ENV } from '../constants'; import sendVideoCallNotification from './helpers/sendVideoCallNotification'; @@ -14,113 +14,91 @@ import { import isJSON from './helpers/isJSON'; import { - IMediaStream, SignerType, - VideoAcceptRequestInputOptions, - VideoAcceptRequestReturnOptions, - VideoCallInfoType, - VideoEstablishInputOptions, + VideoCallData, + VideoCreateInputOptions, VideoRequestInputOptions, - VideoRequestReturnOptions, + VideoAcceptRequestInputOptions, + VideoConnectInputOptions, + VideoCallStatus, } from '../types'; +export const initVideoCallData: VideoCallData = { + meta: { + chatId: '', + initiator: { + address: '', + signal: null, + }, + }, + local: { + stream: null, + audio: null, + video: null, + address: '', + }, + incoming: { + stream: null, + audio: null, + video: null, + address: '', + status: VideoCallStatus.UNINITIALIZED, + }, +}; + export class Video { - // user related info - private signer: SignerType | undefined = undefined; - private chainId: number | undefined = undefined; + // user, call related info + private signer: SignerType | null = null; + private chainId: number | null = null; private pgpPrivateKey: string | null = null; private env: ENV = Constants.ENV.PROD; // storing the peer instance - private peerInstance: Peer.Instance | undefined = undefined; - - // variables for video call state handling - localStream: IMediaStream; - setLocalStream: React.Dispatch>; - incomingStream: IMediaStream; - setIncomingStream: React.Dispatch< - React.SetStateAction - >; - videoCallInfo: VideoCallInfoType; - setVideoCallInfo: React.Dispatch>; - isVideoOn: boolean; - setIsVideoOn: React.Dispatch>; - isAudioOn: boolean; - setIsAudioOn: React.Dispatch>; - isIncomingVideoOn: boolean; - setIsIncomingVideoOn: React.Dispatch>; - isIncomingAudioOn: boolean; - setIsIncomingAudioOn: React.Dispatch>; + private peerInstance: any = null; + + data: VideoCallData; + setData: (fn: (data: VideoCallData) => VideoCallData) => void; constructor({ - localStream, - setLocalStream, - incomingStream, - setIncomingStream, - videoCallInfo, - setVideoCallInfo, - isVideoOn, - setIsVideoOn, - isAudioOn, - setIsAudioOn, - isIncomingVideoOn, - setIsIncomingVideoOn, - isIncomingAudioOn, - setIsIncomingAudioOn, + data, + setData, }: { - localStream: IMediaStream; - setLocalStream: React.Dispatch< - React.SetStateAction - >; - incomingStream: IMediaStream; - setIncomingStream: React.Dispatch< - React.SetStateAction - >; - videoCallInfo: VideoCallInfoType; - setVideoCallInfo: React.Dispatch>; - isVideoOn: boolean; - setIsVideoOn: React.Dispatch>; - isAudioOn: boolean; - setIsAudioOn: React.Dispatch>; - isIncomingVideoOn: boolean; - setIsIncomingVideoOn: React.Dispatch>; - isIncomingAudioOn: boolean; - setIsIncomingAudioOn: React.Dispatch>; + data: VideoCallData; + setData: (fn: (data: VideoCallData) => VideoCallData) => void; }) { - this.localStream = localStream; - this.setLocalStream = setLocalStream; - this.incomingStream = incomingStream; - this.setIncomingStream = setIncomingStream; - this.videoCallInfo = videoCallInfo; - this.setVideoCallInfo = setVideoCallInfo; - this.isVideoOn = isVideoOn; - this.setIsVideoOn = setIsVideoOn; - this.isAudioOn = isAudioOn; - this.setIsAudioOn = setIsAudioOn; - this.isIncomingVideoOn = isIncomingVideoOn; - this.setIsIncomingVideoOn = setIsIncomingVideoOn; - this.isIncomingAudioOn = isIncomingAudioOn; - this.setIsIncomingAudioOn = setIsIncomingAudioOn; + this.data = data; + this.setData = setData; } - create = async () => { + create = async (options: VideoCreateInputOptions): Promise => { + const { audio, video } = options || {}; + try { const localStream = await navigator.mediaDevices.getUserMedia({ video: true, audio: true, }); - this.setLocalStream(localStream); - this.setIsAudioOn(true); - this.setIsVideoOn(true); + if (video === false) { + stopVideoStream(localStream); + } + if (audio === false) { + stopAudioStream(localStream); + } + + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.stream = localStream; + draft.local.video = video; + draft.local.audio = audio; + }); + }); } catch (err) { - console.log('Error in creating local stream', err); + console.log('error in create', err); } }; - request = async ( - options: VideoRequestInputOptions - ): Promise => { + request = async (options: VideoRequestInputOptions): Promise => { const { library, chainId, @@ -129,92 +107,126 @@ export class Video { chatId, onRecieveMessage, env = Constants.ENV.PROD, - pgpPrivateKey=null, + pgpPrivateKey = null, } = options || {}; - const signer: SignerType = await library.getSigner(senderAddress); - - const peer = new Peer({ - initiator: true, - trickle: false, - stream: this.localStream, - }); - - peer.on('signal', (data: any) => { - // sending notification to the recipientAddress with video call signaling data - sendVideoCallNotification( - { signer, chainId, pgpPrivateKey }, - { - senderAddress, - recipientAddress, - status: 1, - chatId, - signalingData: data, - env, - } + try { + const signer: SignerType = await library.getSigner(senderAddress); + + console.log( + 'request', + 'options', + options, + 'localStream', + this.data.local.stream ); - }); - // set videoCallInfo state with status 1 (call initiated) - this.setVideoCallInfo({ - senderAddress: senderAddress, - receiverAddress: recipientAddress, - callStatus: 1, - chatId, - }); + this.peerInstance = new Peer({ + initiator: true, + trickle: false, + stream: this.data.local.stream, + }); - peer.on('connect', () => { - peer.send('initial message from caller'); - peer.send( - JSON.stringify({ type: 'isVideoOn', isVideoOn: this.isVideoOn }) - ); - peer.send( - JSON.stringify({ type: 'isAudioOn', isAudioOn: this.isAudioOn }) - ); - }); - - peer.on('data', (data: any) => { - if (isJSON(data)) { - const parsedData = JSON.parse(data); - if (parsedData.type === 'isVideoOn') { - console.log('IS VIDEO ON', parsedData.isVideoOn); - this.setIsIncomingVideoOn(parsedData.isVideoOn); - } - if (parsedData.type === 'isAudioOn') { - console.log('IS AUDIO ON', parsedData.isAudioOn); - this.setIsIncomingAudioOn(parsedData.isAudioOn); - } - if (parsedData.type === 'endLocalStream') { - console.log('END LOCAL STREAM', parsedData.endLocalStream); - window.location.reload(); + this.peerInstance.on('signal', (data: any) => { + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.meta.initiator.signal = data; + }); + }); + + // sending notification to the recipientAddress with video call signaling data + sendVideoCallNotification( + { signer, chainId, pgpPrivateKey }, + { + senderAddress, + recipientAddress, + status: VideoCallStatus.INITIALIZED, + chatId, + signalingData: data, + env, + } + ); + }); + + this.peerInstance.on('connect', () => { + this.peerInstance.send(`initial message from ${senderAddress}`); + this.peerInstance.send( + JSON.stringify({ + type: 'isVideoOn', + isVideoOn: this.data.local.video, + }) + ); + this.peerInstance.send( + JSON.stringify({ + type: 'isAudioOn', + isAudioOn: this.data.local.audio, + }) + ); + }); + + this.peerInstance.on('data', (data: any) => { + if (isJSON(data)) { + const parsedData = JSON.parse(data); + if (parsedData.type === 'isVideoOn') { + console.log('IS VIDEO ON', parsedData.isVideoOn); + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.video = parsedData.isVideoOn; + }); + }); + } + + if (parsedData.type === 'isAudioOn') { + console.log('IS AUDIO ON', parsedData.isAudioOn); + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.audio = parsedData.isAudioOn; + }); + }); + } + + if (parsedData.type === 'endLocalStream') { + console.log('END LOCAL STREAM', parsedData.endLocalStream); + this.setData(() => initVideoCallData); + } + } else { + console.log('received a message', data); + onRecieveMessage(data); } - } else { - console.log('received a message', data); - onRecieveMessage(data); - } - }); - - peer.on('stream', (currentStream: MediaStream) => { - this.setIncomingStream(currentStream); - }); - - const sendMessage = (message: string): void => { - peer.send(message); - }; - - this.peerInstance = peer; - this.signer = signer; - this.chainId = chainId; - this.pgpPrivateKey = pgpPrivateKey; - this.env = env; - return { - sendMessage, - }; + }); + + this.peerInstance.on('stream', (currentStream: MediaStream) => { + console.log('received incoming stream', currentStream); + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.stream = currentStream; + }); + }); + }); + + this.signer = signer; + this.chainId = chainId; + this.pgpPrivateKey = pgpPrivateKey; + this.env = env; + + // set videoCallInfo state with status 1 (call initiated) + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.address = senderAddress; + draft.incoming.address = recipientAddress; + draft.meta.chatId = chatId; + draft.meta.initiator.address = senderAddress; + draft.incoming.status = VideoCallStatus.INITIALIZED; + }); + }); + } catch (err) { + console.log('error in request', err); + } }; acceptRequest = async ( options: VideoAcceptRequestInputOptions - ): Promise => { + ): Promise => { const { signalData, library, @@ -224,183 +236,234 @@ export class Video { chatId, onRecieveMessage, env = Constants.ENV.PROD, - pgpPrivateKey=null, + pgpPrivateKey = null, } = options || {}; - const signer: SignerType = await library.getSigner(senderAddress); - - const peer = new Peer({ - initiator: false, - trickle: false, - stream: this.localStream, - }); - - peer.signal(signalData); - - peer.on('signal', (data: any) => { - sendVideoCallNotification( - { signer, chainId, pgpPrivateKey }, - { - senderAddress, - recipientAddress, - status: 2, - chatId, - signalingData: data, - env, - } + try { + const signer: SignerType = await library.getSigner(senderAddress); + + console.log( + 'accept request', + 'options', + options, + 'localStream', + this.data.local.stream ); - }); - // set videoCallInfo state with status 2 (call received) - this.setVideoCallInfo({ - senderAddress: senderAddress, - receiverAddress: recipientAddress, - callStatus: 2, - chatId, - }); + this.peerInstance = new Peer({ + initiator: false, + trickle: false, + stream: this.data.local.stream, + }); - peer.on('connect', () => { - peer.send('initial message from receiver'); - peer.send( - JSON.stringify({ type: 'isVideoOn', isVideoOn: this.isVideoOn }) - ); - peer.send( - JSON.stringify({ type: 'isAudioOn', isAudioOn: this.isAudioOn }) - ); + this.peerInstance.signal(signalData); - // set videoCallInfo state with status 3 (call established) for the receiver's end - this.setVideoCallInfo((oldVideoCallInfo) => ({ - ...oldVideoCallInfo, - callStatus: 3, - })); - }); - - peer.on('data', (data: any) => { - if (isJSON(data)) { - const parsedData = JSON.parse(data); - if (parsedData.type === 'isVideoOn') { - console.log('IS VIDEO ON', parsedData.isVideoOn); - this.setIsIncomingVideoOn(parsedData.isVideoOn); - } - if (parsedData.type === 'isAudioOn') { - console.log('IS AUDIO ON', parsedData.isAudioOn); - this.setIsIncomingAudioOn(parsedData.isAudioOn); - } - if (parsedData.type === 'endLocalStream') { - console.log('END LOCAL STREAM', parsedData.endLocalStream); - window.location.reload(); + this.peerInstance.on('signal', (data: any) => { + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.meta.initiator.signal = data; + }); + }); + + sendVideoCallNotification( + { signer, chainId, pgpPrivateKey }, + { + senderAddress, + recipientAddress, + status: VideoCallStatus.RECEIVED, + chatId, + signalingData: data, + env, + } + ); + }); + + this.peerInstance.on('connect', () => { + this.peerInstance.send('initial message from receiver'); + this.peerInstance.send( + JSON.stringify({ + type: 'isVideoOn', + isVideoOn: this.data.local.video, + }) + ); + this.peerInstance.send( + JSON.stringify({ + type: 'isAudioOn', + isAudioOn: this.data.local.audio, + }) + ); + + // set videoCallInfo state with status connected for the receiver's end + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.status = VideoCallStatus.CONNECTED; + }); + }); + }); + + this.peerInstance.on('data', (data: any) => { + if (isJSON(data)) { + const parsedData = JSON.parse(data); + if (parsedData.type === 'isVideoOn') { + console.log('IS VIDEO ON', parsedData.isVideoOn); + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.video = parsedData.isVideoOn; + }); + }); + } + + if (parsedData.type === 'isAudioOn') { + console.log('IS AUDIO ON', parsedData.isAudioOn); + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.audio = parsedData.isAudioOn; + }); + }); + } + + if (parsedData.type === 'endLocalStream') { + console.log('END LOCAL STREAM', parsedData.endLocalStream); + this.setData(() => initVideoCallData); + } + } else { + console.log('received a message', data); + onRecieveMessage(data); } - } else { - console.log('received a message', data); - onRecieveMessage(data); - } - }); - - peer.on('stream', (currentStream: MediaStream) => { - this.setIncomingStream(currentStream); - }); - - const sendMessage = (message: string): void => { - peer.send(message); - }; - - this.peerInstance = peer; - this.signer = signer; - this.chainId = chainId; - this.pgpPrivateKey = pgpPrivateKey; - this.env = env; - return { - sendMessage, - }; + }); + + this.peerInstance.on('stream', (currentStream: MediaStream) => { + console.log('received incoming stream', currentStream); + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.stream = currentStream; + }); + }); + }); + + this.signer = signer; + this.chainId = chainId; + this.pgpPrivateKey = pgpPrivateKey; + this.env = env; + + // set videoCallInfo state with status 2 (call received) + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.address = senderAddress; + draft.incoming.address = recipientAddress; + draft.meta.chatId = chatId; + draft.meta.initiator.address = senderAddress; + draft.incoming.status = VideoCallStatus.RECEIVED; + }); + }); + } catch (err) { + console.log('error in accept request', err); + } }; - establish = (options: VideoEstablishInputOptions): void => { + connect = (options: VideoConnectInputOptions): void => { const { signalData } = options || {}; - if (this.peerInstance) { - this.peerInstance.signal(signalData); - // set videoCallInfo state with status 3 (call established) for the caller's end - this.setVideoCallInfo((oldVideoCallInfo) => ({ - ...oldVideoCallInfo, - callStatus: 3, - })); - } else { - throw new Error('Peer instance is undefined'); + try { + console.log('connect', 'options', options); + + this.peerInstance?.signal(signalData); + + // set videoCallInfo state with status connected for the caller's end + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming.status = VideoCallStatus.CONNECTED; + }); + }); + } catch (err) { + console.log('error in connect', err); } }; - end = (): void => { + disconnect = (): void => { try { - if (this.videoCallInfo.callStatus === 3) { + console.log('disconnect'); + if (this.data.incoming.status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( JSON.stringify({ type: 'endLocalStream', endLocalStream: true }) ); this.peerInstance?.destroy(); // ending the local stream - if (this.localStream) { - console.log('END LOCAL STREAM'); - this.localStream.getTracks().forEach((track) => track.stop()); - } + this.data.local.stream?.getTracks().forEach((track) => track.stop()); } - if (this.videoCallInfo.callStatus === 1 || this.videoCallInfo.callStatus === 2) { + if ( + this.data.incoming.status === VideoCallStatus.INITIALIZED || + this.data.incoming.status === VideoCallStatus.RECEIVED + ) { // for disconnecting during status 1, 2 // send a notif to the other user signaling status=4 sendVideoCallNotification( - { signer: this.signer!, chainId: this.chainId!, pgpPrivateKey: this.pgpPrivateKey }, { - senderAddress: this.videoCallInfo.senderAddress, - recipientAddress: this.videoCallInfo.receiverAddress, - status: 4, - chatId: this.videoCallInfo.chatId, + signer: this.signer!, + chainId: this.chainId!, + pgpPrivateKey: this.pgpPrivateKey, + }, + { + senderAddress: this.data.local.address, + recipientAddress: this.data.incoming.address, + status: VideoCallStatus.DISCONNECTED, + chatId: this.data.meta.chatId, signalingData: null, env: this.env, } ); - window.location.reload(); } - } catch (error) { - console.log('error occured', error); + + this.setData(() => initVideoCallData); + } catch (err) { + console.log('error in disconnect', err); } }; // functions for toggling local audio and video toggleVideo = (): void => { - if (this.videoCallInfo.callStatus === 3) { + console.log('toggleVideo', 'current video', this.data.local.video); + if (this.data.incoming.status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( - JSON.stringify({ type: 'isVideoOn', isVideoOn: !this.isVideoOn }) + JSON.stringify({ type: 'isVideoOn', isVideoOn: !this.data.local.video }) ); } - - if (this.isVideoOn === false && this.localStream) { - console.log('INITIALIZE LOCAL STREAM'); - restartVideoStream(this.localStream); - this.setIsVideoOn(true); - } - if (this.isVideoOn === true && this.localStream) { - console.log('STOP LOCAL STREAM'); - stopVideoStream(this.localStream); - this.setIsVideoOn(false); + if (this.data.local.stream) { + if (this.data.local.video === false) { + restartVideoStream(this.data.local.stream); + } + if (this.data.local.video === true) { + stopVideoStream(this.data.local.stream); + } + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.video = !oldData.local.video; + }); + }); } }; toggleAudio = (): void => { - if (this.videoCallInfo.callStatus === 3) { + console.log('toggleAudio', 'current audio', this.data.local.audio); + if (this.data.incoming.status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( - JSON.stringify({ type: 'isAudioOn', isAudioOn: !this.isAudioOn }) + JSON.stringify({ type: 'isAudioOn', isAudioOn: !this.data.local.audio }) ); } - - if (this.isAudioOn === false && this.localStream) { - console.log('INITIALIZE LOCAL STREAM'); - restartAudioStream(this.localStream); - this.setIsAudioOn(true); - } - if (this.isAudioOn === true && this.localStream) { - console.log('STOP LOCAL STREAM'); - stopAudioStream(this.localStream); - this.setIsAudioOn(false); + if (this.data.local.stream) { + if (this.data.local.audio === false) { + restartAudioStream(this.data.local.stream); + } + if (this.data.local.audio === true) { + stopAudioStream(this.data.local.stream); + } + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.audio = !oldData.local.audio; + }); + }); } }; } diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts index 96baf55b2..408147055 100644 --- a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -2,22 +2,14 @@ import { getConnectedUser, getWallet } from '../../chat/helpers'; import Constants, { ENV } from '../../constants'; import { getCAIPWithChainId } from '../../helpers'; import { sendNotification } from '../../payloads'; -import { SignerType } from '../../types'; +import { SignerType, VideoCallStatus } from '../../types'; interface VideoCallInfoType { recipientAddress: string; senderAddress: string; chatId: string; signalingData: any; - /* - callStatus - 0 - call not initiated - 1 - call initiated by the caller address - 2 - call recieved by the receiver address - 3 - call is established - 4 - call ended - */ - status: 1 | 2 | 3 | 4; + status: VideoCallStatus; env?: ENV; } @@ -27,16 +19,16 @@ interface UserInfoType { pgpPrivateKey: string | null; } -interface videoPayloadType { +interface VideoPayloadType { recipientAddress: string; senderAddress: string; chatId: string; signalingData?: any; - status: number; + status: VideoCallStatus; } const sendVideoCallNotification = async ( - { signer, chainId, pgpPrivateKey=null, }: UserInfoType, + { signer, chainId, pgpPrivateKey = null }: UserInfoType, { recipientAddress, senderAddress, @@ -47,7 +39,7 @@ const sendVideoCallNotification = async ( }: VideoCallInfoType ) => { try { - const videoPayload: videoPayloadType = { + const videoPayload: VideoPayloadType = { recipientAddress, senderAddress, chatId, @@ -55,6 +47,8 @@ const sendVideoCallNotification = async ( status, }; + console.log('sendVideoCallNotification', 'videoPayload', videoPayload); + const senderAddressInCaip = getCAIPWithChainId(senderAddress, chainId); const recipientAddressInCaip = getCAIPWithChainId( recipientAddress, @@ -62,7 +56,9 @@ const sendVideoCallNotification = async ( ); const wallet = getWallet({ account: senderAddress, signer }); - const connectedUser = await getConnectedUser(wallet, pgpPrivateKey, env); + const connectedUser = await getConnectedUser(wallet, pgpPrivateKey, env); + + const notificationText = `Video Call from ${senderAddress}`; await sendNotification({ senderType: 1, // for chat notification @@ -72,8 +68,8 @@ const sendVideoCallNotification = async ( type: 3, identityType: 2, notification: { - title: 'VideoCall', - body: 'VideoCall', + title: notificationText, + body: notificationText, }, payload: { title: 'VideoCall', diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index b0df125c3..1a880b108 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -630,6 +630,11 @@ ieee754@^1.2.1: resolved "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== +immer@^10.0.2: + version "10.0.2" + resolved "https://registry.yarnpkg.com/immer/-/immer-10.0.2.tgz#11636c5b77acf529e059582d76faf338beb56141" + integrity sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA== + inflight@^1.0.4: version "1.0.6" resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" From c126cc0e53bfdb475a1aaf23a1df94a170c73ee0 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 10 May 2023 18:53:46 +0530 Subject: [PATCH 067/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 50deeaa68..dd4edc03e 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.1...restapi-0.0.1-alpha.2) (2023-05-10) + + +### Bug Fixes + +* eip191v2 signatures for create and auth.update ([#359](https://github.com/ethereum-push-notification-service/push-sdk/issues/359)) ([48abaf6](https://github.com/ethereum-push-notification-service/push-sdk/commit/48abaf667dce2a1140c3622451c1c5b49d153c00)) +* merge alpha ([7f0642c](https://github.com/ethereum-push-notification-service/push-sdk/commit/7f0642c4c417390a5bb52d36d9493bd5b767b634)) +* merge main ([a5fdfe1](https://github.com/ethereum-push-notification-service/push-sdk/commit/a5fdfe10f18c857c32aa5fe5c5dd95db0f268cd1)) +* merge main to alpha ([4866a37](https://github.com/ethereum-push-notification-service/push-sdk/commit/4866a37ed0502c0d16ac91f088d3bb5e597b652a)) + + + ## [0.0.1-alpha.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.0...restapi-0.0.1-alpha.1) (2023-05-08) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 101225791..e12b13031 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.1", + "version": "0.0.1-alpha.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From b90435a953b908899c92eb5b4d4c3677e47b1552 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Thu, 11 May 2023 12:25:11 +0530 Subject: [PATCH 068/298] fix: Replace arrow functions with normal functions in the Video class (#380) * feat(video): add create and request method * feat(video): add simple-peer dependency * feat(video): add acceptRequest method * feat(video): add establish and end methods * refactor(video): wrap video methods in a class * feat(video): add video audio toggle functions * fix(video): add pgp private key in send video call notification * fix(video): fix end call logic and remove hidden ppt from send video call notifications * refactor(video): combine all the states in the Video class to single state * fix(video): replace arrow functions with normal functions --------- Co-authored-by: Madhur Gupta --- packages/restapi/src/lib/video/Video.ts | 30 ++++++++++++------------- 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index d6fc58b0e..1defb0d57 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -70,7 +70,7 @@ export class Video { this.setData = setData; } - create = async (options: VideoCreateInputOptions): Promise => { + async create(options: VideoCreateInputOptions): Promise { const { audio, video } = options || {}; try { @@ -96,9 +96,9 @@ export class Video { } catch (err) { console.log('error in create', err); } - }; + } - request = async (options: VideoRequestInputOptions): Promise => { + async request(options: VideoRequestInputOptions): Promise { const { library, chainId, @@ -222,11 +222,9 @@ export class Video { } catch (err) { console.log('error in request', err); } - }; + } - acceptRequest = async ( - options: VideoAcceptRequestInputOptions - ): Promise => { + async acceptRequest(options: VideoAcceptRequestInputOptions): Promise { const { signalData, library, @@ -359,9 +357,9 @@ export class Video { } catch (err) { console.log('error in accept request', err); } - }; + } - connect = (options: VideoConnectInputOptions): void => { + connect(options: VideoConnectInputOptions): void { const { signalData } = options || {}; try { @@ -378,9 +376,9 @@ export class Video { } catch (err) { console.log('error in connect', err); } - }; + } - disconnect = (): void => { + disconnect(): void { try { console.log('disconnect'); if (this.data.incoming.status === VideoCallStatus.CONNECTED) { @@ -419,11 +417,11 @@ export class Video { } catch (err) { console.log('error in disconnect', err); } - }; + } // functions for toggling local audio and video - toggleVideo = (): void => { + toggleVideo(): void { console.log('toggleVideo', 'current video', this.data.local.video); if (this.data.incoming.status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( @@ -443,9 +441,9 @@ export class Video { }); }); } - }; + } - toggleAudio = (): void => { + toggleAudio(): void { console.log('toggleAudio', 'current audio', this.data.local.audio); if (this.data.incoming.status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( @@ -465,5 +463,5 @@ export class Video { }); }); } - }; + } } From f298ecb260b811212c75e36ab705d2b7d082b722 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 11 May 2023 12:28:09 +0530 Subject: [PATCH 069/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index dd4edc03e..bf64a2dfb 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.2...restapi-0.0.1-alpha.3) (2023-05-11) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([e19b9b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/e19b9b05b60174e68dc7bfe0e2349e20d8af2604)) +* Replace arrow functions with normal functions in the Video class ([#380](https://github.com/ethereum-push-notification-service/push-sdk/issues/380)) ([b90435a](https://github.com/ethereum-push-notification-service/push-sdk/commit/b90435a953b908899c92eb5b4d4c3677e47b1552)) + + + ## [0.0.1-alpha.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.1...restapi-0.0.1-alpha.2) (2023-05-10) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index e12b13031..20d87d59f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.2", + "version": "0.0.1-alpha.3", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 83756bb181a5f9dd9847f8e1686e2f1eb4582502 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Thu, 11 May 2023 17:04:15 +0530 Subject: [PATCH 070/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.14?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 7ca2db1d1..f2e07af7b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.13...restapi-1.2.14) (2023-05-11) + + +### Bug Fixes + +* fix chat.chat for grps ([#382](https://github.com/ethereum-push-notification-service/push-sdk/issues/382)) ([052a75c](https://github.com/ethereum-push-notification-service/push-sdk/commit/052a75ca0f0fea7664d8c607fc85cdf37cc5d398)) +* Merge branch 'main' into deployment ([dd21949](https://github.com/ethereum-push-notification-service/push-sdk/commit/dd21949792a6028efdae17232ba16bb98605b017)) + + + ## [1.2.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.12...restapi-1.2.13) (2023-05-10) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 11f2eca89..5f3c39479 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.13", + "version": "1.2.14", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 17733ed82f2b2ec25ae010413ef37d64c07086fa Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 12 May 2023 12:51:45 +0530 Subject: [PATCH 071/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.15?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index f2e07af7b..8d999c6ec 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.14...restapi-1.2.15) (2023-05-12) + + +### Bug Fixes + +* fix eip712v2 ([#385](https://github.com/ethereum-push-notification-service/push-sdk/issues/385)) ([42c10ba](https://github.com/ethereum-push-notification-service/push-sdk/commit/42c10ba6f5331c9caf5db7136ba94d1a6ed05e10)) +* Merge branch 'main' into deployment ([3250a7c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3250a7cfc3bb8fefd630179cd204deef023a5e6c)) + + + ## [1.2.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.13...restapi-1.2.14) (2023-05-11) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 5f3c39479..b4826c786 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.14", + "version": "1.2.15", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 83bf4457332b127bf9e41a2f4c93fb851367724d Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Fri, 12 May 2023 19:12:00 +0530 Subject: [PATCH 072/298] fix(video): separate react state from video class instance variable data (#389) Co-authored-by: Madhur Gupta --- packages/demoreact/src/index.html | 1 + packages/restapi/src/lib/payloads/helpers.ts | 13 +- .../src/lib/payloads/sendNotifications.ts | 5 - packages/restapi/src/lib/types/index.ts | 15 +- packages/restapi/src/lib/video/Video.ts | 181 ++++++++++-------- .../src/lib/video/helpers/mediaToggle.ts | 5 + .../helpers/sendVideoCallNotification.ts | 10 +- 7 files changed, 118 insertions(+), 112 deletions(-) diff --git a/packages/demoreact/src/index.html b/packages/demoreact/src/index.html index f9876fddb..d1d7bd245 100644 --- a/packages/demoreact/src/index.html +++ b/packages/demoreact/src/index.html @@ -10,5 +10,6 @@
+ diff --git a/packages/restapi/src/lib/payloads/helpers.ts b/packages/restapi/src/lib/payloads/helpers.ts index dfed4064d..f70f35ae9 100644 --- a/packages/restapi/src/lib/payloads/helpers.ts +++ b/packages/restapi/src/lib/payloads/helpers.ts @@ -176,9 +176,7 @@ export async function getVerificationProof({ graph = {}, uuid, chatId, - wallet, // - pgpPrivateKey, // - env, // + pgpPrivateKey, }: { senderType: 0 | 1; signer: any; @@ -192,9 +190,7 @@ export async function getVerificationProof({ uuid: string; // for notifications which have additionalMeta in payload chatId?: string; - wallet?: walletType; pgpPrivateKey?: string; - env?: ENV; }) { let message = null; let verificationProof = null; @@ -245,15 +241,10 @@ export async function getVerificationProof({ break; } case 1: { - const connectedUser = await getConnectedUser( - wallet!, - pgpPrivateKey!, - env! - ); const hash = CryptoJS.SHA256(JSON.stringify(message)).toString(); const signature = await sign({ message: hash, - signingKey: connectedUser.privateKey!, + signingKey: pgpPrivateKey!, }); verificationProof = `pgpv2:${signature}:meta:${chatId}::uid::${uuid}`; break; diff --git a/packages/restapi/src/lib/payloads/sendNotifications.ts b/packages/restapi/src/lib/payloads/sendNotifications.ts index e8adfdda7..9d36b0762 100644 --- a/packages/restapi/src/lib/payloads/sendNotifications.ts +++ b/packages/restapi/src/lib/payloads/sendNotifications.ts @@ -12,7 +12,6 @@ import { import { getCAIPAddress, getCAIPDetails, getConfig } from '../helpers'; import { IDENTITY_TYPE } from './constants'; import { ENV } from '../constants'; -import { getWallet } from '../chat/helpers'; /** * Validate options for some scenarios @@ -65,8 +64,6 @@ export async function sendNotification(options: ISendNotificationInputOptions) { throw new Error(`Signer is necessary!`); } - const wallet = getWallet({ account: null, signer }); - const _channelAddress = getCAIPAddress(env, channel, 'Channel'); const channelCAIPDetails = getCAIPDetails(_channelAddress); @@ -103,9 +100,7 @@ export async function sendNotification(options: ISendNotificationInputOptions) { uuid, // for the pgpv2 verfication proof chatId, - wallet, pgpPrivateKey, - env, }); const identity = getPayloadIdentity({ diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index e58c6d9fd..508110bf8 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -359,8 +359,7 @@ export type VideoCallData = { video: boolean | null; address: string; }; - // incoming: PeerData | [PeerData]; - incoming: PeerData; + incoming: [PeerData]; }; export type VideoCreateInputOptions = { @@ -369,26 +368,18 @@ export type VideoCreateInputOptions = { }; export type VideoRequestInputOptions = { - library: any; - chainId: number; senderAddress: string; recipientAddress: string; chatId: string; - onRecieveMessage: (message: string) => void; - env?: ENV; - pgpPrivateKey: string | null; + onReceiveMessage?: (message: string) => void; }; export type VideoAcceptRequestInputOptions = { signalData: any; - library: any; - chainId: number; senderAddress: string; recipientAddress: string; chatId: string; - onRecieveMessage: (message: string) => void; - env?: ENV; - pgpPrivateKey: string | null; + onReceiveMessage?: (message: string) => void; }; export type VideoConnectInputOptions = { diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 1defb0d57..0a538f3f2 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -6,6 +6,7 @@ import { produce } from 'immer'; import Constants, { ENV } from '../constants'; import sendVideoCallNotification from './helpers/sendVideoCallNotification'; import { + endStream, restartAudioStream, restartVideoStream, stopAudioStream, @@ -37,42 +38,67 @@ export const initVideoCallData: VideoCallData = { video: null, address: '', }, - incoming: { - stream: null, - audio: null, - video: null, - address: '', - status: VideoCallStatus.UNINITIALIZED, - }, + incoming: [ + { + stream: null, + audio: null, + video: null, + address: '', + status: VideoCallStatus.UNINITIALIZED, + }, + ], }; export class Video { // user, call related info - private signer: SignerType | null = null; - private chainId: number | null = null; - private pgpPrivateKey: string | null = null; - private env: ENV = Constants.ENV.PROD; + private signer: SignerType; + private chainId: number; + private pgpPrivateKey: string; + private env: ENV; // storing the peer instance private peerInstance: any = null; - data: VideoCallData; + private data: VideoCallData; setData: (fn: (data: VideoCallData) => VideoCallData) => void; constructor({ - data, + signer, + chainId, + pgpPrivateKey, + env, setData, }: { - data: VideoCallData; + signer: SignerType; + chainId: number; + pgpPrivateKey: string; + env?: ENV; setData: (fn: (data: VideoCallData) => VideoCallData) => void; }) { - this.data = data; - this.setData = setData; + this.signer = signer; + this.chainId = chainId; + this.pgpPrivateKey = pgpPrivateKey; + this.env = env ? env : Constants.ENV.PROD; + + // init the react state + setData(() => initVideoCallData); + + // init the class variable + this.data = initVideoCallData; + + // set the state updating function + this.setData = function (fn) { + // update the react state + setData(fn); + + // update the class variable + this.data = fn(this.data); + }; } async create(options: VideoCreateInputOptions): Promise { const { audio, video } = options || {}; - + try { const localStream = await navigator.mediaDevices.getUserMedia({ video: true, @@ -100,19 +126,13 @@ export class Video { async request(options: VideoRequestInputOptions): Promise { const { - library, - chainId, senderAddress, // notification sender recipientAddress, // notification receiver chatId, - onRecieveMessage, - env = Constants.ENV.PROD, - pgpPrivateKey = null, + onReceiveMessage, } = options || {}; try { - const signer: SignerType = await library.getSigner(senderAddress); - console.log( 'request', 'options', @@ -136,14 +156,18 @@ export class Video { // sending notification to the recipientAddress with video call signaling data sendVideoCallNotification( - { signer, chainId, pgpPrivateKey }, + { + signer: this.signer, + chainId: this.chainId, + pgpPrivateKey: this.pgpPrivateKey, + }, { senderAddress, recipientAddress, status: VideoCallStatus.INITIALIZED, chatId, signalingData: data, - env, + env: this.env, } ); }); @@ -171,7 +195,7 @@ export class Video { console.log('IS VIDEO ON', parsedData.isVideoOn); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.video = parsedData.isVideoOn; + draft.incoming[0].video = parsedData.isVideoOn; }); }); } @@ -180,18 +204,24 @@ export class Video { console.log('IS AUDIO ON', parsedData.isAudioOn); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.audio = parsedData.isAudioOn; + draft.incoming[0].audio = parsedData.isAudioOn; }); }); } - if (parsedData.type === 'endLocalStream') { - console.log('END LOCAL STREAM', parsedData.endLocalStream); + if (parsedData.type === 'endCall') { + console.log('END CALL', parsedData.endCall); + // destroy the local stream + if (this.data.local.stream) { + endStream(this.data.local.stream); + } + + // reset the state this.setData(() => initVideoCallData); } } else { console.log('received a message', data); - onRecieveMessage(data); + onReceiveMessage ? onReceiveMessage(data) : ''; } }); @@ -199,24 +229,19 @@ export class Video { console.log('received incoming stream', currentStream); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.stream = currentStream; + draft.incoming[0].stream = currentStream; }); }); }); - this.signer = signer; - this.chainId = chainId; - this.pgpPrivateKey = pgpPrivateKey; - this.env = env; - // set videoCallInfo state with status 1 (call initiated) this.setData((oldData) => { return produce(oldData, (draft) => { draft.local.address = senderAddress; - draft.incoming.address = recipientAddress; + draft.incoming[0].address = recipientAddress; draft.meta.chatId = chatId; draft.meta.initiator.address = senderAddress; - draft.incoming.status = VideoCallStatus.INITIALIZED; + draft.incoming[0].status = VideoCallStatus.INITIALIZED; }); }); } catch (err) { @@ -227,19 +252,13 @@ export class Video { async acceptRequest(options: VideoAcceptRequestInputOptions): Promise { const { signalData, - library, - chainId, senderAddress, // notification sender recipientAddress, // notification receiver chatId, - onRecieveMessage, - env = Constants.ENV.PROD, - pgpPrivateKey = null, + onReceiveMessage, } = options || {}; try { - const signer: SignerType = await library.getSigner(senderAddress); - console.log( 'accept request', 'options', @@ -264,14 +283,18 @@ export class Video { }); sendVideoCallNotification( - { signer, chainId, pgpPrivateKey }, + { + signer: this.signer, + chainId: this.chainId, + pgpPrivateKey: this.pgpPrivateKey, + }, { senderAddress, recipientAddress, status: VideoCallStatus.RECEIVED, chatId, signalingData: data, - env, + env: this.env, } ); }); @@ -294,7 +317,7 @@ export class Video { // set videoCallInfo state with status connected for the receiver's end this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.status = VideoCallStatus.CONNECTED; + draft.incoming[0].status = VideoCallStatus.CONNECTED; }); }); }); @@ -306,7 +329,7 @@ export class Video { console.log('IS VIDEO ON', parsedData.isVideoOn); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.video = parsedData.isVideoOn; + draft.incoming[0].video = parsedData.isVideoOn; }); }); } @@ -315,18 +338,24 @@ export class Video { console.log('IS AUDIO ON', parsedData.isAudioOn); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.audio = parsedData.isAudioOn; + draft.incoming[0].audio = parsedData.isAudioOn; }); }); } - if (parsedData.type === 'endLocalStream') { - console.log('END LOCAL STREAM', parsedData.endLocalStream); + if (parsedData.type === 'endCall') { + console.log('END CALL', parsedData.endCall); + // destroy the local stream + if (this.data.local.stream) { + endStream(this.data.local.stream); + } + + // reset the state this.setData(() => initVideoCallData); } } else { console.log('received a message', data); - onRecieveMessage(data); + onReceiveMessage ? onReceiveMessage(data) : ''; } }); @@ -334,24 +363,19 @@ export class Video { console.log('received incoming stream', currentStream); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.stream = currentStream; + draft.incoming[0].stream = currentStream; }); }); }); - this.signer = signer; - this.chainId = chainId; - this.pgpPrivateKey = pgpPrivateKey; - this.env = env; - // set videoCallInfo state with status 2 (call received) this.setData((oldData) => { return produce(oldData, (draft) => { draft.local.address = senderAddress; - draft.incoming.address = recipientAddress; + draft.incoming[0].address = recipientAddress; draft.meta.chatId = chatId; draft.meta.initiator.address = senderAddress; - draft.incoming.status = VideoCallStatus.RECEIVED; + draft.incoming[0].status = VideoCallStatus.RECEIVED; }); }); } catch (err) { @@ -370,7 +394,7 @@ export class Video { // set videoCallInfo state with status connected for the caller's end this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming.status = VideoCallStatus.CONNECTED; + draft.incoming[0].status = VideoCallStatus.CONNECTED; }); }); } catch (err) { @@ -380,31 +404,28 @@ export class Video { disconnect(): void { try { - console.log('disconnect'); - if (this.data.incoming.status === VideoCallStatus.CONNECTED) { + console.log('disconnect', 'status', this.data.incoming[0].status); + if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( - JSON.stringify({ type: 'endLocalStream', endLocalStream: true }) + JSON.stringify({ type: 'endCall', endCall: true }) ); this.peerInstance?.destroy(); - - // ending the local stream - this.data.local.stream?.getTracks().forEach((track) => track.stop()); } if ( - this.data.incoming.status === VideoCallStatus.INITIALIZED || - this.data.incoming.status === VideoCallStatus.RECEIVED + this.data.incoming[0].status === VideoCallStatus.INITIALIZED || + this.data.incoming[0].status === VideoCallStatus.RECEIVED ) { // for disconnecting during status 1, 2 - // send a notif to the other user signaling status=4 + // send a notif to the other user signaling status = DISCONNECTED sendVideoCallNotification( { - signer: this.signer!, - chainId: this.chainId!, + signer: this.signer, + chainId: this.chainId, pgpPrivateKey: this.pgpPrivateKey, }, { senderAddress: this.data.local.address, - recipientAddress: this.data.incoming.address, + recipientAddress: this.data.incoming[0].address, status: VideoCallStatus.DISCONNECTED, chatId: this.data.meta.chatId, signalingData: null, @@ -413,6 +434,12 @@ export class Video { ); } + // destroy the local stream + if (this.data.local.stream) { + endStream(this.data.local.stream); + } + + // reset the state this.setData(() => initVideoCallData); } catch (err) { console.log('error in disconnect', err); @@ -423,7 +450,7 @@ export class Video { toggleVideo(): void { console.log('toggleVideo', 'current video', this.data.local.video); - if (this.data.incoming.status === VideoCallStatus.CONNECTED) { + if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( JSON.stringify({ type: 'isVideoOn', isVideoOn: !this.data.local.video }) ); @@ -445,7 +472,7 @@ export class Video { toggleAudio(): void { console.log('toggleAudio', 'current audio', this.data.local.audio); - if (this.data.incoming.status === VideoCallStatus.CONNECTED) { + if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { this.peerInstance?.send( JSON.stringify({ type: 'isAudioOn', isAudioOn: !this.data.local.audio }) ); diff --git a/packages/restapi/src/lib/video/helpers/mediaToggle.ts b/packages/restapi/src/lib/video/helpers/mediaToggle.ts index 6fbdd6cab..260368d97 100644 --- a/packages/restapi/src/lib/video/helpers/mediaToggle.ts +++ b/packages/restapi/src/lib/video/helpers/mediaToggle.ts @@ -21,3 +21,8 @@ export const stopAudioStream = (stream: MediaStream): void => { const audTracks = stream.getAudioTracks(); audTracks.forEach((track) => (track.enabled = false)); }; + +export const endStream = (stream: MediaStream) => { + console.log("END STREAM"); + stream.getTracks().forEach((track) => track.stop()); +} diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts index 408147055..bc24ab4b7 100644 --- a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -1,4 +1,3 @@ -import { getConnectedUser, getWallet } from '../../chat/helpers'; import Constants, { ENV } from '../../constants'; import { getCAIPWithChainId } from '../../helpers'; import { sendNotification } from '../../payloads'; @@ -16,7 +15,7 @@ interface VideoCallInfoType { interface UserInfoType { signer: SignerType; chainId: number; - pgpPrivateKey: string | null; + pgpPrivateKey: string; } interface VideoPayloadType { @@ -28,7 +27,7 @@ interface VideoPayloadType { } const sendVideoCallNotification = async ( - { signer, chainId, pgpPrivateKey = null }: UserInfoType, + { signer, chainId, pgpPrivateKey }: UserInfoType, { recipientAddress, senderAddress, @@ -55,15 +54,12 @@ const sendVideoCallNotification = async ( chainId ); - const wallet = getWallet({ account: senderAddress, signer }); - const connectedUser = await getConnectedUser(wallet, pgpPrivateKey, env); - const notificationText = `Video Call from ${senderAddress}`; await sendNotification({ senderType: 1, // for chat notification signer, - pgpPrivateKey: connectedUser.privateKey!, + pgpPrivateKey, chatId, type: 3, identityType: 2, From 39c9c83a7601036b46d3375f09fa2ca2c63f4121 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 12 May 2023 19:13:16 +0530 Subject: [PATCH 073/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index bf64a2dfb..6b5bb1c64 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.3...restapi-0.0.1-alpha.4) (2023-05-12) + + +### Bug Fixes + +* fix chat.chat for grps ([#382](https://github.com/ethereum-push-notification-service/push-sdk/issues/382)) ([052a75c](https://github.com/ethereum-push-notification-service/push-sdk/commit/052a75ca0f0fea7664d8c607fc85cdf37cc5d398)) +* fix eip712v2 ([#385](https://github.com/ethereum-push-notification-service/push-sdk/issues/385)) ([42c10ba](https://github.com/ethereum-push-notification-service/push-sdk/commit/42c10ba6f5331c9caf5db7136ba94d1a6ed05e10)) +* Merge branch 'alpha' into alpha-deployment ([a1a8666](https://github.com/ethereum-push-notification-service/push-sdk/commit/a1a86661b1823c84328ec90ac9aafc6c57f574f3)) +* Merge branch 'main' into alpha ([5fc51db](https://github.com/ethereum-push-notification-service/push-sdk/commit/5fc51db1a336203048b4b42a5384cb37cf79c509)) +* **video:** separate react state from video class instance variable data ([#389](https://github.com/ethereum-push-notification-service/push-sdk/issues/389)) ([83bf445](https://github.com/ethereum-push-notification-service/push-sdk/commit/83bf4457332b127bf9e41a2f4c93fb851367724d)) + + + ## [0.0.1-alpha.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.2...restapi-0.0.1-alpha.3) (2023-05-11) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 20d87d59f..a8189f308 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.3", + "version": "0.0.1-alpha.4", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 6c321c760055fa9aaebf1ee5f693bbbad16fb9c8 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sat, 13 May 2023 17:28:50 +0530 Subject: [PATCH 074/298] fix: update package json --- packages/uiweb/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 89acb815b..2b2e92379 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -12,7 +12,7 @@ "peerDependencies": { "react": ">=16.8.0", "styled-components": "^5.3.5", - "@pushprotocol/restapi": "^1.2.8", + "@pushprotocol/restapi": "^1.2.15", "@pushprotocol/socket": "^0.4.2" } } From 5052b6ab721a942dcb7560bfe875296fa2d6a992 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sat, 13 May 2023 17:33:04 +0530 Subject: [PATCH 075/298] fix: updated socket version --- packages/uiweb/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 2b2e92379..9a38200c4 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -13,6 +13,6 @@ "react": ">=16.8.0", "styled-components": "^5.3.5", "@pushprotocol/restapi": "^1.2.15", - "@pushprotocol/socket": "^0.4.2" + "@pushprotocol/socket": "^0.5.0" } } From 7edacbf24495d8574d492bf3d5f4e8753364ad45 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sat, 13 May 2023 17:33:29 +0530 Subject: [PATCH 076/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.0.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 10 ++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index fea8965b1..810cc5a54 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-1.0.2) (2023-05-13) + + +### Bug Fixes + +* update package json ([6c321c7](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c321c760055fa9aaebf1ee5f693bbbad16fb9c8)) +* updated socket version ([5052b6a](https://github.com/ethereum-push-notification-service/push-sdk/commit/5052b6ab721a942dcb7560bfe875296fa2d6a992)) + + + ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.0...uiweb-1.0.1) (2023-05-01) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 9a38200c4..4396a526e 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.0.1", + "version": "1.0.2", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 1301f999fe37b8e801a3d3e24aa45cf012db158a Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sat, 13 May 2023 17:41:07 +0530 Subject: [PATCH 077/298] fix: socket lib update --- packages/socket/package-lock.json | 5 + packages/uiweb/package-lock.json | 215 ++++++++++++++++++++++++++++++ packages/uiweb/package.json | 1 + 3 files changed, 221 insertions(+) create mode 100644 packages/socket/package-lock.json create mode 100644 packages/uiweb/package-lock.json diff --git a/packages/socket/package-lock.json b/packages/socket/package-lock.json new file mode 100644 index 000000000..e5bec83f1 --- /dev/null +++ b/packages/socket/package-lock.json @@ -0,0 +1,5 @@ +{ + "name": "@pushprotocol/socket", + "version": "0.5.0", + "lockfileVersion": 1 +} diff --git a/packages/uiweb/package-lock.json b/packages/uiweb/package-lock.json new file mode 100644 index 000000000..764f96b37 --- /dev/null +++ b/packages/uiweb/package-lock.json @@ -0,0 +1,215 @@ +{ + "name": "@pushprotocol/uiweb", + "version": "1.0.2", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "@babel/runtime": { + "version": "7.21.5", + "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.21.5.tgz", + "integrity": "sha512-8jI69toZqqcsnqGGqwGS4Qb1VwLOEp4hz+CXPywcvjs60u3B4Pom/U/7rm4W8tMOYEB+E9wgD0mW1l3r8qlI9Q==", + "requires": { + "regenerator-runtime": "^0.13.11" + } + }, + "@pushprotocol/socket": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz", + "integrity": "sha512-b6hzyUIMunmf2hLeTqTtJFvDG1Ngm+Rho00Z0mod+3khSOKy1Kwgpcpmj9bISLgr0ymeFqMYqNPj9+X89EAMZA==", + "requires": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + } + }, + "@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "date-fns": { + "version": "2.30.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz", + "integrity": "sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==", + "requires": { + "@babel/runtime": "^7.21.0" + } + }, + "debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "requires": { + "ms": "2.1.2" + } + }, + "dom-serializer": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", + "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.0", + "entities": "^2.0.0" + }, + "dependencies": { + "entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==" + } + } + }, + "domelementtype": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", + "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==" + }, + "domhandler": { + "version": "4.3.1", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", + "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", + "requires": { + "domelementtype": "^2.2.0" + } + }, + "domutils": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", + "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", + "requires": { + "dom-serializer": "^1.0.1", + "domelementtype": "^2.2.0", + "domhandler": "^4.2.0" + } + }, + "emoji-picker-react": { + "version": "3.6.5", + "resolved": "https://registry.npmjs.org/emoji-picker-react/-/emoji-picker-react-3.6.5.tgz", + "integrity": "sha512-pfu3XkHSeqXjygyoKtRsmJdsNkRxhkE7hlnWrYBoPnm8V03aJ8Y9H5oRUQ+fF4WRZpjfJFsw5V7ewRVhuj/8cA==" + }, + "engine.io-client": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.4.0.tgz", + "integrity": "sha512-GyKPDyoEha+XZ7iEqam49vz6auPnNJ9ZBfy89f+rMMas8AuiMWOZ9PVzu8xb9ZC6rafUqiGHSCfu22ih66E+1g==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.0.3", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + } + }, + "engine.io-parser": { + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.0.6.tgz", + "integrity": "sha512-tjuoZDMAdEhVnSFleYPCtdL2GXwVTGtNjoeJd9IhIG3C1xs9uwxqRNEu5WpnDZCaozwVlK/nuQhpodhXSIMaxw==" + }, + "entities": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-3.0.1.tgz", + "integrity": "sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q==" + }, + "html-dom-parser": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/html-dom-parser/-/html-dom-parser-1.2.0.tgz", + "integrity": "sha512-2HIpFMvvffsXHFUFjso0M9LqM+1Lm22BF+Df2ba+7QHJXjk63pWChEnI6YG27eaWqUdfnh5/Vy+OXrNTtepRsg==", + "requires": { + "domhandler": "4.3.1", + "htmlparser2": "7.2.0" + } + }, + "html-react-parser": { + "version": "1.4.14", + "resolved": "https://registry.npmjs.org/html-react-parser/-/html-react-parser-1.4.14.tgz", + "integrity": "sha512-pxhNWGie8Y+DGDpSh8cTa0k3g8PsDcwlfolA+XxYo1AGDeB6e2rdlyv4ptU9bOTiZ2i3fID+6kyqs86MN0FYZQ==", + "requires": { + "domhandler": "4.3.1", + "html-dom-parser": "1.2.0", + "react-property": "2.0.0", + "style-to-js": "1.1.1" + } + }, + "htmlparser2": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-7.2.0.tgz", + "integrity": "sha512-H7MImA4MS6cw7nbyURtLPO1Tms7C5H602LRETv95z1MxO/7CP7rDVROehUYeYBUYEON94NXXDEPmZuq+hX4sog==", + "requires": { + "domelementtype": "^2.0.1", + "domhandler": "^4.2.2", + "domutils": "^2.8.0", + "entities": "^3.0.1" + } + }, + "inline-style-parser": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.1.1.tgz", + "integrity": "sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q==" + }, + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + }, + "react-property": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/react-property/-/react-property-2.0.0.tgz", + "integrity": "sha512-kzmNjIgU32mO4mmH5+iUyrqlpFQhF8K2k7eZ4fdLSOPFrD1XgEuSBv9LDEgxRXTMBqMd8ppT0x6TIzqE5pdGdw==" + }, + "regenerator-runtime": { + "version": "0.13.11", + "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz", + "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==" + }, + "socket.io-client": { + "version": "4.6.1", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.6.1.tgz", + "integrity": "sha512-5UswCV6hpaRsNg5kkEHVcbBIXEYoVbMQaHJBXJCyEQ+CiFPV1NIOY0XOFWG4XR4GZcB8Kn6AsRs/9cy9TbqVMQ==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.4.0", + "socket.io-parser": "~4.2.1" + } + }, + "socket.io-parser": { + "version": "4.2.2", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.2.tgz", + "integrity": "sha512-DJtziuKypFkMMHCm2uIshOYC7QaylbtzQwiMYDuCKy3OPkjLzu4B2vAhTlqipRHHzrI0NJeBAizTK7X+6m1jVw==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + } + }, + "style-to-js": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/style-to-js/-/style-to-js-1.1.1.tgz", + "integrity": "sha512-RJ18Z9t2B02sYhZtfWKQq5uplVctgvjTfLWT7+Eb1zjUjIrWzX5SdlkwLGQozrqarTmEzJJ/YmdNJCUNI47elg==", + "requires": { + "style-to-object": "0.3.0" + } + }, + "style-to-object": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/style-to-object/-/style-to-object-0.3.0.tgz", + "integrity": "sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==", + "requires": { + "inline-style-parser": "0.1.1" + } + }, + "tslib": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz", + "integrity": "sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg==" + }, + "ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==" + }, + "xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==" + } + } +} diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 4396a526e..20c7a00db 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -5,6 +5,7 @@ "registry": "https://registry.npmjs.org/" }, "dependencies": { + "@pushprotocol/socket": "^0.5.0", "date-fns": "^2.28.0", "emoji-picker-react": "^3.5.1", "html-react-parser": "^1.4.13" From 259b507725a74aea661c56cd6155b93e0af9d96f Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sat, 13 May 2023 17:41:36 +0530 Subject: [PATCH 078/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.0.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 810cc5a54..7cdac7208 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -5,6 +5,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-1.0.2) (2023-05-13) +### Bug Fixes + +* socket lib update ([1301f99](https://github.com/ethereum-push-notification-service/push-sdk/commit/1301f999fe37b8e801a3d3e24aa45cf012db158a)) +* update package json ([6c321c7](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c321c760055fa9aaebf1ee5f693bbbad16fb9c8)) +* updated socket version ([5052b6a](https://github.com/ethereum-push-notification-service/push-sdk/commit/5052b6ab721a942dcb7560bfe875296fa2d6a992)) + + + +## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-1.0.2) (2023-05-13) + + ### Bug Fixes * update package json ([6c321c7](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c321c760055fa9aaebf1ee5f693bbbad16fb9c8)) From 1fb880207fb4d3400e74d58a13cdd51da26550da Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sun, 14 May 2023 14:04:44 +0530 Subject: [PATCH 079/298] fix: url fix --- packages/uiweb/package.json | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 89acb815b..e8b23acd0 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -16,3 +16,4 @@ "@pushprotocol/socket": "^0.4.2" } } + From 91190a67ca0fd4ecad61f8041ae9adea42cddfac Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sun, 14 May 2023 14:06:34 +0530 Subject: [PATCH 080/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 4 ++++ packages/restapi/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 6b5bb1c64..8348831f3 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.4...restapi-0.0.1-alpha.5) (2023-05-14) + + + ## [0.0.1-alpha.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.3...restapi-0.0.1-alpha.4) (2023-05-12) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index a8189f308..11df93249 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.4", + "version": "0.0.1-alpha.5", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 9c8c86b35d1cb0300d0170e87931dd31a15f9342 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Sun, 14 May 2023 22:38:30 +0530 Subject: [PATCH 081/298] fix: add video call retry logic upon error & doc: add video call in restapi/readme (#391) * docs(video): add video calls in restapi readme * fix(video): add video call retry logic upon error --------- Co-authored-by: Madhur Gupta --- packages/restapi/README.md | 412 +++++++++++++++++++++--- packages/restapi/src/lib/types/index.ts | 9 +- packages/restapi/src/lib/video/Video.ts | 104 ++++-- 3 files changed, 459 insertions(+), 66 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 603b27506..e1e6885ef 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -2,55 +2,82 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer Docs](https://docs.push.org/developers) or [Push.org](https://push.org) to learn more. # Index +- [restapi](#restapi) +- [Index](#index) - [How to use in your app?](#how-to-use-in-your-app) - [Installation](#installation) - [Import SDK](#import-sdk) - - [About generating the signer object for different platforms](#about-generating-the-signer-object-for-different-platforms) - - [About blockchain agnostic address format](#about-blockchain-agnostic-address-format) - - [About Push contract addresses](#about-push-contract-addresses) + - [**About generating the "signer" object for different platforms**](#about-generating-the-signer-object-for-different-platforms) + - [When using in SERVER-SIDE code:](#when-using-in-server-side-code) + - [When using in FRONT-END code:](#when-using-in-front-end-code) + - [**About blockchain agnostic address format**](#about-blockchain-agnostic-address-format) + - [Chat blockchain agnostic address format](#chat-blockchain-agnostic-address-format) + - [**About Push contract addresses**](#about-push-contract-addresses) + - [Push core contract address](#push-core-contract-address) + - [Push communicator contract address](#push-communicator-contract-address) - [SDK Features](#sdk-features) - - [Notification](#for-notification) - - [Fetching user notifications](#fetching-user-notifications) - - [Fetching user spam notifications](#fetching-user-spam-notifications) - - [Fetching user subscriptions](#fetching-user-subscriptions) - - [Fetching channel details](#fetching-channel-details) - - [Searching for channel(s)](#searching-for-channels) - - [Opt in to a channel](#opt-in-to-a-channel) - - [Opt out to a channel](#opt-out-to-a-channel) - - [Sending notification](#sending-notification) - - [Direct payload for single recipient(target)](#direct-payload-for-single-recipienttarget) - - [Direct payload for group of recipients(subset)](#direct-payload-for-group-of-recipientssubset) - - [Direct payload for all recipients(broadcast)](#direct-payload-for-all-recipientsbroadcast) - - [IPFS payload for single recipient(target)](#ipfs-payload-for-single-recipienttarget) - - [IPFS payload for group of recipients(subset)](#ipfs-payload-for-group-of-recipientssubset) - - [IPFS payload for all recipients(broadcast)](#ipfs-payload-for-all-recipientsbroadcast) - - [Minimal payload for single recipient(target)](#minimal-payload-for-single-recipienttarget) - - [Minimal payload for a group of recipient(subset)](#minimal-payload-for-a-group-of-recipientsubset) - - [Minimal payload for all recipients(broadcast)](#minimal-payload-for-all-recipientsbroadcast) - - [Graph payload for single recipient(target)](#graph-payload-for-single-recipienttarget) - - [Graph payload for group of recipients(subset)](#graph-payload-for-group-of-recipientssubset) - - [Graph payload for all recipients(broadcast)](#graph-payload-for-all-recipientsbroadcast) - - [Notification helper utils](#notification-helper-utils) - - [Parsing notifications](#parsing-notifications) - - [Advanced Notification (WIP)](#advanced-notifications-wip) - - [**Deprecated** Get a channel’s subscriber list of addresses](#get-a-channels-subscriber-list-of-addresses) - - [Chat](#for-chat) - - [Create user for chat](#create-user-for-chat) - - [Get user data for chat](#get-user-data-for-chat) - - [Decrypting encrypted pgp private key](#decrypting-encrypted-pgp-private-key-from-user-data) - - [Fetching list of user chats](#fetching-list-of-user-chats) - - [Fetching list of user chat requests](#fetching-list-of-user-chat-requests) - - [Fetching conversation hash between two users](#fetching-conversation-hash-between-two-users) - - [Fetching latest chat between two users](#fetching-latest-chat-between-two-users) - - [Fetching chat history between two users](#fetching-chat-history-between-two-users) - - [To send a message](#to-send-a-message) - - [To approve a chat request](#to-approve-a-chat-request) - - [To create a group](#to-create-a-group) - - [To update group details](#to-update-group-details) - - [To get group details by group name](#to-get-group-details-by-group-name) - - [To get group details by chat id](#to-get-group-details-by-chatid) - - [Chat helper utils](#chat-helper-utils) - - [Decrypting messages](#decrypting-messages) + - [For Notification](#for-notification) + - [**Fetching user notifications**](#fetching-user-notifications) + - [**Fetching user spam notifications**](#fetching-user-spam-notifications) + - [**Fetching user subscriptions**](#fetching-user-subscriptions) + - [**Fetching channel details**](#fetching-channel-details) + - [**Searching for channel(s)**](#searching-for-channels) + - [**Opt in to a channel**](#opt-in-to-a-channel) + - [**Opt out to a channel**](#opt-out-to-a-channel) + - [**Sending notification**](#sending-notification) + - [**Direct payload for single recipient(target)**](#direct-payload-for-single-recipienttarget) + - [**Direct payload for group of recipients(subset)**](#direct-payload-for-group-of-recipientssubset) + - [**Direct payload for all recipients(broadcast)**](#direct-payload-for-all-recipientsbroadcast) + - [**IPFS payload for single recipient(target)**](#ipfs-payload-for-single-recipienttarget) + - [**IPFS payload for group of recipients(subset)**](#ipfs-payload-for-group-of-recipientssubset) + - [**IPFS payload for all recipients(broadcast)**](#ipfs-payload-for-all-recipientsbroadcast) + - [**Minimal payload for single recipient(target)**](#minimal-payload-for-single-recipienttarget) + - [**Minimal payload for a group of recipient(subset)**](#minimal-payload-for-a-group-of-recipientsubset) + - [**Minimal payload for all recipients(broadcast)**](#minimal-payload-for-all-recipientsbroadcast) + - [**Graph payload for single recipient(target)**](#graph-payload-for-single-recipienttarget) + - [**Graph payload for group of recipients(subset)**](#graph-payload-for-group-of-recipientssubset) + - [**Graph payload for all recipients(broadcast)**](#graph-payload-for-all-recipientsbroadcast) + - [Notification Helper Utils](#notification-helper-utils) + - [**Parsing notifications**](#parsing-notifications) + - [Advanced Notifications (WIP)](#advanced-notifications-wip) + - [DEPRECATED](#deprecated) + - [**Get a channel's subscriber list of addresses**](#get-a-channels-subscriber-list-of-addresses) + - [For Chat](#for-chat) + - [**Create user for chat**](#create-user-for-chat) + - [**Get user data for chat**](#get-user-data-for-chat) + - [**Decrypting encrypted pgp private key from user data**](#decrypting-encrypted-pgp-private-key-from-user-data) + - [**Fetching list of user chats**](#fetching-list-of-user-chats) + - [**Fetching list of user chat requests**](#fetching-list-of-user-chat-requests) + - [**Fetching conversation hash between two users**](#fetching-conversation-hash-between-two-users) + - [**Fetching latest chat between two users**](#fetching-latest-chat-between-two-users) + - [**Fetching chat history between two users**](#fetching-chat-history-between-two-users) + - [**To send a message**](#to-send-a-message) + - [**To approve a chat request**](#to-approve-a-chat-request) + - [**To create a group**](#to-create-a-group) + - [**To update group details**](#to-update-group-details) + - [**To get group details by group name**](#to-get-group-details-by-group-name) + - [**To get group details by chatId**](#to-get-group-details-by-chatid) + - [**Chat Helper Utils**](#chat-helper-utils) + - [**Decrypting messages**](#decrypting-messages) + - [For Video](#for-video) + - [**Instance Variables**](#instance-variables) + - [**peerInstance**](#peerinstance) + - [**signer**](#signer) + - [**chainId**](#chainid) + - [**pgpPrivateKey**](#pgpprivatekey) + - [**env**](#env) + - [**data**](#data) + - [**setData**](#setdata) + - [**Methods**](#methods) + - [**constructor**](#constructor) + - [**create**](#create) + - [**request**](#request) + - [**acceptRequest**](#acceptrequest) + - [**connect**](#connect) + - [**disconnect**](#disconnect) + - [**toggleVideo**](#togglevideo) + - [**toggleAudio**](#toggleaudio) + - [**isInitiator**](#isinitiator) # How to use in your app? ## Installation @@ -3227,3 +3254,298 @@ Allowed Options (params with * are mandatory) ----- + +## For Video + +### **Instance Variables** +#### **peerInstance** +- Used to store the simple peer instance used for the webRTC connection. +```typescript +private peerInstance: any = null; +``` + +----- + +#### **signer** +- Used to store the signer of a user. +- Used in the request, acceptRequest and disconnect methods to send notifications. +```typescript + private signer: SignerType; +``` + +----- + +#### **chainId** +The chain id of the chain on which the call is being conducted. +```typescript + private chainId: number; +``` + +----- + +#### **pgpPrivateKey** +- Used to store the PGP private key of a user. +- Used in the request, acceptRequest and disconnect methods to send notifications. +```typescript + private pgpPrivateKey: string; +``` + +----- + +#### **env** +- The environment on which the call is being conducted. +```typescript +private env: ENV; +``` + +----- + +### **data** +- Stores data related to the video call. +```typescript +export type IMediaStream = MediaStream | null; + +export enum VideoCallStatus { + UNINITIALIZED, + INITIALIZED, + RECEIVED, + CONNECTED, + DISCONNECTED, + RETRY_INITIALIZED, + RETRY_RECEIVED, +} + +export type PeerData = { + stream: IMediaStream; // incoming media stream + audio: boolean | null; // incoming audio status + video: boolean | null; // incoming video status + address: string; // incoming address + status: VideoCallStatus; // status for the connection with incoming peer + retryCount: number; // number of retires done +}; + +export type VideoCallData = { + meta: { + chatId: string; // unique chatId for the corresponding push w2w chat + initiator: { + address: string; // initiator's address + signal: any; // initiator's signaling data for webRTC connection + }; + broadcast?: { + livepeerInfo: any; + hostAddress: string; + coHostAddress: string; + }; + }; + local: { + stream: IMediaStream; // local media stream + audio: boolean | null; // local audio status + video: boolean | null; // local video status + address: string; // local address + }; + incoming: [PeerData]; +}; + +private data: VideoCallData; +``` + +----- + +#### **setData** +- This function can be used to update the video call ```data``` +```typescript +setData: (fn: (data: VideoCallData) => VideoCallData) => void; + +// usage + +import { produce } from 'immer'; + +setData((oldData) => { + return produce(oldData, (draft) => { + // update the draft object, example + draft.incoming.status = VideoCallStatus.INITIALIZED; + }); +}); +``` + +----- + +### **Methods** +#### **constructor** +```typescript +constructor({ + signer, + chainId, + pgpPrivateKey, + env, + setData, + }: { + signer: SignerType; + chainId: number; + pgpPrivateKey: string; + env?: ENV; + setData: (fn: (data: VideoCallData) => VideoCallData) => void; + }) {} +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| signer* | SignerType | - | signer object for a user | +| chainId* | number | - | chainId for the video call - Eth Mainnet: 1, Polygon Mainnet: 137 | +| pgpPrivatekey* | string | - | PGP private key of the user, used while sending video call notifications | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| setData* | ```(fn: (data: VideoCallData) => VideoCallData) => void``` | - | Function to update video call data | + +----- + +#### **create** +- This method is used to create a local stream +- Assigns the local stream obtained from the ```navigator.mediaDevices.getUserMedia``` to `data.local.stream` state. +```typescript +export type VideoCreateInputOptions = { + video?: boolean; + audio?: boolean; +}; + +async create(options: VideoCreateInputOptions): Promise {} +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| video | boolean | true | video status for the local stream | +| audio | boolean | true | audio status for the local stream | + +Note - If audio, video aren't enabled in create() then they wont be available during the call respectively. + +----- + +#### **request** +- This method is used to request a push video call. +- Will be triggered on the initiator's end. +```typescript +export type VideoRequestInputOptions = { + senderAddress: string; + recipientAddress: string; + chatId: string; + onReceiveMessage?: (message: string) => void; + retry?: boolean; +}; + +async request(options: VideoRequestInputOptions): Promise {} +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| senderAddress* | string | - | Local peer address | +| recipientAddress* | string | - | Incoming/remote peer address | +| chatId* | string | - | Unique identifier for every wallet-to-wallet push chat, will be used during verification proof generation | +| onReceiveMessage | ```(message: string) => void``` | ```(message: string) => {console.log('received a meesage', message);}``` | Function which will be called when the sender receives a message via webRTC data channel | +| retry | boolean | false | If we are retrying the call, only for internal use | + + +----- + +#### **acceptRequest** +- This method is used to accept a push video call. +- Will be triggered on the receiver's end. +```typescript +export type VideoAcceptRequestInputOptions = { + signalData: any; + senderAddress: string; + recipientAddress: string; + chatId: string; + onReceiveMessage?: (message: string) => void; + retry?: boolean; +}; + +async acceptRequest(options: VideoAcceptRequestInputOptions): Promise {} +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| signalData* | any | - | Signal data received from the initiator peer via psuh notification upon call request | +| senderAddress* | string | - | Local peer address | +| recipientAddress* | string | - | Incoming/remote peer address | +| chatId* | string | - | Unique identifier for every wallet-to-wallet push chat, will be used during verification proof generation | +| onReceiveMessage | ```(message: string) => void``` | ```(message: string) => {console.log('received a meesage', message);}``` | Function which will be called when the sender receives a message via webRTC data channel | +| retry | boolean | false | If we are retrying the call, only for internal use | + +----- + +#### **connect** +- This is the final method which is used to connect a push video call. +- Will be triggered on the initiator's end. +```typescript +export type VideoConnectInputOptions = { + signalData: any; +}; + +connect(options: VideoConnectInputOptions): void {} +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| signalData* | any | - | Signal data received from the receiver peer via push notification upon call acceptRequest | + +----- + +#### **disconnect** +- This method is used to end a push video call. +- Can be triggered on the initiator as well as receivers end. +```typescript +disconnect(): void {} +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| - | - | - | - | + +----- + +#### **toggleVideo** +- This method is used to toggle the video (from ```data.local.stream```) on or off for a push video call. +- Can be triggered on the initiator as well as receivers end. +- **Note -** If video was not enabled during ```create()``` then it will always remain off. +```typescript +toggleVideo(): void +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| - | - | - | - | + +----- + +#### **toggleAudio** +- This method is used to toggle the audio (from ```data.local.stream```) on or off for a push video call. +- Can be triggered on the initiator as well as receivers end. +- **Note -** If audio was not enabled during ```create()``` then it will always remain off. +```typescript +toggleAudio(): void +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| - | - | - | - | + +----- + +#### **isInitiator** +- This method is used to tell if the current peer is the initator of the push video call or not. +- Can be triggered on the initiator as well as receivers end. +```typescript +isInitiator(): boolean +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| - | - | - | - | diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 508110bf8..c4daeac08 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -330,6 +330,8 @@ export enum VideoCallStatus { RECEIVED, CONNECTED, DISCONNECTED, + RETRY_INITIALIZED, + RETRY_RECEIVED, } export type PeerData = { @@ -338,6 +340,7 @@ export type PeerData = { video: boolean | null; address: string; status: VideoCallStatus; + retryCount: number; }; export type VideoCallData = { @@ -363,8 +366,8 @@ export type VideoCallData = { }; export type VideoCreateInputOptions = { - video: boolean; - audio: boolean; + video?: boolean; + audio?: boolean; }; export type VideoRequestInputOptions = { @@ -372,6 +375,7 @@ export type VideoRequestInputOptions = { recipientAddress: string; chatId: string; onReceiveMessage?: (message: string) => void; + retry?: boolean; }; export type VideoAcceptRequestInputOptions = { @@ -380,6 +384,7 @@ export type VideoAcceptRequestInputOptions = { recipientAddress: string; chatId: string; onReceiveMessage?: (message: string) => void; + retry?: boolean; }; export type VideoConnectInputOptions = { diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 0a538f3f2..7ef15397e 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -45,6 +45,7 @@ export const initVideoCallData: VideoCallData = { video: null, address: '', status: VideoCallStatus.UNINITIALIZED, + retryCount: 0, }, ], }; @@ -97,12 +98,12 @@ export class Video { } async create(options: VideoCreateInputOptions): Promise { - const { audio, video } = options || {}; + const { audio = true, video = true } = options || {}; try { const localStream = await navigator.mediaDevices.getUserMedia({ - video: true, - audio: true, + video, + audio, }); if (video === false) { @@ -129,7 +130,10 @@ export class Video { senderAddress, // notification sender recipientAddress, // notification receiver chatId, - onReceiveMessage, + onReceiveMessage = (message: string) => { + console.log('received a meesage', message); + }, + retry = false, } = options || {}; try { @@ -164,7 +168,9 @@ export class Video { { senderAddress, recipientAddress, - status: VideoCallStatus.INITIALIZED, + status: retry + ? VideoCallStatus.RETRY_INITIALIZED + : VideoCallStatus.INITIALIZED, chatId, signalingData: data, env: this.env, @@ -186,6 +192,15 @@ export class Video { isAudioOn: this.data.local.audio, }) ); + + // set videoCallInfo state with status received for the sender's end + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.incoming[0].status = retry + ? VideoCallStatus.RETRY_RECEIVED + : VideoCallStatus.RECEIVED; + }); + }); }); this.peerInstance.on('data', (data: any) => { @@ -220,8 +235,7 @@ export class Video { this.setData(() => initVideoCallData); } } else { - console.log('received a message', data); - onReceiveMessage ? onReceiveMessage(data) : ''; + onReceiveMessage(data); } }); @@ -241,7 +255,10 @@ export class Video { draft.incoming[0].address = recipientAddress; draft.meta.chatId = chatId; draft.meta.initiator.address = senderAddress; - draft.incoming[0].status = VideoCallStatus.INITIALIZED; + draft.incoming[0].status = retry + ? VideoCallStatus.RETRY_INITIALIZED + : VideoCallStatus.INITIALIZED; + draft.incoming[0].retryCount += retry ? 1 : 0; }); }); } catch (err) { @@ -255,7 +272,9 @@ export class Video { senderAddress, // notification sender recipientAddress, // notification receiver chatId, - onReceiveMessage, + onReceiveMessage = (message: string) => { + console.log('received a meesage', message);}, + retry = false, } = options || {}; try { @@ -291,7 +310,9 @@ export class Video { { senderAddress, recipientAddress, - status: VideoCallStatus.RECEIVED, + status: retry + ? VideoCallStatus.RETRY_RECEIVED + : VideoCallStatus.RECEIVED, chatId, signalingData: data, env: this.env, @@ -354,8 +375,7 @@ export class Video { this.setData(() => initVideoCallData); } } else { - console.log('received a message', data); - onReceiveMessage ? onReceiveMessage(data) : ''; + onReceiveMessage(data); } }); @@ -375,11 +395,36 @@ export class Video { draft.incoming[0].address = recipientAddress; draft.meta.chatId = chatId; draft.meta.initiator.address = senderAddress; - draft.incoming[0].status = VideoCallStatus.RECEIVED; + draft.incoming[0].status = retry + ? VideoCallStatus.RETRY_RECEIVED + : VideoCallStatus.RECEIVED; + draft.incoming[0].retryCount += retry ? 1 : 0; }); }); } catch (err) { console.log('error in accept request', err); + + if (this.data.incoming[0].retryCount >= 5) { + console.log('Max retries exceeded, please try again.'); + this.disconnect(); + } + + // retrying in case of connection error + sendVideoCallNotification( + { + signer: this.signer, + chainId: this.chainId, + pgpPrivateKey: this.pgpPrivateKey, + }, + { + senderAddress, + recipientAddress, + status: VideoCallStatus.RETRY_INITIALIZED, + chatId, + signalingData: null, + env: this.env, + } + ); } } @@ -399,6 +444,19 @@ export class Video { }); } catch (err) { console.log('error in connect', err); + + if (this.data.incoming[0].retryCount >= 5) { + console.log('Max retries exceeded, please try again.'); + this.disconnect(); + } + + // retrying in case of connection error + this.request({ + senderAddress: this.data.local.address, + recipientAddress: this.data.incoming[0].address, + chatId: this.data.meta.chatId, + retry: true, + }); } } @@ -410,12 +468,8 @@ export class Video { JSON.stringify({ type: 'endCall', endCall: true }) ); this.peerInstance?.destroy(); - } - if ( - this.data.incoming[0].status === VideoCallStatus.INITIALIZED || - this.data.incoming[0].status === VideoCallStatus.RECEIVED - ) { - // for disconnecting during status 1, 2 + } else { + // for disconnecting during status INITIALIZED, RECEIVED, RETRY_INITIALIZED, RETRY_RECEIVED // send a notif to the other user signaling status = DISCONNECTED sendVideoCallNotification( { @@ -491,4 +545,16 @@ export class Video { }); } } + + // helper functions + + isInitiator(): boolean { + if ( + this.data.meta.initiator.address === '' || + this.data.local.address === '' + ) + return false; + + return this.data.meta.initiator.address === this.data.local.address; + } } From 3ab451663543245b02ea448b34ac5bbd9a44fc20 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Sun, 14 May 2023 23:50:05 +0530 Subject: [PATCH 082/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8348831f3..8163a8c91 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.5...restapi-0.0.1-alpha.6) (2023-05-14) + + +### Bug Fixes + +* add video call retry logic upon error & doc: add video call in restapi/readme ([#391](https://github.com/ethereum-push-notification-service/push-sdk/issues/391)) ([9c8c86b](https://github.com/ethereum-push-notification-service/push-sdk/commit/9c8c86b35d1cb0300d0170e87931dd31a15f9342)) + + + ## [0.0.1-alpha.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.4...restapi-0.0.1-alpha.5) (2023-05-14) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 11df93249..2976e8666 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.5", + "version": "0.0.1-alpha.6", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 7441ef0fb2c9ed39e12a4f1819ade0ee7e0d6b10 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Mon, 15 May 2023 14:20:32 +0530 Subject: [PATCH 083/298] fix(video): remove status change upon connect in request (#394) Co-authored-by: Madhur Gupta --- packages/restapi/src/lib/video/Video.ts | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 7ef15397e..64cfaad99 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -192,15 +192,6 @@ export class Video { isAudioOn: this.data.local.audio, }) ); - - // set videoCallInfo state with status received for the sender's end - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.incoming[0].status = retry - ? VideoCallStatus.RETRY_RECEIVED - : VideoCallStatus.RECEIVED; - }); - }); }); this.peerInstance.on('data', (data: any) => { @@ -273,7 +264,8 @@ export class Video { recipientAddress, // notification receiver chatId, onReceiveMessage = (message: string) => { - console.log('received a meesage', message);}, + console.log('received a meesage', message); + }, retry = false, } = options || {}; From c4abb656b6b031b13f955522273cfac127f54ef7 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 15 May 2023 14:21:39 +0530 Subject: [PATCH 084/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8163a8c91..ae5065136 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.6...restapi-0.0.1-alpha.7) (2023-05-15) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([37c1c8d](https://github.com/ethereum-push-notification-service/push-sdk/commit/37c1c8db579876f5835c2e5bb5e6baf073dc9208)) +* **video:** remove status change upon connect in request ([#394](https://github.com/ethereum-push-notification-service/push-sdk/issues/394)) ([7441ef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/7441ef0fb2c9ed39e12a4f1819ade0ee7e0d6b10)) + + + ## [0.0.1-alpha.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.5...restapi-0.0.1-alpha.6) (2023-05-14) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 2976e8666..43dfdaa00 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.6", + "version": "0.0.1-alpha.7", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 3d892f5f89e58c0b94d203996c0a026178530622 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Tue, 16 May 2023 14:27:07 +0530 Subject: [PATCH 085/298] docs: add push video backend example (#396) * docs(video): add backend exmaple for push video * fix(video): add backend compatibility to create function --------- Co-authored-by: Madhur Gupta --- .../examples/sdk-backend-node/.env.sample | 14 +- .../examples/sdk-backend-node/src/main.ts | 182 +++++++++++++++++- packages/restapi/src/lib/types/index.ts | 1 + packages/restapi/src/lib/video/Video.ts | 14 +- 4 files changed, 204 insertions(+), 7 deletions(-) diff --git a/packages/examples/sdk-backend-node/.env.sample b/packages/examples/sdk-backend-node/.env.sample index ab1cd1e64..550450212 100644 --- a/packages/examples/sdk-backend-node/.env.sample +++ b/packages/examples/sdk-backend-node/.env.sample @@ -35,4 +35,16 @@ NFT_TOKEN_ID_2=your_nft_token_id NFT_HOLDER_WALLET_PRIVATE_KEY_2=your_nft_holder_wallet_private_key # NFT PROFILE WALLET PASSWORD -NFT_PROFILE_PASSWORD_2=your_nft_profile_password \ No newline at end of file +NFT_PROFILE_PASSWORD_2=your_nft_profile_password + +# VIDEO CHAIN ID +VIDEO_CHAIN_ID=your_video_chain_id + +# VIDEO SENDER ADDRESS +VIDEO_SENDER_ADDRESS=your_video_sender_address + +# VIDEO RECIPEINT ADDRESS +VIDEO_RECIPEINT_ADDRESS=your_video_recipeint_address + +# VIDEO CHAT ID +VIDEO_CHAT_ID=your_video_chat_id \ No newline at end of file diff --git a/packages/examples/sdk-backend-node/src/main.ts b/packages/examples/sdk-backend-node/src/main.ts index d50a24ebe..6c6185131 100644 --- a/packages/examples/sdk-backend-node/src/main.ts +++ b/packages/examples/sdk-backend-node/src/main.ts @@ -73,6 +73,19 @@ const updatedNftGroupName = uniqueNamesGenerator({ dictionaries: [adjectives, colors, animals], }); +// Video Data +const videoChainId = +process.env.VIDEO_CHAIN_ID; +let videoData = PushAPI.video.initVideoCallData; +const videoSetData: (fn:(data:PushAPI.VideoCallData) => PushAPI.VideoCallData) => void = (fn) => { + videoData = fn(videoData); +} +let videoObject = null; +const videoLocalStream = null; // get the local stream +const videoSenderAddress = process.env.VIDEO_SENDER_ADDRESS; +const videoRecipientAddress = process.env.VIDEO_RECIPEINT_ADDRESS; +const videoChatId = process.env.VIDEO_CHAT_ID; +let videoSignalData_1 = null; + // Push Notification - Run Notifications Use cases async function runNotificaitonsUseCases() { console.log(` @@ -1484,13 +1497,180 @@ async function PushNFTChatSDKSocket(silent = !showAPIResponse) { await delay(4000); } +// Push Video - Run Video Use cases +async function runVideoUseCases(){ + console.log(` +██╗ ██╗██╗██████╗ ███████╗ ██████╗ +██║ ██║██║██╔══██╗██╔════╝██╔═══██╗ +██║ ██║██║██║ ██║█████╗ ██║ ██║ +╚██╗ ██╔╝██║██║ ██║██╔══╝ ██║ ██║ + ╚████╔╝ ██║██████╔╝███████╗╚██████╔╝ + ╚═══╝ ╚═╝╚═════╝ ╚══════╝ ╚═════╝ + `); + console.log('new PushAPI.video.Video({...})'); + videoObject = await PushAPI_video_object_init(); + + console.log('await videoObject.create({...})'); + videoObject = await PushAPI_video_create(); + + console.log('await videoObject.request({...})'); + videoObject = await PushAPI_video_request(); // for initiator + + console.log('await videoObject.acceptRequest({...})'); + videoObject = await PushAPI_video_accept_request(); // for receiver + + console.log('videoObject.connect()'); + // should be only called inside of the USER_FEEDS event handler as shown later in PushVideoSDKSocket + videoObject = await PushAPI_video_connect(); // for initiator + + console.log('videoObject.disconnect()'); + videoObject = await PushAPI_video_disconnect(); + + console.log('Push Video - PushSDKSocket()'); + await PushVideoSDKSocket(); +} + +async function PushAPI_video_object_init(){ + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + + signer: signer, + }); + + // Init the Video object + const videoObject = new PushAPI.video.Video({ + signer, + chainId: videoChainId, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + setData: videoSetData, + }); + + return videoObject; +} + +async function PushAPI_video_create(){ + await videoObject.create({ + stream: videoLocalStream +}); +} + +async function PushAPI_video_request() { + videoObject.request({ + senderAddress: videoSenderAddress, + recipientAddress: videoRecipientAddress, + chatId: videoChatId, + }); +} + +async function PushAPI_video_accept_request(){ + videoObject.acceptRequest({ + signalData: videoSignalData_1, + senderAddress: videoRecipientAddress, + recipientAddress: videoSenderAddress, + chatId: videoChatId, + }); +} + +async function PushAPI_video_connect(){ + videoObject.connect({ + signalData: {} // signalData from sockets + }) +} + +async function PushAPI_video_disconnect(){ + videoObject.disconnect(); +} + +async function PushVideoSDKSocket() { + const pushSDKSocket = createSocketConnection({ + user: videoSenderAddress, + socketType: 'chat', + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + env: env as ENV, + }); + + if (!pushSDKSocket) { + throw new Error('Socket not connected'); + } + + pushSDKSocket.on(EVENTS.USER_FEEDS, (feedItem) => { + const { payload } = feedItem || {}; + + if ( + Object.prototype.hasOwnProperty.call(payload, 'data') && + Object.prototype.hasOwnProperty.call(payload['data'], 'additionalMeta') + ) { + const additionalMeta = JSON.parse(payload['data']['additionalMeta']); + + if (additionalMeta.status === PushAPI.VideoCallStatus.INITIALIZED) { + videoSignalData_1 = additionalMeta.signalingData; + } else if ( + additionalMeta.status === PushAPI.VideoCallStatus.RECEIVED || + additionalMeta.status === PushAPI.VideoCallStatus.RETRY_RECEIVED + ) { + videoObject.connect({ + signalData: additionalMeta.signalingData, + }); + } else if ( + additionalMeta.status === PushAPI.VideoCallStatus.DISCONNECTED + ) { + // can clear out the states here + } else if ( + additionalMeta.status === PushAPI.VideoCallStatus.RETRY_INITIALIZED && + videoObject.isInitiator() + ) { + videoObject.request({ + senderAddress: videoSenderAddress, + recipientAddress: videoRecipientAddress, + chatId: videoChatId, + retry: true, + }); + } else if ( + additionalMeta.status === PushAPI.VideoCallStatus.RETRY_INITIALIZED && + !videoObject.isInitiator() + ) { + videoObject.acceptRequest({ + signalData: additionalMeta.signalingData, + senderAddress: videoRecipientAddress, + recipientAddress: videoSenderAddress, + chatId: videoChatId, + retry: true, + }); + } + } + }); + + const delay = (ms: number) => + new Promise((resolve) => setTimeout(resolve, ms)); + await delay(4000); +} + // Use Cases function start() { console.log(`${returnHeadingLog()}`); console.log(`${returnENVLog()}`); runNotificaitonsUseCases().then(() => { runChatUseCases().then(() => { - runNFTChatUseCases(); + runNFTChatUseCases().then(() => { + if(videoLocalStream !== null){ + /* + - One instance of videoObject corresponds to one user/peer of the call + - For a wallet-to-wallet video call we need 2 such users/peers + - One of these peer would be the initiator and the other would be the receiver + - Stream object has to be fetched from the frontend of your app to the backend and supplied to videoLocalStream corresponding to each of the peer + - Might be of help: https://stackoverflow.com/questions/25523289/sending-a-mediastream-to-host-server-with-webrtc-after-it-is-captured-by-getuser + */ + runVideoUseCases(); + } + }); }); }); } diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index c4daeac08..e4bbfa8e7 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -368,6 +368,7 @@ export type VideoCallData = { export type VideoCreateInputOptions = { video?: boolean; audio?: boolean; + stream?: MediaStream; // for backend use }; export type VideoRequestInputOptions = { diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 64cfaad99..3fe01cf5c 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -98,13 +98,17 @@ export class Video { } async create(options: VideoCreateInputOptions): Promise { - const { audio = true, video = true } = options || {}; + const { audio = true, video = true, stream = null } = options || {}; try { - const localStream = await navigator.mediaDevices.getUserMedia({ - video, - audio, - }); + const localStream = + stream !== null + ? stream // for backend + : await navigator.mediaDevices.getUserMedia({ + // for frontend + video, + audio, + }); if (video === false) { stopVideoStream(localStream); From 0b609bec87a6187d1e7cbf8052a2b9a36b9fcd7a Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Tue, 16 May 2023 15:50:37 +0530 Subject: [PATCH 086/298] fix(video): set trickle to true while creating peer instance (#397) Co-authored-by: Madhur Gupta --- packages/restapi/src/lib/video/Video.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 3fe01cf5c..b7a3b0f31 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -151,7 +151,7 @@ export class Video { this.peerInstance = new Peer({ initiator: true, - trickle: false, + trickle: true, stream: this.data.local.stream, }); @@ -284,7 +284,7 @@ export class Video { this.peerInstance = new Peer({ initiator: false, - trickle: false, + trickle: true, stream: this.data.local.stream, }); From 262c06ba76d20e74ae17bf53a1e0a86b85155400 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 16 May 2023 15:53:24 +0530 Subject: [PATCH 087/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index ae5065136..5734eaf8b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.7...restapi-0.0.1-alpha.8) (2023-05-16) + + +### Bug Fixes + +* add deprecated info to chat.chat ([#392](https://github.com/ethereum-push-notification-service/push-sdk/issues/392)) ([d84ae64](https://github.com/ethereum-push-notification-service/push-sdk/commit/d84ae64c116adb7eea9e8faf7929b6eb3b74c657)) +* Merge branch 'alpha' into alpha-deployment ([549fd83](https://github.com/ethereum-push-notification-service/push-sdk/commit/549fd839867d84a98a10206a7f9945aeb1720e49)) +* Merge branch 'main' into alpha ([72464fd](https://github.com/ethereum-push-notification-service/push-sdk/commit/72464fd97260b612649035e3b241f946de8f9e92)) +* show hardcoded msg rather than throwing error ([#388](https://github.com/ethereum-push-notification-service/push-sdk/issues/388)) ([8962e10](https://github.com/ethereum-push-notification-service/push-sdk/commit/8962e10036916d0bc161324f5684f74bb7b74dc3)) +* **video:** set trickle to true while creating peer instance ([#397](https://github.com/ethereum-push-notification-service/push-sdk/issues/397)) ([0b609be](https://github.com/ethereum-push-notification-service/push-sdk/commit/0b609bec87a6187d1e7cbf8052a2b9a36b9fcd7a)) + + + ## [0.0.1-alpha.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.6...restapi-0.0.1-alpha.7) (2023-05-15) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 43dfdaa00..7affe8c67 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.7", + "version": "0.0.1-alpha.8", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ae5b38e702539eaf92a516b4e557c5a88de0f4c7 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Tue, 16 May 2023 16:48:11 +0530 Subject: [PATCH 088/298] fix(video): turn off trickle while creating peer instance (#398) Co-authored-by: Madhur Gupta --- packages/restapi/src/lib/video/Video.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index b7a3b0f31..3fe01cf5c 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -151,7 +151,7 @@ export class Video { this.peerInstance = new Peer({ initiator: true, - trickle: true, + trickle: false, stream: this.data.local.stream, }); @@ -284,7 +284,7 @@ export class Video { this.peerInstance = new Peer({ initiator: false, - trickle: true, + trickle: false, stream: this.data.local.stream, }); From 598fc55c18cc8121397975fbd9717e604090daa7 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 16 May 2023 16:49:25 +0530 Subject: [PATCH 089/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 5734eaf8b..7197fb8fe 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.8...restapi-0.0.1-alpha.9) (2023-05-16) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([469398d](https://github.com/ethereum-push-notification-service/push-sdk/commit/469398dc94df805257d6a6bb8e0707cebc5f7d8a)) +* **video:** turn off trickle while creating peer instance ([#398](https://github.com/ethereum-push-notification-service/push-sdk/issues/398)) ([ae5b38e](https://github.com/ethereum-push-notification-service/push-sdk/commit/ae5b38e702539eaf92a516b4e557c5a88de0f4c7)) + + + ## [0.0.1-alpha.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.7...restapi-0.0.1-alpha.8) (2023-05-16) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 7affe8c67..8d11b8110 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.8", + "version": "0.0.1-alpha.9", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From eda1a345975141c5656891dbf919aacd2924d66b Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Wed, 17 May 2023 15:29:41 +0530 Subject: [PATCH 090/298] fix: added deprecated info to history (#399) --- .../restapi/src/lib/chat/helpers/inbox.ts | 36 +++++++++++++++++++ .../src/lib/chat/historicalMessages.ts | 9 +++-- packages/restapi/src/lib/types/index.ts | 2 ++ 3 files changed, 45 insertions(+), 2 deletions(-) diff --git a/packages/restapi/src/lib/chat/helpers/inbox.ts b/packages/restapi/src/lib/chat/helpers/inbox.ts index 447bdf4b2..3757a59f3 100644 --- a/packages/restapi/src/lib/chat/helpers/inbox.ts +++ b/packages/restapi/src/lib/chat/helpers/inbox.ts @@ -135,3 +135,39 @@ export const addDeprecatedInfo = (() => { return chats; }; })(); + +//immediately invoked function expression to maintain latestDIDs +export const addDeprecatedInfoToMessages = (() => { + // mapping for LAtest NFT DIDs + const latestDIDs: { [key: string]: string } = {}; + return (chats: IMessageIPFS[]): IMessageIPFS[] => { + chats.forEach((chat) => { + if (isValidCAIP10NFTAddress(chat.fromDID)) { + const didWithoutTimestamp = chat.fromDID + .split(':') + .slice(0, 5) + .join(':'); + const timestamp = chat.fromDID.split(':')[5]; + if ( + !latestDIDs[didWithoutTimestamp] || + timestamp > latestDIDs[didWithoutTimestamp].split(':')[5] + ) { + latestDIDs[didWithoutTimestamp] = chat.fromDID; + } + } + }); + chats.forEach((chat) => { + if (isValidCAIP10NFTAddress(chat.fromDID)) { + const didWithoutTimestamp = chat.fromDID + .split(':') + .slice(0, 5) + .join(':'); + if (latestDIDs[didWithoutTimestamp] !== chat.fromDID) { + chat['deprecated'] = true; + chat['deprecatedCode'] = 'NFT Owner Changed'; + } + } + }); + return chats; + }; +})(); diff --git a/packages/restapi/src/lib/chat/historicalMessages.ts b/packages/restapi/src/lib/chat/historicalMessages.ts index fe0bbb947..18b42ace2 100644 --- a/packages/restapi/src/lib/chat/historicalMessages.ts +++ b/packages/restapi/src/lib/chat/historicalMessages.ts @@ -2,7 +2,11 @@ import Constants from '../constants'; import { pCAIP10ToWallet } from '../helpers'; import { AccountEnvOptionsType, IMessageIPFS } from '../types'; import { get } from '../user'; -import { decryptConversation, getMessagesService } from './helpers'; +import { + addDeprecatedInfoToMessages, + decryptConversation, + getMessagesService, +} from './helpers'; enum FetchLimit { MIN = 1, @@ -44,10 +48,11 @@ export const history = async ( } const messages = await getMessagesService({ threadhash, limit, env }); + const updatedMessages = addDeprecatedInfoToMessages(messages); const connectedUser = await get({ account: pCAIP10ToWallet(account), env }); if (toDecrypt) { return await decryptConversation({ - messages, + messages: updatedMessages, connectedUser, pgpPrivateKey, env, diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index e4bbfa8e7..648cb5618 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -133,6 +133,8 @@ export interface IMessageIPFS { timestamp?: number; encType: string; encryptedSecret: string; + deprecated?: boolean; // scope only at sdk level + deprecatedCode?: string; // scope only at sdk level } export interface IFeeds { msg: IMessageIPFS; From 89bd0fb13caad9170dd806d7e0470e99600c77dc Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 17 May 2023 15:30:35 +0530 Subject: [PATCH 091/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.10?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 7197fb8fe..2726c340c 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.9...restapi-0.0.1-alpha.10) (2023-05-17) + + +### Bug Fixes + +* added deprecated info to history ([#399](https://github.com/ethereum-push-notification-service/push-sdk/issues/399)) ([eda1a34](https://github.com/ethereum-push-notification-service/push-sdk/commit/eda1a345975141c5656891dbf919aacd2924d66b)) +* Merge branch 'alpha' into alpha-deployment ([46ebed2](https://github.com/ethereum-push-notification-service/push-sdk/commit/46ebed2b9d4b4ff0518429a091d0a37b1d3f022d)) + + + ## [0.0.1-alpha.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.8...restapi-0.0.1-alpha.9) (2023-05-16) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 8d11b8110..b6c689437 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.9", + "version": "0.0.1-alpha.10", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 26f6fcb9b2992850cd33ea613cea13830bd48bc3 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Thu, 18 May 2023 15:19:46 +0530 Subject: [PATCH 092/298] revert(getverificationproof): add wallet and env params to getVerificationProof (#403) Co-authored-by: Madhur Gupta --- packages/restapi/src/lib/payloads/helpers.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/restapi/src/lib/payloads/helpers.ts b/packages/restapi/src/lib/payloads/helpers.ts index f70f35ae9..0bd5df87b 100644 --- a/packages/restapi/src/lib/payloads/helpers.ts +++ b/packages/restapi/src/lib/payloads/helpers.ts @@ -176,7 +176,9 @@ export async function getVerificationProof({ graph = {}, uuid, chatId, + wallet, pgpPrivateKey, + env, }: { senderType: 0 | 1; signer: any; @@ -190,7 +192,9 @@ export async function getVerificationProof({ uuid: string; // for notifications which have additionalMeta in payload chatId?: string; + wallet?: walletType; pgpPrivateKey?: string; + env?: ENV; }) { let message = null; let verificationProof = null; From 983c896a2c89463f117f5a4d8153ef95501f2124 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Thu, 18 May 2023 16:13:00 +0530 Subject: [PATCH 093/298] fix(video): remove stop audio/video logic from create function (#404) Co-authored-by: Madhur Gupta --- packages/restapi/src/lib/video/Video.ts | 7 ------- 1 file changed, 7 deletions(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 3fe01cf5c..199c6a296 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -110,13 +110,6 @@ export class Video { audio, }); - if (video === false) { - stopVideoStream(localStream); - } - if (audio === false) { - stopAudioStream(localStream); - } - this.setData((oldData) => { return produce(oldData, (draft) => { draft.local.stream = localStream; From 0cf573e56165bf3164a42cbc4b41a3085801e90a Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Fri, 19 May 2023 14:26:39 +0530 Subject: [PATCH 094/298] fix: changed additionalMeta structure (#406) * docs: update * docs: update * fix: changed additionalMeta strcuture --------- Co-authored-by: strykerin --- packages/restapi/README.md | 438 +++++++++++++++--- .../restapi/src/lib/payloads/constants.ts | 24 +- .../src/lib/payloads/sendNotifications.ts | 5 +- packages/restapi/src/lib/types/index.ts | 6 +- 4 files changed, 399 insertions(+), 74 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index e1e6885ef..3e7a22498 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -1174,6 +1174,63 @@ Allowed Options (params with * are mandatory) ### **Sending notification** +```typescript +async function sendNotification(options: { + senderType?: 0 | 1; + signer: any; + type: NOTIFICATION_TYPE; + identityType: IDENTITY_TYPE; + notification?: { + title: string; + body: string; + }; + payload?: { + sectype?: string; + title: string; + body: string; + cta: string; + img: string; + metadata?: any; + additionalMeta?: any; + }; + recipients?: string | string[]; // CAIP or plain ETH + channel: string; // CAIP or plain ETH + expiry?: number; + hidden?: boolean; + graph?: { + id: string; + counter: number; + }; + ipfsHash?: string; + env?: ENV; + chatId?: string; + pgpPrivateKey?: string; +}) +``` + +Allowed Options (params with * are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| senderType* | number | 0 | 0 for channel notification. 1 for chat notification | +| signer* | - | - | Signer object | +| channel* | string | - | channel address (CAIP) | +| type* | number | - | Notification Type
Target = 3 (send to 1 address),
Subset = 4 (send to 1 or more addresses),
Broadcast = 1 (send to all addresses) | +| identityType* | number | - | Identity Type
Minimal = 0,
IPFS = 1,
Direct Payload = 2,
Subgraph = 3 } | +| recipients* | string or string[] | - | for Notification Type = Target it is 1 address,
for Notification Type = Subset, Broadcast it is an array of addresses (CAIP) | +| notification.title* | string | - | Push Notification Title (not required for identityType IPFS, Subgraph)| +| notification.body* | string | - | Push Notification Body (not required for identityType IPFS, Subgraph)| +| payload.title | string | - | Notification Title (not required for identityType IPFS, Subgraph)| +| payload.body | string | - | Notification Body (not required for identityType IPFS, Subgraph)| +| payload.cta | string | - | Notification Call To Action url (not required for identityType IPFS, Subgraph)| +| payload.img | string | - | Notification Media url (not required for identityType IPFS, Subgraph)| +| payload.sectype | string | - | If Secret Notification then pass (not required for identityType IPFS, Subgraph)| +| graph.id | string | - | graph id, required only if the identityType is 3 | +| graph.counter | string | - | graph counter, required only if the identityType is 3 | +| ipfsHash | string | - | ipfsHash, required only if the identityType is 1 | +| expiry | number | - | (optional) epoch value if the notification has an expiry | +| hidden | boolean | false | (optional) true if we want to hide the notification | +| pgpPrivateKey | string | - | (optional) pgp private key for new notification verification proof | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| #### **Direct payload for single recipient(target)** ```typescript @@ -1405,28 +1462,6 @@ const apiResponse = await PushAPI.payloads.sendNotification({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | -|----------|---------|---------|--------------------------------------------| -| signer* | - | - | Signer object | -| channel* | string | - | channel address (CAIP) | -| type* | number | - | Notification Type
Target = 3 (send to 1 address),
Subset = 4 (send to 1 or more addresses),
Broadcast = 1 (send to all addresses) | -| identityType* | number | - | Identity Type
Minimal = 0,
IPFS = 1,
Direct Payload = 2,
Subgraph = 3 } | -| recipients* | string or string[] | - | for Notification Type = Target it is 1 address,
for Notification Type = Subset, Broadcast it is an array of addresses (CAIP) | -| notification.title* | string | - | Push Notification Title (not required for identityType IPFS, Subgraph)| -| notification.body* | string | - | Push Notification Body (not required for identityType IPFS, Subgraph)| -| payload.title | string | - | Notification Title (not required for identityType IPFS, Subgraph)| -| payload.body | string | - | Notification Body (not required for identityType IPFS, Subgraph)| -| payload.cta | string | - | Notification Call To Action url (not required for identityType IPFS, Subgraph)| -| payload.img | string | - | Notification Media url (not required for identityType IPFS, Subgraph)| -| payload.sectype | string | - | If Secret Notification then pass (not required for identityType IPFS, Subgraph)| -| graph.id | string | - | graph id, required only if the identityType is 3 | -| graph.counter | string | - | graph counter, required only if the identityType is 3 | -| ipfsHash | string | - | ipfsHash, required only if the identityType is 1 | -| expiry | number | - | (optional) epoch value if the notification has an expiry | -| hidden | boolean | false | (optional) true if we want to hide the notification | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| -
Expected response (Send Notification) @@ -1608,13 +1643,18 @@ Allowed Options (params with * are mandatory) ## For Chat ### **Create user for chat** + ```typescript const user = await PushAPI.user.create({ - env?: ENV; + env?: ENV; account?: string; signer?: SignerType; version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3; - additionalMeta?: { password?: string }; + additionalMeta?: { + NFTPGP_V1?: { + password: string; + }; + }; progressHook?: (progress: ProgressHookType) => void; }) ``` @@ -1628,6 +1668,26 @@ const user = await PushAPI.user.create({ | additionalMeta | Additional meta data for user | | progressHook | Progress hook | +Example creating normal user for chat: + +```typescript +const user = await PushAPI.user.create({ + signer: signer, // ethers.js signer + env: env as ENV, +}); +``` + +Example creating NFT user for chat: + +```typescript + const user = await PushAPI.user.create({ + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + signer: nftSigner, // ethers.js signer + env: env as ENV, + additionalMeta: { NFTPGP_V1: { password: '@Test0i1223de' } }, + }); +``` +
Expected response (Create Chat User) @@ -1673,7 +1733,7 @@ export interface IUser { | `linkedListHash` | cid from all messages this user has sent | | `nfts` | array of NFTs owned by the user | -Example response: +Example response normal user: ```typescript // PushAPI_user_get | Response - 200 OK { @@ -1725,27 +1785,125 @@ Example response: } ``` +Example response NFT user: + +```typescript +{ + about: null, + name: null, + allowedNumMsg: 1000, + did: 'nft:eip155:5:0x42af3147f17239341477113484752D5D3dda997B:2:1684313853', + encryptedPrivateKey: '{"ciphertext":"833ddc6dfe07e8af7f78991f679ecb5b64d60b1cffc2fed4ecb6287dd04fb27e712c1fd8988b1f15c7b6f30914941f52b316a67b4cc1a8172c7918f00ee333b8a8610cca0320b9593145087a27d4dbd0582043d47538735d087455afacfa3b48b5aa40d82040778f5de3b8bed2c281fa9a381024dc233a92132afd745853a1abb2f305a4eafe7072dc3df405af93ceec52f1b8ce9bb796b5567993ef29e735c7ddcfd8b5b5e7ac6c261b67a76e0c392505777591a98e85f7829796d35efaed030b348b14349539bcd6bd34d4599c7af95db1fb605672d3318737184f92c0d54580abf4be00138f047d8ad69952f368192ab62906dd7f9ef66d1573f9ffdb129bf40c11816057541aefaf8fbee93e80d27e6b09854aef29b8d853bd8b9d994c955400b90e8d4e2b40dd1885ebad81f6c6bf2c41e16039e6a94b8213a501d100ae0b5351198ababe328a8f17480daa70cc0cb65c0f4791903ddb8508f1d304daf64b91f43bbcb489163fb01a6c43815d18e6befbeb78c30be4699366b64b5687335a1f910eb7bb542df5b3fee6f01807656e7b498a55914453dc08c17d89aed5b68d65959959e1a6381944491c7f709cbdec6192f2431f8f47bf94939c866539e5869b1b2ada24159b217fb30f117064120c8eab40eea54b7cf5b2ecb862bb9cdbe45c2d6f5a83476ae3c04019a7920120fc98ae704017f0b93a7ea84ef2a0b503ddbceef31fb31b5e57e6b3e782a4622dfd3fc9df59e4d8100fbf9901ec5a18768c2368182a4a6db10d2bbdaf5972ba8c7a57d4d45d6bbfaecdc529522e4dbe852b6cedcb82d7e105e8f8c169537e15bbb87c64270856328af88262b89ac2abe038d9d185d0cf8e03b760a4f08ce02c06ea205bce7c837259f06bce42795e5bfd8aa769175cba15fd29bbced2f39748e5ed992760aa6da6379560b2247976fec08614226d5090ece1daff0013fec33dd9bee160d9eee9d357c9efc859af81944996d7f4f12c56910b96dfc4b1ae7530c259027229a0e6cd8da0f352bc296611d7ae3d83aee6007aa72ff0a6de0e49a4f73eaea9b688162845f28875da97b0968caa39cdb9d64c4440799fde517b63e2836840173054952ecb7a70dcb139cf78261056cc9120bc78adb815380038b1c4c1c7502ab0ec065349a3f44ebc838663f1618c9ba1c22920baee2f8ab97fd4526c7a6ba7f6d69a8a2bd5b0142e63e2fd29c7618c2c902d50de3b0c16cc849acc003c6865460ce81280ab4fc1eeb93aaa21ec2093e3337e05b3755bc2bff3157ab5c292dcdac3b514560b14ac60e08b770f008e4e77217a84a153f2fa246f728317f06470ca31abcc060f00b6eee751a99e38f56b3759e395c2ec58a77e7cca5312077a0f23d3e456ae329f8e1ec54e9f59d21537756b1b1f07b776edd8ea5dea34c84ada1331cb0d6f2b84df6785a36615786985082f7f8a6b8ef52f1111245f5cdda223d6e5e3794e5fd7afdafaa104280337e0bb2db832c004e9ea74f10b95c272ea4361d4bc6f5ed79ee361fbafedc629da0ecfb91f14da9b687b0c569982fe8682b383476a445c67d3929b4b80fa2478ea3b49d9fc73aa58c3567f2271679978ccfc0c511bf596bd5e4bd1ff79fc939bcb9f4f21781098411043a20aa0b48b91bcf55bcf0bea1af34acef1c27c2d3e1b6afef2dc0265e40ac812872faed5ef0f948181fceb303eb8a43ba5f25523f06031bc6ad151dddabd7df2296f91d1f6a9840b3d3651c02c93a467249d01b364302b7a2def68ba64114861ec61eebf353823d043ad72ec40068e2b60b19a1582a817e1048f02578a2933f4cdbfd87029b5329b1c05babf3650d1f7895333100a695fcba41ceb092fc0c539c62960b232ddd83fbefe8b757b1f69f853657493ea5ed23009ace2faa47a6bd0f253c8990f934e7c26a4924bd5628b59a969e56ffea4fdb3fba9aeb0213149cbb4f9cb33ee62bde1ab4330f3a7674264e89d97d131ceade5e11c9de12305602c6c148d7e19fa77457396ca9bd0d7d5816dd46a9e14690f4d3c40843d17489b70b89a655566fd01d3fd3d2dfb559599e2f450b137ef5fad512b98bff6f783ee6b348edcd4163b7ff554e3bd093c5c7bf1a4823a82bb2ae641f24963ad54409f65db3ab094d0605397ca2774204af5bcac834ce0c987c1b5d2afb43f07c461dd64a523030f9329cbc48f6cfbe6a28a41bc8c6ead39fab275f6d6c6e07be9313702f314dd12c1fb3f1d6666d5d05623d9633ae892b9545b96a77f48de349ed3105b714c7cafa8990e1a7e7a135624374dd1b9338fbe2dabc583f8faa4f5e3978b10c2b6ff0218c51fe604267e93757fa3a65d2ce9698e6ac50d1bf3bb7721b54a8395084d20d9a85d774389f867e91650e4699cfb0f2850e0512d2b53efbf5df6ef3a816fdb1829ab32ce3ae96b564d36f415a55721d0b9f5b6277d23f47c1a58669083d77a11c9d543332ca73e261f8046639b07f35bf727ce2ccbf86a15f853350b58cde58992bba4ba79b6d52654bb956093c6d876b1cc18566677da4d281273305e20eeab54dfbc8f9d00f7a36d3addb9f622986936f80a2c74798a9dadd3fc0fa489f9211e32bc7e3b33752249a1911b44d873128b22ecbe95451c8b693ad40f7898f7e5b76e5f09b51a1dd9dd9ca838e4f8c19eeca153f99b57387ae8d7fc71939d7f48ae75296cfc4db6ddab08b4d2cb15b7d69acdf13e2a0e9a6839db390ba9744b421c029a9811c9fea18948eaebaeeb75b9476e3be90fdd162419152cdd6b7f4a099c1a807f55882415f936add29210dbd8f6462be8c7f1949011f62529f98dcfb9766c60d40292f01c6fcab1f5a899bfe4ebe8b60515f6afbe4803ee99e37b976a92891251d28a43d56fca6ce736f1eb6ef94d20b84c53c822edc94a3ccc55de033a852f3da27508b1c81de1cca9f19b46a5909b0ba8bf7c38ddef2179d119ea205a00573c435befe16cbfdc0c315922a24cdcfc789c965297c64017ac0a0ab23e8ed5b47f76f42ab3552e470a4080564fc7b77149b997761f1a4b3b9f15ba22fa1a6da3f7366a7f90df62124ae637573b92a50b3c29870edd96250d310e8e8413e958880d73619840ecc1b8a8c5f6ce7133dae4740d2deba69ad89d4a7b637db48df5f36491793042ecd88605863024db842768acb43d12cd61aedcf8ab7a34957918d4688f2728b02431dee06a28ed6d6b149f714b7f89986ad684991f291459bbd97bbeb1ab73da5475dc75b48b6417a25a9c2836cb4f3d30e433382b6cb78d5b8642c37b8e9a8c02bbc0fac47e84f80cbf555f8e886a1f4e4ed9064884d7ffa8833933d30d13a31f1deb875f86f4a25b7456a96eeaceb44f4dc39620ac3fe1f8a4830a6bc30c584adadada3dd4a612c8941f6b97417411cc1ed2aa41c6bc442b8971bf5efb1998d5110861fb650004d0a33a5ca4522bb6ac7cd904909f206ae15f66314be98d7772ee4bf7185455c867719c3b61bbc753ca3e6b5b4052fb2a71c80dce5ee31fff0380ce786c934f94896c2c344561f8da151eefec62c84784dd38b2c19d32e3d27571ddb4c30b673e6aac7ea59e56455c7bd1084fbe0eaacd23e3c72a4d16e7cf3296bdde8037ba085a5d8e5e12e506be8696b97f0a4cdbdc3ba63ab5a3567f558d287e67ed897d084a66fc9e74ea5f8c3f4c66b5b132d123d81a6bd313fa735a3472776f917ae6c9b2e1ede2dea152277338d60c4c27446f1dd55f338cdd22dc30002c2a4c9bf7d8c82a0dca395062a3cbe6d3d1e67aed0bfd877334f134228221b530aee740a9fd96cdbf2dab8ac178d53a690edb592e5264f05faacc83721d35bb878724a90369b6b339884f53d51583ae7110caaf5790964c7adcc50d6310226b1fee785616ed47ae54b9e89233be47b7c53c7c51d7cf99bf2785d742b1927ae1b46b389c00c9be90def2475d5ef01fb30477b864389172686bf27af83c68ee0811fa03c12d3356b44cb8aed2cbc0e562ac0d7b2da58293b568bda2d73a2cc716f6796583b6f1213654153997e4f9e0fd68b47df65d933d14be7876d66d7a80b45ef1e53a172473b6b70e9d5eee0e4e77fa15c63c8dc21d452dcf9346973d6b539eebf88d1163314aeb180b44fc19e37a155537075e905155001935b2a09d041c4afbf9ebb688e70c0d90867af9f18b005ff0f6765b5e1483e5b9af9faefd12208ed285ab46a19f4f147e0a30aa66b683a84db4942953ca4b65cef720819d1c6b67983c16d78da3b6e649b55a26b69fa307a339139fc51c56fc8eccf3297fddd1fbfcdda60d3906225160091380725673dfa0e508e7407b1a1d6668ab63c6e2f171dbf647abe0e9c0edc231b99c0ccf7ef64206a51aa566e00e6c549104a5139e844d1876b85123aa6f4bb42a643279da16190c272ddd11ab854a6f8420ceff18108646bb2a7fc914cfcb93dc496ced49c72afc97dea4d285ecd09f55797178e7d366931117ce55532a1ded360635f64d3ea1553ee7dbad5945391810927f22c378970c0d26fd0d9662e381bed5d066cf99b4e52660a10c86ca116fdd2fa763c2d4be36871c24b577a12b6e405a49776f691b5e72567c38d0ea5b302fe5c190eb3e3e97f7145dc67bfbed9bc4371747e7d015b528b21c7fcdfd189d0801849950aeb23dd9d727ce524138ce382c02f17f4b5b62923150abfdabd254e96a62ae3acbfd136febed24b693c124ae8b38e18e69bf1dc0835dcaa38891a6b78bef84317d817964d92b97e48ed4dc4a79b1939bc020bde8b58eed6bd72c380fb1872101d08e340f593daa5ad1aed1dfb13734aa0e8f6c6fe6aae8b3c7cbbb17b2a152424c29e3b7c47a7803c4b1ab0536c3f74e3b1b9c103d64c8f1895b48f71fe881bf1d82e9e6c0f9a7da703a7b774dfd72f0293ca25f338cd7a63354bf912b1668","salt":"cfdf1532770a3b27e0329a8fb1053f9d8a226e836192be779e17d41433bf460d","nonce":"f5d61962ead20df2cd138c89","version":"pgpv1:nft","preKey":"","encryptedPassword":{"ciphertext":"7cae72fd38d784c7e200a7e503042876cd9fae923c0614a1d1f66a3008","salt":"7af2cf5b44bbeb31f19559fccbab9890fae5ecc67e0e3a1e0654cb2caadb51e3","nonce":"194fca4778be7d05348d9c04","version":"eip191-aes256-gcm-hkdf-sha256","preKey":"78217c6716dc1f346f7335d5bc7e3c39cd71cfc866fec1ac0daae98af0787909"}}', + encryptionType: 'pgpv1:nft', + encryptedPassword: null, + nftOwner: 'eip155:0x736cd8461132a1b52d95d535230ca4cd4c8bd7e5', + numMsg: 0, + profilePicture: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA3UlEQVR4AcXBsYnEMBRF0bsfgWKVNLCgzAqmBRegUlSAWnBgZ45cw1aiWNFu+tjAMMzAP+fr+2f7RYzZuJNi5c6YjTspVpThzHBmOAtjNtR67qieC+9Yzx3Vc0EZzgxnhrOwnjuq54JKsfKKFCuq54Jazx1lODOcGc7CtlyoREWN2XhHihW1LRfKcGY4M5wF/hmz8UljNlSKFWU4M5wZzsKYjVekWLkzZuPOmA1lODOcGc5CihX1PB6ongvvWM8dtS0XynBmODOchefxQPVc+KSeC2o9dpThzHBmOPsD9rc47ZwLW74AAAAASUVORK5CYII=', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGRklv0BCACT75kx7wWnXEqbCi9wqV0wVTcw+qMmEcL0gVoov9xu1ZqO\n' + + '5v/MP4i9O4HyvqiPprI3tZP+7tdGs6l49oOhZfNDJ+fzgwVNbB2h3B7bMv0D\n' + + 'VDEwaqU1vwLZD7REFoCFyG3XQZ1sm+kzeWBU32i1B3gfwDb/k851bZtIl2Xg\n' + + 'E31SmAehMq8ndoxNz4T6emRf3l6f76Cd3tFHzaScYXxEkebATxmfNkt/PAEa\n' + + 'K8ArbkYGwzzIbR6QfIP2DIzeIkL1Cv+dkTNFoU3mmbllL+73VezXy60GhtjJ\n' + + 'dsNONtTxZ80gIYznRsyfXLMAGhmIU6+jU9jC5dI0TUjMSCFEetBeIGi/ABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZGSW/QQLCQcICZAPoYjqh/J4mgMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBFA32mzi6MqpsczcbA+hiOqH8niaAAD22QgAgpRqs1lCIedY\n' + + 'trMpey7xBbBbMbV3c+XOX0PK720Z2DY3B+rf8WDbOnZwiKhYFO0SEYL8Tjd3\n' + + '/VmkwgOXeY9fwgAdb1yUAUv95P9C9SOqC6SnMEwumQhbwuf5QpQL2YKV9uCE\n' + + '/nzVhqZtofoOVZg/d0+oGzh41VIPzg4XRHYVl1m+5WblgT+r80iV3KxPEJ5o\n' + + '0zTZVDH6O8E4JUxJogzacCg/d8iswOhrph/GwhI5W/vwfoZpVGPxoH5tWSrV\n' + + 'VbHlXC4UczUPbuUdmSUclgxW1slKPm/ZvoG7g1dkiTKT1pePefp/OeyUqOOi\n' + + 'dGaJvwptzSUh5HipNhZJSJLNal5b8s7ATQRkZJb9AQgAv9+bMh0+JFWEg2CB\n' + + 'z7WV6AV37m9Thx5zKmwKrnrJvJ1ksEPkSu+a2TZzulWXIHFQ0R7ZA/I1P/TF\n' + + 'aZU3LeRbo8XE8sUxiDN+QKeUUIVQed69jVEiw6A0qlZ6CCLprYnrMTEcBj1z\n' + + 'n9ORrQEankOSnrBNnvV0FoWapPMpYB05vrzQHzFwSDRnunC8lW3ctnxsOqLV\n' + + 'kX38L4yg7RSFgpvLh9wIEu3jZEbq1NCAa6WWuJ6SiyX8YC5xq/TQUdSG5k2d\n' + + 'mbvhKiKIoqL5RlkRxRNro4zTzC0S7dxDngTnXu2US208k97B9rq+jYZeEajG\n' + + 'DN0OxjjUECwU3w3m1Zd06dLmIQARAQABwsB2BBgBCAAqBYJkZJb9CZAPoYjq\n' + + 'h/J4mgKbDBYhBFA32mzi6MqpsczcbA+hiOqH8niaAADfGgf/SL6CCFj9b6sO\n' + + 'bw08wCT3gddIG174HIMGJ1VUuajaTU4ex5ibuhpumJmRQdx5fykM1k23C676\n' + + 'mXKbXqnmT6Gk2Lu54gl44m+phBbwjyedb9nqTeeuS+2r/cubm+BLH9MQphbF\n' + + 'N8uMxsCJ2tPO9pTsBNFoOSkqVHYcwxtQp5/wkczSqWFvgf9Z8966QOpd/j/i\n' + + 'aopY/oO/fca36wDn1Gh50YZJ0IFLiHtyqNtY+3nfukycmwc9+LXXB33cagmk\n' + + 'ciku7y7o1+i8eLOi4Nu+trK23hx7/W2l3EHPrW4pyrywr1zhTNehLaacb7AB\n' + + '/3vvjFt8AVCXLJRB5vcwnf4O+CnfLA==\n' + + '=Ji6t\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + sigType: '0x2422c8b422b5437cd3718823b4bd952c418108f77e0f5d67994d268445ff076d0ca9b73555e642d4ae656af1bff1a7ac87b856181067175541168b7ae492b0c61c', + signature: 'eip191v2', + wallets: 'nft:eip155:5:0x42af3147f17239341477113484752D5D3dda997B:2:1684313853', + linkedListHash: null, + nfts: [] +} +``` + **Version 1.3.x** ```typescript export interface IUser { - msgSent: number; - maxMsgPersisted : number; - + msgSent: number; + maxMsgPersisted: number; did: string; wallets: string; - - profile: { - name: string | null; - desc: string | null; - profilePicture: string | null; - } - + profile: { + name: string | null; + desc: string | null; + picture: string | null; + profileVerificationProof: string | null; + }; encryptedPrivateKey: string; publicKey: string; - nftOwner: string; - verificationProof: string; + + /** + * @deprecated Use `profile.name` instead. + */ + name: string | null; + /** + * @deprecated Use `profile.desc` instead. + */ + about: string | null; + /** + * @deprecated Use `profile.picture` instead. + */ + profilePicture: string | null; + /** + * @deprecated Use `msgSent` instead. + */ + numMsg: number; + /** + * @deprecated Use `maxMsgPersisted` instead. + */ + allowedNumMsg: number; + /** + * @deprecated Use `encryptedPrivateKey.version` instead. + */ + encryptionType: string; + /** + * @deprecated Use `verificationProof` instead. + */ + signature: string; + /** + * @deprecated Use `verificationProof` instead. + */ + sigType: string; + /** + * @deprecated Use `encryptedPrivateKey.encryptedPassword` instead. + */ + encryptedPassword: string | null; + /** + * @deprecated + */ + nftOwner: string | null; + /** + * @deprecated Not recommended to be used anywhere + */ + linkedListHash?: string | null; + /** + * @deprecated Not recommended to be used anywhere + */ + nfts?: [] | null; } ``` @@ -1780,6 +1938,24 @@ const user = await PushAPI.user.get({ | account | Account address | | env | API env - 'prod', 'staging', 'dev'| +Example request get normal user data: + +```typescript +const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: ENV.STAGING, +}); +``` + +Example request get NFT user data: + +```typescript +const user = await PushAPI.user.get({ + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + env: ENV.STAGING, +}); +``` +
Expected response (Get Push Chat User) @@ -1825,7 +2001,8 @@ export interface IUser { | `linkedListHash` | cid from all messages this user has sent | | `nfts` | array of NFTs owned by the user | -Example response: +Example response normal user: + ```typescript // PushAPI_user_get | Response - 200 OK { @@ -1877,27 +2054,125 @@ Example response: } ``` +Example response NFT user: + +```typescript +{ + about: null, + name: null, + allowedNumMsg: 1000, + did: 'nft:eip155:5:0x42af3147f17239341477113484752D5D3dda997B:2:1684313853', + encryptedPrivateKey: '{"ciphertext":"833ddc6dfe07e8af7f78991f679ecb5b64d60b1cffc2fed4ecb6287dd04fb27e712c1fd8988b1f15c7b6f30914941f52b316a67b4cc1a8172c7918f00ee333b8a8610cca0320b9593145087a27d4dbd0582043d47538735d087455afacfa3b48b5aa40d82040778f5de3b8bed2c281fa9a381024dc233a92132afd745853a1abb2f305a4eafe7072dc3df405af93ceec52f1b8ce9bb796b5567993ef29e735c7ddcfd8b5b5e7ac6c261b67a76e0c392505777591a98e85f7829796d35efaed030b348b14349539bcd6bd34d4599c7af95db1fb605672d3318737184f92c0d54580abf4be00138f047d8ad69952f368192ab62906dd7f9ef66d1573f9ffdb129bf40c11816057541aefaf8fbee93e80d27e6b09854aef29b8d853bd8b9d994c955400b90e8d4e2b40dd1885ebad81f6c6bf2c41e16039e6a94b8213a501d100ae0b5351198ababe328a8f17480daa70cc0cb65c0f4791903ddb8508f1d304daf64b91f43bbcb489163fb01a6c43815d18e6befbeb78c30be4699366b64b5687335a1f910eb7bb542df5b3fee6f01807656e7b498a55914453dc08c17d89aed5b68d65959959e1a6381944491c7f709cbdec6192f2431f8f47bf94939c866539e5869b1b2ada24159b217fb30f117064120c8eab40eea54b7cf5b2ecb862bb9cdbe45c2d6f5a83476ae3c04019a7920120fc98ae704017f0b93a7ea84ef2a0b503ddbceef31fb31b5e57e6b3e782a4622dfd3fc9df59e4d8100fbf9901ec5a18768c2368182a4a6db10d2bbdaf5972ba8c7a57d4d45d6bbfaecdc529522e4dbe852b6cedcb82d7e105e8f8c169537e15bbb87c64270856328af88262b89ac2abe038d9d185d0cf8e03b760a4f08ce02c06ea205bce7c837259f06bce42795e5bfd8aa769175cba15fd29bbced2f39748e5ed992760aa6da6379560b2247976fec08614226d5090ece1daff0013fec33dd9bee160d9eee9d357c9efc859af81944996d7f4f12c56910b96dfc4b1ae7530c259027229a0e6cd8da0f352bc296611d7ae3d83aee6007aa72ff0a6de0e49a4f73eaea9b688162845f28875da97b0968caa39cdb9d64c4440799fde517b63e2836840173054952ecb7a70dcb139cf78261056cc9120bc78adb815380038b1c4c1c7502ab0ec065349a3f44ebc838663f1618c9ba1c22920baee2f8ab97fd4526c7a6ba7f6d69a8a2bd5b0142e63e2fd29c7618c2c902d50de3b0c16cc849acc003c6865460ce81280ab4fc1eeb93aaa21ec2093e3337e05b3755bc2bff3157ab5c292dcdac3b514560b14ac60e08b770f008e4e77217a84a153f2fa246f728317f06470ca31abcc060f00b6eee751a99e38f56b3759e395c2ec58a77e7cca5312077a0f23d3e456ae329f8e1ec54e9f59d21537756b1b1f07b776edd8ea5dea34c84ada1331cb0d6f2b84df6785a36615786985082f7f8a6b8ef52f1111245f5cdda223d6e5e3794e5fd7afdafaa104280337e0bb2db832c004e9ea74f10b95c272ea4361d4bc6f5ed79ee361fbafedc629da0ecfb91f14da9b687b0c569982fe8682b383476a445c67d3929b4b80fa2478ea3b49d9fc73aa58c3567f2271679978ccfc0c511bf596bd5e4bd1ff79fc939bcb9f4f21781098411043a20aa0b48b91bcf55bcf0bea1af34acef1c27c2d3e1b6afef2dc0265e40ac812872faed5ef0f948181fceb303eb8a43ba5f25523f06031bc6ad151dddabd7df2296f91d1f6a9840b3d3651c02c93a467249d01b364302b7a2def68ba64114861ec61eebf353823d043ad72ec40068e2b60b19a1582a817e1048f02578a2933f4cdbfd87029b5329b1c05babf3650d1f7895333100a695fcba41ceb092fc0c539c62960b232ddd83fbefe8b757b1f69f853657493ea5ed23009ace2faa47a6bd0f253c8990f934e7c26a4924bd5628b59a969e56ffea4fdb3fba9aeb0213149cbb4f9cb33ee62bde1ab4330f3a7674264e89d97d131ceade5e11c9de12305602c6c148d7e19fa77457396ca9bd0d7d5816dd46a9e14690f4d3c40843d17489b70b89a655566fd01d3fd3d2dfb559599e2f450b137ef5fad512b98bff6f783ee6b348edcd4163b7ff554e3bd093c5c7bf1a4823a82bb2ae641f24963ad54409f65db3ab094d0605397ca2774204af5bcac834ce0c987c1b5d2afb43f07c461dd64a523030f9329cbc48f6cfbe6a28a41bc8c6ead39fab275f6d6c6e07be9313702f314dd12c1fb3f1d6666d5d05623d9633ae892b9545b96a77f48de349ed3105b714c7cafa8990e1a7e7a135624374dd1b9338fbe2dabc583f8faa4f5e3978b10c2b6ff0218c51fe604267e93757fa3a65d2ce9698e6ac50d1bf3bb7721b54a8395084d20d9a85d774389f867e91650e4699cfb0f2850e0512d2b53efbf5df6ef3a816fdb1829ab32ce3ae96b564d36f415a55721d0b9f5b6277d23f47c1a58669083d77a11c9d543332ca73e261f8046639b07f35bf727ce2ccbf86a15f853350b58cde58992bba4ba79b6d52654bb956093c6d876b1cc18566677da4d281273305e20eeab54dfbc8f9d00f7a36d3addb9f622986936f80a2c74798a9dadd3fc0fa489f9211e32bc7e3b33752249a1911b44d873128b22ecbe95451c8b693ad40f7898f7e5b76e5f09b51a1dd9dd9ca838e4f8c19eeca153f99b57387ae8d7fc71939d7f48ae75296cfc4db6ddab08b4d2cb15b7d69acdf13e2a0e9a6839db390ba9744b421c029a9811c9fea18948eaebaeeb75b9476e3be90fdd162419152cdd6b7f4a099c1a807f55882415f936add29210dbd8f6462be8c7f1949011f62529f98dcfb9766c60d40292f01c6fcab1f5a899bfe4ebe8b60515f6afbe4803ee99e37b976a92891251d28a43d56fca6ce736f1eb6ef94d20b84c53c822edc94a3ccc55de033a852f3da27508b1c81de1cca9f19b46a5909b0ba8bf7c38ddef2179d119ea205a00573c435befe16cbfdc0c315922a24cdcfc789c965297c64017ac0a0ab23e8ed5b47f76f42ab3552e470a4080564fc7b77149b997761f1a4b3b9f15ba22fa1a6da3f7366a7f90df62124ae637573b92a50b3c29870edd96250d310e8e8413e958880d73619840ecc1b8a8c5f6ce7133dae4740d2deba69ad89d4a7b637db48df5f36491793042ecd88605863024db842768acb43d12cd61aedcf8ab7a34957918d4688f2728b02431dee06a28ed6d6b149f714b7f89986ad684991f291459bbd97bbeb1ab73da5475dc75b48b6417a25a9c2836cb4f3d30e433382b6cb78d5b8642c37b8e9a8c02bbc0fac47e84f80cbf555f8e886a1f4e4ed9064884d7ffa8833933d30d13a31f1deb875f86f4a25b7456a96eeaceb44f4dc39620ac3fe1f8a4830a6bc30c584adadada3dd4a612c8941f6b97417411cc1ed2aa41c6bc442b8971bf5efb1998d5110861fb650004d0a33a5ca4522bb6ac7cd904909f206ae15f66314be98d7772ee4bf7185455c867719c3b61bbc753ca3e6b5b4052fb2a71c80dce5ee31fff0380ce786c934f94896c2c344561f8da151eefec62c84784dd38b2c19d32e3d27571ddb4c30b673e6aac7ea59e56455c7bd1084fbe0eaacd23e3c72a4d16e7cf3296bdde8037ba085a5d8e5e12e506be8696b97f0a4cdbdc3ba63ab5a3567f558d287e67ed897d084a66fc9e74ea5f8c3f4c66b5b132d123d81a6bd313fa735a3472776f917ae6c9b2e1ede2dea152277338d60c4c27446f1dd55f338cdd22dc30002c2a4c9bf7d8c82a0dca395062a3cbe6d3d1e67aed0bfd877334f134228221b530aee740a9fd96cdbf2dab8ac178d53a690edb592e5264f05faacc83721d35bb878724a90369b6b339884f53d51583ae7110caaf5790964c7adcc50d6310226b1fee785616ed47ae54b9e89233be47b7c53c7c51d7cf99bf2785d742b1927ae1b46b389c00c9be90def2475d5ef01fb30477b864389172686bf27af83c68ee0811fa03c12d3356b44cb8aed2cbc0e562ac0d7b2da58293b568bda2d73a2cc716f6796583b6f1213654153997e4f9e0fd68b47df65d933d14be7876d66d7a80b45ef1e53a172473b6b70e9d5eee0e4e77fa15c63c8dc21d452dcf9346973d6b539eebf88d1163314aeb180b44fc19e37a155537075e905155001935b2a09d041c4afbf9ebb688e70c0d90867af9f18b005ff0f6765b5e1483e5b9af9faefd12208ed285ab46a19f4f147e0a30aa66b683a84db4942953ca4b65cef720819d1c6b67983c16d78da3b6e649b55a26b69fa307a339139fc51c56fc8eccf3297fddd1fbfcdda60d3906225160091380725673dfa0e508e7407b1a1d6668ab63c6e2f171dbf647abe0e9c0edc231b99c0ccf7ef64206a51aa566e00e6c549104a5139e844d1876b85123aa6f4bb42a643279da16190c272ddd11ab854a6f8420ceff18108646bb2a7fc914cfcb93dc496ced49c72afc97dea4d285ecd09f55797178e7d366931117ce55532a1ded360635f64d3ea1553ee7dbad5945391810927f22c378970c0d26fd0d9662e381bed5d066cf99b4e52660a10c86ca116fdd2fa763c2d4be36871c24b577a12b6e405a49776f691b5e72567c38d0ea5b302fe5c190eb3e3e97f7145dc67bfbed9bc4371747e7d015b528b21c7fcdfd189d0801849950aeb23dd9d727ce524138ce382c02f17f4b5b62923150abfdabd254e96a62ae3acbfd136febed24b693c124ae8b38e18e69bf1dc0835dcaa38891a6b78bef84317d817964d92b97e48ed4dc4a79b1939bc020bde8b58eed6bd72c380fb1872101d08e340f593daa5ad1aed1dfb13734aa0e8f6c6fe6aae8b3c7cbbb17b2a152424c29e3b7c47a7803c4b1ab0536c3f74e3b1b9c103d64c8f1895b48f71fe881bf1d82e9e6c0f9a7da703a7b774dfd72f0293ca25f338cd7a63354bf912b1668","salt":"cfdf1532770a3b27e0329a8fb1053f9d8a226e836192be779e17d41433bf460d","nonce":"f5d61962ead20df2cd138c89","version":"pgpv1:nft","preKey":"","encryptedPassword":{"ciphertext":"7cae72fd38d784c7e200a7e503042876cd9fae923c0614a1d1f66a3008","salt":"7af2cf5b44bbeb31f19559fccbab9890fae5ecc67e0e3a1e0654cb2caadb51e3","nonce":"194fca4778be7d05348d9c04","version":"eip191-aes256-gcm-hkdf-sha256","preKey":"78217c6716dc1f346f7335d5bc7e3c39cd71cfc866fec1ac0daae98af0787909"}}', + encryptionType: 'pgpv1:nft', + encryptedPassword: null, + nftOwner: 'eip155:0x736cd8461132a1b52d95d535230ca4cd4c8bd7e5', + numMsg: 0, + profilePicture: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA3UlEQVR4AcXBsYnEMBRF0bsfgWKVNLCgzAqmBRegUlSAWnBgZ45cw1aiWNFu+tjAMMzAP+fr+2f7RYzZuJNi5c6YjTspVpThzHBmOAtjNtR67qieC+9Yzx3Vc0EZzgxnhrOwnjuq54JKsfKKFCuq54Jazx1lODOcGc7CtlyoREWN2XhHihW1LRfKcGY4M5wF/hmz8UljNlSKFWU4M5wZzsKYjVekWLkzZuPOmA1lODOcGc5CihX1PB6ongvvWM8dtS0XynBmODOchefxQPVc+KSeC2o9dpThzHBmOPsD9rc47ZwLW74AAAAASUVORK5CYII=', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGRklv0BCACT75kx7wWnXEqbCi9wqV0wVTcw+qMmEcL0gVoov9xu1ZqO\n' + + '5v/MP4i9O4HyvqiPprI3tZP+7tdGs6l49oOhZfNDJ+fzgwVNbB2h3B7bMv0D\n' + + 'VDEwaqU1vwLZD7REFoCFyG3XQZ1sm+kzeWBU32i1B3gfwDb/k851bZtIl2Xg\n' + + 'E31SmAehMq8ndoxNz4T6emRf3l6f76Cd3tFHzaScYXxEkebATxmfNkt/PAEa\n' + + 'K8ArbkYGwzzIbR6QfIP2DIzeIkL1Cv+dkTNFoU3mmbllL+73VezXy60GhtjJ\n' + + 'dsNONtTxZ80gIYznRsyfXLMAGhmIU6+jU9jC5dI0TUjMSCFEetBeIGi/ABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZGSW/QQLCQcICZAPoYjqh/J4mgMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBFA32mzi6MqpsczcbA+hiOqH8niaAAD22QgAgpRqs1lCIedY\n' + + 'trMpey7xBbBbMbV3c+XOX0PK720Z2DY3B+rf8WDbOnZwiKhYFO0SEYL8Tjd3\n' + + '/VmkwgOXeY9fwgAdb1yUAUv95P9C9SOqC6SnMEwumQhbwuf5QpQL2YKV9uCE\n' + + '/nzVhqZtofoOVZg/d0+oGzh41VIPzg4XRHYVl1m+5WblgT+r80iV3KxPEJ5o\n' + + '0zTZVDH6O8E4JUxJogzacCg/d8iswOhrph/GwhI5W/vwfoZpVGPxoH5tWSrV\n' + + 'VbHlXC4UczUPbuUdmSUclgxW1slKPm/ZvoG7g1dkiTKT1pePefp/OeyUqOOi\n' + + 'dGaJvwptzSUh5HipNhZJSJLNal5b8s7ATQRkZJb9AQgAv9+bMh0+JFWEg2CB\n' + + 'z7WV6AV37m9Thx5zKmwKrnrJvJ1ksEPkSu+a2TZzulWXIHFQ0R7ZA/I1P/TF\n' + + 'aZU3LeRbo8XE8sUxiDN+QKeUUIVQed69jVEiw6A0qlZ6CCLprYnrMTEcBj1z\n' + + 'n9ORrQEankOSnrBNnvV0FoWapPMpYB05vrzQHzFwSDRnunC8lW3ctnxsOqLV\n' + + 'kX38L4yg7RSFgpvLh9wIEu3jZEbq1NCAa6WWuJ6SiyX8YC5xq/TQUdSG5k2d\n' + + 'mbvhKiKIoqL5RlkRxRNro4zTzC0S7dxDngTnXu2US208k97B9rq+jYZeEajG\n' + + 'DN0OxjjUECwU3w3m1Zd06dLmIQARAQABwsB2BBgBCAAqBYJkZJb9CZAPoYjq\n' + + 'h/J4mgKbDBYhBFA32mzi6MqpsczcbA+hiOqH8niaAADfGgf/SL6CCFj9b6sO\n' + + 'bw08wCT3gddIG174HIMGJ1VUuajaTU4ex5ibuhpumJmRQdx5fykM1k23C676\n' + + 'mXKbXqnmT6Gk2Lu54gl44m+phBbwjyedb9nqTeeuS+2r/cubm+BLH9MQphbF\n' + + 'N8uMxsCJ2tPO9pTsBNFoOSkqVHYcwxtQp5/wkczSqWFvgf9Z8966QOpd/j/i\n' + + 'aopY/oO/fca36wDn1Gh50YZJ0IFLiHtyqNtY+3nfukycmwc9+LXXB33cagmk\n' + + 'ciku7y7o1+i8eLOi4Nu+trK23hx7/W2l3EHPrW4pyrywr1zhTNehLaacb7AB\n' + + '/3vvjFt8AVCXLJRB5vcwnf4O+CnfLA==\n' + + '=Ji6t\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + sigType: '0x2422c8b422b5437cd3718823b4bd952c418108f77e0f5d67994d268445ff076d0ca9b73555e642d4ae656af1bff1a7ac87b856181067175541168b7ae492b0c61c', + signature: 'eip191v2', + wallets: 'nft:eip155:5:0x42af3147f17239341477113484752D5D3dda997B:2:1684313853', + linkedListHash: null, + nfts: [] +} +``` + **Version 1.3.x** ```typescript export interface IUser { - msgSent: number; - maxMsgPersisted : number; - + msgSent: number; + maxMsgPersisted: number; did: string; wallets: string; - - profile: { - name: string | null; - desc: string | null; - profilePicture: string | null; - } - + profile: { + name: string | null; + desc: string | null; + picture: string | null; + profileVerificationProof: string | null; + }; encryptedPrivateKey: string; publicKey: string; - nftOwner: string; - verificationProof: string; + + /** + * @deprecated Use `profile.name` instead. + */ + name: string | null; + /** + * @deprecated Use `profile.desc` instead. + */ + about: string | null; + /** + * @deprecated Use `profile.picture` instead. + */ + profilePicture: string | null; + /** + * @deprecated Use `msgSent` instead. + */ + numMsg: number; + /** + * @deprecated Use `maxMsgPersisted` instead. + */ + allowedNumMsg: number; + /** + * @deprecated Use `encryptedPrivateKey.version` instead. + */ + encryptionType: string; + /** + * @deprecated Use `verificationProof` instead. + */ + signature: string; + /** + * @deprecated Use `verificationProof` instead. + */ + sigType: string; + /** + * @deprecated Use `encryptedPrivateKey.encryptedPassword` instead. + */ + encryptedPassword: string | null; + /** + * @deprecated + */ + nftOwner: string | null; + /** + * @deprecated Not recommended to be used anywhere + */ + linkedListHash?: string | null; + /** + * @deprecated Not recommended to be used anywhere + */ + nfts?: [] | null; } ``` @@ -1943,19 +2218,36 @@ const response = await PushAPI.chat.decryptPGPKey({ | `toUpgrade` | `boolean` | if true, the user will be upgraded to the latest version | | `progressHook` | `(progress: ProgressHookType) => void` | progress hook | -**Example:** +**Example request for normal user:** ```typescript - const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, - env: ENV.STAGING, - }) +const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: ENV.STAGING, +}) + +// decrypt the PGP Key +const pgpKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, +}) +``` + +**Example request for NFT user:** - // decrypt the PGP Key - const pgpKey = await PushAPI.chat.decryptPGPKey({ - encryptedPGPPrivateKey: user.encryptedPrivateKey, - signer: signer, - }) +```typescript +// get user and derive encrypted PGP key +const user = await PushAPI.user.get({ + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + env: env as ENV, +}); + +// decrypt the PGP Key +const pgpKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + signer: nftSigner, +}); ```
@@ -2022,7 +2314,7 @@ const chats = await PushAPI.chat.chats({ | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| -**Example:** +**Example normal user:** ```typescript // pre-requisite API calls that should be made before @@ -2044,6 +2336,30 @@ const chats = await PushAPI.chat.chats({ }); ``` +**Example NFT user:** + +```typescript +// Fetch user +const user = await PushAPI.user.get({ + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + env: env as ENV, +}); + +// Decrypt PGP Key +const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: nftSigner, +}); + +// Actual api +const response = await PushAPI.chat.chats({ + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + toDecrypt: true, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, +}); +``` +
Expected response (Get chats of a specific user) diff --git a/packages/restapi/src/lib/payloads/constants.ts b/packages/restapi/src/lib/payloads/constants.ts index 981cecee4..ad78aedf6 100644 --- a/packages/restapi/src/lib/payloads/constants.ts +++ b/packages/restapi/src/lib/payloads/constants.ts @@ -3,16 +3,16 @@ export interface ChainIdToSourceType { } export const CHAIN_ID_TO_SOURCE: ChainIdToSourceType = { - 1: "ETH_MAINNET", - 5: "ETH_TEST_GOERLI", - 137: "POLYGON_MAINNET", - 80001: "POLYGON_TEST_MUMBAI", - 56: "BSC_MAINNET", - 97: "BSC_TESTNET", - 10: "OPTIMISM_MAINNET", - 420: "OPTIMISM_TESTNET", - 1442: "POLYGON_ZK_EVM_TESTNET", - 1101: "POLYGON_ZK_EVM_MAINNET" + 1: 'ETH_MAINNET', + 5: 'ETH_TEST_GOERLI', + 137: 'POLYGON_MAINNET', + 80001: 'POLYGON_TEST_MUMBAI', + 56: 'BSC_MAINNET', + 97: 'BSC_TESTNET', + 10: 'OPTIMISM_MAINNET', + 420: 'OPTIMISM_TESTNET', + 1442: 'POLYGON_ZK_EVM_TESTNET', + 1101: 'POLYGON_ZK_EVM_MAINNET', }; export const SOURCE_TYPES = { @@ -25,7 +25,7 @@ export const SOURCE_TYPES = { OPTIMISM_MAINNET: 'OPTIMISM_MAINNET', OPTIMISM_TESTNET: 'OPTIMISM_TESTNET', POLYGON_ZK_EVM_TESTNET: 'POLYGON_ZK_EVM_TESTNET', - POLYGON_ZK_EVM_MAINNET:'POLYGON_ZK_EVM_MAINNET', + POLYGON_ZK_EVM_MAINNET: 'POLYGON_ZK_EVM_MAINNET', THE_GRAPH: 'THE_GRAPH', PUSH_VIDEO: 'PUSH_VIDEO', }; @@ -42,3 +42,5 @@ export enum NOTIFICATION_TYPE { TARGETTED = 3, SUBSET = 4, } + +export const DEFAULT_DOMAIN = 'push.org'; diff --git a/packages/restapi/src/lib/payloads/sendNotifications.ts b/packages/restapi/src/lib/payloads/sendNotifications.ts index 9d36b0762..e9710cb5a 100644 --- a/packages/restapi/src/lib/payloads/sendNotifications.ts +++ b/packages/restapi/src/lib/payloads/sendNotifications.ts @@ -10,7 +10,7 @@ import { getUUID, } from './helpers'; import { getCAIPAddress, getCAIPDetails, getConfig } from '../helpers'; -import { IDENTITY_TYPE } from './constants'; +import { IDENTITY_TYPE, DEFAULT_DOMAIN } from './constants'; import { ENV } from '../constants'; /** @@ -63,6 +63,9 @@ export async function sendNotification(options: ISendNotificationInputOptions) { if (signer === undefined) { throw new Error(`Signer is necessary!`); } + if (payload && payload.additionalMeta && !payload.additionalMeta.domain) { + payload.additionalMeta.domain = DEFAULT_DOMAIN; + } const _channelAddress = getCAIPAddress(env, channel, 'Channel'); const channelCAIPDetails = getCAIPDetails(_channelAddress); diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 648cb5618..01002410f 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -86,7 +86,11 @@ export interface ISendNotificationInputOptions { cta: string; img: string; metadata?: any; - additionalMeta?: any; + additionalMeta?: { + type: string; + data: string; + domain?: string; + }; }; recipients?: string | string[]; // CAIP or plain ETH channel: string; // CAIP or plain ETH From cc559b1e222abf18980a3d3741082c68d4351f79 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 14:29:45 +0530 Subject: [PATCH 095/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 16 ++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 2726c340c..c0036d75c 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,22 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.10...restapi-0.0.1-alpha.11) (2023-05-19) + + +### Bug Fixes + +* changed additionalMeta structure ([#406](https://github.com/ethereum-push-notification-service/push-sdk/issues/406)) ([0cf573e](https://github.com/ethereum-push-notification-service/push-sdk/commit/0cf573e56165bf3164a42cbc4b41a3085801e90a)) +* Merge branch 'alpha' into alpha-deployment ([925b437](https://github.com/ethereum-push-notification-service/push-sdk/commit/925b4379aa7b7d2d061b23d5ccbc42d06829f100)) +* **video:** remove stop audio/video logic from create function ([#404](https://github.com/ethereum-push-notification-service/push-sdk/issues/404)) ([983c896](https://github.com/ethereum-push-notification-service/push-sdk/commit/983c896a2c89463f117f5a4d8153ef95501f2124)) + + +### Reverts + +* **getverificationproof:** add wallet and env params to getVerificationProof ([#403](https://github.com/ethereum-push-notification-service/push-sdk/issues/403)) ([26f6fcb](https://github.com/ethereum-push-notification-service/push-sdk/commit/26f6fcb9b2992850cd33ea613cea13830bd48bc3)) + + + ## [0.0.1-alpha.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.9...restapi-0.0.1-alpha.10) (2023-05-17) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index b6c689437..a19b51389 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.10", + "version": "0.0.1-alpha.11", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From f1880d8f037fc640851af4311bd5e514de5cf3db Mon Sep 17 00:00:00 2001 From: aman035 Date: Fri, 19 May 2023 15:25:03 +0530 Subject: [PATCH 096/298] fix: added enums --- packages/restapi/src/lib/payloads/constants.ts | 9 +++++++++ packages/restapi/src/lib/types/index.ts | 9 +++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/packages/restapi/src/lib/payloads/constants.ts b/packages/restapi/src/lib/payloads/constants.ts index ad78aedf6..78350b7ad 100644 --- a/packages/restapi/src/lib/payloads/constants.ts +++ b/packages/restapi/src/lib/payloads/constants.ts @@ -43,4 +43,13 @@ export enum NOTIFICATION_TYPE { SUBSET = 4, } +export enum ADDITIONAL_META_TYPE { + CUSTOM = 0, + PUSH_VIDEO = 1, +} + +export enum ADDITIONAL_META_VERSION { + V1 = 1, +} + export const DEFAULT_DOMAIN = 'push.org'; diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 01002410f..39c395b8f 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -1,5 +1,10 @@ import { ethers } from 'ethers'; -import { IDENTITY_TYPE, NOTIFICATION_TYPE } from '../../lib/payloads/constants'; +import { + ADDITIONAL_META_TYPE, + ADDITIONAL_META_VERSION, + IDENTITY_TYPE, + NOTIFICATION_TYPE, +} from '../../lib/payloads/constants'; import { ENV } from '../constants'; import { EthEncryptedData } from '@metamask/eth-sig-util'; @@ -87,7 +92,7 @@ export interface ISendNotificationInputOptions { img: string; metadata?: any; additionalMeta?: { - type: string; + type: `${ADDITIONAL_META_TYPE}+${ADDITIONAL_META_VERSION}`; data: string; domain?: string; }; From 05c8fa9f9286e78d706c6be53e7b8ae963105766 Mon Sep 17 00:00:00 2001 From: aman035 Date: Fri, 19 May 2023 15:46:00 +0530 Subject: [PATCH 097/298] fix: fix versions --- packages/restapi/src/lib/payloads/constants.ts | 4 ---- packages/restapi/src/lib/types/index.ts | 6 +++++- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/packages/restapi/src/lib/payloads/constants.ts b/packages/restapi/src/lib/payloads/constants.ts index 78350b7ad..fc0eca252 100644 --- a/packages/restapi/src/lib/payloads/constants.ts +++ b/packages/restapi/src/lib/payloads/constants.ts @@ -48,8 +48,4 @@ export enum ADDITIONAL_META_TYPE { PUSH_VIDEO = 1, } -export enum ADDITIONAL_META_VERSION { - V1 = 1, -} - export const DEFAULT_DOMAIN = 'push.org'; diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 39c395b8f..7945f1ef3 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -92,7 +92,11 @@ export interface ISendNotificationInputOptions { img: string; metadata?: any; additionalMeta?: { - type: `${ADDITIONAL_META_TYPE}+${ADDITIONAL_META_VERSION}`; + /** + * type = ADDITIONAL_META_TYPE+VERSION + * VERSION > 0 + */ + type: `${ADDITIONAL_META_TYPE}+${number}`; data: string; domain?: string; }; From 9d2124aa61f798a0b137636aac62397e1e52150e Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Fri, 19 May 2023 16:35:27 +0530 Subject: [PATCH 098/298] fix(sendvideonotifications): modify additional meta acc to new std (#407) --- .../examples/sdk-backend-node/src/main.ts | 62 +++++----- packages/restapi/src/lib/types/index.ts | 8 ++ packages/restapi/src/lib/video/Video.ts | 108 +++++++++++------- .../helpers/sendVideoCallNotification.ts | 20 ++-- 4 files changed, 120 insertions(+), 78 deletions(-) diff --git a/packages/examples/sdk-backend-node/src/main.ts b/packages/examples/sdk-backend-node/src/main.ts index 6c6185131..fd7744a1c 100644 --- a/packages/examples/sdk-backend-node/src/main.ts +++ b/packages/examples/sdk-backend-node/src/main.ts @@ -89,11 +89,11 @@ let videoSignalData_1 = null; // Push Notification - Run Notifications Use cases async function runNotificaitonsUseCases() { console.log(` - ███ ██ ██████ ████████ ██ ███████ ██ ██████ █████ ████████ ██ ██████ ███ ██ ███████ - ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ ██ ██ - ██ ██ ██ ██ ██ ██ ██ █████ ██ ██ ███████ ██ ██ ██ ██ ██ ██ ██ ███████ - ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ - ██ ████ ██████ ██ ██ ██ ██ ██████ ██ ██ ██ ██ ██████ ██ ████ ███████ + ███ ██ ██████ ████████ ██ ███████ ██ ██████ █████ ████████ ██ ██████ ███ ██ ███████ + ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ████ ██ ██ + ██ ██ ██ ██ ██ ██ ██ █████ ██ ██ ███████ ██ ██ ██ ██ ██ ██ ██ ███████ + ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ + ██ ████ ██████ ██ ██ ██ ██ ██████ ██ ██ ██ ██ ██████ ██ ████ ███████ `); console.log('PushAPI.user.getFeeds'); await PushAPI_user_getFeeds(); @@ -402,11 +402,11 @@ async function PushSDKSocket(silent = !showAPIResponse) { // Push Chat - Run Chat Use cases async function runChatUseCases() { console.log(` - ██████ ██ ██ █████ ████████ - ██ ██ ██ ██ ██ ██ - ██ ███████ ███████ ██ - ██ ██ ██ ██ ██ ██ - ██████ ██ ██ ██ ██ ██ + ██████ ██ ██ █████ ████████ + ██ ██ ██ ██ ██ ██ + ██ ███████ ███████ ██ + ██ ██ ██ ██ ██ ██ + ██████ ██ ██ ██ ██ ██ `); console.log('PushAPI.user.create'); await PushAPI_user_create(); @@ -954,11 +954,11 @@ async function PushChatSDKSocket(silent = !showAPIResponse) { // Push Chat - Run Chat Use cases async function runNFTChatUseCases() { console.log(` - ███ ██ ███████ ████████ ██████ ██ ██ █████ ████████ - ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ - ██ ██ ██ █████ ██ ██ ███████ ███████ ██ - ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ - ██ ████ ██ ██ ██████ ██ ██ ██ ██ ██ + ███ ██ ███████ ████████ ██████ ██ ██ █████ ████████ + ████ ██ ██ ██ ██ ██ ██ ██ ██ ██ + ██ ██ ██ █████ ██ ██ ███████ ███████ ██ + ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ + ██ ████ ██ ██ ██████ ██ ██ ██ ██ ██ `); console.log('PushAPI.user.create'); await PushAPI_nft_user_create(); @@ -1500,12 +1500,12 @@ async function PushNFTChatSDKSocket(silent = !showAPIResponse) { // Push Video - Run Video Use cases async function runVideoUseCases(){ console.log(` -██╗ ██╗██╗██████╗ ███████╗ ██████╗ +██╗ ██╗██╗██████╗ ███████╗ ██████╗ ██║ ██║██║██╔══██╗██╔════╝██╔═══██╗ ██║ ██║██║██║ ██║█████╗ ██║ ██║ ╚██╗ ██╔╝██║██║ ██║██╔══╝ ██║ ██║ ╚████╔╝ ██║██████╔╝███████╗╚██████╔╝ - ╚═══╝ ╚═╝╚═════╝ ╚══════╝ ╚═════╝ + ╚═══╝ ╚═╝╚═════╝ ╚══════╝ ╚═════╝ `); console.log('new PushAPI.video.Video({...})'); videoObject = await PushAPI_video_object_init(); @@ -1611,13 +1611,13 @@ async function PushVideoSDKSocket() { const additionalMeta = JSON.parse(payload['data']['additionalMeta']); if (additionalMeta.status === PushAPI.VideoCallStatus.INITIALIZED) { - videoSignalData_1 = additionalMeta.signalingData; + videoSignalData_1 = additionalMeta.signalData; } else if ( additionalMeta.status === PushAPI.VideoCallStatus.RECEIVED || additionalMeta.status === PushAPI.VideoCallStatus.RETRY_RECEIVED ) { videoObject.connect({ - signalData: additionalMeta.signalingData, + signalData: additionalMeta.signalData, }); } else if ( additionalMeta.status === PushAPI.VideoCallStatus.DISCONNECTED @@ -1638,7 +1638,7 @@ async function PushVideoSDKSocket() { !videoObject.isInitiator() ) { videoObject.acceptRequest({ - signalData: additionalMeta.signalingData, + signalData: additionalMeta.signalData, senderAddress: videoRecipientAddress, recipientAddress: videoSenderAddress, chatId: videoChatId, @@ -1664,7 +1664,7 @@ function start() { /* - One instance of videoObject corresponds to one user/peer of the call - For a wallet-to-wallet video call we need 2 such users/peers - - One of these peer would be the initiator and the other would be the receiver + - One of these peer would be the initiator and the other would be the receiver - Stream object has to be fetched from the frontend of your app to the backend and supplied to videoLocalStream corresponding to each of the peer - Might be of help: https://stackoverflow.com/questions/25523289/sending-a-mediastream-to-host-server-with-webrtc-after-it-is-captured-by-getuser */ @@ -1684,22 +1684,22 @@ start(); // ----------- function returnHeadingLog() { const headingLog = ` - ███████ ██████ ██ ██ ███████ ██ ██ ███ ██ ██████ ████████ ██ ██████ ███ ██ █████ ██ ██ ████████ ██ ██ - ██ ██ ██ ██ ██ ██ ██ ██ ████ ██ ██ ██ ██ ██ ██ ████ ██ ██ ██ ██ ██ ██ ██ ██ - ███████ ██ ██ █████ █████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ███████ ██ ██ ██ ████ - ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ - ███████ ██████ ██ ██ ██ ██████ ██ ████ ██████ ██ ██ ██████ ██ ████ ██ ██ ███████ ██ ██ ██ + ███████ ██████ ██ ██ ███████ ██ ██ ███ ██ ██████ ████████ ██ ██████ ███ ██ █████ ██ ██ ████████ ██ ██ + ██ ██ ██ ██ ██ ██ ██ ██ ████ ██ ██ ██ ██ ██ ██ ████ ██ ██ ██ ██ ██ ██ ██ ██ + ███████ ██ ██ █████ █████ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ███████ ██ ██ ██ ████ + ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ + ███████ ██████ ██ ██ ██ ██████ ██ ████ ██████ ██ ██ ██████ ██ ████ ██ ██ ███████ ██ ██ ██ `; return headingLog; } function returnENVLog() { let environmentLog = ` - ███████ ████████ █████ ██████ ██ ███ ██ ██████ - ██ ██ ██ ██ ██ ██ ████ ██ ██ - ███████ ██ ███████ ██ ███ ██ ██ ██ ██ ██ ███ - ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ - ███████ ██ ██ ██ ██████ ██ ██ ████ ██████ + ███████ ████████ █████ ██████ ██ ███ ██ ██████ + ██ ██ ██ ██ ██ ██ ████ ██ ██ + ███████ ██ ███████ ██ ███ ██ ██ ██ ██ ██ ███ + ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ ██ + ███████ ██ ██ ██ ██████ ██ ██ ████ ██████ `; if (env === ENV.PROD) { diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 7945f1ef3..c63f3cc76 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -406,3 +406,11 @@ export type VideoAcceptRequestInputOptions = { export type VideoConnectInputOptions = { signalData: any; }; + +export type EnableVideoInputOptions = { + state: boolean; +} + +export type EnableAudioInputOptions = { + state: boolean; +} diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 199c6a296..6379c9287 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -22,6 +22,8 @@ import { VideoAcceptRequestInputOptions, VideoConnectInputOptions, VideoCallStatus, + EnableAudioInputOptions, + EnableVideoInputOptions, } from '../types'; export const initVideoCallData: VideoCallData = { @@ -169,7 +171,7 @@ export class Video { ? VideoCallStatus.RETRY_INITIALIZED : VideoCallStatus.INITIALIZED, chatId, - signalingData: data, + signalData: data, env: this.env, } ); @@ -303,7 +305,7 @@ export class Video { ? VideoCallStatus.RETRY_RECEIVED : VideoCallStatus.RECEIVED, chatId, - signalingData: data, + signalData: data, env: this.env, } ); @@ -410,7 +412,7 @@ export class Video { recipientAddress, status: VideoCallStatus.RETRY_INITIALIZED, chatId, - signalingData: null, + signalData: null, env: this.env, } ); @@ -471,7 +473,7 @@ export class Video { recipientAddress: this.data.incoming[0].address, status: VideoCallStatus.DISCONNECTED, chatId: this.data.meta.chatId, - signalingData: null, + signalData: null, env: this.env, } ); @@ -489,49 +491,77 @@ export class Video { } } - // functions for toggling local audio and video + // functions for enabling/disabling local audio and video - toggleVideo(): void { - console.log('toggleVideo', 'current video', this.data.local.video); - if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { - this.peerInstance?.send( - JSON.stringify({ type: 'isVideoOn', isVideoOn: !this.data.local.video }) - ); - } - if (this.data.local.stream) { - if (this.data.local.video === false) { - restartVideoStream(this.data.local.stream); - } - if (this.data.local.video === true) { - stopVideoStream(this.data.local.stream); + enableVideo(options: EnableVideoInputOptions): void { + const { state } = options || {}; + + console.log( + 'enableVideo', + 'current video', + this.data.local.video, + 'requested state', + state + ); + if (this.data.local.video !== state) { + // need to change the video state + + if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { + this.peerInstance?.send( + JSON.stringify({ + type: 'isVideoOn', + isVideoOn: state, + }) + ); } - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.local.video = !oldData.local.video; + if (this.data.local.stream) { + if (state) { + restartVideoStream(this.data.local.stream); + } + else { + stopVideoStream(this.data.local.stream); + } + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.video = state; + }); }); - }); + } } } - toggleAudio(): void { - console.log('toggleAudio', 'current audio', this.data.local.audio); - if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { - this.peerInstance?.send( - JSON.stringify({ type: 'isAudioOn', isAudioOn: !this.data.local.audio }) - ); - } - if (this.data.local.stream) { - if (this.data.local.audio === false) { - restartAudioStream(this.data.local.stream); - } - if (this.data.local.audio === true) { - stopAudioStream(this.data.local.stream); + enableAudio(options: EnableAudioInputOptions): void { + const { state } = options || {}; + + console.log( + 'enableAudio', + 'current audio', + this.data.local.audio, + 'requested state', + state + ); + + if (this.data.local.video !== state) { + // need to change the audio state + + if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { + this.peerInstance?.send( + JSON.stringify({ type: 'isAudioOn', isAudioOn: state }) + ); } - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.local.audio = !oldData.local.audio; + if (this.data.local.stream) { + if (state) { + restartAudioStream(this.data.local.stream); + } + else { + stopAudioStream(this.data.local.stream); + } + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.local.audio = state; + }); }); - }); + } } } diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts index bc24ab4b7..07beed66c 100644 --- a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -1,13 +1,14 @@ import Constants, { ENV } from '../../constants'; import { getCAIPWithChainId } from '../../helpers'; import { sendNotification } from '../../payloads'; +import { ADDITIONAL_META_TYPE } from '../../payloads/constants'; import { SignerType, VideoCallStatus } from '../../types'; interface VideoCallInfoType { recipientAddress: string; senderAddress: string; chatId: string; - signalingData: any; + signalData: any; status: VideoCallStatus; env?: ENV; } @@ -18,11 +19,11 @@ interface UserInfoType { pgpPrivateKey: string; } -interface VideoPayloadType { +interface VideoDataType { recipientAddress: string; senderAddress: string; chatId: string; - signalingData?: any; + signalData?: any; status: VideoCallStatus; } @@ -32,21 +33,21 @@ const sendVideoCallNotification = async ( recipientAddress, senderAddress, chatId, - signalingData = null, + signalData = null, status, env = Constants.ENV.PROD, }: VideoCallInfoType ) => { try { - const videoPayload: VideoPayloadType = { + const videoData: VideoDataType = { recipientAddress, senderAddress, chatId, - signalingData, + signalData, status, }; - console.log('sendVideoCallNotification', 'videoPayload', videoPayload); + console.log('sendVideoCallNotification', 'videoData', videoData); const senderAddressInCaip = getCAIPWithChainId(senderAddress, chainId); const recipientAddressInCaip = getCAIPWithChainId( @@ -72,7 +73,10 @@ const sendVideoCallNotification = async ( body: 'VideoCall', cta: '', img: '', - additionalMeta: videoPayload, + additionalMeta: { + type: `${ADDITIONAL_META_TYPE.PUSH_VIDEO}+1`, + data: JSON.stringify(videoData), + } }, recipients: recipientAddressInCaip, channel: senderAddressInCaip, From e6aa2473b0015493b63d75b45ebb8eeae6dec44d Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 16:36:27 +0530 Subject: [PATCH 099/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index c0036d75c..beab3b441 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.11...restapi-0.0.1-alpha.12) (2023-05-19) + + +### Bug Fixes + +* added enums ([f1880d8](https://github.com/ethereum-push-notification-service/push-sdk/commit/f1880d8f037fc640851af4311bd5e514de5cf3db)) +* fix versions ([05c8fa9](https://github.com/ethereum-push-notification-service/push-sdk/commit/05c8fa9f9286e78d706c6be53e7b8ae963105766)) +* Merge branch 'alpha' into alpha-deployment ([3700515](https://github.com/ethereum-push-notification-service/push-sdk/commit/3700515be010fdcab6062db0a039f7df612a7a6b)) +* **sendvideonotifications:** modify additional meta acc to new std ([#407](https://github.com/ethereum-push-notification-service/push-sdk/issues/407)) ([9d2124a](https://github.com/ethereum-push-notification-service/push-sdk/commit/9d2124aa61f798a0b137636aac62397e1e52150e)) + + + ## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.10...restapi-0.0.1-alpha.11) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index a19b51389..9a82e9d51 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.11", + "version": "0.0.1-alpha.12", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 55172002a2cecb33407a3828c2debeca24e0c972 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Fri, 19 May 2023 16:45:42 +0530 Subject: [PATCH 100/298] fix(types): remove bad import --- packages/restapi/src/lib/types/index.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index c63f3cc76..25b45ba33 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -1,7 +1,6 @@ import { ethers } from 'ethers'; import { ADDITIONAL_META_TYPE, - ADDITIONAL_META_VERSION, IDENTITY_TYPE, NOTIFICATION_TYPE, } from '../../lib/payloads/constants'; From f0619350982e91e962949753c94c5039d86dbdf0 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 16:50:39 +0530 Subject: [PATCH 101/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 22 ++++++++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index beab3b441..bc349a268 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,28 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.10...restapi-0.0.1-alpha.11) (2023-05-19) + + +### Bug Fixes + +* added enums ([f1880d8](https://github.com/ethereum-push-notification-service/push-sdk/commit/f1880d8f037fc640851af4311bd5e514de5cf3db)) +* changed additionalMeta structure ([#406](https://github.com/ethereum-push-notification-service/push-sdk/issues/406)) ([0cf573e](https://github.com/ethereum-push-notification-service/push-sdk/commit/0cf573e56165bf3164a42cbc4b41a3085801e90a)) +* fix versions ([05c8fa9](https://github.com/ethereum-push-notification-service/push-sdk/commit/05c8fa9f9286e78d706c6be53e7b8ae963105766)) +* Merge branch 'alpha' into alpha-deployment ([68f11eb](https://github.com/ethereum-push-notification-service/push-sdk/commit/68f11eb71d44423081000c00c36cb0a936558f2f)) +* Merge branch 'alpha' into alpha-deployment ([3700515](https://github.com/ethereum-push-notification-service/push-sdk/commit/3700515be010fdcab6062db0a039f7df612a7a6b)) +* Merge branch 'alpha' into alpha-deployment ([925b437](https://github.com/ethereum-push-notification-service/push-sdk/commit/925b4379aa7b7d2d061b23d5ccbc42d06829f100)) +* **sendvideonotifications:** modify additional meta acc to new std ([#407](https://github.com/ethereum-push-notification-service/push-sdk/issues/407)) ([9d2124a](https://github.com/ethereum-push-notification-service/push-sdk/commit/9d2124aa61f798a0b137636aac62397e1e52150e)) +* **types:** remove bad import ([5517200](https://github.com/ethereum-push-notification-service/push-sdk/commit/55172002a2cecb33407a3828c2debeca24e0c972)) +* **video:** remove stop audio/video logic from create function ([#404](https://github.com/ethereum-push-notification-service/push-sdk/issues/404)) ([983c896](https://github.com/ethereum-push-notification-service/push-sdk/commit/983c896a2c89463f117f5a4d8153ef95501f2124)) + + +### Reverts + +* **getverificationproof:** add wallet and env params to getVerificationProof ([#403](https://github.com/ethereum-push-notification-service/push-sdk/issues/403)) ([26f6fcb](https://github.com/ethereum-push-notification-service/push-sdk/commit/26f6fcb9b2992850cd33ea613cea13830bd48bc3)) + + + ## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.11...restapi-0.0.1-alpha.12) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 9a82e9d51..a19b51389 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.12", + "version": "0.0.1-alpha.11", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 85ef733127bdfbae5c66c671ddc7700785d192c0 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Fri, 19 May 2023 17:37:43 +0530 Subject: [PATCH 102/298] fix(video): fix enableAudio --- packages/restapi/src/lib/video/Video.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 6379c9287..e3b5c2c6b 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -541,7 +541,7 @@ export class Video { state ); - if (this.data.local.video !== state) { + if (this.data.local.audio !== state) { // need to change the audio state if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { From 9eafa70e15660ebb7ea8530884d9cd031e882175 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 17:53:01 +0530 Subject: [PATCH 103/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index bc349a268..5f95f5a8b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.11...restapi-0.0.1-alpha.12) (2023-05-19) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([963cc02](https://github.com/ethereum-push-notification-service/push-sdk/commit/963cc02768862b6a9427519257ff9f9565f613ea)) +* **video:** fix enableAudio ([85ef733](https://github.com/ethereum-push-notification-service/push-sdk/commit/85ef733127bdfbae5c66c671ddc7700785d192c0)) + + + ## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.10...restapi-0.0.1-alpha.11) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index a19b51389..9a82e9d51 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.11", + "version": "0.0.1-alpha.12", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From fbf246396a44513626fc1dda6e90c12d2f073ead Mon Sep 17 00:00:00 2001 From: aman035 Date: Fri, 19 May 2023 18:02:26 +0530 Subject: [PATCH 104/298] fix: backward compatiblity fix --- .../src/lib/payloads/sendNotifications.ts | 7 +++++- packages/restapi/src/lib/types/index.ts | 24 ++++++++++--------- 2 files changed, 19 insertions(+), 12 deletions(-) diff --git a/packages/restapi/src/lib/payloads/sendNotifications.ts b/packages/restapi/src/lib/payloads/sendNotifications.ts index e9710cb5a..01987699f 100644 --- a/packages/restapi/src/lib/payloads/sendNotifications.ts +++ b/packages/restapi/src/lib/payloads/sendNotifications.ts @@ -63,7 +63,12 @@ export async function sendNotification(options: ISendNotificationInputOptions) { if (signer === undefined) { throw new Error(`Signer is necessary!`); } - if (payload && payload.additionalMeta && !payload.additionalMeta.domain) { + if ( + payload && + payload.additionalMeta && + typeof payload.additionalMeta === 'object' && + !payload.additionalMeta.domain + ) { payload.additionalMeta.domain = DEFAULT_DOMAIN; } diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 25b45ba33..a0cf03047 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -90,15 +90,17 @@ export interface ISendNotificationInputOptions { cta: string; img: string; metadata?: any; - additionalMeta?: { - /** - * type = ADDITIONAL_META_TYPE+VERSION - * VERSION > 0 - */ - type: `${ADDITIONAL_META_TYPE}+${number}`; - data: string; - domain?: string; - }; + additionalMeta?: + | { + /** + * type = ADDITIONAL_META_TYPE+VERSION + * VERSION > 0 + */ + type: `${ADDITIONAL_META_TYPE}+${number}`; + data: string; + domain?: string; + } + | string; }; recipients?: string | string[]; // CAIP or plain ETH channel: string; // CAIP or plain ETH @@ -408,8 +410,8 @@ export type VideoConnectInputOptions = { export type EnableVideoInputOptions = { state: boolean; -} +}; export type EnableAudioInputOptions = { state: boolean; -} +}; From 5eb6c040802c681c046f3ef72ebc0508af391ecc Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 18:16:10 +0530 Subject: [PATCH 105/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 5f95f5a8b..3cbc3aec7 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.12...restapi-0.0.1-alpha.13) (2023-05-19) + + +### Bug Fixes + +* backward compatiblity fix ([fbf2463](https://github.com/ethereum-push-notification-service/push-sdk/commit/fbf246396a44513626fc1dda6e90c12d2f073ead)) +* Merge branch 'alpha' into alpha-deployment ([3b5a0f1](https://github.com/ethereum-push-notification-service/push-sdk/commit/3b5a0f160b72e775cf17031067fa7488171e1bbd)) + + + ## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.11...restapi-0.0.1-alpha.12) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 9a82e9d51..5f37605fb 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.12", + "version": "0.0.1-alpha.13", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 11fc1cff0c2bfc26f3f953845dc31ac07ffef0b2 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Fri, 19 May 2023 19:28:49 +0530 Subject: [PATCH 106/298] docs: Update the enableVideo/Audio methods --- packages/restapi/README.md | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 3e7a22498..b853f0f7f 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -75,8 +75,8 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [**acceptRequest**](#acceptrequest) - [**connect**](#connect) - [**disconnect**](#disconnect) - - [**toggleVideo**](#togglevideo) - - [**toggleAudio**](#toggleaudio) + - [**enableVideo**](#enablevideo) + - [**enableAudio**](#enableaudio) - [**isInitiator**](#isinitiator) # How to use in your app? @@ -3824,33 +3824,41 @@ Allowed Options (params with * are mandatory) ----- -#### **toggleVideo** -- This method is used to toggle the video (from ```data.local.stream```) on or off for a push video call. +#### **enableVideo** +- This method is used to enable/disable the video (from ```data.local.stream```) for a push video call. - Can be triggered on the initiator as well as receivers end. - **Note -** If video was not enabled during ```create()``` then it will always remain off. ```typescript -toggleVideo(): void + export type EnableVideoInputOptions = { + state: boolean; +} + +enableVideo(options: EnableVideoInputOptions): void ``` Allowed Options (params with * are mandatory) | Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| - | - | - | - | +| state | boolean | - | true for enable and false for disable | ----- -#### **toggleAudio** -- This method is used to toggle the audio (from ```data.local.stream```) on or off for a push video call. +#### **enableAudio** +- This method is used to enable/disable the audio (from ```data.local.stream```) for a push video call. - Can be triggered on the initiator as well as receivers end. - **Note -** If audio was not enabled during ```create()``` then it will always remain off. ```typescript -toggleAudio(): void +export type EnableAudioInputOptions = { + state: boolean; +} + +enableAudio(options: EnableAudioInputOptions): void ``` Allowed Options (params with * are mandatory) | Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| - | - | - | - | +| state | boolean | - | true for enable and false for disable | ----- From 97f054613b0fcb9821e581b78d4acf00c3fa2847 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 19:59:09 +0530 Subject: [PATCH 107/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.2.16?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8d999c6ec..3358fd4ef 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.2.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.15...restapi-1.2.16) (2023-05-19) + + +### Bug Fixes + +* add deprecated info to chat.chat ([#392](https://github.com/ethereum-push-notification-service/push-sdk/issues/392)) ([d84ae64](https://github.com/ethereum-push-notification-service/push-sdk/commit/d84ae64c116adb7eea9e8faf7929b6eb3b74c657)) +* show hardcoded msg rather than throwing error ([#388](https://github.com/ethereum-push-notification-service/push-sdk/issues/388)) ([8962e10](https://github.com/ethereum-push-notification-service/push-sdk/commit/8962e10036916d0bc161324f5684f74bb7b74dc3)) + + + ## [1.2.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.14...restapi-1.2.15) (2023-05-12) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index b4826c786..ba5d2910f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.15", + "version": "1.2.16", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From d63fd205fd25b2d5d299346085e7088c012b86a8 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Fri, 19 May 2023 20:35:37 +0530 Subject: [PATCH 108/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 14 ++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 4c225e662..8b78491e9 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,20 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +# [1.3.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.16...restapi-1.3.0) (2023-05-19) + + +### Bug Fixes + +* merge main ([b58d9d5](https://github.com/ethereum-push-notification-service/push-sdk/commit/b58d9d53bd91fa33200a854170fe7e3facff4371)) + + +### Features + +* add video sdk methods ([#395](https://github.com/ethereum-push-notification-service/push-sdk/issues/395)) ([4b9dd69](https://github.com/ethereum-push-notification-service/push-sdk/commit/4b9dd691ac1fde6a91be0478b20780f6755fbb4f)), closes [#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295) [#309](https://github.com/ethereum-push-notification-service/push-sdk/issues/309) [#357](https://github.com/ethereum-push-notification-service/push-sdk/issues/357) [#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295) + + + ## [1.2.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.15...restapi-1.2.16) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 8bdd9dcaf..be37b6920 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.2.16", + "version": "1.3.0", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 8cdb999bc548caf67ec6fbe625253b5795a4e465 Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Mon, 22 May 2023 20:11:13 +0530 Subject: [PATCH 109/298] fix: fix nft videocall (#411) --- .../examples/sdk-backend-node/src/main.ts | 138 ++++++++++++++++-- .../src/lib/channels/_getSubscribers.ts | 2 +- .../restapi/src/lib/channels/getChannel.ts | 2 +- .../restapi/src/lib/channels/getDelegates.ts | 2 +- .../src/lib/channels/getSubscribers.ts | 2 +- .../restapi/src/lib/channels/subscribe.ts | 4 +- .../restapi/src/lib/channels/unsubscribe.ts | 4 +- packages/restapi/src/lib/helpers/address.ts | 8 +- packages/restapi/src/lib/payloads/helpers.ts | 51 ++++--- .../src/lib/payloads/sendNotifications.ts | 40 +++-- .../restapi/src/lib/user/getDelegations.ts | 2 +- packages/restapi/src/lib/user/getFeeds.ts | 2 +- .../restapi/src/lib/user/getSubscriptions.ts | 2 +- 13 files changed, 195 insertions(+), 64 deletions(-) diff --git a/packages/examples/sdk-backend-node/src/main.ts b/packages/examples/sdk-backend-node/src/main.ts index fd7744a1c..97150161f 100644 --- a/packages/examples/sdk-backend-node/src/main.ts +++ b/packages/examples/sdk-backend-node/src/main.ts @@ -76,9 +76,11 @@ const updatedNftGroupName = uniqueNamesGenerator({ // Video Data const videoChainId = +process.env.VIDEO_CHAIN_ID; let videoData = PushAPI.video.initVideoCallData; -const videoSetData: (fn:(data:PushAPI.VideoCallData) => PushAPI.VideoCallData) => void = (fn) => { +const videoSetData: ( + fn: (data: PushAPI.VideoCallData) => PushAPI.VideoCallData +) => void = (fn) => { videoData = fn(videoData); -} +}; let videoObject = null; const videoLocalStream = null; // get the local stream const videoSenderAddress = process.env.VIDEO_SENDER_ADDRESS; @@ -424,11 +426,14 @@ async function runChatUseCases() { await PushAPI_chat_requests(); console.log('PushAPI.chat.send'); - await PushAPI_chat_send(); + const TargetChatId = await PushAPI_chat_send(); console.log('PushAPI.chat.approve'); await PushAPI_chat_approve(); + console.log('PushAPI chat Video call Notification'); + await PushAPI_chat_video_call_notification(TargetChatId); + console.log('PushAPI.chat.createGroup'); const chatId = await PushAPI_chat_createGroup(); @@ -694,6 +699,7 @@ async function PushAPI_chat_send(silent = !showAPIResponse) { if (!silent) { console.log(response); } + return response.chatId; } // Push Chat - Approve @@ -951,6 +957,55 @@ async function PushChatSDKSocket(silent = !showAPIResponse) { await delay(4000); } +async function PushAPI_chat_video_call_notification( + chatId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: signer.address, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + }); + // get PGP KEy + const apiResponse = await PushAPI.payloads.sendNotification({ + senderType: 1, + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + chatId: chatId, + type: 3, // target + identityType: 2, // direct payload + notification: { + title: `VC TITLE:`, + body: `VC BODY`, + }, + payload: { + title: `payload title`, + body: `sample msg body`, + cta: '', + img: '', + additionalMeta: { + type: '1+1', + data: 'Random DATA', + domain: 'push.org', + }, + }, + recipients: signerSecondAccount.address, // recipient address + channel: signer.address, // your channel address + env: env as ENV, + }); + + console.log('PushAPI.payloads.sendNotification | Response - 204 OK'); + if (!silent) { + console.log(apiResponse); + } +} + // Push Chat - Run Chat Use cases async function runNFTChatUseCases() { console.log(` @@ -976,11 +1031,14 @@ async function runNFTChatUseCases() { await PushAPI_nft_chat_requests(); console.log('PushAPI.chat.send'); - await PushAPI_nft_chat_send(); + const TargetchatId = await PushAPI_nft_chat_send(); console.log('PushAPI.chat.approve'); await PushAPI_nft_chat_approve(); + console.log('NFT Video Call Notification'); + await PushAPI_nft_chat_video_call_notification(TargetchatId); + console.log('PushAPI.chat.createGroup'); const chatId = await PushAPI_nft_chat_createGroup(); @@ -1245,6 +1303,7 @@ async function PushAPI_nft_chat_send(silent = !showAPIResponse) { if (!silent) { console.log(response); } + return response.chatId; } // Push Chat - Approve @@ -1278,6 +1337,55 @@ async function PushAPI_nft_chat_approve(silent = !showAPIResponse) { } } +async function PushAPI_nft_chat_video_call_notification( + chatId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: nftAccount1, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: nftSigner1, + }); + + const apiResponse = await PushAPI.payloads.sendNotification({ + senderType: 1, + signer: nftSigner1, + pgpPrivateKey: pgpDecrpyptedPvtKey, + chatId: chatId, + type: 1, // target + identityType: 2, // direct payload + notification: { + title: `VC TITLE:`, + body: `VC BODY`, + }, + payload: { + title: `payload title`, + body: `sample msg body`, + cta: '', + img: '', + additionalMeta: { + type: '1+1', + data: 'Random DATA', + domain: 'push.org', + }, + }, + recipients: nftAccount1, // recipient address + channel: nftAccount1, // your channel address + env: env as ENV, + }); + + console.log('PushAPI.payloads.sendNotification | Response - 204 OK'); + if (!silent) { + console.log(apiResponse); + } +} + // Push Chat - PushAPI.chat.createGroup async function PushAPI_nft_chat_createGroup( silent = !showAPIResponse @@ -1498,7 +1606,7 @@ async function PushNFTChatSDKSocket(silent = !showAPIResponse) { } // Push Video - Run Video Use cases -async function runVideoUseCases(){ +async function runVideoUseCases() { console.log(` ██╗ ██╗██╗██████╗ ███████╗ ██████╗ ██║ ██║██║██╔══██╗██╔════╝██╔═══██╗ @@ -1530,7 +1638,7 @@ async function runVideoUseCases(){ await PushVideoSDKSocket(); } -async function PushAPI_video_object_init(){ +async function PushAPI_video_object_init() { // Fetch user const user = await PushAPI.user.get({ account: `eip155:${signer.address}`, @@ -1556,10 +1664,10 @@ async function PushAPI_video_object_init(){ return videoObject; } -async function PushAPI_video_create(){ +async function PushAPI_video_create() { await videoObject.create({ - stream: videoLocalStream -}); + stream: videoLocalStream, + }); } async function PushAPI_video_request() { @@ -1570,7 +1678,7 @@ async function PushAPI_video_request() { }); } -async function PushAPI_video_accept_request(){ +async function PushAPI_video_accept_request() { videoObject.acceptRequest({ signalData: videoSignalData_1, senderAddress: videoRecipientAddress, @@ -1579,13 +1687,13 @@ async function PushAPI_video_accept_request(){ }); } -async function PushAPI_video_connect(){ +async function PushAPI_video_connect() { videoObject.connect({ - signalData: {} // signalData from sockets - }) + signalData: {}, // signalData from sockets + }); } -async function PushAPI_video_disconnect(){ +async function PushAPI_video_disconnect() { videoObject.disconnect(); } @@ -1660,7 +1768,7 @@ function start() { runNotificaitonsUseCases().then(() => { runChatUseCases().then(() => { runNFTChatUseCases().then(() => { - if(videoLocalStream !== null){ + if (videoLocalStream !== null) { /* - One instance of videoObject corresponds to one user/peer of the call - For a wallet-to-wallet video call we need 2 such users/peers diff --git a/packages/restapi/src/lib/channels/_getSubscribers.ts b/packages/restapi/src/lib/channels/_getSubscribers.ts index 6e4733980..704f09b99 100644 --- a/packages/restapi/src/lib/channels/_getSubscribers.ts +++ b/packages/restapi/src/lib/channels/_getSubscribers.ts @@ -35,7 +35,7 @@ export const _getSubscribers = async ( env = Constants.ENV.PROD, } = options || {}; - const _channelAddress = getCAIPAddress(env, channel, 'Channel'); + const _channelAddress = await getCAIPAddress(env, channel, 'Channel'); const channelCAIPDetails = getCAIPDetails(_channelAddress); if (!channelCAIPDetails) throw Error('Invalid Channel CAIP!'); diff --git a/packages/restapi/src/lib/channels/getChannel.ts b/packages/restapi/src/lib/channels/getChannel.ts index 39dcb3d8c..eb9a661da 100644 --- a/packages/restapi/src/lib/channels/getChannel.ts +++ b/packages/restapi/src/lib/channels/getChannel.ts @@ -22,7 +22,7 @@ export const getChannel = async ( env = Constants.ENV.PROD, } = options || {}; - const _channel = getCAIPAddress(env, channel, 'Channel'); + const _channel = await getCAIPAddress(env, channel, 'Channel'); const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/channels`; const requestUrl = `${apiEndpoint}/${_channel}`; diff --git a/packages/restapi/src/lib/channels/getDelegates.ts b/packages/restapi/src/lib/channels/getDelegates.ts index d45d90fc0..ef825c96c 100644 --- a/packages/restapi/src/lib/channels/getDelegates.ts +++ b/packages/restapi/src/lib/channels/getDelegates.ts @@ -27,7 +27,7 @@ export const getDelegates = async ( env = Constants.ENV.PROD, } = options || {}; - const _channel = getCAIPAddress(env, channel, 'Channel'); + const _channel = await getCAIPAddress(env, channel, 'Channel'); const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/channels`; const requestUrl = `${apiEndpoint}/${_channel}/delegates`; diff --git a/packages/restapi/src/lib/channels/getSubscribers.ts b/packages/restapi/src/lib/channels/getSubscribers.ts index bf1248fed..50f2f7824 100644 --- a/packages/restapi/src/lib/channels/getSubscribers.ts +++ b/packages/restapi/src/lib/channels/getSubscribers.ts @@ -47,7 +47,7 @@ export const getSubscribers = async ( if (limit > 30) { throw new Error("limit must be lesser than or equal to 30"); } - const _channel = getCAIPAddress(env, channel, 'Channel'); + const _channel = await getCAIPAddress(env, channel, 'Channel'); const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/channels/${_channel}/subscribers?page=${page}&limit=${limit}`; return await axios.get(apiEndpoint) diff --git a/packages/restapi/src/lib/channels/subscribe.ts b/packages/restapi/src/lib/channels/subscribe.ts index 1b2541d21..4db84c914 100644 --- a/packages/restapi/src/lib/channels/subscribe.ts +++ b/packages/restapi/src/lib/channels/subscribe.ts @@ -43,14 +43,14 @@ export const subscribe = async ( } = options || {}; try { - const _channelAddress = getCAIPAddress(env, channelAddress, 'Channel'); + const _channelAddress = await getCAIPAddress(env, channelAddress, 'Channel'); const channelCAIPDetails = getCAIPDetails(_channelAddress); if (!channelCAIPDetails) throw Error('Invalid Channel CAIP!'); const chainId = parseInt(channelCAIPDetails.networkId, 10); - const _userAddress = getCAIPAddress(env, userAddress, 'User'); + const _userAddress = await getCAIPAddress(env, userAddress, 'User'); const userCAIPDetails = getCAIPDetails(_userAddress); if (!userCAIPDetails) throw Error('Invalid User CAIP!'); diff --git a/packages/restapi/src/lib/channels/unsubscribe.ts b/packages/restapi/src/lib/channels/unsubscribe.ts index 404410edf..19ec57b36 100644 --- a/packages/restapi/src/lib/channels/unsubscribe.ts +++ b/packages/restapi/src/lib/channels/unsubscribe.ts @@ -43,14 +43,14 @@ export const unsubscribe = async ( } = options || {}; try { - const _channelAddress = getCAIPAddress(env, channelAddress, 'Channel'); + const _channelAddress = await getCAIPAddress(env, channelAddress, 'Channel'); const channelCAIPDetails = getCAIPDetails(_channelAddress); if (!channelCAIPDetails) throw Error('Invalid Channel CAIP!'); const chainId = parseInt(channelCAIPDetails.networkId, 10); - const _userAddress = getCAIPAddress(env, userAddress, 'User'); + const _userAddress = await getCAIPAddress(env, userAddress, 'User'); const userCAIPDetails = getCAIPDetails(_userAddress); if (!userCAIPDetails) throw Error('Invalid User CAIP!'); diff --git a/packages/restapi/src/lib/helpers/address.ts b/packages/restapi/src/lib/helpers/address.ts index 395b2712f..2457953e2 100644 --- a/packages/restapi/src/lib/helpers/address.ts +++ b/packages/restapi/src/lib/helpers/address.ts @@ -1,5 +1,6 @@ import * as ethers from 'ethers'; import Constants, {ENV} from '../constants'; +import { getUserDID } from '../chat/helpers'; export interface AddressValidatorsType { [key: string]: ({ address } : { address: string }) => boolean; @@ -66,6 +67,8 @@ export function validateCAIP(addressInCAIP: string) { if (!networkId) return false; if (!address) return false; + if(isValidCAIP10NFTAddress(addressInCAIP))return true; + const validatorFn = AddressValidators[blockchain]; return validatorFn({ address }); @@ -115,7 +118,10 @@ export function getFallbackETHCAIPAddress(env: ENV, address: string) { * else * throw error! */ -export function getCAIPAddress(env: ENV, address: string, msg?: string) { +export async function getCAIPAddress(env: ENV, address: string, msg?: string) { + if(isValidCAIP10NFTAddress(address)){ + return await getUserDID(address, env); + } if (validateCAIP(address)) { return address; } else { diff --git a/packages/restapi/src/lib/payloads/helpers.ts b/packages/restapi/src/lib/payloads/helpers.ts index 0bd5df87b..ff876ae3b 100644 --- a/packages/restapi/src/lib/payloads/helpers.ts +++ b/packages/restapi/src/lib/payloads/helpers.ts @@ -91,7 +91,7 @@ export async function getRecipients({ */ if (notificationType === NOTIFICATION_TYPE.TARGETTED) { if (typeof recipients === 'string') { - addressInCAIP = getCAIPAddress(env, recipients, 'Recipient'); + addressInCAIP = await getCAIPAddress(env, recipients, 'Recipient'); secret = ''; // do secret stuff // TODO return { @@ -100,15 +100,18 @@ export async function getRecipients({ } } else if (notificationType === NOTIFICATION_TYPE.SUBSET) { if (Array.isArray(recipients)) { - const recipientObject = recipients.reduce((_recipients, _rAddress) => { - addressInCAIP = getCAIPAddress(env, _rAddress, 'Recipient'); - secret = ''; // do secret stuff // TODO + const recipientObject = recipients.reduce( + async (_recipients, _rAddress) => { + addressInCAIP = await getCAIPAddress(env, _rAddress, 'Recipient'); + secret = ''; // do secret stuff // TODO - return { - ..._recipients, - [addressInCAIP]: secret, - }; - }, {}); + return { + ..._recipients, + [addressInCAIP]: secret, + }; + }, + {} + ); return recipientObject; } @@ -119,23 +122,23 @@ export async function getRecipients({ */ if (notificationType === NOTIFICATION_TYPE.BROADCAST) { - if (!recipients) { - // return getCAIPFormat(chainId, channel || ''); - return getCAIPAddress(env, channel, 'Recipient'); - } + return await getCAIPAddress(env, channel, 'Recipient'); } else if (notificationType === NOTIFICATION_TYPE.TARGETTED) { if (typeof recipients === 'string') { - return getCAIPAddress(env, recipients, 'Recipient'); + return await getCAIPAddress(env, recipients, 'Recipient'); } } else if (notificationType === NOTIFICATION_TYPE.SUBSET) { if (Array.isArray(recipients)) { - const recipientObject = recipients.reduce((_recipients, _rAddress) => { - addressInCAIP = getCAIPAddress(env, _rAddress, 'Recipient'); - return { - ..._recipients, - [addressInCAIP]: null, - }; - }, {}); + const recipientObject = recipients.reduce( + async (_recipients, _rAddress) => { + addressInCAIP = await getCAIPAddress(env, _rAddress, 'Recipient'); + return { + ..._recipients, + [addressInCAIP]: null, + }; + }, + {} + ); return recipientObject; } } @@ -143,7 +146,7 @@ export async function getRecipients({ return recipients; } -export function getRecipientFieldForAPIPayload({ +export async function getRecipientFieldForAPIPayload({ env, notificationType, recipients, @@ -158,10 +161,10 @@ export function getRecipientFieldForAPIPayload({ notificationType === NOTIFICATION_TYPE.TARGETTED && typeof recipients === 'string' ) { - return getCAIPAddress(env, recipients, 'Recipient'); + return await getCAIPAddress(env, recipients, 'Recipient'); } - return getCAIPAddress(env, channel, 'Recipient'); + return await getCAIPAddress(env, channel, 'Recipient'); } export async function getVerificationProof({ diff --git a/packages/restapi/src/lib/payloads/sendNotifications.ts b/packages/restapi/src/lib/payloads/sendNotifications.ts index 01987699f..eb262f5f8 100644 --- a/packages/restapi/src/lib/payloads/sendNotifications.ts +++ b/packages/restapi/src/lib/payloads/sendNotifications.ts @@ -9,7 +9,14 @@ import { getSource, getUUID, } from './helpers'; -import { getCAIPAddress, getCAIPDetails, getConfig } from '../helpers'; +import { + getAPIBaseUrls, + getCAIPAddress, + getCAIPDetails, + getConfig, + isValidCAIP10NFTAddress, + isValidETHAddress, +} from '../helpers'; import { IDENTITY_TYPE, DEFAULT_DOMAIN } from './constants'; import { ENV } from '../constants'; @@ -20,6 +27,15 @@ function validateOptions(options: any) { if (!options?.channel) { throw '[Push SDK] - Error - sendNotification() - "channel" is mandatory!'; } + if (!isValidETHAddress(options.channel)) { + throw '[Push SDK] - Error - sendNotification() - "channel" is invalid!'; + } + if (options.senderType === 0 && options.signer === undefined) { + throw '[Push SDK] - Error - sendNotification() - "signer" is mandatory!'; + } + if (options.senderType === 1 && options.pgpPrivateKey === undefined) { + throw '[Push SDK] - Error - sendNotification() - "pgpPrivateKey" is mandatory!'; + } /** * Apart from IPFS, GRAPH use cases "notification", "payload" is mandatory @@ -60,9 +76,6 @@ export async function sendNotification(options: ISendNotificationInputOptions) { validateOptions(options); - if (signer === undefined) { - throw new Error(`Signer is necessary!`); - } if ( payload && payload.additionalMeta && @@ -71,8 +84,7 @@ export async function sendNotification(options: ISendNotificationInputOptions) { ) { payload.additionalMeta.domain = DEFAULT_DOMAIN; } - - const _channelAddress = getCAIPAddress(env, channel, 'Channel'); + const _channelAddress = await getCAIPAddress(env, channel, 'Channel'); const channelCAIPDetails = getCAIPDetails(_channelAddress); if (!channelCAIPDetails) throw Error('Invalid Channel CAIP!'); @@ -80,10 +92,12 @@ export async function sendNotification(options: ISendNotificationInputOptions) { const uuid = getUUID(); const chainId = parseInt(channelCAIPDetails.networkId, 10); - const { API_BASE_URL, EPNS_COMMUNICATOR_CONTRACT } = getConfig( - env, - channelCAIPDetails - ); + const API_BASE_URL = getAPIBaseUrls(env); + let COMMUNICATOR_CONTRACT = ''; + if (senderType === 0) { + const { EPNS_COMMUNICATOR_CONTRACT } = getConfig(env, channelCAIPDetails); + COMMUNICATOR_CONTRACT = EPNS_COMMUNICATOR_CONTRACT; + } const _recipients = await getRecipients({ env, @@ -101,7 +115,7 @@ export async function sendNotification(options: ISendNotificationInputOptions) { chainId, identityType, notificationType: type, - verifyingContract: EPNS_COMMUNICATOR_CONTRACT, + verifyingContract: COMMUNICATOR_CONTRACT, payload: notificationPayload, graph, ipfsHash, @@ -125,12 +139,12 @@ export async function sendNotification(options: ISendNotificationInputOptions) { verificationProof, identity, sender: - senderType === 1 + senderType === 1 && !isValidCAIP10NFTAddress(_channelAddress) ? `${channelCAIPDetails?.blockchain}:${channelCAIPDetails?.address}` : _channelAddress, source, /** note this recipient key has a different expectation from the BE API, see the funciton for more */ - recipient: getRecipientFieldForAPIPayload({ + recipient: await getRecipientFieldForAPIPayload({ env, notificationType: type, recipients: recipients || '', diff --git a/packages/restapi/src/lib/user/getDelegations.ts b/packages/restapi/src/lib/user/getDelegations.ts index acea37325..ba211d09b 100644 --- a/packages/restapi/src/lib/user/getDelegations.ts +++ b/packages/restapi/src/lib/user/getDelegations.ts @@ -27,7 +27,7 @@ export const getDelegations = async ( env = Constants.ENV.PROD, } = options || {}; - const _user = getCAIPAddress(env, user, 'User'); + const _user = await getCAIPAddress(env, user, 'User'); const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/users/${_user}/delegations`; const requestUrl = `${apiEndpoint}`; diff --git a/packages/restapi/src/lib/user/getFeeds.ts b/packages/restapi/src/lib/user/getFeeds.ts index 1f33837fd..87c7fd42a 100644 --- a/packages/restapi/src/lib/user/getFeeds.ts +++ b/packages/restapi/src/lib/user/getFeeds.ts @@ -29,7 +29,7 @@ export const getFeeds = async ( raw = false, } = options || {}; - const _user = getCAIPAddress(env, user, 'User'); + const _user = await getCAIPAddress(env, user, 'User'); const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/users/${_user}/feeds`; diff --git a/packages/restapi/src/lib/user/getSubscriptions.ts b/packages/restapi/src/lib/user/getSubscriptions.ts index 9aae4c9ad..7e45d061e 100644 --- a/packages/restapi/src/lib/user/getSubscriptions.ts +++ b/packages/restapi/src/lib/user/getSubscriptions.ts @@ -15,7 +15,7 @@ export const getSubscriptions = async ( env = Constants.ENV.PROD, } = options || {}; - const _user = getCAIPAddress(env, user, 'User'); + const _user = await getCAIPAddress(env, user, 'User'); const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/users/${_user}/subscriptions`; const requestUrl = `${apiEndpoint}`; From 713c5ff23d6f56cb25c89952f6c0f60f61786148 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 22 May 2023 20:14:23 +0530 Subject: [PATCH 110/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.14?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 3cbc3aec7..1f100aaae 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.13...restapi-0.0.1-alpha.14) (2023-05-22) + + +### Bug Fixes + +* fix nft videocall ([#411](https://github.com/ethereum-push-notification-service/push-sdk/issues/411)) ([8cdb999](https://github.com/ethereum-push-notification-service/push-sdk/commit/8cdb999bc548caf67ec6fbe625253b5795a4e465)) +* Merge branch 'alpha' into alpha-deployment ([f247665](https://github.com/ethereum-push-notification-service/push-sdk/commit/f2476650b650ade59721c30f6e8483e86c013cd4)) + + + ## [0.0.1-alpha.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.12...restapi-0.0.1-alpha.13) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 5f37605fb..a21a6fc2e 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.13", + "version": "0.0.1-alpha.14", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 970e84d58009a2d276f3514affb5196f1dbfb984 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 22 May 2023 20:35:37 +0530 Subject: [PATCH 111/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8b78491e9..9be102169 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.0...restapi-1.3.1) (2023-05-22) + + +### Bug Fixes + +* merge main ([dc2ba17](https://github.com/ethereum-push-notification-service/push-sdk/commit/dc2ba179cef2f834ac4fe13a6673095b97a6e019)) + + + # [1.3.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.16...restapi-1.3.0) (2023-05-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index be37b6920..a45285dd0 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.0", + "version": "1.3.1", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 8c5e4b02c55c18d78a79a813fe307abae4b13d71 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 22 May 2023 22:04:25 +0530 Subject: [PATCH 112/298] =?UTF-8?q?ci(socket):=20=F0=9F=8E=89=20cut=20rele?= =?UTF-8?q?ase=20to=20socket-v0.5.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/socket/CHANGELOG.md | 9 +++++++++ packages/socket/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/socket/CHANGELOG.md b/packages/socket/CHANGELOG.md index 608a00bc2..78b0cb728 100644 --- a/packages/socket/CHANGELOG.md +++ b/packages/socket/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.5.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/socket-0.5.0...socket-0.5.1) (2023-05-22) + + +### Bug Fixes + +* fixed nft socket ([#413](https://github.com/ethereum-push-notification-service/push-sdk/issues/413)) ([0d8c3ab](https://github.com/ethereum-push-notification-service/push-sdk/commit/0d8c3ab628ec29903bcc051254e5c54e94a2325e)) + + + # [0.5.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/socket-0.4.1...socket-0.5.0) (2023-04-27) diff --git a/packages/socket/package.json b/packages/socket/package.json index 18bd79d85..ff281d423 100644 --- a/packages/socket/package.json +++ b/packages/socket/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/socket", - "version": "0.5.0", + "version": "0.5.1", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 7953495adb26ed61673682a5eb9c20c162da699d Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Tue, 23 May 2023 17:58:38 +0530 Subject: [PATCH 113/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 785c5a8cb..909f52dcf 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.1...restapi-1.3.2) (2023-05-23) + + +### Bug Fixes + +* merge main ([5d0bc64](https://github.com/ethereum-push-notification-service/push-sdk/commit/5d0bc649b16c674d20e96eedc590a0efe6a5b77f)) + + + ## [1.3.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.0...restapi-1.3.1) (2023-05-22) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index a45285dd0..6ce3329d6 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.1", + "version": "1.3.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 2fc6f549c80a65a5a6009b0c2fa9635d757bdf11 Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Mon, 29 May 2023 13:36:36 +0530 Subject: [PATCH 114/298] fix: Iuser structure changed (#365) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix: iuser changed * fix: changed route * fix: change profilePicture to picture * fix: fixed tests * fix: fix nftOwner and readme * fix: iuser changes * Deployment (#390) * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.1 * ci(restapi): 🎉 cut release to restapi-v1.0.1 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * fix: success progressHook * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.1.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * fix(component): dummy * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.2.1 * fix: local for local development (#295) Co-Authored-By: aman035 * fix: version update * ci(restapi): 🎉 cut release to restapi-v1.2.2 * ci(restapi): 🎉 cut release to restapi-v1.2.3 * ci(restapi): 🎉 cut release to restapi-v1.2.4 * ci(restapi): 🎉 cut release to restapi-v1.2.5 * ci(restapi): 🎉 cut release to restapi-v1.2.6 * ci(restapi): 🎉 cut release to restapi-v1.2.7 * ci(socket): 🎉 cut release to socket-v0.5.0 * fix: test commit * ci(restapi): 🎉 cut release to restapi-v1.2.8 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.1 * fix: added ci-version-beta * fix: added ci-version-beta * ci(restapi): 🎉 cut beta release to restapi-v1.2.9 * fix: added releaseType * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.1 * ci(restapi): 🎉 cut release to restapi-v1.2.11 * fix: linkedListHash test cases removed & CI version corrected * fix: update name to beta * ci(restapi): 🎉 cut release to restapi-v1.2.12 * ci(restapi): 🎉 cut release to restapi-v1.2.12 * ci(restapi): 🎉 cut release to restapi-v1.2.13 * ci(restapi): 🎉 cut release to restapi-v1.2.14 * ci(restapi): 🎉 cut release to restapi-v1.2.15 * fix: update package json * fix: updated socket version * ci(uiweb): 🎉 cut release to uiweb-v1.0.2 * fix: socket lib update * ci(uiweb): 🎉 cut release to uiweb-v1.0.2 --------- Co-authored-by: aman035 * fix: add deprecated info to chat.chat (#392) * fix: show hardcoded msg rather than throwing error (#388) * docs: update * fix: fix decprecated param and verification of keys --------- Co-authored-by: Mohammed S Co-authored-by: strykerin --- .../demoreact/src/app/ChatTest/GetUser.tsx | 2 +- packages/restapi/CHANGELOG.md | 775 +++------ packages/restapi/README.md | 1439 ++++++++--------- .../restapi/src/lib/chat/helpers/crypto.ts | 3 - .../restapi/src/lib/chat/helpers/service.ts | 77 +- .../restapi/src/lib/chat/helpers/signature.ts | 8 +- packages/restapi/src/lib/helpers/crypto.ts | 51 +- packages/restapi/src/lib/types/index.ts | 58 +- .../restapi/src/lib/user/auth.updateUser.ts | 7 - packages/restapi/src/lib/user/createUser.ts | 5 - packages/restapi/src/lib/user/getUser.ts | 13 +- .../restapi/src/lib/user/getUsersBatch.ts | 12 +- packages/restapi/src/lib/user/upgradeUser.ts | 5 +- .../restapi/src/lib/utils/populateIUser.ts | 39 + .../restapi/tests/lib/user/createUser.test.ts | 35 +- .../restapi/tests/lib/user/getUser.test.ts | 2 +- .../tests/lib/user/upgradeUser.test.ts | 22 +- .../src/lib/components/chat/AddressInfo.tsx | 7 +- 18 files changed, 1095 insertions(+), 1465 deletions(-) create mode 100644 packages/restapi/src/lib/utils/populateIUser.ts diff --git a/packages/demoreact/src/app/ChatTest/GetUser.tsx b/packages/demoreact/src/app/ChatTest/GetUser.tsx index 8233e07e6..973234e03 100644 --- a/packages/demoreact/src/app/ChatTest/GetUser.tsx +++ b/packages/demoreact/src/app/ChatTest/GetUser.tsx @@ -152,7 +152,7 @@ const GetUserTest = () => { ) : null}
- {connectedUser && (connectedUser as IUser).nftOwner !== null && ( + {connectedUser && (connectedUser as IUser).did.split(':')[0] === 'nft' && (
{connectedUser ? {password} : null} diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 3cbc3aec7..2e310f369 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -4,7 +4,6 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ## [0.0.1-alpha.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.12...restapi-0.0.1-alpha.13) (2023-05-19) - ### Bug Fixes * backward compatiblity fix ([fbf2463](https://github.com/ethereum-push-notification-service/push-sdk/commit/fbf246396a44513626fc1dda6e90c12d2f073ead)) @@ -14,7 +13,6 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.11...restapi-0.0.1-alpha.12) (2023-05-19) - ### Bug Fixes * Merge branch 'alpha' into alpha-deployment ([963cc02](https://github.com/ethereum-push-notification-service/push-sdk/commit/963cc02768862b6a9427519257ff9f9565f613ea)) @@ -24,7 +22,6 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.10...restapi-0.0.1-alpha.11) (2023-05-19) - ### Bug Fixes * added enums ([f1880d8](https://github.com/ethereum-push-notification-service/push-sdk/commit/f1880d8f037fc640851af4311bd5e514de5cf3db)) @@ -94,989 +91,747 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s ## [0.0.1-alpha.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.7...restapi-0.0.1-alpha.8) (2023-05-16) - ### Bug Fixes -* add deprecated info to chat.chat ([#392](https://github.com/ethereum-push-notification-service/push-sdk/issues/392)) ([d84ae64](https://github.com/ethereum-push-notification-service/push-sdk/commit/d84ae64c116adb7eea9e8faf7929b6eb3b74c657)) -* Merge branch 'alpha' into alpha-deployment ([549fd83](https://github.com/ethereum-push-notification-service/push-sdk/commit/549fd839867d84a98a10206a7f9945aeb1720e49)) -* Merge branch 'main' into alpha ([72464fd](https://github.com/ethereum-push-notification-service/push-sdk/commit/72464fd97260b612649035e3b241f946de8f9e92)) -* show hardcoded msg rather than throwing error ([#388](https://github.com/ethereum-push-notification-service/push-sdk/issues/388)) ([8962e10](https://github.com/ethereum-push-notification-service/push-sdk/commit/8962e10036916d0bc161324f5684f74bb7b74dc3)) -* **video:** set trickle to true while creating peer instance ([#397](https://github.com/ethereum-push-notification-service/push-sdk/issues/397)) ([0b609be](https://github.com/ethereum-push-notification-service/push-sdk/commit/0b609bec87a6187d1e7cbf8052a2b9a36b9fcd7a)) - - +- add deprecated info to chat.chat ([#392](https://github.com/ethereum-push-notification-service/push-sdk/issues/392)) ([d84ae64](https://github.com/ethereum-push-notification-service/push-sdk/commit/d84ae64c116adb7eea9e8faf7929b6eb3b74c657)) +- Merge branch 'alpha' into alpha-deployment ([549fd83](https://github.com/ethereum-push-notification-service/push-sdk/commit/549fd839867d84a98a10206a7f9945aeb1720e49)) +- Merge branch 'main' into alpha ([72464fd](https://github.com/ethereum-push-notification-service/push-sdk/commit/72464fd97260b612649035e3b241f946de8f9e92)) +- show hardcoded msg rather than throwing error ([#388](https://github.com/ethereum-push-notification-service/push-sdk/issues/388)) ([8962e10](https://github.com/ethereum-push-notification-service/push-sdk/commit/8962e10036916d0bc161324f5684f74bb7b74dc3)) +- **video:** set trickle to true while creating peer instance ([#397](https://github.com/ethereum-push-notification-service/push-sdk/issues/397)) ([0b609be](https://github.com/ethereum-push-notification-service/push-sdk/commit/0b609bec87a6187d1e7cbf8052a2b9a36b9fcd7a)) ## [0.0.1-alpha.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.6...restapi-0.0.1-alpha.7) (2023-05-15) - ### Bug Fixes -* Merge branch 'alpha' into alpha-deployment ([37c1c8d](https://github.com/ethereum-push-notification-service/push-sdk/commit/37c1c8db579876f5835c2e5bb5e6baf073dc9208)) -* **video:** remove status change upon connect in request ([#394](https://github.com/ethereum-push-notification-service/push-sdk/issues/394)) ([7441ef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/7441ef0fb2c9ed39e12a4f1819ade0ee7e0d6b10)) - - +- Merge branch 'alpha' into alpha-deployment ([37c1c8d](https://github.com/ethereum-push-notification-service/push-sdk/commit/37c1c8db579876f5835c2e5bb5e6baf073dc9208)) +- **video:** remove status change upon connect in request ([#394](https://github.com/ethereum-push-notification-service/push-sdk/issues/394)) ([7441ef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/7441ef0fb2c9ed39e12a4f1819ade0ee7e0d6b10)) ## [0.0.1-alpha.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.5...restapi-0.0.1-alpha.6) (2023-05-14) - ### Bug Fixes -* add video call retry logic upon error & doc: add video call in restapi/readme ([#391](https://github.com/ethereum-push-notification-service/push-sdk/issues/391)) ([9c8c86b](https://github.com/ethereum-push-notification-service/push-sdk/commit/9c8c86b35d1cb0300d0170e87931dd31a15f9342)) - - +- add video call retry logic upon error & doc: add video call in restapi/readme ([#391](https://github.com/ethereum-push-notification-service/push-sdk/issues/391)) ([9c8c86b](https://github.com/ethereum-push-notification-service/push-sdk/commit/9c8c86b35d1cb0300d0170e87931dd31a15f9342)) ## [0.0.1-alpha.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.4...restapi-0.0.1-alpha.5) (2023-05-14) - - ## [0.0.1-alpha.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.3...restapi-0.0.1-alpha.4) (2023-05-12) - ### Bug Fixes -* fix chat.chat for grps ([#382](https://github.com/ethereum-push-notification-service/push-sdk/issues/382)) ([052a75c](https://github.com/ethereum-push-notification-service/push-sdk/commit/052a75ca0f0fea7664d8c607fc85cdf37cc5d398)) -* fix eip712v2 ([#385](https://github.com/ethereum-push-notification-service/push-sdk/issues/385)) ([42c10ba](https://github.com/ethereum-push-notification-service/push-sdk/commit/42c10ba6f5331c9caf5db7136ba94d1a6ed05e10)) -* Merge branch 'alpha' into alpha-deployment ([a1a8666](https://github.com/ethereum-push-notification-service/push-sdk/commit/a1a86661b1823c84328ec90ac9aafc6c57f574f3)) -* Merge branch 'main' into alpha ([5fc51db](https://github.com/ethereum-push-notification-service/push-sdk/commit/5fc51db1a336203048b4b42a5384cb37cf79c509)) -* **video:** separate react state from video class instance variable data ([#389](https://github.com/ethereum-push-notification-service/push-sdk/issues/389)) ([83bf445](https://github.com/ethereum-push-notification-service/push-sdk/commit/83bf4457332b127bf9e41a2f4c93fb851367724d)) - - +- fix chat.chat for grps ([#382](https://github.com/ethereum-push-notification-service/push-sdk/issues/382)) ([052a75c](https://github.com/ethereum-push-notification-service/push-sdk/commit/052a75ca0f0fea7664d8c607fc85cdf37cc5d398)) +- fix eip712v2 ([#385](https://github.com/ethereum-push-notification-service/push-sdk/issues/385)) ([42c10ba](https://github.com/ethereum-push-notification-service/push-sdk/commit/42c10ba6f5331c9caf5db7136ba94d1a6ed05e10)) +- Merge branch 'alpha' into alpha-deployment ([a1a8666](https://github.com/ethereum-push-notification-service/push-sdk/commit/a1a86661b1823c84328ec90ac9aafc6c57f574f3)) +- Merge branch 'main' into alpha ([5fc51db](https://github.com/ethereum-push-notification-service/push-sdk/commit/5fc51db1a336203048b4b42a5384cb37cf79c509)) +- **video:** separate react state from video class instance variable data ([#389](https://github.com/ethereum-push-notification-service/push-sdk/issues/389)) ([83bf445](https://github.com/ethereum-push-notification-service/push-sdk/commit/83bf4457332b127bf9e41a2f4c93fb851367724d)) ## [0.0.1-alpha.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.2...restapi-0.0.1-alpha.3) (2023-05-11) - ### Bug Fixes -* Merge branch 'alpha' into alpha-deployment ([e19b9b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/e19b9b05b60174e68dc7bfe0e2349e20d8af2604)) -* Replace arrow functions with normal functions in the Video class ([#380](https://github.com/ethereum-push-notification-service/push-sdk/issues/380)) ([b90435a](https://github.com/ethereum-push-notification-service/push-sdk/commit/b90435a953b908899c92eb5b4d4c3677e47b1552)) - - +- Merge branch 'alpha' into alpha-deployment ([e19b9b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/e19b9b05b60174e68dc7bfe0e2349e20d8af2604)) +- Replace arrow functions with normal functions in the Video class ([#380](https://github.com/ethereum-push-notification-service/push-sdk/issues/380)) ([b90435a](https://github.com/ethereum-push-notification-service/push-sdk/commit/b90435a953b908899c92eb5b4d4c3677e47b1552)) ## [0.0.1-alpha.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.1...restapi-0.0.1-alpha.2) (2023-05-10) - ### Bug Fixes -* eip191v2 signatures for create and auth.update ([#359](https://github.com/ethereum-push-notification-service/push-sdk/issues/359)) ([48abaf6](https://github.com/ethereum-push-notification-service/push-sdk/commit/48abaf667dce2a1140c3622451c1c5b49d153c00)) -* merge alpha ([7f0642c](https://github.com/ethereum-push-notification-service/push-sdk/commit/7f0642c4c417390a5bb52d36d9493bd5b767b634)) -* merge main ([a5fdfe1](https://github.com/ethereum-push-notification-service/push-sdk/commit/a5fdfe10f18c857c32aa5fe5c5dd95db0f268cd1)) -* merge main to alpha ([4866a37](https://github.com/ethereum-push-notification-service/push-sdk/commit/4866a37ed0502c0d16ac91f088d3bb5e597b652a)) - - +- eip191v2 signatures for create and auth.update ([#359](https://github.com/ethereum-push-notification-service/push-sdk/issues/359)) ([48abaf6](https://github.com/ethereum-push-notification-service/push-sdk/commit/48abaf667dce2a1140c3622451c1c5b49d153c00)) +- merge alpha ([7f0642c](https://github.com/ethereum-push-notification-service/push-sdk/commit/7f0642c4c417390a5bb52d36d9493bd5b767b634)) +- merge main ([a5fdfe1](https://github.com/ethereum-push-notification-service/push-sdk/commit/a5fdfe10f18c857c32aa5fe5c5dd95db0f268cd1)) +- merge main to alpha ([4866a37](https://github.com/ethereum-push-notification-service/push-sdk/commit/4866a37ed0502c0d16ac91f088d3bb5e597b652a)) ## [0.0.1-alpha.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.0...restapi-0.0.1-alpha.1) (2023-05-08) - ### Bug Fixes -* Merge branch 'alpha' into alpha-deployment ([1223c60](https://github.com/ethereum-push-notification-service/push-sdk/commit/1223c60b0f179b26537992a776155aefffd7b5ef)) -* sendVideoNotification and end video call logic ([#367](https://github.com/ethereum-push-notification-service/push-sdk/issues/367)) ([d39c703](https://github.com/ethereum-push-notification-service/push-sdk/commit/d39c703bcda6d332717a5e9b1af6ab574be9d991)) - - +- Merge branch 'alpha' into alpha-deployment ([1223c60](https://github.com/ethereum-push-notification-service/push-sdk/commit/1223c60b0f179b26537992a776155aefffd7b5ef)) +- sendVideoNotification and end video call logic ([#367](https://github.com/ethereum-push-notification-service/push-sdk/issues/367)) ([d39c703](https://github.com/ethereum-push-notification-service/push-sdk/commit/d39c703bcda6d332717a5e9b1af6ab574be9d991)) ## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.2...restapi-0.0.1-alpha.0) (2023-05-04) - ### Bug Fixes -* added pagination and deprecation tag ([#346](https://github.com/ethereum-push-notification-service/push-sdk/issues/346)) ([69763b8](https://github.com/ethereum-push-notification-service/push-sdk/commit/69763b8da2cf3e92bb85908e4f46a72b650c9dba)) -* change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) -* changed Definitions for auth.update and upgrade ([#351](https://github.com/ethereum-push-notification-service/push-sdk/issues/351)) ([31daee3](https://github.com/ethereum-push-notification-service/push-sdk/commit/31daee3a5aa913705d1dec8210c0412cd89c94c9)) -* eip191v2 signatures for create and auth.update ([#353](https://github.com/ethereum-push-notification-service/push-sdk/issues/353)) ([008e6d0](https://github.com/ethereum-push-notification-service/push-sdk/commit/008e6d08d75fdacf19f1674cc2b8bd82091fa31f)) -* Merge branch 'main' into alpha ([477bae4](https://github.com/ethereum-push-notification-service/push-sdk/commit/477bae4fdc4e86374615f0f67c41c570a567b9fe)) - - +- added pagination and deprecation tag ([#346](https://github.com/ethereum-push-notification-service/push-sdk/issues/346)) ([69763b8](https://github.com/ethereum-push-notification-service/push-sdk/commit/69763b8da2cf3e92bb85908e4f46a72b650c9dba)) +- change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) +- changed Definitions for auth.update and upgrade ([#351](https://github.com/ethereum-push-notification-service/push-sdk/issues/351)) ([31daee3](https://github.com/ethereum-push-notification-service/push-sdk/commit/31daee3a5aa913705d1dec8210c0412cd89c94c9)) +- eip191v2 signatures for create and auth.update ([#353](https://github.com/ethereum-push-notification-service/push-sdk/issues/353)) ([008e6d0](https://github.com/ethereum-push-notification-service/push-sdk/commit/008e6d08d75fdacf19f1674cc2b8bd82091fa31f)) +- Merge branch 'main' into alpha ([477bae4](https://github.com/ethereum-push-notification-service/push-sdk/commit/477bae4fdc4e86374615f0f67c41c570a567b9fe)) ## [0.0.1-beta.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-beta.2) (2023-05-04) - ### Bug Fixes -* change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) -* changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) - - +- change preid to alpha ([#358](https://github.com/ethereum-push-notification-service/push-sdk/issues/358)) ([6ac2c23](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ac2c23c5e4a9f54f8bd6ae99aeb77c96417aae3)) +- changed AdditionalMeta structure ([#349](https://github.com/ethereum-push-notification-service/push-sdk/issues/349)) ([ee8ca02](https://github.com/ethereum-push-notification-service/push-sdk/commit/ee8ca022b2d948d08fa8503616898ff6c773062e)) ## [1.2.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-1.2.11) (2023-05-08) - - ## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-1.2.10) (2023-05-08) - - ## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.1...restapi-0.0.1-alpha.0) (2023-05-08) - - ## [0.0.1-beta.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.10...restapi-0.0.1-beta.1) (2023-05-04) - - ## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.0...restapi-1.2.10) (2023-05-02) - ### Bug Fixes -* add password validation ([#345](https://github.com/ethereum-push-notification-service/push-sdk/issues/345)) ([863f48f](https://github.com/ethereum-push-notification-service/push-sdk/commit/863f48f9cbb3022e01f8715005cc8cd0fa96d0a8)) -* Merge branch 'main' into deployment ([a3cf078](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3cf078f37d31859ae83129d2b704639bbaab62b)) - - +- add password validation ([#345](https://github.com/ethereum-push-notification-service/push-sdk/issues/345)) ([863f48f](https://github.com/ethereum-push-notification-service/push-sdk/commit/863f48f9cbb3022e01f8715005cc8cd0fa96d0a8)) +- Merge branch 'main' into deployment ([a3cf078](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3cf078f37d31859ae83129d2b704639bbaab62b)) ## [1.2.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.0...restapi-1.2.10) (2023-05-02) - ### Bug Fixes -* add password validation ([#345](https://github.com/ethereum-push-notification-service/push-sdk/issues/345)) ([863f48f](https://github.com/ethereum-push-notification-service/push-sdk/commit/863f48f9cbb3022e01f8715005cc8cd0fa96d0a8)) -* Merge branch 'main' into deployment ([a3cf078](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3cf078f37d31859ae83129d2b704639bbaab62b)) - - +- add password validation ([#345](https://github.com/ethereum-push-notification-service/push-sdk/issues/345)) ([863f48f](https://github.com/ethereum-push-notification-service/push-sdk/commit/863f48f9cbb3022e01f8715005cc8cd0fa96d0a8)) +- Merge branch 'main' into deployment ([a3cf078](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3cf078f37d31859ae83129d2b704639bbaab62b)) ## [0.0.1-beta.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.9...restapi-0.0.1-beta.0) (2023-05-02) - ### Bug Fixes -* added ci-version-beta ([2f282ce](https://github.com/ethereum-push-notification-service/push-sdk/commit/2f282ce60003733fc95ce239a6c1a2d6c24616cc)) -* added ci-version-beta ([496952a](https://github.com/ethereum-push-notification-service/push-sdk/commit/496952ac8faab02c82ee11be8e8925a1fb01cd01)) -* added release type ([28d7181](https://github.com/ethereum-push-notification-service/push-sdk/commit/28d71818c766b7057d4b1b8f629c8a4d01378db0)) -* added releaseType ([55429e5](https://github.com/ethereum-push-notification-service/push-sdk/commit/55429e54fc9df054dab955796ae4e34da8dd25ec)) - - +- added ci-version-beta ([2f282ce](https://github.com/ethereum-push-notification-service/push-sdk/commit/2f282ce60003733fc95ce239a6c1a2d6c24616cc)) +- added ci-version-beta ([496952a](https://github.com/ethereum-push-notification-service/push-sdk/commit/496952ac8faab02c82ee11be8e8925a1fb01cd01)) +- added release type ([28d7181](https://github.com/ethereum-push-notification-service/push-sdk/commit/28d71818c766b7057d4b1b8f629c8a4d01378db0)) +- added releaseType ([55429e5](https://github.com/ethereum-push-notification-service/push-sdk/commit/55429e54fc9df054dab955796ae4e34da8dd25ec)) ## [0.0.1-beta.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.9...restapi-0.0.1-beta.0) (2023-05-02) - ### Bug Fixes -* added ci-version-beta ([2f282ce](https://github.com/ethereum-push-notification-service/push-sdk/commit/2f282ce60003733fc95ce239a6c1a2d6c24616cc)) -* added ci-version-beta ([496952a](https://github.com/ethereum-push-notification-service/push-sdk/commit/496952ac8faab02c82ee11be8e8925a1fb01cd01)) -* added release type ([28d7181](https://github.com/ethereum-push-notification-service/push-sdk/commit/28d71818c766b7057d4b1b8f629c8a4d01378db0)) -* added releaseType ([55429e5](https://github.com/ethereum-push-notification-service/push-sdk/commit/55429e54fc9df054dab955796ae4e34da8dd25ec)) - - +- added ci-version-beta ([2f282ce](https://github.com/ethereum-push-notification-service/push-sdk/commit/2f282ce60003733fc95ce239a6c1a2d6c24616cc)) +- added ci-version-beta ([496952a](https://github.com/ethereum-push-notification-service/push-sdk/commit/496952ac8faab02c82ee11be8e8925a1fb01cd01)) +- added release type ([28d7181](https://github.com/ethereum-push-notification-service/push-sdk/commit/28d71818c766b7057d4b1b8f629c8a4d01378db0)) +- added releaseType ([55429e5](https://github.com/ethereum-push-notification-service/push-sdk/commit/55429e54fc9df054dab955796ae4e34da8dd25ec)) ## [1.2.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.8...restapi-1.2.9) (2023-05-02) - ### Bug Fixes -* Merge branch 'main' into deployment ([2b3993c](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b3993c673fcf11a39acd7a6663b6e6996fc26b6)) -* remove autoupgarde for v4 ([#344](https://github.com/ethereum-push-notification-service/push-sdk/issues/344)) ([3a4bef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3a4bef0750abb5bdb5ab9e96c9cc76e2269afa3c)) - - +- Merge branch 'main' into deployment ([2b3993c](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b3993c673fcf11a39acd7a6663b6e6996fc26b6)) +- remove autoupgarde for v4 ([#344](https://github.com/ethereum-push-notification-service/push-sdk/issues/344)) ([3a4bef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3a4bef0750abb5bdb5ab9e96c9cc76e2269afa3c)) ## [1.2.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.7...restapi-1.2.8) (2023-05-01) - ### Bug Fixes -* error ProgressHook added ([#336](https://github.com/ethereum-push-notification-service/push-sdk/issues/336)) ([3f7295f](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f7295f7811c15e5b9f3ba74a69ffcbe3fb6d829)) - - +- error ProgressHook added ([#336](https://github.com/ethereum-push-notification-service/push-sdk/issues/336)) ([3f7295f](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f7295f7811c15e5b9f3ba74a69ffcbe3fb6d829)) ## [1.2.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.6...restapi-1.2.7) (2023-04-27) - ### Bug Fixes -* Merge branch 'deployment' ([0d184dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/0d184dc75d8680ac8a77f1124204af86befac82c)) -* senderType is optional param ([#329](https://github.com/ethereum-push-notification-service/push-sdk/issues/329)) ([ed3d6e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/ed3d6e611975da054d5e1b3809e614450a563cd5)) - - +- Merge branch 'deployment' ([0d184dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/0d184dc75d8680ac8a77f1124204af86befac82c)) +- senderType is optional param ([#329](https://github.com/ethereum-push-notification-service/push-sdk/issues/329)) ([ed3d6e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/ed3d6e611975da054d5e1b3809e614450a563cd5)) ## [1.2.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.5...restapi-1.2.6) (2023-04-27) - ### Bug Fixes -* add chat.chat to exports ([#331](https://github.com/ethereum-push-notification-service/push-sdk/issues/331)) ([289c774](https://github.com/ethereum-push-notification-service/push-sdk/commit/289c774074cecd6998b0bda39bee4e779ee9daa3)) - - +- add chat.chat to exports ([#331](https://github.com/ethereum-push-notification-service/push-sdk/issues/331)) ([289c774](https://github.com/ethereum-push-notification-service/push-sdk/commit/289c774074cecd6998b0bda39bee4e779ee9daa3)) ## [1.2.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.4...restapi-1.2.5) (2023-04-27) - ### Bug Fixes -* nft compatibility ([#326](https://github.com/ethereum-push-notification-service/push-sdk/issues/326)) ([80650e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/80650e65f490e08df30c17c9e5dadc0b513b1f46)) - - +- nft compatibility ([#326](https://github.com/ethereum-push-notification-service/push-sdk/issues/326)) ([80650e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/80650e65f490e08df30c17c9e5dadc0b513b1f46)) ## [1.2.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.4...restapi-1.2.5) (2023-04-27) - ### Bug Fixes -* nft compatibility ([#326](https://github.com/ethereum-push-notification-service/push-sdk/issues/326)) ([80650e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/80650e65f490e08df30c17c9e5dadc0b513b1f46)) - - +- nft compatibility ([#326](https://github.com/ethereum-push-notification-service/push-sdk/issues/326)) ([80650e6](https://github.com/ethereum-push-notification-service/push-sdk/commit/80650e65f490e08df30c17c9e5dadc0b513b1f46)) ## [1.2.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.3...restapi-1.2.4) (2023-04-19) - ### Bug Fixes -* chamged signerType from ethers.wallet ([#315](https://github.com/ethereum-push-notification-service/push-sdk/issues/315)) ([385b3dd](https://github.com/ethereum-push-notification-service/push-sdk/commit/385b3ddf2e2aa22b687a5094ba5cfec0e13da63b)) -* fix videoCall Notif ([#310](https://github.com/ethereum-push-notification-service/push-sdk/issues/310)) ([069783e](https://github.com/ethereum-push-notification-service/push-sdk/commit/069783e2cbe77723e335affb2f2668c785aeace6)) - - +- chamged signerType from ethers.wallet ([#315](https://github.com/ethereum-push-notification-service/push-sdk/issues/315)) ([385b3dd](https://github.com/ethereum-push-notification-service/push-sdk/commit/385b3ddf2e2aa22b687a5094ba5cfec0e13da63b)) +- fix videoCall Notif ([#310](https://github.com/ethereum-push-notification-service/push-sdk/issues/310)) ([069783e](https://github.com/ethereum-push-notification-service/push-sdk/commit/069783e2cbe77723e335affb2f2668c785aeace6)) ## [1.2.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.2...restapi-1.2.3) (2023-04-18) - ### Bug Fixes -* git merge ([87a31a1](https://github.com/ethereum-push-notification-service/push-sdk/commit/87a31a142b80e3305d5986e9f6b5734d9345b7d0)) - - +- git merge ([87a31a1](https://github.com/ethereum-push-notification-service/push-sdk/commit/87a31a142b80e3305d5986e9f6b5734d9345b7d0)) ## [1.2.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.1...restapi-1.2.2) (2023-04-07) - ### Bug Fixes -* local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([639b4d2](https://github.com/ethereum-push-notification-service/push-sdk/commit/639b4d2de728ef289da5889b51fd45e003156699)) -* main merge ([0be9604](https://github.com/ethereum-push-notification-service/push-sdk/commit/0be9604eacf003db0cc4244f41d5e9c533f7613a)) -* remove hardcoded values ([#299](https://github.com/ethereum-push-notification-service/push-sdk/issues/299)) ([02a4e20](https://github.com/ethereum-push-notification-service/push-sdk/commit/02a4e2077a2ee4fb010d619d04acffc1881a2c0c)) -* signerType ([#303](https://github.com/ethereum-push-notification-service/push-sdk/issues/303)) ([20eb15a](https://github.com/ethereum-push-notification-service/push-sdk/commit/20eb15af4bc3286e5836845e299326352af0ce34)) -* version update ([d5433a9](https://github.com/ethereum-push-notification-service/push-sdk/commit/d5433a93de34e69953ca88e602d264b234708727)) -* version update ([#302](https://github.com/ethereum-push-notification-service/push-sdk/issues/302)) ([82bd4f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/82bd4f7882f8782f8d19a1daf97e5366ce26c5de)) - - +- local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([639b4d2](https://github.com/ethereum-push-notification-service/push-sdk/commit/639b4d2de728ef289da5889b51fd45e003156699)) +- main merge ([0be9604](https://github.com/ethereum-push-notification-service/push-sdk/commit/0be9604eacf003db0cc4244f41d5e9c533f7613a)) +- remove hardcoded values ([#299](https://github.com/ethereum-push-notification-service/push-sdk/issues/299)) ([02a4e20](https://github.com/ethereum-push-notification-service/push-sdk/commit/02a4e2077a2ee4fb010d619d04acffc1881a2c0c)) +- signerType ([#303](https://github.com/ethereum-push-notification-service/push-sdk/issues/303)) ([20eb15a](https://github.com/ethereum-push-notification-service/push-sdk/commit/20eb15af4bc3286e5836845e299326352af0ce34)) +- version update ([d5433a9](https://github.com/ethereum-push-notification-service/push-sdk/commit/d5433a93de34e69953ca88e602d264b234708727)) +- version update ([#302](https://github.com/ethereum-push-notification-service/push-sdk/issues/302)) ([82bd4f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/82bd4f7882f8782f8d19a1daf97e5366ce26c5de)) ## [1.2.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.0...restapi-1.2.1) (2023-04-07) - ### Bug Fixes -* added types for chat fn ([#298](https://github.com/ethereum-push-notification-service/push-sdk/issues/298)) ([1c944b2](https://github.com/ethereum-push-notification-service/push-sdk/commit/1c944b237909e393f6ae72c76138411076c62b13)) - - - +- added types for chat fn ([#298](https://github.com/ethereum-push-notification-service/push-sdk/issues/298)) ([1c944b2](https://github.com/ethereum-push-notification-service/push-sdk/commit/1c944b237909e393f6ae72c76138411076c62b13)) # [1.2.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.1.0...restapi-1.2.0) (2023-04-06) - ### Bug Fixes -* **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) - +- **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) ### Features -* local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([2b09806](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b09806d28f1c8d2f74e163691fc2bcc60f26116)) - - +- local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([2b09806](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b09806d28f1c8d2f74e163691fc2bcc60f26116)) # [1.2.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.1.0...restapi-1.2.0) (2023-04-06) - ### Bug Fixes -* **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) - +- **component:** add chatid to requests and chats ([#278](https://github.com/ethereum-push-notification-service/push-sdk/issues/278)) ([e1d4af5](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1d4af5aa9cfeef0a2ca422d87a158e546fe9d4a)) ### Features -* local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([2b09806](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b09806d28f1c8d2f74e163691fc2bcc60f26116)) - - +- local for local development ([#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295)) ([2b09806](https://github.com/ethereum-push-notification-service/push-sdk/commit/2b09806d28f1c8d2f74e163691fc2bcc60f26116)) # [1.1.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.4...restapi-1.1.0) (2023-04-05) - ### Bug Fixes -* remove unnecessary log ([#289](https://github.com/ethereum-push-notification-service/push-sdk/issues/289)) ([7ac6be3](https://github.com/ethereum-push-notification-service/push-sdk/commit/7ac6be3b99ab1c36fa18e701b7656ff483834456)) -* success progressHook ([#291](https://github.com/ethereum-push-notification-service/push-sdk/issues/291)) ([9fd5b5a](https://github.com/ethereum-push-notification-service/push-sdk/commit/9fd5b5a0a64d922b299e8e33543c0ba500147fbc)) - +- remove unnecessary log ([#289](https://github.com/ethereum-push-notification-service/push-sdk/issues/289)) ([7ac6be3](https://github.com/ethereum-push-notification-service/push-sdk/commit/7ac6be3b99ab1c36fa18e701b7656ff483834456)) +- success progressHook ([#291](https://github.com/ethereum-push-notification-service/push-sdk/issues/291)) ([9fd5b5a](https://github.com/ethereum-push-notification-service/push-sdk/commit/9fd5b5a0a64d922b299e8e33543c0ba500147fbc)) ### Features -* **sendnotification:** add additionalMeta field to payload ([#235](https://github.com/ethereum-push-notification-service/push-sdk/issues/235)) ([6d9d60b](https://github.com/ethereum-push-notification-service/push-sdk/commit/6d9d60b2532bf408aaed708a8bbf753aeab13296)), closes [#234](https://github.com/ethereum-push-notification-service/push-sdk/issues/234) - - +- **sendnotification:** add additionalMeta field to payload ([#235](https://github.com/ethereum-push-notification-service/push-sdk/issues/235)) ([6d9d60b](https://github.com/ethereum-push-notification-service/push-sdk/commit/6d9d60b2532bf408aaed708a8bbf753aeab13296)), closes [#234](https://github.com/ethereum-push-notification-service/push-sdk/issues/234) ## [1.0.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.3...restapi-1.0.4) (2023-04-04) - ### Bug Fixes -* success progressHook ([3e699b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3e699b07071fe53499d8116bab108ff5a00d8a85)) - - +- success progressHook ([3e699b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3e699b07071fe53499d8116bab108ff5a00d8a85)) ## [1.0.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.2...restapi-1.0.3) (2023-04-04) - ### Bug Fixes - ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) - ### Bug Fixes - - - - ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) - ### Bug Fixes - - ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) - ### Bug Fixes - ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) - ### Bug Fixes - ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) - ### Bug Fixes - # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) -* progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) -* **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) -* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) -* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) - - -* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +- progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) +- **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) +- sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +- signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) +- Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ### BREAKING CHANGES -* New chat key ecnryption +- New chat key ecnryption -* feat: chat key encryption v2 +- feat: chat key encryption v2 New encryption version for pgp keys -* Signer is required in ui-web -* refactor: add signer in ApproveRequest +- Signer is required in ui-web -* fix: revert dev from localhost +- refactor: add signer in ApproveRequest -* feat: auto uprade keys +- fix: revert dev from localhost -* test: tests for upgrade User +- feat: auto uprade keys -* test: test for send chat message +- test: tests for upgrade User -* test: rename tests - -* test: text formating fix +- test: test for send chat message +- test: rename tests +- test: text formating fix # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) -* progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) -* **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) -* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) -* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) - - -* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +- progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) +- **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) +- sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +- signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) +- Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ### BREAKING CHANGES -* New chat key ecnryption +- New chat key ecnryption -* feat: chat key encryption v2 +- feat: chat key encryption v2 New encryption version for pgp keys -* Signer is required in ui-web -* refactor: add signer in ApproveRequest +- Signer is required in ui-web -* fix: revert dev from localhost +- refactor: add signer in ApproveRequest -* feat: auto uprade keys +- fix: revert dev from localhost -* test: tests for upgrade User +- feat: auto uprade keys -* test: test for send chat message +- test: tests for upgrade User -* test: rename tests - -* test: text formating fix +- test: test for send chat message +- test: rename tests +- test: text formating fix # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) -* progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) -* **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) -* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) -* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) - - -* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +- progressHook Changes ([#287](https://github.com/ethereum-push-notification-service/push-sdk/issues/287)) ([10d3e92](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d3e929022fdada202be1a9cbb3d49d90edb1d1)) +- **restapi/helpers/crypto.ts:** hook Fix ([#288](https://github.com/ethereum-push-notification-service/push-sdk/issues/288)) ([b751637](https://github.com/ethereum-push-notification-service/push-sdk/commit/b751637c158811201140cfa1190c57c5f1b07262)) +- sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +- signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) +- Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ### BREAKING CHANGES -* New chat key ecnryption +- New chat key ecnryption -* feat: chat key encryption v2 +- feat: chat key encryption v2 New encryption version for pgp keys -* Signer is required in ui-web - -* refactor: add signer in ApproveRequest -* fix: revert dev from localhost +- Signer is required in ui-web -* feat: auto uprade keys +- refactor: add signer in ApproveRequest -* test: tests for upgrade User +- fix: revert dev from localhost -* test: test for send chat message +- feat: auto uprade keys -* test: rename tests +- test: tests for upgrade User -* test: text formating fix +- test: test for send chat message +- test: rename tests +- test: text formating fix ## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.1...restapi-1.0.2) (2023-04-04) - ### Bug Fixes - ## [1.0.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.0.0...restapi-1.0.1) (2023-04-04) - ### Bug Fixes - - # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) -* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) -* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) - - -* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +- sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +- signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) +- Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ### BREAKING CHANGES -* New chat key ecnryption +- New chat key ecnryption -* feat: chat key encryption v2 +- feat: chat key encryption v2 New encryption version for pgp keys -* Signer is required in ui-web - -* refactor: add signer in ApproveRequest -* fix: revert dev from localhost +- Signer is required in ui-web -* feat: auto uprade keys +- refactor: add signer in ApproveRequest -* test: tests for upgrade User +- fix: revert dev from localhost -* test: test for send chat message +- feat: auto uprade keys -* test: rename tests +- test: tests for upgrade User -* test: text formating fix +- test: test for send chat message +- test: rename tests +- test: text formating fix # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-04-04) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) -* sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) -* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) - - -* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +- sig changes to include domain ([#279](https://github.com/ethereum-push-notification-service/push-sdk/issues/279)) ([3dd8a9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3dd8a9ce301521e3913437f3192cefa8d699a914)) +- signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) +- Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ### BREAKING CHANGES -* New chat key ecnryption +- New chat key ecnryption -* feat: chat key encryption v2 +- feat: chat key encryption v2 New encryption version for pgp keys -* Signer is required in ui-web -* refactor: add signer in ApproveRequest +- Signer is required in ui-web -* fix: revert dev from localhost +- refactor: add signer in ApproveRequest -* feat: auto uprade keys +- fix: revert dev from localhost -* test: tests for upgrade User +- feat: auto uprade keys -* test: test for send chat message +- test: tests for upgrade User -* test: rename tests - -* test: text formating fix +- test: test for send chat message +- test: rename tests +- test: text formating fix # [1.0.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-1.0.0) (2023-03-28) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) -* signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) - - -* Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) +- signature Validation of chat msg ([#272](https://github.com/ethereum-push-notification-service/push-sdk/issues/272)) ([9f6093f](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f6093fcc5941a2a7bc19d00217483016828bdcb)) +- Chat keys Encryption V2 (#231) ([f35730b](https://github.com/ethereum-push-notification-service/push-sdk/commit/f35730bd6398694176941875abb3e8678b255568)), closes [#231](https://github.com/ethereum-push-notification-service/push-sdk/issues/231) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ### BREAKING CHANGES -* New chat key ecnryption +- New chat key ecnryption -* feat: chat key encryption v2 +- feat: chat key encryption v2 New encryption version for pgp keys -* Signer is required in ui-web - -* refactor: add signer in ApproveRequest -* fix: revert dev from localhost +- Signer is required in ui-web -* feat: auto uprade keys +- refactor: add signer in ApproveRequest -* test: tests for upgrade User +- fix: revert dev from localhost -* test: test for send chat message +- feat: auto uprade keys -* test: rename tests +- test: tests for upgrade User -* test: text formating fix +- test: test for send chat message +- test: rename tests +- test: text formating fix # [0.9.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-0.9.0) (2023-03-23) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) - +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) # [0.9.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-0.9.0) (2023-03-23) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) - +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) # [0.9.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-0.9.0) (2023-03-23) - ### Bug Fixes -* **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) -* **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) -* **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) -* **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) -* **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) -* **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) - +- **component:** decrypt issue fixed ([21538db](https://github.com/ethereum-push-notification-service/push-sdk/commit/21538dbb0569914b880d8f36aea341360041b4e7)) +- **component:** mocha setup ([6ecf79d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ecf79dd3ee4840350965fb045cc163bdd98b5a9)) +- **component:** mocha setup ([5b7c504](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7c50444734c8df507175eb98ab780507ddcad4)) +- **component:** mocha setup with basic test case ([35fa1dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/35fa1dc259051572ca51f8e2e0607a3917589159)) +- **component:** removed duplicate decryptAndVerifySignature method ([e42b7ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/e42b7ffb4659c4f603a2f15eec2f6bf84ddcf303)) +- **component:** removed duplicate decryptAndVerifySignature method ([a03cf7e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a03cf7e2ff56e5af82e0d80943cfb3ee48b773f6)) ### Features -* chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) -* mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) - - +- chat.chat function ([760dda4](https://github.com/ethereum-push-notification-service/push-sdk/commit/760dda4095e57ef1f79fba8543aa5ff6a8c48c6f)) +- mediaURL type message support ([72d8d41](https://github.com/ethereum-push-notification-service/push-sdk/commit/72d8d411155ffce55da14810d7aeb5845035dade)) ## [0.8.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.2...restapi-0.8.3) (2023-03-22) - - ## [0.8.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.1...restapi-0.8.2) (2023-03-17) - ### Bug Fixes -* fix user.getBatch fn of restapi ([24e6a82](https://github.com/ethereum-push-notification-service/push-sdk/commit/24e6a8251031f766ceb8b76f89a72651f133db78)) -* rollback to crypto-js ([ba06e91](https://github.com/ethereum-push-notification-service/push-sdk/commit/ba06e9122c6b2c230d6f45980fddc0ddff77a201)) - - +- fix user.getBatch fn of restapi ([24e6a82](https://github.com/ethereum-push-notification-service/push-sdk/commit/24e6a8251031f766ceb8b76f89a72651f133db78)) +- rollback to crypto-js ([ba06e91](https://github.com/ethereum-push-notification-service/push-sdk/commit/ba06e9122c6b2c230d6f45980fddc0ddff77a201)) ## [0.8.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.8.0...restapi-0.8.1) (2023-03-09) - - # [0.8.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.6...restapi-0.8.0) (2023-03-07) - ### Bug Fixes -* **component:** added enum type to notification type and identity type ([#216](https://github.com/ethereum-push-notification-service/push-sdk/issues/216)) ([e76dc18](https://github.com/ethereum-push-notification-service/push-sdk/commit/e76dc1800739472133cf97e59891c62d223a80f7)) -* **component:** added signing fix for approve intent request ([#215](https://github.com/ethereum-push-notification-service/push-sdk/issues/215)) ([b117fe5](https://github.com/ethereum-push-notification-service/push-sdk/commit/b117fe544b96e5b80c8df1b91257afca2402cde3)) -* **component:** env type in demo react and uiweb ([#225](https://github.com/ethereum-push-notification-service/push-sdk/issues/225)) ([ff1113a](https://github.com/ethereum-push-notification-service/push-sdk/commit/ff1113adb226aee4c9f6ccdfa488e59b47ca9b9e)) - +- **component:** added enum type to notification type and identity type ([#216](https://github.com/ethereum-push-notification-service/push-sdk/issues/216)) ([e76dc18](https://github.com/ethereum-push-notification-service/push-sdk/commit/e76dc1800739472133cf97e59891c62d223a80f7)) +- **component:** added signing fix for approve intent request ([#215](https://github.com/ethereum-push-notification-service/push-sdk/issues/215)) ([b117fe5](https://github.com/ethereum-push-notification-service/push-sdk/commit/b117fe544b96e5b80c8df1b91257afca2402cde3)) +- **component:** env type in demo react and uiweb ([#225](https://github.com/ethereum-push-notification-service/push-sdk/issues/225)) ([ff1113a](https://github.com/ethereum-push-notification-service/push-sdk/commit/ff1113adb226aee4c9f6ccdfa488e59b47ca9b9e)) ### Features -* added Optimism Chain ([#221](https://github.com/ethereum-push-notification-service/push-sdk/issues/221)) ([a9f6e56](https://github.com/ethereum-push-notification-service/push-sdk/commit/a9f6e56f51ac6eb089ddeffd6c47f144b9b28dd8)) - - +- added Optimism Chain ([#221](https://github.com/ethereum-push-notification-service/push-sdk/issues/221)) ([a9f6e56](https://github.com/ethereum-push-notification-service/push-sdk/commit/a9f6e56f51ac6eb089ddeffd6c47f144b9b28dd8)) ## [0.7.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.5...restapi-0.7.6) (2023-03-03) - ### Bug Fixes -* **component:** eNV type check across all the functions ([#210](https://github.com/ethereum-push-notification-service/push-sdk/issues/210)) ([d532b12](https://github.com/ethereum-push-notification-service/push-sdk/commit/d532b1217d836d7fcedb3f665173b96cbb588607)) -* resolved buffer polyfills issue in browser environments ([#218](https://github.com/ethereum-push-notification-service/push-sdk/issues/218)) ([ded2c50](https://github.com/ethereum-push-notification-service/push-sdk/commit/ded2c50e25916e0ceb907701c30a334faaacf403)) - - +- **component:** eNV type check across all the functions ([#210](https://github.com/ethereum-push-notification-service/push-sdk/issues/210)) ([d532b12](https://github.com/ethereum-push-notification-service/push-sdk/commit/d532b1217d836d7fcedb3f665173b96cbb588607)) +- resolved buffer polyfills issue in browser environments ([#218](https://github.com/ethereum-push-notification-service/push-sdk/issues/218)) ([ded2c50](https://github.com/ethereum-push-notification-service/push-sdk/commit/ded2c50e25916e0ceb907701c30a334faaacf403)) ## [0.7.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.4...restapi-0.7.5) (2023-02-25) - - ## [0.7.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.3...restapi-0.7.4) (2023-02-25) - ### Bug Fixes -* send message signature fixes ([#203](https://github.com/ethereum-push-notification-service/push-sdk/issues/203)) ([9a3c448](https://github.com/ethereum-push-notification-service/push-sdk/commit/9a3c4484f2c1ac5f7abd2796801da626caa91629)) - - +- send message signature fixes ([#203](https://github.com/ethereum-push-notification-service/push-sdk/issues/203)) ([9a3c448](https://github.com/ethereum-push-notification-service/push-sdk/commit/9a3c4484f2c1ac5f7abd2796801da626caa91629)) ## [0.7.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.2...restapi-0.7.3) (2023-02-25) - - ## [0.7.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.1...restapi-0.7.2) (2023-02-24) - ### Bug Fixes -* **component:** implemented signature validation for create and update indent ([ffe026b](https://github.com/ethereum-push-notification-service/push-sdk/commit/ffe026bb76b97883a301d887395df055d579356b)) -* fix merge conflict ([90fb1d5](https://github.com/ethereum-push-notification-service/push-sdk/commit/90fb1d5c1a60695d7c559eaa43a6b72b3a5705af)) -* merge conflict fix ([af6ee32](https://github.com/ethereum-push-notification-service/push-sdk/commit/af6ee324937e31581b1ece56d817740e55a5ced6)) -* small change ([e346547](https://github.com/ethereum-push-notification-service/push-sdk/commit/e346547b848c69f1f41866e9625e52e285256a12)) - - +- **component:** implemented signature validation for create and update indent ([ffe026b](https://github.com/ethereum-push-notification-service/push-sdk/commit/ffe026bb76b97883a301d887395df055d579356b)) +- fix merge conflict ([90fb1d5](https://github.com/ethereum-push-notification-service/push-sdk/commit/90fb1d5c1a60695d7c559eaa43a6b72b3a5705af)) +- merge conflict fix ([af6ee32](https://github.com/ethereum-push-notification-service/push-sdk/commit/af6ee324937e31581b1ece56d817740e55a5ced6)) +- small change ([e346547](https://github.com/ethereum-push-notification-service/push-sdk/commit/e346547b848c69f1f41866e9625e52e285256a12)) ## [0.7.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.7.0...restapi-0.7.1) (2023-02-23) - ### Bug Fixes -* added missing import in approveRequest ([b79045d](https://github.com/ethereum-push-notification-service/push-sdk/commit/b79045d0946facd57e1bf72e5664c54021f3e3d7)) -* **component:** added group meta ([#193](https://github.com/ethereum-push-notification-service/push-sdk/issues/193)) ([8e0ef1e](https://github.com/ethereum-push-notification-service/push-sdk/commit/8e0ef1e584a4e28be965e46a2f3bac7f81262c14)) - - +- added missing import in approveRequest ([b79045d](https://github.com/ethereum-push-notification-service/push-sdk/commit/b79045d0946facd57e1bf72e5664c54021f3e3d7)) +- **component:** added group meta ([#193](https://github.com/ethereum-push-notification-service/push-sdk/issues/193)) ([8e0ef1e](https://github.com/ethereum-push-notification-service/push-sdk/commit/8e0ef1e584a4e28be965e46a2f3bac7f81262c14)) # [0.7.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.6.4...restapi-0.7.0) (2023-02-22) - ### Features -* add group by name function ([8601021](https://github.com/ethereum-push-notification-service/push-sdk/commit/860102153e2f8876423b218aa0d5dce98f012dba)) -* **component:** added sdk method get users in batch ([#182](https://github.com/ethereum-push-notification-service/push-sdk/issues/182)) ([ebb8e8b](https://github.com/ethereum-push-notification-service/push-sdk/commit/ebb8e8b39d7b50d4dda6787b06fe7bef803d87c3)) -* update npm package version for rest-api ([66d7d9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/66d7d9c028bd936203a7e3640f552b833203ca47)) - - +- add group by name function ([8601021](https://github.com/ethereum-push-notification-service/push-sdk/commit/860102153e2f8876423b218aa0d5dce98f012dba)) +- **component:** added sdk method get users in batch ([#182](https://github.com/ethereum-push-notification-service/push-sdk/issues/182)) ([ebb8e8b](https://github.com/ethereum-push-notification-service/push-sdk/commit/ebb8e8b39d7b50d4dda6787b06fe7bef803d87c3)) +- update npm package version for rest-api ([66d7d9c](https://github.com/ethereum-push-notification-service/push-sdk/commit/66d7d9c028bd936203a7e3640f552b833203ca47)) ## [0.6.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.6.3...restapi-0.6.4) (2023-02-21) - - ## [0.6.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.6.2...restapi-0.6.3) (2023-02-21) - - ## [0.6.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.6.1...restapi-0.6.2) (2023-02-21) - ### Bug Fixes -* commenting out for jscutlery semver version fix ([0e52b01](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e52b01a488cb7a63f6b5162f02cdf412ee10139)) - - +- commenting out for jscutlery semver version fix ([0e52b01](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e52b01a488cb7a63f6b5162f02cdf412ee10139)) ## [0.6.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.6.0...restapi-0.6.1) (2023-02-21) - ### Bug Fixes -* commenting for jscutlery semver version tag fix ([d7def98](https://github.com/ethereum-push-notification-service/push-sdk/commit/d7def98bb0ad4a2ebe0b51dc658c5fb7439b5dda)) - - +- commenting for jscutlery semver version tag fix ([d7def98](https://github.com/ethereum-push-notification-service/push-sdk/commit/d7def98bb0ad4a2ebe0b51dc658c5fb7439b5dda)) # [0.6.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.5.0...restapi-0.6.0) (2023-02-21) - ### Features -* commenting out for jscutlery/semver version tag bug fix ([3533ae7](https://github.com/ethereum-push-notification-service/push-sdk/commit/3533ae75e362e1801bd7d03e5c3a6e599b784acc)) - - +- commenting out for jscutlery/semver version tag bug fix ([3533ae7](https://github.com/ethereum-push-notification-service/push-sdk/commit/3533ae75e362e1801bd7d03e5c3a6e599b784acc)) # [0.5.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.4.0...restapi-0.5.0) (2023-02-21) - ### Bug Fixes -* **component:** get-subscribers-api page, limit improvements ([#156](https://github.com/ethereum-push-notification-service/push-sdk/issues/156)) ([a396fa4](https://github.com/ethereum-push-notification-service/push-sdk/commit/a396fa4343a79239b2ef0ffba3ace57f7b5f9dcc)) -* **component:** group chat - Added validation for NFT Address with ChainId ([#172](https://github.com/ethereum-push-notification-service/push-sdk/issues/172)) ([bca5191](https://github.com/ethereum-push-notification-service/push-sdk/commit/bca519108f244ffb21fcfcebb27a1e4bed197835)) -* **component:** group chat SDK changes and improvements ([#154](https://github.com/ethereum-push-notification-service/push-sdk/issues/154)) ([e94fab9](https://github.com/ethereum-push-notification-service/push-sdk/commit/e94fab906eba9fa5672e3171871cf94259a95992)) -* **component:** update group signature generation bug fix ([#164](https://github.com/ethereum-push-notification-service/push-sdk/issues/164)) ([acb82a9](https://github.com/ethereum-push-notification-service/push-sdk/commit/acb82a9b44625b1ac37b5ea2d82e7877bcfc669e)) - +- **component:** get-subscribers-api page, limit improvements ([#156](https://github.com/ethereum-push-notification-service/push-sdk/issues/156)) ([a396fa4](https://github.com/ethereum-push-notification-service/push-sdk/commit/a396fa4343a79239b2ef0ffba3ace57f7b5f9dcc)) +- **component:** group chat - Added validation for NFT Address with ChainId ([#172](https://github.com/ethereum-push-notification-service/push-sdk/issues/172)) ([bca5191](https://github.com/ethereum-push-notification-service/push-sdk/commit/bca519108f244ffb21fcfcebb27a1e4bed197835)) +- **component:** group chat SDK changes and improvements ([#154](https://github.com/ethereum-push-notification-service/push-sdk/issues/154)) ([e94fab9](https://github.com/ethereum-push-notification-service/push-sdk/commit/e94fab906eba9fa5672e3171871cf94259a95992)) +- **component:** update group signature generation bug fix ([#164](https://github.com/ethereum-push-notification-service/push-sdk/issues/164)) ([acb82a9](https://github.com/ethereum-push-notification-service/push-sdk/commit/acb82a9b44625b1ac37b5ea2d82e7877bcfc669e)) ### Features -* **component:** group chat - update group, conversation hash ([#150](https://github.com/ethereum-push-notification-service/push-sdk/issues/150)) ([fc24618](https://github.com/ethereum-push-notification-service/push-sdk/commit/fc2461847bb86d7e0384ace5a484675480f00503)) - - +- **component:** group chat - update group, conversation hash ([#150](https://github.com/ethereum-push-notification-service/push-sdk/issues/150)) ([fc24618](https://github.com/ethereum-push-notification-service/push-sdk/commit/fc2461847bb86d7e0384ace5a484675480f00503)) # [0.4.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.3.1...restapi-0.4.0) (2023-02-09) - ### Bug Fixes -* fixed response of chat.chats restapi and published restapi v0.3.3 ([#142](https://github.com/ethereum-push-notification-service/push-sdk/issues/142)) ([40abc16](https://github.com/ethereum-push-notification-service/push-sdk/commit/40abc1609d780aea6620d6f136d46c37e8e70744)) -* Metamask reject handled ([#136](https://github.com/ethereum-push-notification-service/push-sdk/issues/136)) ([46a20b7](https://github.com/ethereum-push-notification-service/push-sdk/commit/46a20b751e655a526168c8ae7c400211f3b62b15)) -* **restapi:** fix parse api response of notifications to send subject/title as asub ([#140](https://github.com/ethereum-push-notification-service/push-sdk/issues/140)) ([6a11feb](https://github.com/ethereum-push-notification-service/push-sdk/commit/6a11feb7cc02bf9ca0541b34f399992ad33f12a4)), closes [#139](https://github.com/ethereum-push-notification-service/push-sdk/issues/139) -* send request bug fixed ([#143](https://github.com/ethereum-push-notification-service/push-sdk/issues/143)) ([99b305d](https://github.com/ethereum-push-notification-service/push-sdk/commit/99b305d2a54f51fd8d82b15a79e58344e6ff66c8)) - +- fixed response of chat.chats restapi and published restapi v0.3.3 ([#142](https://github.com/ethereum-push-notification-service/push-sdk/issues/142)) ([40abc16](https://github.com/ethereum-push-notification-service/push-sdk/commit/40abc1609d780aea6620d6f136d46c37e8e70744)) +- Metamask reject handled ([#136](https://github.com/ethereum-push-notification-service/push-sdk/issues/136)) ([46a20b7](https://github.com/ethereum-push-notification-service/push-sdk/commit/46a20b751e655a526168c8ae7c400211f3b62b15)) +- **restapi:** fix parse api response of notifications to send subject/title as asub ([#140](https://github.com/ethereum-push-notification-service/push-sdk/issues/140)) ([6a11feb](https://github.com/ethereum-push-notification-service/push-sdk/commit/6a11feb7cc02bf9ca0541b34f399992ad33f12a4)), closes [#139](https://github.com/ethereum-push-notification-service/push-sdk/issues/139) +- send request bug fixed ([#143](https://github.com/ethereum-push-notification-service/push-sdk/issues/143)) ([99b305d](https://github.com/ethereum-push-notification-service/push-sdk/commit/99b305d2a54f51fd8d82b15a79e58344e6ff66c8)) ### Features -* **component:** Added Group Chat Functionality ([#122](https://github.com/ethereum-push-notification-service/push-sdk/issues/122)) ([5bf341f](https://github.com/ethereum-push-notification-service/push-sdk/commit/5bf341f6f60a6786be47f668fa3ed1b15a66be88)) - - +- **component:** Added Group Chat Functionality ([#122](https://github.com/ethereum-push-notification-service/push-sdk/issues/122)) ([5bf341f](https://github.com/ethereum-push-notification-service/push-sdk/commit/5bf341f6f60a6786be47f668fa3ed1b15a66be88)) ## [0.3.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.3.1...restapi-0.3.2) (2023-02-08) - ### Bug Fixes -* fixed response of chat.chats restapi ([ab1f432](https://github.com/ethereum-push-notification-service/push-sdk/commit/ab1f432dbe5443c72375ab1baa7226b997396aa4)) -* fixed the message response object ([83d4f1e](https://github.com/ethereum-push-notification-service/push-sdk/commit/83d4f1e565b090d1c62859f7461f4e1c3bb9398a)) -* Metamask reject handled ([#136](https://github.com/ethereum-push-notification-service/push-sdk/issues/136)) ([46a20b7](https://github.com/ethereum-push-notification-service/push-sdk/commit/46a20b751e655a526168c8ae7c400211f3b62b15)) -* **restapi:** fix parse api response of notifications to send subject/title as asub ([#140](https://github.com/ethereum-push-notification-service/push-sdk/issues/140)) ([6a11feb](https://github.com/ethereum-push-notification-service/push-sdk/commit/6a11feb7cc02bf9ca0541b34f399992ad33f12a4)), closes [#139](https://github.com/ethereum-push-notification-service/push-sdk/issues/139) - - +- fixed response of chat.chats restapi ([ab1f432](https://github.com/ethereum-push-notification-service/push-sdk/commit/ab1f432dbe5443c72375ab1baa7226b997396aa4)) +- fixed the message response object ([83d4f1e](https://github.com/ethereum-push-notification-service/push-sdk/commit/83d4f1e565b090d1c62859f7461f4e1c3bb9398a)) +- Metamask reject handled ([#136](https://github.com/ethereum-push-notification-service/push-sdk/issues/136)) ([46a20b7](https://github.com/ethereum-push-notification-service/push-sdk/commit/46a20b751e655a526168c8ae7c400211f3b62b15)) +- **restapi:** fix parse api response of notifications to send subject/title as asub ([#140](https://github.com/ethereum-push-notification-service/push-sdk/issues/140)) ([6a11feb](https://github.com/ethereum-push-notification-service/push-sdk/commit/6a11feb7cc02bf9ca0541b34f399992ad33f12a4)), closes [#139](https://github.com/ethereum-push-notification-service/push-sdk/issues/139) ## [0.3.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.3.1...restapi-0.3.2) (2023-02-03) - ### Bug Fixes -* Metamask reject handled ([#136](https://github.com/ethereum-push-notification-service/push-sdk/issues/136)) ([46a20b7](https://github.com/ethereum-push-notification-service/push-sdk/commit/46a20b751e655a526168c8ae7c400211f3b62b15)) -* **restapi:** fix parse api response of notifications to send subject/title as asub ([#140](https://github.com/ethereum-push-notification-service/push-sdk/issues/140)) ([6a11feb](https://github.com/ethereum-push-notification-service/push-sdk/commit/6a11feb7cc02bf9ca0541b34f399992ad33f12a4)), closes [#139](https://github.com/ethereum-push-notification-service/push-sdk/issues/139) - - +- Metamask reject handled ([#136](https://github.com/ethereum-push-notification-service/push-sdk/issues/136)) ([46a20b7](https://github.com/ethereum-push-notification-service/push-sdk/commit/46a20b751e655a526168c8ae7c400211f3b62b15)) +- **restapi:** fix parse api response of notifications to send subject/title as asub ([#140](https://github.com/ethereum-push-notification-service/push-sdk/issues/140)) ([6a11feb](https://github.com/ethereum-push-notification-service/push-sdk/commit/6a11feb7cc02bf9ca0541b34f399992ad33f12a4)), closes [#139](https://github.com/ethereum-push-notification-service/push-sdk/issues/139) ## [0.3.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.3.0...restapi-0.3.1) (2023-01-27) - - # [0.3.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.2.1...restapi-0.3.0) (2023-01-13) - ### Bug Fixes -* added throw Error in remaining sdk endpoints ([f78e3d6](https://github.com/ethereum-push-notification-service/push-sdk/commit/f78e3d66684f8941315b21ac9876a18f37fdf1d0)) - +- added throw Error in remaining sdk endpoints ([f78e3d6](https://github.com/ethereum-push-notification-service/push-sdk/commit/f78e3d66684f8941315b21ac9876a18f37fdf1d0)) ### Features -* Bsc chain config changes added ([#113](https://github.com/ethereum-push-notification-service/push-sdk/issues/113)) ([e1af11b](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1af11b1fa444e30f8aa08ee6b54a30bb03d6070)) - - +- Bsc chain config changes added ([#113](https://github.com/ethereum-push-notification-service/push-sdk/issues/113)) ([e1af11b](https://github.com/ethereum-push-notification-service/push-sdk/commit/e1af11b1fa444e30f8aa08ee6b54a30bb03d6070)) ## [0.2.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.2.0...restapi-0.2.1) (2022-11-03) - ### Bug Fixes -* removed lightweight package ([4c0883e](https://github.com/ethereum-push-notification-service/push-sdk/commit/4c0883eb5d7172ef9c6134bad9d26a0a8116f53d)) - - +- removed lightweight package ([4c0883e](https://github.com/ethereum-push-notification-service/push-sdk/commit/4c0883eb5d7172ef9c6134bad9d26a0a8116f53d)) # [0.2.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.1.1...restapi-0.2.0) (2022-11-02) - ### Features -* push chat restapi ([5899556](https://github.com/ethereum-push-notification-service/push-sdk/commit/5899556fc33a2be247911a1cf194e656c3e7a6df)), closes [#31](https://github.com/ethereum-push-notification-service/push-sdk/issues/31) [#40](https://github.com/ethereum-push-notification-service/push-sdk/issues/40) - - +- push chat restapi ([5899556](https://github.com/ethereum-push-notification-service/push-sdk/commit/5899556fc33a2be247911a1cf194e656c3e7a6df)), closes [#31](https://github.com/ethereum-push-notification-service/push-sdk/issues/31) [#40](https://github.com/ethereum-push-notification-service/push-sdk/issues/40) ## [0.1.1](https://github.com/ethereum-push-notification-service/sdk/compare/restapi-0.1.0...restapi-0.1.1) (2022-10-07) - - # [0.1.0](https://github.com/ethereum-push-notification-service/sdk/compare/restapi-0.0.5...restapi-0.1.0) (2022-10-07) - ### Features -* **restapi:** stable version ([f6d18b6](https://github.com/ethereum-push-notification-service/sdk/commit/f6d18b685696d00c06b711fd70b51e567a31e288)) - - +- **restapi:** stable version ([f6d18b6](https://github.com/ethereum-push-notification-service/sdk/commit/f6d18b685696d00c06b711fd70b51e567a31e288)) ## [0.0.5](https://github.com/ethereum-push-notification-service/sdk/compare/restapi-0.0.4...restapi-0.0.5) (2022-10-07) - ### Bug Fixes -* **all:** updating restapi, uiweb ([d86945d](https://github.com/ethereum-push-notification-service/sdk/commit/d86945d43af815a6a7ccd6a38f6a383a1fc8d4d1)) - - +- **all:** updating restapi, uiweb ([d86945d](https://github.com/ethereum-push-notification-service/sdk/commit/d86945d43af815a6a7ccd6a38f6a383a1fc8d4d1)) ## [0.0.4](https://github.com/ethereum-push-notification-service/sdk/compare/restapi-0.0.3...restapi-0.0.4) (2022-10-05) - - ## [0.0.3](https://github.com/ethereum-push-notification-service/sdk/compare/restapi-0.0.2...restapi-0.0.3) (2022-10-05) - - ## [0.0.2](https://github.com/ethereum-push-notification-service/sdk/compare/restapi-0.0.1...restapi-0.0.2) (2022-10-05) - ### Bug Fixes -* **restapi:** trigger publish ([41348fc](https://github.com/ethereum-push-notification-service/sdk/commit/41348fcefa62471fa3272e53b40bde1d0587ee0c)) - - +- **restapi:** trigger publish ([41348fc](https://github.com/ethereum-push-notification-service/sdk/commit/41348fcefa62471fa3272e53b40bde1d0587ee0c)) ## 0.0.1 (2022-10-05) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 86df69317..722c67255 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -1,7 +1,9 @@ # restapi + This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer Docs](https://docs.push.org/developers) or [Push.org](https://push.org) to learn more. # Index + - [restapi](#restapi) - [Index](#index) - [How to use in your app?](#how-to-use-in-your-app) @@ -80,6 +82,7 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [isInitiator](#isinitiator) # How to use in your app? + ## Installation ```bash @@ -91,21 +94,26 @@ or ```bash npm install @pushprotocol/restapi@latest ethers@^5.6 ``` + ## Import SDK + ```typescript -import * as PushAPI from "@pushprotocol/restapi"; +import * as PushAPI from '@pushprotocol/restapi'; ``` ## **About generating the "signer" object for different platforms** -### When using in SERVER-SIDE code: +### When using in SERVER-SIDE code: + ```typescript const ethers = require('ethers'); const PK = 'your_channel_address_secret_key'; const Pkey = `0x${PK}`; const _signer = new ethers.Wallet(Pkey); ``` -### When using in FRONT-END code: + +### When using in FRONT-END code: + ```typescript // any other web3 ui lib is also acceptable import { useWeb3React } from "@web3-react/core"; @@ -118,24 +126,29 @@ const _signer = library.getSigner(account); ## **About blockchain agnostic address format** -In any of the below methods (unless explicitly stated otherwise) we accept either - -- [CAIP format](https://github.com/ChainAgnostic/CAIPs/blob/master/CAIPs/caip-10.md#test-cases): for any on chain addresses ***We strongly recommend using this address format***. [Learn more about the format and examples](https://docs.push.org/developers/concepts/web3-notifications). -(Example : `eip155:1:0xab16a96d359ec26a11e2c2b3d8f8b8942d5bfcdb`) +In any of the below methods (unless explicitly stated otherwise) we accept either - -- ETH address format: only for backwards compatibility. -(Example: `0xab16a96d359ec26a11e2c2b3d8f8b8942d5bfcdb`) - - ### Chat blockchain agnostic address format - **Note** - For chat related apis, the address is in the format: eip155:<address> instead of eip155:<chainId>:<address>, we call this format **Partial CAIP** +- [CAIP format](https://github.com/ChainAgnostic/CAIPs/blob/master/CAIPs/caip-10.md#test-cases): for any on chain addresses **_We strongly recommend using this address format_**. [Learn more about the format and examples](https://docs.push.org/developers/concepts/web3-notifications). + (Example : `eip155:1:0xab16a96d359ec26a11e2c2b3d8f8b8942d5bfcdb`) + +- ETH address format: only for backwards compatibility. + (Example: `0xab16a96d359ec26a11e2c2b3d8f8b8942d5bfcdb`) + +### Chat blockchain agnostic address format + +**Note** - For chat related apis, the address is in the format: eip155:<address> instead of eip155:<chainId>:<address>, we call this format **Partial CAIP** (Example : `eip155:0xab16a96d359ec26a11e2c2b3d8f8b8942d5bfcdb`) ## **About Push contract addresses** + ### Push core contract address + ``` ETH Mainnet - 0x66329Fdd4042928BfCAB60b179e1538D56eeeeeE ``` ### Push communicator contract address + ``` ETH Mainnet - 0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa ETH Goerli - 0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa @@ -148,13 +161,15 @@ Optimism Testnet - 0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa ``` # SDK Features + ## For Notification ### **Fetching user notifications** + ```typescript const notifications = await PushAPI.user.getFeeds({ user: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // user address in CAIP - env: 'staging' + env: 'staging', }); ``` @@ -167,10 +182,7 @@ const notifications = await PushAPI.user.getFeeds({ { cta: 'https://idle.finance/#/governance/proposals', title: 'New Proposal', - message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + - '\n' + - '[d:Proposal] : IIP-32: Add Euler staking PYT wrappers for AA tranche to IdleDAI\n' + - '[timestamp:1676570405.922][timestamp: 1676570405]', + message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + '\n' + '[d:Proposal] : IIP-32: Add Euler staking PYT wrappers for AA tranche to IdleDAI\n' + '[timestamp:1676570405.922][timestamp: 1676570405]', icon: 'https://gateway.ipfs.io/ipfs/bafybeidgjepmup44yqmghcmmzp5aohj6yemjuwal3hozowp2mnxmtdjv5u/bafkreieqw4su7yuqf5ycow4ajpzjyimfl4umnnoe5fz2mq7ukrmqnesk2y', url: 'https://idle.finance/', sid: '3401597', @@ -179,9 +191,9 @@ const notifications = await PushAPI.user.getFeeds({ blockchain: 'ETH_TEST_GOERLI', notification: { body: 'New Proposal On Idle Finance', - title: 'Idle Finance - New Proposal' + title: 'Idle Finance - New Proposal', }, - secret: '' + secret: '', }, { cta: '', @@ -194,7 +206,7 @@ const notifications = await PushAPI.user.getFeeds({ image: '', blockchain: 'ETH_TEST_GOERLI', notification: { body: 'hi socket', title: 'AKP Test Channel - ' }, - secret: '' + secret: '', }, { cta: '', @@ -207,7 +219,7 @@ const notifications = await PushAPI.user.getFeeds({ image: '', blockchain: 'ETH_TEST_GOERLI', notification: { body: 'hiii', title: 'AKP Test Channel - ' }, - secret: '' + secret: '', }, { cta: '', @@ -220,7 +232,7 @@ const notifications = await PushAPI.user.getFeeds({ image: '', blockchain: 'ETH_TEST_GOERLI', notification: { body: 'Hey -testing', title: 'Gnosis - ' }, - secret: '' + secret: '', }, { cta: '', @@ -233,15 +245,12 @@ const notifications = await PushAPI.user.getFeeds({ image: '', blockchain: 'ETH_TEST_GOERLI', notification: { body: 'Hey', title: 'Gnosis - ' }, - secret: '' + secret: '', }, { cta: 'https://idle.finance/#/governance/proposals', title: 'New Proposal', - message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + - '\n' + - '[d:Proposal] : IIP-31: Add AA Euler staking PYT wrappers to IdleUSDT, IdleUSDC and IdleWETH. Gauges rate to 0. Extend LM. \n' + - '[timestamp:1674583206.258][timestamp: 1674583206]', + message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + '\n' + '[d:Proposal] : IIP-31: Add AA Euler staking PYT wrappers to IdleUSDT, IdleUSDC and IdleWETH. Gauges rate to 0. Extend LM. \n' + '[timestamp:1674583206.258][timestamp: 1674583206]', icon: 'https://gateway.ipfs.io/ipfs/bafybeidgjepmup44yqmghcmmzp5aohj6yemjuwal3hozowp2mnxmtdjv5u/bafkreieqw4su7yuqf5ycow4ajpzjyimfl4umnnoe5fz2mq7ukrmqnesk2y', url: 'https://idle.finance/', sid: '1784234', @@ -250,9 +259,9 @@ const notifications = await PushAPI.user.getFeeds({ blockchain: 'ETH_TEST_GOERLI', notification: { body: 'New Proposal On Idle Finance', - title: 'Idle Finance - New Proposal' + title: 'Idle Finance - New Proposal', }, - secret: '' + secret: '', }, { cta: '', @@ -265,7 +274,7 @@ const notifications = await PushAPI.user.getFeeds({ image: '', blockchain: 'ETH_TEST_GOERLI', notification: { body: 'hi 2023', title: 'AKP Test Channel - ' }, - secret: '' + secret: '', }, { cta: '', @@ -278,16 +287,12 @@ const notifications = await PushAPI.user.getFeeds({ image: '', blockchain: 'ETH_TEST_GOERLI', notification: { body: 'hi', title: 'AKP Test Channel - ' }, - secret: '' + secret: '', }, { cta: 'https://idle.finance/#/governance/proposals', title: 'New Proposal', - message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + - '\n' + - '[d:Proposal] : IIP-30: Remove idleDAI wrapper for cpFOL-USDC (DAI) senior. Same for idleUSDC with cpWIN-USDC. Remove idleRAI, idleSUSD, idleTUSD and idleFEI from IdleController. Update voting delay in Governor \n' + - ' \n' + - '[timestamp:1672769747.911][timestamp: 1672769747]', + message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + '\n' + '[d:Proposal] : IIP-30: Remove idleDAI wrapper for cpFOL-USDC (DAI) senior. Same for idleUSDC with cpWIN-USDC. Remove idleRAI, idleSUSD, idleTUSD and idleFEI from IdleController. Update voting delay in Governor \n' + ' \n' + '[timestamp:1672769747.911][timestamp: 1672769747]', icon: 'https://gateway.ipfs.io/ipfs/bafybeidgjepmup44yqmghcmmzp5aohj6yemjuwal3hozowp2mnxmtdjv5u/bafkreieqw4su7yuqf5ycow4ajpzjyimfl4umnnoe5fz2mq7ukrmqnesk2y', url: 'https://idle.finance/', sid: '1080072', @@ -296,18 +301,14 @@ const notifications = await PushAPI.user.getFeeds({ blockchain: 'ETH_TEST_GOERLI', notification: { body: 'New Proposal On Idle Finance', - title: 'Idle Finance - New Proposal' + title: 'Idle Finance - New Proposal', }, - secret: '' + secret: '', }, { cta: 'https://idle.finance/#/governance/proposals', title: 'New Proposal', - message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + - '\n' + - '[d:Proposal] : IIP-29: Remove idleDAI wrapper for cpFOL-USDC (DAI) senior. Same for idleUSDC with cpWIN-USDC. Remove idleRAI, idleSUSD, idleTUSD and idleFEI from IdleController. Update voting delay in Governor \n' + - ' \n' + - '[timestamp:1671624005.155][timestamp: 1671624005]', + message: '[d:Proposer] : 0xe8eA8bAE250028a8709A3841E0Ae1a44820d677b\n' + '\n' + '[d:Proposal] : IIP-29: Remove idleDAI wrapper for cpFOL-USDC (DAI) senior. Same for idleUSDC with cpWIN-USDC. Remove idleRAI, idleSUSD, idleTUSD and idleFEI from IdleController. Update voting delay in Governor \n' + ' \n' + '[timestamp:1671624005.155][timestamp: 1671624005]', icon: 'https://gateway.ipfs.io/ipfs/bafybeidgjepmup44yqmghcmmzp5aohj6yemjuwal3hozowp2mnxmtdjv5u/bafkreieqw4su7yuqf5ycow4ajpzjyimfl4umnnoe5fz2mq7ukrmqnesk2y', url: 'https://idle.finance/', sid: '935285', @@ -316,34 +317,36 @@ const notifications = await PushAPI.user.getFeeds({ blockchain: 'ETH_TEST_GOERLI', notification: { body: 'New Proposal On Idle Finance', - title: 'Idle Finance - New Proposal' + title: 'Idle Finance - New Proposal', }, - secret: '' - } -] + secret: '', + }, +]; ``` + ------ +--- ### **Fetching user spam notifications** + ```typescript const spams = await PushAPI.user.getFeeds({ user: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // user address in CAIP spam: true, - env: 'staging' + env: 'staging', }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| user* | string | - | user account address (CAIP) | -| page | number | 1 | page index of the results | -| limit | number | 10 | number of items in 1 page | -| spam | boolean | false | if "true" it will fetch spam feeds | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| -| raw | boolean | false | if "true" the method will return unformatted raw API response| +| user_ | string | - | user account address (CAIP) | +| page | number | 1 | page index of the results | +| limit | number | 10 | number of items in 1 page | +| spam | boolean | false | if "true" it will fetch spam feeds | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| raw | boolean | false | if "true" the method will return unformatted raw API response|
Expected response (Fetching user spam notifications) @@ -513,85 +516,56 @@ PushAPI.user.getFeeds [Spam] | Response - 200 OK } ] ``` +
------ +--- ### **Fetching user subscriptions** + ```typescript const subscriptions = await PushAPI.user.getSubscriptions({ user: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // user address in CAIP - env: 'staging' + env: 'staging', }); ``` where `subscriptions` is a list of channels `[{ channel: '0xaddress', ... }]` subscribed by the user. -*Note: We can find out if a user is subscribed to a channel by checking if the channel address is present in the subscriptions list* +_Note: We can find out if a user is subscribed to a channel by checking if the channel address is present in the subscriptions list_ -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| user* | string | - | user address (CAIP) | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - +| user_ | string | - | user address (CAIP) | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (Fetching user opted in channels / subscriptions) ```typescript // PushAPI.user.getSubscriptions | Response - 200 OK -[ - { channel: '0x0000000000000000000000000000000000000000' }, - { channel: '0xa3B6712fB922cdbbdce9AB22571e75d0d81B3b00' }, - { channel: '0xde3aEA26fDC3ADdC1dB32baf1a058Cf0878FEac1' }, - { channel: '0x69e666767Ba3a661369e1e2F572EdE7ADC926029' }, - { channel: '0x466AEEf0943C5F098dBcEf3c1eEC03322E1F97eD' }, - { channel: '0xcE98113b998380729B04596e3eA0255fbA138D34' }, - { channel: '0xa89523351BE1e2De64937AA9AF61Ae06eAd199C7' }, - { channel: '0x0a651cF7A9b60082fecdb5f30DB7914Fd7d2cf93' }, - { channel: '0x0b5E9fa12C4C1946fA2f14b7271cC60541508f23' }, - { channel: '0x2AEcb6DeE3652dA1dD6b54D5fd4f7D8F43DaEb78' }, - { channel: '0xcB6C7b2E340D50701d45d55507f19A5cE5d72330' }, - { channel: '0xB59Cdc85Cacd15097ecE4C77ed9D225014b4D56D' }, - { channel: '0xA5E269eec042Bf61183DEf9911D03359597494b7' }, - { channel: '0x6bf1ee9DE5D11Fa558c1FA8D8855E26C38Fa582A' }, - { channel: '0x72Ac64A3aE0ab60D725980b73Ef460ED9e742cc7' }, - { channel: '0xEc6CbD318CB7BA8a0fBbffF697681C0a4ADA0349' }, - { channel: '0xAb9415961F58eBD6d79029bC76F261Fa65a80D3D' }, - { channel: '0x08D77bD7500a07d791dD1323919C22e1FDb72224' }, - { channel: '0xa1016081D6Da53b4246178eD83922C55F7171e54' }, - { channel: '0x6A06014AC6BdE2906D194e63ec3b1B5B4c9C2Abb' }, - { channel: '0xf69389475E082f4BeFDb9dee4a1E9fe6cd29f6e7' }, - { channel: '0x9601f08b9EcB981D273B72e7f33964Cb98f977fe' }, - { channel: '0x47A2910432016CA9f62B20dCE09b89d357d0c3d7' }, - { channel: '0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' }, - { channel: '0x14c0157f9eEA7AEe61ba2606E75716E210b4697a' }, - { channel: '0x025846389950A13292E63e4794C7D148FF57F995' }, - { channel: '0x2aecb6dee3652da1dd6b54d5fd4f7d8f43daeb77' }, - { channel: '0xD8634C39BBFd4033c0d3289C4515275102423681' }, - { channel: '0x19fB80f16EAFCfb5BBFa07451CC5694E8932EA52' }, - { channel: '0x94c3016ef3e503774630fC71F59B8Da9f7D470B7' } -] +[{ channel: '0x0000000000000000000000000000000000000000' }, { channel: '0xa3B6712fB922cdbbdce9AB22571e75d0d81B3b00' }, { channel: '0xde3aEA26fDC3ADdC1dB32baf1a058Cf0878FEac1' }, { channel: '0x69e666767Ba3a661369e1e2F572EdE7ADC926029' }, { channel: '0x466AEEf0943C5F098dBcEf3c1eEC03322E1F97eD' }, { channel: '0xcE98113b998380729B04596e3eA0255fbA138D34' }, { channel: '0xa89523351BE1e2De64937AA9AF61Ae06eAd199C7' }, { channel: '0x0a651cF7A9b60082fecdb5f30DB7914Fd7d2cf93' }, { channel: '0x0b5E9fa12C4C1946fA2f14b7271cC60541508f23' }, { channel: '0x2AEcb6DeE3652dA1dD6b54D5fd4f7D8F43DaEb78' }, { channel: '0xcB6C7b2E340D50701d45d55507f19A5cE5d72330' }, { channel: '0xB59Cdc85Cacd15097ecE4C77ed9D225014b4D56D' }, { channel: '0xA5E269eec042Bf61183DEf9911D03359597494b7' }, { channel: '0x6bf1ee9DE5D11Fa558c1FA8D8855E26C38Fa582A' }, { channel: '0x72Ac64A3aE0ab60D725980b73Ef460ED9e742cc7' }, { channel: '0xEc6CbD318CB7BA8a0fBbffF697681C0a4ADA0349' }, { channel: '0xAb9415961F58eBD6d79029bC76F261Fa65a80D3D' }, { channel: '0x08D77bD7500a07d791dD1323919C22e1FDb72224' }, { channel: '0xa1016081D6Da53b4246178eD83922C55F7171e54' }, { channel: '0x6A06014AC6BdE2906D194e63ec3b1B5B4c9C2Abb' }, { channel: '0xf69389475E082f4BeFDb9dee4a1E9fe6cd29f6e7' }, { channel: '0x9601f08b9EcB981D273B72e7f33964Cb98f977fe' }, { channel: '0x47A2910432016CA9f62B20dCE09b89d357d0c3d7' }, { channel: '0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' }, { channel: '0x14c0157f9eEA7AEe61ba2606E75716E210b4697a' }, { channel: '0x025846389950A13292E63e4794C7D148FF57F995' }, { channel: '0x2aecb6dee3652da1dd6b54d5fd4f7d8f43daeb77' }, { channel: '0xD8634C39BBFd4033c0d3289C4515275102423681' }, { channel: '0x19fB80f16EAFCfb5BBFa07451CC5694E8932EA52' }, { channel: '0x94c3016ef3e503774630fC71F59B8Da9f7D470B7' }]; ``` +
------ +--- ### **Fetching channel details** + ```typescript const channelData = await PushAPI.channels.getChannel({ channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // channel address in CAIP - env: 'staging' + env: 'staging', }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| channel* | string | - | channel address (CAIP) | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - +| channel_ | string | - | channel address (CAIP) | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (Fetching channel details) @@ -620,28 +594,29 @@ Allowed Options (params with * are mandatory) subgraph_details: null } ``` +
------ +--- ### **Searching for channel(s)** + ```typescript const channelsData = await PushAPI.channels.search({ query: 'push', // a search query page: 1, // page index limit: 20, // no of items per page - env: 'staging' + env: 'staging', }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| query* | string | - | search query | -| page | number | 1 | page index of the results | -| limit | number | 10 | number of items in 1 page | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - +| query_ | string | - | search query | +| page | number | 1 | page index of the results | +| limit | number | 10 | number of items in 1 page | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (Searching for channel) @@ -669,7 +644,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 756 + subscriber_count: 756, }, { id: 817, @@ -691,7 +666,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 57 + subscriber_count: 57, }, { id: 243, @@ -713,7 +688,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 9 + subscriber_count: 9, }, { id: 923, @@ -735,7 +710,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 9 + subscriber_count: 9, }, { id: 274, @@ -757,7 +732,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 5 + subscriber_count: 5, }, { id: 1242, @@ -779,7 +754,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 5 + subscriber_count: 5, }, { id: 210, @@ -801,7 +776,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 4 + subscriber_count: 4, }, { id: 809, @@ -823,7 +798,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: 18, subgraph_details: '60+aiswaryawalter/push-graph-test', - subscriber_count: 4 + subscriber_count: 4, }, { id: 956, @@ -845,7 +820,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 4 + subscriber_count: 4, }, { id: 967, @@ -867,7 +842,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: 18, subgraph_details: '60+aiswaryawalter/push-graph-test', - subscriber_count: 4 + subscriber_count: 4, }, { id: 1425, @@ -889,7 +864,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 4 + subscriber_count: 4, }, { id: 1659, @@ -911,7 +886,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 4 + subscriber_count: 4, }, { id: 287, @@ -933,7 +908,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 369, @@ -955,7 +930,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 445, @@ -977,7 +952,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 735, @@ -999,7 +974,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 737, @@ -1021,7 +996,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 929, @@ -1043,7 +1018,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 1039, @@ -1065,7 +1040,7 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 + subscriber_count: 3, }, { id: 1241, @@ -1087,41 +1062,42 @@ Allowed Options (params with * are mandatory) blocked: 0, counter: null, subgraph_details: null, - subscriber_count: 3 - } -] + subscriber_count: 3, + }, +]; ``` -
------ + +--- ### **Opt in to a channel** + ```typescript await PushAPI.channels.subscribe({ signer: _signer, channelAddress: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // channel address in CAIP userAddress: 'eip155:5:0x52f856A160733A860ae7DC98DC71061bE33A28b3', // user address in CAIP onSuccess: () => { - console.log('opt in success'); + console.log('opt in success'); }, onError: () => { console.error('opt in error'); }, - env: 'staging' -}) + env: 'staging', +}); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| signer* | - | - | Signer object | -| channelAddress* | string | - | channel address (CAIP) | -| userAddress* | string | - | user address (CAIP) | | -| verifyingContractAddress | string | - | Push communicator contract address| -| onSuccess | function | - | on success callback | -| onError | function | - | on error callback | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| signer_ | - | - | Signer object | +| channelAddress* | string | - | channel address (CAIP) | +| userAddress* | string | - | user address (CAIP) | | +| verifyingContractAddress | string | - | Push communicator contract address| +| onSuccess | function | - | on success callback | +| onError | function | - | on error callback | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (Opt in to channel) @@ -1131,35 +1107,38 @@ Allowed Options (params with * are mandatory) { status: 'success', message: 'successfully opted into channel' } ``` +
------ +--- ### **Opt out to a channel** + ```typescript await PushAPI.channels.unsubscribe({ signer: _signer, channelAddress: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // channel address in CAIP userAddress: 'eip155:5:0x52f856A160733A860ae7DC98DC71061bE33A28b3', // user address in CAIP onSuccess: () => { - console.log('opt out success'); + console.log('opt out success'); }, onError: () => { console.error('opt out error'); }, - env: 'staging' -}) + env: 'staging', +}); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| signer* | - | - | Signer object | -| channelAddress* | string | - | channel address (CAIP) | -| userAddress* | string | - | user address (CAIP) | | -| verifyingContractAddress | string | - | Push communicator contract address| -| onSuccess | function | - | on success callback | -| onError | function | - | on error callback | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| signer_ | - | - | Signer object | +| channelAddress* | string | - | channel address (CAIP) | +| userAddress* | string | - | user address (CAIP) | | +| verifyingContractAddress | string | - | Push communicator contract address| +| onSuccess | function | - | on success callback | +| onError | function | - | on error callback | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (Opt out of a channel) @@ -1168,9 +1147,10 @@ Allowed Options (params with * are mandatory) // PushAPI.channels.unsubscribe | Response - 200 OK { status: 'success', message: 'successfully opted out channel' } ``` +
------ +--- ### **Sending notification** @@ -1205,34 +1185,35 @@ async function sendNotification(options: { env?: ENV; chatId?: string; pgpPrivateKey?: string; -}) +}); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| senderType* | number | 0 | 0 for channel notification. 1 for chat notification | -| signer* | - | - | Signer object | -| channel* | string | - | channel address (CAIP) | -| type* | number | - | Notification Type
Target = 3 (send to 1 address),
Subset = 4 (send to 1 or more addresses),
Broadcast = 1 (send to all addresses) | -| identityType* | number | - | Identity Type
Minimal = 0,
IPFS = 1,
Direct Payload = 2,
Subgraph = 3 } | -| recipients* | string or string[] | - | for Notification Type = Target it is 1 address,
for Notification Type = Subset, Broadcast it is an array of addresses (CAIP) | -| notification.title* | string | - | Push Notification Title (not required for identityType IPFS, Subgraph)| -| notification.body* | string | - | Push Notification Body (not required for identityType IPFS, Subgraph)| -| payload.title | string | - | Notification Title (not required for identityType IPFS, Subgraph)| -| payload.body | string | - | Notification Body (not required for identityType IPFS, Subgraph)| -| payload.cta | string | - | Notification Call To Action url (not required for identityType IPFS, Subgraph)| -| payload.img | string | - | Notification Media url (not required for identityType IPFS, Subgraph)| -| payload.sectype | string | - | If Secret Notification then pass (not required for identityType IPFS, Subgraph)| -| graph.id | string | - | graph id, required only if the identityType is 3 | -| graph.counter | string | - | graph counter, required only if the identityType is 3 | -| ipfsHash | string | - | ipfsHash, required only if the identityType is 1 | -| expiry | number | - | (optional) epoch value if the notification has an expiry | -| hidden | boolean | false | (optional) true if we want to hide the notification | -| pgpPrivateKey | string | - | (optional) pgp private key for new notification verification proof | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| senderType_ | number | 0 | 0 for channel notification. 1 for chat notification | +| signer* | - | - | Signer object | +| channel* | string | - | channel address (CAIP) | +| type* | number | - | Notification Type
Target = 3 (send to 1 address),
Subset = 4 (send to 1 or more addresses),
Broadcast = 1 (send to all addresses) | +| identityType* | number | - | Identity Type
Minimal = 0,
IPFS = 1,
Direct Payload = 2,
Subgraph = 3 } | +| recipients* | string or string[] | - | for Notification Type = Target it is 1 address,
for Notification Type = Subset, Broadcast it is an array of addresses (CAIP) | +| notification.title* | string | - | Push Notification Title (not required for identityType IPFS, Subgraph)| +| notification.body\* | string | - | Push Notification Body (not required for identityType IPFS, Subgraph)| +| payload.title | string | - | Notification Title (not required for identityType IPFS, Subgraph)| +| payload.body | string | - | Notification Body (not required for identityType IPFS, Subgraph)| +| payload.cta | string | - | Notification Call To Action url (not required for identityType IPFS, Subgraph)| +| payload.img | string | - | Notification Media url (not required for identityType IPFS, Subgraph)| +| payload.sectype | string | - | If Secret Notification then pass (not required for identityType IPFS, Subgraph)| +| graph.id | string | - | graph id, required only if the identityType is 3 | +| graph.counter | string | - | graph counter, required only if the identityType is 3 | +| ipfsHash | string | - | ipfsHash, required only if the identityType is 1 | +| expiry | number | - | (optional) epoch value if the notification has an expiry | +| hidden | boolean | false | (optional) true if we want to hide the notification | +| pgpPrivateKey | string | - | (optional) pgp private key for new notification verification proof | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| #### **Direct payload for single recipient(target)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1241,21 +1222,22 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.DIRECT_PAYLOAD, // direct payload notification: { title: `[SDK-TEST] notification TITLE:`, - body: `[sdk-test] notification BODY` + body: `[sdk-test] notification BODY`, }, payload: { title: `[sdk-test] payload title`, body: `sample msg body`, cta: '', - img: '' + img: '', }, recipients: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // recipient address channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` - + #### **Direct payload for group of recipients(subset)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1264,21 +1246,22 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: 2, // direct payload notification: { title: `[SDK-TEST] notification TITLE:`, - body: `[sdk-test] notification BODY` + body: `[sdk-test] notification BODY`, }, payload: { title: `[sdk-test] payload title`, body: `sample msg body`, cta: '', - img: '' + img: '', }, recipients: ['eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', 'eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1'], // recipients addresses channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Direct payload for all recipients(broadcast)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1287,20 +1270,21 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.DIRECT_PAYLOAD, // direct payload notification: { title: `[SDK-TEST] notification TITLE:`, - body: `[sdk-test] notification BODY` + body: `[sdk-test] notification BODY`, }, payload: { title: `[sdk-test] payload title`, body: `sample msg body`, cta: '', - img: '' + img: '', }, channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **IPFS payload for single recipient(target)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1310,11 +1294,12 @@ const apiResponse = await PushAPI.payloads.sendNotification({ ipfsHash: 'bafkreicuttr5gpbyzyn6cyapxctlr7dk2g6fnydqxy6lps424mcjcn73we', // IPFS hash of the payload recipients: 'eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1', // recipient address channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **IPFS payload for group of recipients(subset)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1324,11 +1309,12 @@ const apiResponse = await PushAPI.payloads.sendNotification({ ipfsHash: 'bafkreicuttr5gpbyzyn6cyapxctlr7dk2g6fnydqxy6lps424mcjcn73we', // IPFS hash of the payload recipients: ['eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1', 'eip155:5:0x52f856A160733A860ae7DC98DC71061bE33A28b3'], // recipients addresses channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **IPFS payload for all recipients(broadcast)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1337,11 +1323,12 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.DIRECT_PAYLOAD, // direct payload ipfsHash: 'bafkreicuttr5gpbyzyn6cyapxctlr7dk2g6fnydqxy6lps424mcjcn73we', // IPFS hash of the payload channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Minimal payload for single recipient(target)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1350,21 +1337,22 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.MINIMAL, // Minimal payload notification: { title: `[SDK-TEST] notification TITLE:`, - body: `[sdk-test] notification BODY` + body: `[sdk-test] notification BODY`, }, payload: { title: `[sdk-test] payload title`, body: `sample msg body`, cta: '', - img: '' + img: '', }, recipients: 'eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1', // recipient address channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Minimal payload for a group of recipient(subset)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1373,21 +1361,22 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.MINIMAL, // Minimal payload notification: { title: `[SDK-TEST] notification TITLE:`, - body: `[sdk-test] notification BODY` + body: `[sdk-test] notification BODY`, }, payload: { title: `[sdk-test] payload title`, body: `sample msg body`, cta: '', - img: '' + img: '', }, recipients: ['eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1', 'eip155:5:0x52f856A160733A860ae7DC98DC71061bE33A28b3'], // recipients address channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Minimal payload for all recipients(broadcast)** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1396,21 +1385,23 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.MINIMAL, // Minimal payload notification: { title: `[SDK-TEST] notification TITLE:`, - body: `[sdk-test] notification BODY` + body: `[sdk-test] notification BODY`, }, payload: { title: `[sdk-test] payload title`, body: `sample msg body`, cta: '', - img: '' + img: '', }, channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Graph payload for single recipient(target)** -***Make sure the channel has the graph id you are providing!!*** + +**_Make sure the channel has the graph id you are providing!!_** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1419,16 +1410,18 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.SUBGRAPH, // Subgraph payload graph: { id: '_your_graph_id', - counter: 3 + counter: 3, }, recipients: 'eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1', // recipient address channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Graph payload for group of recipients(subset)** -***Make sure the channel has the graph id you are providing!!*** + +**_Make sure the channel has the graph id you are providing!!_** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1437,16 +1430,18 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.SUBGRAPH, // graph payload graph: { id: '_your_graph_id', - counter: 3 + counter: 3, }, recipients: ['eip155:5:0xCdBE6D076e05c5875D90fa35cc85694E1EAFBBd1', 'eip155:5:0x52f856A160733A860ae7DC98DC71061bE33A28b3'], // recipients addresses channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` #### **Graph payload for all recipients(broadcast)** -***Make sure the channel has the graph id you are providing!!*** + +**_Make sure the channel has the graph id you are providing!!_** + ```typescript // apiResponse?.status === 204, if sent successfully! const apiResponse = await PushAPI.payloads.sendNotification({ @@ -1455,34 +1450,36 @@ const apiResponse = await PushAPI.payloads.sendNotification({ identityType: PushAPI.payloads.IDENTITY_TYPE.SUBGRAPH, // graph payload graph: { id: '_your_graph_id', - counter: 3 + counter: 3, }, channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // your channel address - env: 'staging' + env: 'staging', }); ``` -
Expected response (Send Notification) ```typescript // PushAPI.payloads.sendNotification | Response - 204 OK ``` -
------ + +--- ### Notification Helper Utils + #### **Parsing notifications** + Utils method to parse raw Push Feeds API response into a pre-defined shape as below. + ```typescript // fetch some raw feeds data const apiResponse = await PushAPI.user.getFeeds({ user: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // user address raw: true, - env: 'staging' + env: 'staging', }); // parse it to get a specific shape of object. const parsedResults = PushAPI.utils.parseApiResponse(apiResponse); @@ -1491,28 +1488,19 @@ const [oneNotification] = parsedResults; // Now this object can be directly used by for e.g. "@pushprotocol/uiweb" NotificationItem component as props. -const { - cta, - title, - message, - app, - icon, - image, - url, - blockchain, - secret, - notification -} = oneNotification; - +const { cta, title, message, app, icon, image, url, blockchain, secret, notification } = oneNotification; ``` -*We get the above `keys` after the parsing of the API repsonse.* ------ +_We get the above `keys` after the parsing of the API repsonse._ + +--- ### Advanced Notifications (WIP) ### DEPRECATED + #### **Get a channel's subscriber list of addresses** + ```typescript const subscribers = await PushAPI.channels.getSubscribers({ channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', // channel address in CAIP @@ -1522,11 +1510,11 @@ const subscribers = await PushAPI.channels.getSubscribers({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| channel* | string | - | channel address (CAIP) | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| channel_ | string | - | channel address (CAIP) | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
DEPRECATED - Expected response (Get channel's subscribers list) @@ -1637,11 +1625,13 @@ Allowed Options (params with * are mandatory) ... 656 more items ] ``` +
------ +--- ## For Chat + ### **Create user for chat** ```typescript @@ -1660,7 +1650,7 @@ const user = await PushAPI.user.create({ ``` | Param | Remarks | -|----------------|---------------------------------------------------------------| +| -------------- | ------------------------------------------------------------- | | env | API env - 'prod', 'staging', 'dev' | | account | Account address | | signer | ethers.js signer | @@ -1680,12 +1670,12 @@ const user = await PushAPI.user.create({ Example creating NFT user for chat: ```typescript - const user = await PushAPI.user.create({ - account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, - signer: nftSigner, // ethers.js signer - env: env as ENV, - additionalMeta: { NFTPGP_V1: { password: '@Test0i1223de' } }, - }); +const user = await PushAPI.user.create({ + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + signer: nftSigner, // ethers.js signer + env: env as ENV, + additionalMeta: { NFTPGP_V1: { password: '@Test0i1223de' } }, +}); ```
@@ -1714,26 +1704,27 @@ export interface IUser { } ``` -| Parameter | Description | -| --- | --- | -| `did` | user decentralized identity | -| `wallets` | all wallets associated to the did | -| `profilePicture` | user chat profile picture. As of now i cannot be changed | -| `publicKey` | PGP public key | -| `encryptedPrivateKey` | encrypted private PGP key | -| `encryptionType` | encryption type used to encrypt the private key | -| `signature` | user payload signature used when creating a user | -| `sigType` | signature type used when creating a user | -| `about` | short user description | -| `name` | user name | -| `encryptedPassword` | encrypted password used to encrypt the private key for NFT chat | -| `nftOwner` | NFT owner address | -| `numMsg` | number of messages sent by the user | -| `allowedNumMsg` | number of messages allowed to be sent by the user | -| `linkedListHash` | cid from all messages this user has sent | -| `nfts` | array of NFTs owned by the user | +| Parameter | Description | +| --------------------- | --------------------------------------------------------------- | +| `did` | user decentralized identity | +| `wallets` | all wallets associated to the did | +| `profilePicture` | user chat profile picture. As of now i cannot be changed | +| `publicKey` | PGP public key | +| `encryptedPrivateKey` | encrypted private PGP key | +| `encryptionType` | encryption type used to encrypt the private key | +| `signature` | user payload signature used when creating a user | +| `sigType` | signature type used when creating a user | +| `about` | short user description | +| `name` | user name | +| `encryptedPassword` | encrypted password used to encrypt the private key for NFT chat | +| `nftOwner` | NFT owner address | +| `numMsg` | number of messages sent by the user | +| `allowedNumMsg` | number of messages allowed to be sent by the user | +| `linkedListHash` | cid from all messages this user has sent | +| `nfts` | array of NFTs owned by the user | Example response normal user: + ```typescript // PushAPI_user_get | Response - 200 OK { @@ -1907,25 +1898,25 @@ export interface IUser { } ``` -| Parameter | Description | -| --- | --- | -| `msgSent` | number of messages sent by the user | -| `maxMsgPersisted` | number of messages allowed to be sent by the user | -| `did` | user decentralized identity | -| `wallets` | all wallets associated to the did | -| `name` | user name | -| `desc` | short user description | -| `profilePicture` | user chat profile picture. As of now i cannot be changed | -| `encryptedPrivateKey` | encrypted private PGP key | -| `publicKey` | PGP public key | -| `nftOwner` | NFT owner address | -| `verificationProof` | verification proof | +| Parameter | Description | +| --------------------- | -------------------------------------------------------- | +| `msgSent` | number of messages sent by the user | +| `maxMsgPersisted` | number of messages allowed to be sent by the user | +| `did` | user decentralized identity | +| `wallets` | all wallets associated to the did | +| `name` | user name | +| `desc` | short user description | +| `profilePicture` | user chat profile picture. As of now i cannot be changed | +| `encryptedPrivateKey` | encrypted private PGP key | +| `publicKey` | PGP public key | +| `verificationProof` | verification proof |
------ +--- ### **Get user data for chat** + ```typescript const user = await PushAPI.user.get({ env?: ENV; @@ -1933,10 +1924,10 @@ const user = await PushAPI.user.get({ }); ``` -| Param | Remarks | -|----------|---------| -| account | Account address | -| env | API env - 'prod', 'staging', 'dev'| +| Param | Remarks | +| ------- | ---------------------------------- | +| account | Account address | +| env | API env - 'prod', 'staging', 'dev' | Example request get normal user data: @@ -1982,24 +1973,24 @@ export interface IUser { } ``` -| Parameter | Description | -| --- | --- | -| `did` | user decentralized identity | -| `wallets` | all wallets associated to the did | -| `profilePicture` | user chat profile picture. As of now i cannot be changed | -| `publicKey` | PGP public key | -| `encryptedPrivateKey` | encrypted private PGP key | -| `encryptionType` | encryption type used to encrypt the private key | -| `signature` | user payload signature used when creating a user | -| `sigType` | signature type used when creating a user | -| `about` | short user description | -| `name` | user name | -| `encryptedPassword` | encrypted password used to encrypt the private key for NFT chat | -| `nftOwner` | NFT owner address | -| `numMsg` | number of messages sent by the user | -| `allowedNumMsg` | number of messages allowed to be sent by the user | -| `linkedListHash` | cid from all messages this user has sent | -| `nfts` | array of NFTs owned by the user | +| Parameter | Description | +| --------------------- | --------------------------------------------------------------- | +| `did` | user decentralized identity | +| `wallets` | all wallets associated to the did | +| `profilePicture` | user chat profile picture. As of now i cannot be changed | +| `publicKey` | PGP public key | +| `encryptedPrivateKey` | encrypted private PGP key | +| `encryptionType` | encryption type used to encrypt the private key | +| `signature` | user payload signature used when creating a user | +| `sigType` | signature type used when creating a user | +| `about` | short user description | +| `name` | user name | +| `encryptedPassword` | encrypted password used to encrypt the private key for NFT chat | +| `nftOwner` | NFT owner address | +| `numMsg` | number of messages sent by the user | +| `allowedNumMsg` | number of messages allowed to be sent by the user | +| `linkedListHash` | cid from all messages this user has sent | +| `nfts` | array of NFTs owned by the user | Example response normal user: @@ -2176,24 +2167,23 @@ export interface IUser { } ``` -| Parameter | Description | -| --- | --- | -| `msgSent` | number of messages sent by the user | -| `maxMsgPersisted` | number of messages allowed to be sent by the user | -| `did` | user decentralized identity | -| `wallets` | all wallets associated to the did | -| `name` | user name | -| `desc` | short user description | -| `profilePicture` | user chat profile picture. As of now i cannot be changed | -| `encryptedPrivateKey` | encrypted private PGP key | -| `publicKey` | PGP public key | -| `nftOwner` | NFT owner address | -| `verificationProof` | verification proof | +| Parameter | Description | +| --------------------- | -------------------------------------------------------- | +| `msgSent` | number of messages sent by the user | +| `maxMsgPersisted` | number of messages allowed to be sent by the user | +| `did` | user decentralized identity | +| `wallets` | all wallets associated to the did | +| `name` | user name | +| `desc` | short user description | +| `picture` | user chat profile picture. As of now i cannot be changed | +| `encryptedPrivateKey` | encrypted private PGP key | +| `publicKey` | PGP public key | +| `verificationProof` | verification proof | ------ - +--- + ### **Decrypting encrypted pgp private key from user data** ```typescript @@ -2201,22 +2191,22 @@ const response = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: string; account?: string; signer?: SignerType; - additionalMeta?: { password?: string }; + additionalMeta?: { password?: string }; env?: ENV; toUpgrade?: boolean; progressHook?: (progress: ProgressHookType) => void; }) ``` -| Parameter | Type | Description | -| --- | --- | --- | -| `encryptedPGPPrivateKey` | `string` | encrypted pgp private key | -| `account` | `string` | user account | -| `signer` | `SignerType` | ethers.js signer | -| `additionalMeta` | `{ password?: string }` | additional meta data | -| `env` | `ENV` | environment | -| `toUpgrade` | `boolean` | if true, the user will be upgraded to the latest version | -| `progressHook` | `(progress: ProgressHookType) => void` | progress hook | +| Parameter | Type | Description | +| ------------------------ | -------------------------------------- | -------------------------------------------------------- | +| `encryptedPGPPrivateKey` | `string` | encrypted pgp private key | +| `account` | `string` | user account | +| `signer` | `SignerType` | ethers.js signer | +| `additionalMeta` | `{ password?: string }` | additional meta data | +| `env` | `ENV` | environment | +| `toUpgrade` | `boolean` | if true, the user will be upgraded to the latest version | +| `progressHook` | `(progress: ProgressHookType) => void` | progress hook | **Example request for normal user:** @@ -2224,13 +2214,13 @@ const response = await PushAPI.chat.decryptPGPKey({ const user = await PushAPI.user.get({ account: `eip155:${signer.address}`, env: ENV.STAGING, -}) +}); // decrypt the PGP Key const pgpKey = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: signer, -}) +}); ``` **Example request for NFT user:** @@ -2238,14 +2228,14 @@ const pgpKey = await PushAPI.chat.decryptPGPKey({ ```typescript // get user and derive encrypted PGP key const user = await PushAPI.user.get({ - account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, env: env as ENV, }); // decrypt the PGP Key const pgpKey = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, - account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, + account: `nft:eip155:${nftChainId}:${nftContractAddress}:${nftTokenId}`, signer: nftSigner, }); ``` @@ -2286,9 +2276,10 @@ n4FxJNoL/lmuCqhQm4Zgduj3GdYUunMDID3k54J1FPGN+iCj =OX08 -----END PGP PRIVATE KEY BLOCK----- ``` + ------ +--- ### **Fetching list of user chats** @@ -2307,12 +2298,12 @@ const chats = await PushAPI.chat.chats({ }); ``` -| Param | Type | Default | Remarks | -|----------|---------|---------|--------------------------------------------| -| account | string | - | user address (Partial CAIP) | -| toDecrypt | boolean | false | if "true" the method will return decrypted message content in response| -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| Param | Type | Default | Remarks | +| ------------- | ------- | ------- | ---------------------------------------------------------------------- | +| account | string | - | user address (Partial CAIP) | +| toDecrypt | boolean | false | if "true" the method will return decrypted message content in response | +| pgpPrivateKey | string | null | mandatory for users having pgp keys | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev' | **Example normal user:** @@ -2323,10 +2314,10 @@ const user = await PushAPI.user.get({ account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: ENV.STAGING, }) - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: signer); - + // actual api const chats = await PushAPI.chat.chats({ account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', @@ -2360,7 +2351,6 @@ const response = await PushAPI.chat.chats({ }); ``` -
Expected response (Get chats of a specific user) @@ -2388,66 +2378,39 @@ const response = await PushAPI.chat.chats({ toDID: 'eip155:0x1C48fE875590f8e366447758b13982a3Ca7d9dBE', messageContent: "Gm gm! It's me... Mario", messageType: 'Text', - signature: '-----BEGIN PGP SIGNATURE-----\n' + - '\n' + - 'wsBzBAEBCAAnBYJkWKQWCZB7dzg7q3axjBYhBJFuYslzDGbuE+3FMnt3ODur\n' + - 'drGMAAAjtAf/TXjtm2qb6aSikFPKYXm0Ekws+65fisJGf7T48MYkkfcD4t2e\n' + - 'HXd9LtohzGhcztbOQfAND3yME1GWuMBIksq9rlyEA0ezwsGzCJVhBnkAHBe3\n' + - '+1v4/mNSMmInU8y6sOiLiOcW7ameJvZvDdPDJ0YHhc9dKDCIh1UAZEPAgx+z\n' + - 'Wc0DM6pW8bT70dfgnuW2LlLGF5Z23Z1vbHmeszt78+xYY3ez/hoMHXUIE25z\n' + - 'Wrnt75nasBBahtJ0mwH10ATnsQNE9hTi6XPGYxRSNDM9nyRxTQUpjhNmGS/+\n' + - '7oFyq8xTcRSaL7d3h8URp9hgFWher5ZZDyMV0jvk+HPguUX54g6Kgw==\n' + - '=dcRD\n' + - '-----END PGP SIGNATURE-----\n', + signature: '-----BEGIN PGP SIGNATURE-----\n' + '\n' + 'wsBzBAEBCAAnBYJkWKQWCZB7dzg7q3axjBYhBJFuYslzDGbuE+3FMnt3ODur\n' + 'drGMAAAjtAf/TXjtm2qb6aSikFPKYXm0Ekws+65fisJGf7T48MYkkfcD4t2e\n' + 'HXd9LtohzGhcztbOQfAND3yME1GWuMBIksq9rlyEA0ezwsGzCJVhBnkAHBe3\n' + '+1v4/mNSMmInU8y6sOiLiOcW7ameJvZvDdPDJ0YHhc9dKDCIh1UAZEPAgx+z\n' + 'Wc0DM6pW8bT70dfgnuW2LlLGF5Z23Z1vbHmeszt78+xYY3ez/hoMHXUIE25z\n' + 'Wrnt75nasBBahtJ0mwH10ATnsQNE9hTi6XPGYxRSNDM9nyRxTQUpjhNmGS/+\n' + '7oFyq8xTcRSaL7d3h8URp9hgFWher5ZZDyMV0jvk+HPguUX54g6Kgw==\n' + '=dcRD\n' + '-----END PGP SIGNATURE-----\n', timestamp: 1683530775648, sigType: 'pgp', encType: 'pgp', - encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + - '\n' + - 'wcBMA9aU+JGZVRn/AQgA1pIJHyeJinU21r6At5S5ZaWeN0OEKVB2TjpqZ0IW\n' + - 'lHLKQrQ8k3M16bN+Vf0P+DzDVOL84QRkBD56qSNVHOOCox5wcQeR01CczenV\n' + - 'LUVvVjBzR2hj7Sdw+Q+M//rgeZPPUDbNyiVmGijelhwDqWd7IOoZY26AGXlm\n' + - '7YQiElvHN2HcYXaTlLAOy36BcccwHu3Tn06F77ZXaf8FnGMWOUy7wh1/jugg\n' + - 'D17jUZGLYbmw+u5l9BOfljbw2pb4vtjWht0I1b4GYlKb+bYg/NY0UNsq7mSh\n' + - 'dGAmOhy5tC2NMjLRRLfD2qasxHoHN50onlB6HcYLl0RCf31ebOgO6rMhUnxt\n' + - '9cHATAMLWLG2xubrYAEH/2tVeq2j7nJALGSFxjJPboOY57aiFrhXNQ/e/oXH\n' + - '//TNJgGWx4Ta++OuF2Oexbh9DIZhl6DWld9adXDDtBS/fEyjNsYqwoYlNEJN\n' + - 'kLvSmokNNrE4MKC1A0GkhSh2MGQDNk42GSgz1tep8XSVc98MHqfNXCHVb5Oa\n' + - 'OBeWKLFyElT3+KuZxSkCsnoO5YjuCGbXPyG06tXMHXMTncpj1ri+vpjUSnhD\n' + - 'wn3o0zpNWu0GaWXIgTqj2ZouVwV2S1+wAJQjE8uI1JvBiMhA+X63/GCcApBu\n' + - 'C7rN0Cs5NGXCn9VWp8i1SCp2NuZ38POABwsXUUkjpF24txyUDX8dbXlkzpao\n' + - 'g93SQAElYYmyKbGp1TKhAZl2u40mgf2yCYDv2DLRfAKMJDLvmjXoUGEg2UYO\n' + - '11w6LD0pIykdKJmFtRls/uMnlcoBgDA=\n' + - '=kzUH\n' + - '-----END PGP MESSAGE-----\n', - link: 'bafyreib34jgnpp573rwquejcq5avxvydis7fbykat6dd5z7uazobucoumm' + encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + '\n' + 'wcBMA9aU+JGZVRn/AQgA1pIJHyeJinU21r6At5S5ZaWeN0OEKVB2TjpqZ0IW\n' + 'lHLKQrQ8k3M16bN+Vf0P+DzDVOL84QRkBD56qSNVHOOCox5wcQeR01CczenV\n' + 'LUVvVjBzR2hj7Sdw+Q+M//rgeZPPUDbNyiVmGijelhwDqWd7IOoZY26AGXlm\n' + '7YQiElvHN2HcYXaTlLAOy36BcccwHu3Tn06F77ZXaf8FnGMWOUy7wh1/jugg\n' + 'D17jUZGLYbmw+u5l9BOfljbw2pb4vtjWht0I1b4GYlKb+bYg/NY0UNsq7mSh\n' + 'dGAmOhy5tC2NMjLRRLfD2qasxHoHN50onlB6HcYLl0RCf31ebOgO6rMhUnxt\n' + '9cHATAMLWLG2xubrYAEH/2tVeq2j7nJALGSFxjJPboOY57aiFrhXNQ/e/oXH\n' + '//TNJgGWx4Ta++OuF2Oexbh9DIZhl6DWld9adXDDtBS/fEyjNsYqwoYlNEJN\n' + 'kLvSmokNNrE4MKC1A0GkhSh2MGQDNk42GSgz1tep8XSVc98MHqfNXCHVb5Oa\n' + 'OBeWKLFyElT3+KuZxSkCsnoO5YjuCGbXPyG06tXMHXMTncpj1ri+vpjUSnhD\n' + 'wn3o0zpNWu0GaWXIgTqj2ZouVwV2S1+wAJQjE8uI1JvBiMhA+X63/GCcApBu\n' + 'C7rN0Cs5NGXCn9VWp8i1SCp2NuZ38POABwsXUUkjpF24txyUDX8dbXlkzpao\n' + 'g93SQAElYYmyKbGp1TKhAZl2u40mgf2yCYDv2DLRfAKMJDLvmjXoUGEg2UYO\n' + '11w6LD0pIykdKJmFtRls/uMnlcoBgDA=\n' + '=kzUH\n' + '-----END PGP MESSAGE-----\n', + link: 'bafyreib34jgnpp573rwquejcq5avxvydis7fbykat6dd5z7uazobucoumm', }, - groupInformation: undefined - } -] -``` - -| Parameter | Type | Description | -| --- | --- | --- | -| msg | `IMessageIPFS` | message object | -| did | `string` | user DID | -| wallets | `string` | user wallets | -| profilePicture | `string` | user profile picture | -| publicKey | `string` | user public key | -| about | `string` | user description | -| threadhash | `string` | cid from the latest message sent on this conversation | -| intent | `string` | addresses concatenated from the users who have approved the intent | -| intentSentBy | `string` | address of the user who sent the intent | -| intentTimestamp | `number` | timestamp of the intent | -| combinedDID | `string` | concatenated addresses of the members of this chat (for DM the 2 addresses and from Group the addresses from all group members) | -| cid | `string` | content identifier on IPFS | -| chatId | `string` | chat identifier | -| groupInformation | `GroupDTO` | if group chat, all group information | + groupInformation: undefined, + }, +]; +``` + +| Parameter | Type | Description | +| ---------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------- | +| msg | `IMessageIPFS` | message object | +| did | `string` | user DID | +| wallets | `string` | user wallets | +| profilePicture | `string` | user profile picture | +| publicKey | `string` | user public key | +| about | `string` | user description | +| threadhash | `string` | cid from the latest message sent on this conversation | +| intent | `string` | addresses concatenated from the users who have approved the intent | +| intentSentBy | `string` | address of the user who sent the intent | +| intentTimestamp | `number` | timestamp of the intent | +| combinedDID | `string` | concatenated addresses of the members of this chat (for DM the 2 addresses and from Group the addresses from all group members) | +| cid | `string` | content identifier on IPFS | +| chatId | `string` | chat identifier | +| groupInformation | `GroupDTO` | if group chat, all group information |
------ - +--- + ### **Fetching list of user chat requests** ```typescript @@ -2465,12 +2428,12 @@ const chats = await PushAPI.chat.requests({ }); ``` -| Param | Type | Default | Remarks | -|----------|---------|---------|--------------------------------------------| -| account | string | - | user address (Partial CAIP) | -| toDecrypt | boolean | false | if "true" the method will return decrypted message content in response| -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| Param | Type | Default | Remarks | +| ------------- | ------- | ------- | ---------------------------------------------------------------------- | +| account | string | - | user address (Partial CAIP) | +| toDecrypt | boolean | false | if "true" the method will return decrypted message content in response | +| pgpPrivateKey | string | null | mandatory for users having pgp keys | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev' | **Example:** @@ -2478,10 +2441,10 @@ const chats = await PushAPI.chat.requests({ // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: ENV.STAGING); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); - + // actual api const chats = await PushAPI.chat.requests({ account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', @@ -2504,37 +2467,7 @@ const chats = await PushAPI.chat.requests({ intent: 'eip155:0x69e666767Ba3a661369e1e2F572EdE7ADC926029', intentSentBy: 'eip155:0x69e666767Ba3a661369e1e2F572EdE7ADC926029', intentTimestamp: '2023-01-07T03:51:11.000Z', - publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + - '\n' + - 'xsBNBGOhhq8BCADP5Nzw0jOXhKO86ndGkY/JlD8AadVXmsLA+Yvoc22LrNTU\n' + - 'QrfcDWaMAzpmtMWJlNEHSTieUPEgODm/qj422+rdskSedum3gq1HWn2bmqEI\n' + - 'LrFc+zR3B70Pe7saEEmC/hXG53/8m7V0HsOuvkEjBa3pW3KElZIhimVvcgYR\n' + - '9AnLjUYKR/lci1eXXsAz+J+RjgPlFfiIE0/3KYXwkjt9meSJDPCIcEIZ1tqw\n' + - 'IkGRINM5XINMvC+FxPNQ+jIHF9WIzmUg4YfYZQbMo96j4LAV0kYvAB0qI2Y8\n' + - 'DHAjHXYQ+fafRGOJwePASjDHUjcB9QEr1EPIMG3i4iFaBV2ZmePjzE7XABEB\n' + - 'AAHNAMLAigQQAQgAPgUCY6GGrwQLCQcICRCUVlBnqYwnwgMVCAoEFgACAQIZ\n' + - 'AQIbAwIeARYhBPYJKSdUrZzVgB9jy5RWUGepjCfCAABLZAgAtVdxz75k3qFY\n' + - 'qtwMdsrIPX4A7rpT/zCd2Yjl2asFdlkyAusfNdFEiff1dHz5+qBM88z/Zh+O\n' + - '1FNDKS/WKL9qmZ+AceyidCjnRVTUeH6Mi/ZD/YZInJyLozCksb0Gciswl6Rp\n' + - 'RHb6nXt0PebUFXTsOVxSeodaEGBgltd/V1bDHpfx8Wu03z3h/Jq2tI4s28XA\n' + - 'S2lSZpG8+nC1zLOmpbYx8mdOe00ONBdnMvxAqckd437ns7Tu8sKW4SsRzjg1\n' + - 'YHTmApRjai1L6bHn0P5Utz0BcynzrUn+bZ0cC+5Rq3kZvrjnaJOIutY+ALDF\n' + - '4yWoVIz8KzzAUx1caVyVvwdFtjVTS87ATQRjoYavAQgA3nCB6WLASwBwp5r/\n' + - 'WU8SiUzf/2srENNObpjxavmv2FVKcKfO0ehSi6ti22KSKnUgm5prlOMWsVl/\n' + - 'wEClvpGw0Btdar4OQI7XdwkY8XUVB5Jff7cNpi4qE+4lIYqCTQief9H5GLC/\n' + - 'QvpE53yZWGFK581OSaeomtibN5xAaUyEE8qITnYyjqA+SgffRFVN5/WOnnBK\n' + - 'zbIHrXl2lXOFkegXaOk+Qxxikw9cSpHNV5YHVoDStRCJZKVU8JhKa7pYKkmC\n' + - 'pSIiXT3IdSAqDiglDRxwX4KlFFhGZ1OGbBmPefN3pZ7/xvaM28TqSDNB7f89\n' + - '/lc5UKLz5Em2aroEclT0YpKYGQARAQABwsB2BBgBCAAqBQJjoYavCRCUVlBn\n' + - 'qYwnwgIbDBYhBPYJKSdUrZzVgB9jy5RWUGepjCfCAAC6rwgAji6/qPQn/BN/\n' + - 'BbwGBN+A8tWRuQLwrgOilg8oHWkyCIUK7DeBp+gpkSghjsnaEAqc94xaGD3U\n' + - 'AfgcPGmC/Jx92W+bX8P40Iq8OvPgLgvG1u5Rf1a1SNYAuypQemuHYu3HOvUU\n' + - 'vP+0omoiTWyNZVqsZA0FGIYQk9uRg8KGsLvXwzPPLqC5Yo3fyfQUmytBZfEf\n' + - 'OwYwuvzx1RBHtvyZ32sfq//q4t2fXY0d49rg6l475zo3JsZsYtqZJCf9h6uK\n' + - 'MrSFgvn8mJFlpwI1+g7X46VB+t8D1Ac35r9Bn9UIWieIyS2Aux2UwBsY2iET\n' + - 'CdgkH8gWFBU7bdKsFh7BQX2ZhrxHXQ==\n' + - '=Lr7Q\n' + - '-----END PGP PUBLIC KEY BLOCK-----\n', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + '\n' + 'xsBNBGOhhq8BCADP5Nzw0jOXhKO86ndGkY/JlD8AadVXmsLA+Yvoc22LrNTU\n' + 'QrfcDWaMAzpmtMWJlNEHSTieUPEgODm/qj422+rdskSedum3gq1HWn2bmqEI\n' + 'LrFc+zR3B70Pe7saEEmC/hXG53/8m7V0HsOuvkEjBa3pW3KElZIhimVvcgYR\n' + '9AnLjUYKR/lci1eXXsAz+J+RjgPlFfiIE0/3KYXwkjt9meSJDPCIcEIZ1tqw\n' + 'IkGRINM5XINMvC+FxPNQ+jIHF9WIzmUg4YfYZQbMo96j4LAV0kYvAB0qI2Y8\n' + 'DHAjHXYQ+fafRGOJwePASjDHUjcB9QEr1EPIMG3i4iFaBV2ZmePjzE7XABEB\n' + 'AAHNAMLAigQQAQgAPgUCY6GGrwQLCQcICRCUVlBnqYwnwgMVCAoEFgACAQIZ\n' + 'AQIbAwIeARYhBPYJKSdUrZzVgB9jy5RWUGepjCfCAABLZAgAtVdxz75k3qFY\n' + 'qtwMdsrIPX4A7rpT/zCd2Yjl2asFdlkyAusfNdFEiff1dHz5+qBM88z/Zh+O\n' + '1FNDKS/WKL9qmZ+AceyidCjnRVTUeH6Mi/ZD/YZInJyLozCksb0Gciswl6Rp\n' + 'RHb6nXt0PebUFXTsOVxSeodaEGBgltd/V1bDHpfx8Wu03z3h/Jq2tI4s28XA\n' + 'S2lSZpG8+nC1zLOmpbYx8mdOe00ONBdnMvxAqckd437ns7Tu8sKW4SsRzjg1\n' + 'YHTmApRjai1L6bHn0P5Utz0BcynzrUn+bZ0cC+5Rq3kZvrjnaJOIutY+ALDF\n' + '4yWoVIz8KzzAUx1caVyVvwdFtjVTS87ATQRjoYavAQgA3nCB6WLASwBwp5r/\n' + 'WU8SiUzf/2srENNObpjxavmv2FVKcKfO0ehSi6ti22KSKnUgm5prlOMWsVl/\n' + 'wEClvpGw0Btdar4OQI7XdwkY8XUVB5Jff7cNpi4qE+4lIYqCTQief9H5GLC/\n' + 'QvpE53yZWGFK581OSaeomtibN5xAaUyEE8qITnYyjqA+SgffRFVN5/WOnnBK\n' + 'zbIHrXl2lXOFkegXaOk+Qxxikw9cSpHNV5YHVoDStRCJZKVU8JhKa7pYKkmC\n' + 'pSIiXT3IdSAqDiglDRxwX4KlFFhGZ1OGbBmPefN3pZ7/xvaM28TqSDNB7f89\n' + '/lc5UKLz5Em2aroEclT0YpKYGQARAQABwsB2BBgBCAAqBQJjoYavCRCUVlBn\n' + 'qYwnwgIbDBYhBPYJKSdUrZzVgB9jy5RWUGepjCfCAAC6rwgAji6/qPQn/BN/\n' + 'BbwGBN+A8tWRuQLwrgOilg8oHWkyCIUK7DeBp+gpkSghjsnaEAqc94xaGD3U\n' + 'AfgcPGmC/Jx92W+bX8P40Iq8OvPgLgvG1u5Rf1a1SNYAuypQemuHYu3HOvUU\n' + 'vP+0omoiTWyNZVqsZA0FGIYQk9uRg8KGsLvXwzPPLqC5Yo3fyfQUmytBZfEf\n' + 'OwYwuvzx1RBHtvyZ32sfq//q4t2fXY0d49rg6l475zo3JsZsYtqZJCf9h6uK\n' + 'MrSFgvn8mJFlpwI1+g7X46VB+t8D1Ac35r9Bn9UIWieIyS2Aux2UwBsY2iET\n' + 'CdgkH8gWFBU7bdKsFh7BQX2ZhrxHXQ==\n' + '=Lr7Q\n' + '-----END PGP PUBLIC KEY BLOCK-----\n', profilePicture: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA1UlEQVR4AcXBobGEMBSG0W//idlKiKARaohMAzEIzFoEhgaQ1EAV6xCkmn32PpMZZue9e87j9Xx/uKGkSMu6X9whnAlnwlkoKdKy7hdWnTJN+4hVUqRFOBPOhLPH6/n+YAznwl86+hFLOBPOhLNQUsRa+5GW4VxoOfqRlpIilnAmnAlnYd0v/tO6X1jCmXAmnIWSIladMtbRj3xjOBesbt6whDPhTDgLdcrc0c0bLQcXLXXKWMKZcCachW7esOqUsUqKWHXKtBQ2rMpv3bxhCWfCmXD2A590MfREqrg1AAAAAElFTkSuQmCC', threadhash: 'bafyreigs26i7k3g5u4xmqg44tecmkfvelclp5lletnikfbsrj7dhg5oi4y', wallets: 'eip155:0x69e666767Ba3a661369e1e2F572EdE7ADC926029', @@ -2545,77 +2478,40 @@ const chats = await PushAPI.chat.requests({ toDID: 'eip155:0x69e666767Ba3a661369e1e2F572EdE7ADC926029', encType: 'pgp', fromDID: 'eip155:0xD8634C39BBFd4033c0d3289C4515275102423681', - sigType: '-----BEGIN PGP SIGNATURE-----\n' + - '\n' + - 'wsBzBAEBCAAnBQJjuJ7WCRCszcBmB607ShYhBEWdLV876c+znjS0l6zNwGYH\n' + - 'rTtKAAAEUQgAiSLgvLRf4UM/VIOImO4I/CHt5vBCqvOjq8068K5Bb2ciRn0o\n' + - '8IqLV2eYKe8c0LK8Gf/CzZn7S13eux4FUlXcX7TlU9BpgHAVQIP4gDe7Q1XN\n' + - '1+rXFH+QW4P/Zv0knObHAby/7wYfD1ZfBrLbo5SpZEBDYQNYZ5t29y7aVD5e\n' + - 'QMOoSvj5+y6SLDLJalb5daeSfaZtpNBsTZvUBLndNomT///gzrXRutkgW4T4\n' + - 'bDipFPUvLMNvWM1qXJjDyYbyQnr8J8aq3FKoGs4Qs5Z2wcwx9RF54Izh81vd\n' + - 'Y5jkZdpULqxjB4BH2mFGyB9Cp2e5cIpKriY597JCAc6Y6WfhgbIZoA==\n' + - '=n2B5\n' + - '-----END PGP SIGNATURE-----\n', + sigType: '-----BEGIN PGP SIGNATURE-----\n' + '\n' + 'wsBzBAEBCAAnBQJjuJ7WCRCszcBmB607ShYhBEWdLV876c+znjS0l6zNwGYH\n' + 'rTtKAAAEUQgAiSLgvLRf4UM/VIOImO4I/CHt5vBCqvOjq8068K5Bb2ciRn0o\n' + '8IqLV2eYKe8c0LK8Gf/CzZn7S13eux4FUlXcX7TlU9BpgHAVQIP4gDe7Q1XN\n' + '1+rXFH+QW4P/Zv0knObHAby/7wYfD1ZfBrLbo5SpZEBDYQNYZ5t29y7aVD5e\n' + 'QMOoSvj5+y6SLDLJalb5daeSfaZtpNBsTZvUBLndNomT///gzrXRutkgW4T4\n' + 'bDipFPUvLMNvWM1qXJjDyYbyQnr8J8aq3FKoGs4Qs5Z2wcwx9RF54Izh81vd\n' + 'Y5jkZdpULqxjB4BH2mFGyB9Cp2e5cIpKriY597JCAc6Y6WfhgbIZoA==\n' + '=n2B5\n' + '-----END PGP SIGNATURE-----\n', toCAIP10: 'eip155:0x69e666767Ba3a661369e1e2F572EdE7ADC926029', - signature: '-----BEGIN PGP SIGNATURE-----\n' + - '\n' + - 'wsBzBAEBCAAnBQJjuJ7WCRCszcBmB607ShYhBEWdLV876c+znjS0l6zNwGYH\n' + - 'rTtKAAAEUQgAiSLgvLRf4UM/VIOImO4I/CHt5vBCqvOjq8068K5Bb2ciRn0o\n' + - '8IqLV2eYKe8c0LK8Gf/CzZn7S13eux4FUlXcX7TlU9BpgHAVQIP4gDe7Q1XN\n' + - '1+rXFH+QW4P/Zv0knObHAby/7wYfD1ZfBrLbo5SpZEBDYQNYZ5t29y7aVD5e\n' + - 'QMOoSvj5+y6SLDLJalb5daeSfaZtpNBsTZvUBLndNomT///gzrXRutkgW4T4\n' + - 'bDipFPUvLMNvWM1qXJjDyYbyQnr8J8aq3FKoGs4Qs5Z2wcwx9RF54Izh81vd\n' + - 'Y5jkZdpULqxjB4BH2mFGyB9Cp2e5cIpKriY597JCAc6Y6WfhgbIZoA==\n' + - '=n2B5\n' + - '-----END PGP SIGNATURE-----\n', + signature: '-----BEGIN PGP SIGNATURE-----\n' + '\n' + 'wsBzBAEBCAAnBQJjuJ7WCRCszcBmB607ShYhBEWdLV876c+znjS0l6zNwGYH\n' + 'rTtKAAAEUQgAiSLgvLRf4UM/VIOImO4I/CHt5vBCqvOjq8068K5Bb2ciRn0o\n' + '8IqLV2eYKe8c0LK8Gf/CzZn7S13eux4FUlXcX7TlU9BpgHAVQIP4gDe7Q1XN\n' + '1+rXFH+QW4P/Zv0knObHAby/7wYfD1ZfBrLbo5SpZEBDYQNYZ5t29y7aVD5e\n' + 'QMOoSvj5+y6SLDLJalb5daeSfaZtpNBsTZvUBLndNomT///gzrXRutkgW4T4\n' + 'bDipFPUvLMNvWM1qXJjDyYbyQnr8J8aq3FKoGs4Qs5Z2wcwx9RF54Izh81vd\n' + 'Y5jkZdpULqxjB4BH2mFGyB9Cp2e5cIpKriY597JCAc6Y6WfhgbIZoA==\n' + '=n2B5\n' + '-----END PGP SIGNATURE-----\n', timestamp: 1673043671357, fromCAIP10: 'eip155:0xD8634C39BBFd4033c0d3289C4515275102423681', messageType: 'Text', messageContent: 'hey', - encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + - '\n' + - 'wcBMAzJsNgcerTKoAQgAvzX9pBj4j7ytnwU7DwMsCMl6PUDx6qAQybQxrlby\n' + - '+xkP1Cf1tOkLj1HP/oFHg3cX5HioM600jAaIYhCr8ib+M3ydvhKnti0mcpbn\n' + - 'VnbWilrzyFUBE7T3eZY54JeFxIQ9mtjl/TmGryXpWD9FHjnSp22NRnbZIcZZ\n' + - 'SHpatgDZYzRhHf9zqusBH2QUDKX1Ty7dIq9JD2AeS55l40IHNMPcP2btxfY1\n' + - 'T7od8WvFYhlWQGtkbm8k42fwdK1mIJ3H/rOSeM8sTliYAECe+IhmpIevg4II\n' + - 'Eel7eG81HjGciWt3Vs3FXkhuEUbQnMRAKfhaqalJNDriaWwzUMMt5a/rWdS1\n' + - 'gMHATAN7roGwZ8OLswEH/2RmDHNAaDi11UT3uLAuQxNzlLeqxFaTPecSFaEW\n' + - 'IFdJ+3ujcy3FHoyndK0S+ucFhP2V0hJRMHyyMiKNKSuUp6Q03NZ7Uqavqku3\n' + - 'kVfAJ3tH6jlUWNetvV8t95OmYInqhC4MNk0nIhdI10bl89KmNRqsfQqKu5Hn\n' + - '5b9Jy7B+XgjKNdj7iWx0FuFabVIQ3NIDnVBDLy8/mDTeB1HuAv/7KljBr0fC\n' + - 'TtzSZij1Pu5+aIPWaGG2hJvxga9g5Zqfvdm79Wn3gfoOCz3FdXcp/n3732rY\n' + - '+mrIE0DVUlWa0YbVotcSCzLlUpXlFts85Ok8W/N8ERtBMbbd2+e2tBKAP8Hs\n' + - 'iYHSQAHz9V5LwQaFvujErtV5KZfD5DnB8RlUVJU4JKLDgYiXaP18O0fpsZyO\n' + - '4fym770psCEPU4sc+flSJ0SxBa8m+yM=\n' + - '=Cp3M\n' + - '-----END PGP MESSAGE-----\n' + encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + '\n' + 'wcBMAzJsNgcerTKoAQgAvzX9pBj4j7ytnwU7DwMsCMl6PUDx6qAQybQxrlby\n' + '+xkP1Cf1tOkLj1HP/oFHg3cX5HioM600jAaIYhCr8ib+M3ydvhKnti0mcpbn\n' + 'VnbWilrzyFUBE7T3eZY54JeFxIQ9mtjl/TmGryXpWD9FHjnSp22NRnbZIcZZ\n' + 'SHpatgDZYzRhHf9zqusBH2QUDKX1Ty7dIq9JD2AeS55l40IHNMPcP2btxfY1\n' + 'T7od8WvFYhlWQGtkbm8k42fwdK1mIJ3H/rOSeM8sTliYAECe+IhmpIevg4II\n' + 'Eel7eG81HjGciWt3Vs3FXkhuEUbQnMRAKfhaqalJNDriaWwzUMMt5a/rWdS1\n' + 'gMHATAN7roGwZ8OLswEH/2RmDHNAaDi11UT3uLAuQxNzlLeqxFaTPecSFaEW\n' + 'IFdJ+3ujcy3FHoyndK0S+ucFhP2V0hJRMHyyMiKNKSuUp6Q03NZ7Uqavqku3\n' + 'kVfAJ3tH6jlUWNetvV8t95OmYInqhC4MNk0nIhdI10bl89KmNRqsfQqKu5Hn\n' + '5b9Jy7B+XgjKNdj7iWx0FuFabVIQ3NIDnVBDLy8/mDTeB1HuAv/7KljBr0fC\n' + 'TtzSZij1Pu5+aIPWaGG2hJvxga9g5Zqfvdm79Wn3gfoOCz3FdXcp/n3732rY\n' + '+mrIE0DVUlWa0YbVotcSCzLlUpXlFts85Ok8W/N8ERtBMbbd2+e2tBKAP8Hs\n' + 'iYHSQAHz9V5LwQaFvujErtV5KZfD5DnB8RlUVJU4JKLDgYiXaP18O0fpsZyO\n' + '4fym770psCEPU4sc+flSJ0SxBa8m+yM=\n' + '=Cp3M\n' + '-----END PGP MESSAGE-----\n', }, - groupInformation: undefined - } -] -``` - -| Parameter | Type | Description | -| --- | --- | --- | -| msg | `IMessageIPFS` | message object | -| did | `string` | user DID | -| wallets | `string` | user wallets | -| profilePicture | `string` | user profile picture | -| publicKey | `string` | user public key | -| about | `string` | user description | -| threadhash | `string` | cid from the latest message sent on this conversation | -| intent | `string` | addresses concatenated from the users who have approved the intent | -| intentSentBy | `string` | address of the user who sent the intent | -| intentTimestamp | `number` | timestamp of the intent | -| combinedDID | `string` | concatenated addresses of the members of this chat (for DM the 2 addresses and from Group the addresses from all group members) | -| cid | `string` | content identifier on IPFS | -| chatId | `string` | chat identifier | -| groupInformation | `GroupDTO` | if group chat, all group information | + groupInformation: undefined, + }, +]; +``` + +| Parameter | Type | Description | +| ---------------- | -------------- | ------------------------------------------------------------------------------------------------------------------------------- | +| msg | `IMessageIPFS` | message object | +| did | `string` | user DID | +| wallets | `string` | user wallets | +| profilePicture | `string` | user profile picture | +| publicKey | `string` | user public key | +| about | `string` | user description | +| threadhash | `string` | cid from the latest message sent on this conversation | +| intent | `string` | addresses concatenated from the users who have approved the intent | +| intentSentBy | `string` | address of the user who sent the intent | +| intentTimestamp | `number` | timestamp of the intent | +| combinedDID | `string` | concatenated addresses of the members of this chat (for DM the 2 addresses and from Group the addresses from all group members) | +| cid | `string` | content identifier on IPFS | +| chatId | `string` | chat identifier | +| groupInformation | `GroupDTO` | if group chat, all group information | ------ +--- ### **Fetching conversation hash between two users** @@ -2630,11 +2526,11 @@ const conversationHash = await PushAPI.chat.conversationHash({ }); ``` -| Param | Type | Default | Remarks | -|----------|---------|---------|--------------------------------------------| -| account | string | - | user address | -| conversationId | string | - | receiver's address (partial CAIP) or chatId of a group| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| Param | Type | Default | Remarks | +| -------------- | ------ | ------- | ------------------------------------------------------ | +| account | string | - | user address | +| conversationId | string | - | receiver's address (partial CAIP) or chatId of a group | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev' | **Example:** @@ -2643,7 +2539,7 @@ const conversationHash = await PushAPI.chat.conversationHash({ const conversationHash = await PushAPI.chat.conversationHash({ account: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', conversationId: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', // receiver's address or chatId of a group - env: ENV.STAGING + env: ENV.STAGING, }); ``` @@ -2653,16 +2549,17 @@ const conversationHash = await PushAPI.chat.conversationHash({ ```typescript // PushAPI_chat_conversationHash | Response - 200 OK { - threadHash: 'bafyreign2egu7so7lf3gdicehyqjvghzmwn5gokh4fmp4oy3vjwrjk2rjy' + threadHash: 'bafyreign2egu7so7lf3gdicehyqjvghzmwn5gokh4fmp4oy3vjwrjk2rjy'; } ``` -| Param | Type | Default | Remarks | -|----------|---------|---------|--------------------------------------------| -| threadHash | string | - | message content identifier | +| Param | Type | Default | Remarks | +| ---------- | ------ | ------- | -------------------------- | +| threadHash | string | - | message content identifier | + ------ +--- ### **Fetching latest chat between two users** @@ -2676,13 +2573,13 @@ const chatHistory = await PushAPI.chat.latest({ }); ``` -| Param | Type | Remarks | -|----------|---------|--------------------------------------------| -| threadHash | string | message content identifier | -| toDecrypt | boolean | true if you want messages to be decrypted | -| pgpPrivateKey | string | PGP Private Key | -| account | string | user account | -| env | ENV | environment variable | +| Param | Type | Remarks | +| ------------- | ------- | ----------------------------------------- | +| threadHash | string | message content identifier | +| toDecrypt | boolean | true if you want messages to be decrypted | +| pgpPrivateKey | string | PGP Private Key | +| account | string | user account | +| env | ENV | environment variable | **Example:** @@ -2690,7 +2587,7 @@ const chatHistory = await PushAPI.chat.latest({ // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); @@ -2700,7 +2597,7 @@ const conversationHash = await PushAPI.chat.conversationHash({ conversationId: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', // receiver's address or chatId of a group env: 'staging' }); - + // actual api const chatHistory = await PushAPI.chat.latest({ threadhash: conversationHash.threadHash, @@ -2724,63 +2621,35 @@ const chatHistory = await PushAPI.chat.latest({ fromDID: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', sigType: 'pgp', toCAIP10: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', - signature: '-----BEGIN PGP SIGNATURE-----\n' + - '\n' + - 'wsBzBAEBCAAnBQJjh5tjCRBaJmgmByp5FRYhBJC23yBJT2d/pTAID1omaCYH\n' + - 'KnkVAAAZmwf/buPLw6caSZmYnw6D3/p6HF1kWlkGUOTP4RasaU/6dkeDaZs9\n' + - 'SJlz2wC8oOpBGWHMJ/5n3ZWmU71E6U7IKIY793MyIv5t32vTNkwsRHUX7IIn\n' + - 'QFF+FzTIEtHHVTRlnkqNR2YUk1kqcpZCZWHfahi5W2d/WkXlFNdvyyFH4W8L\n' + - 'd03FGhOyXbWwU3xicBz5mSBpIFaaSCXl1SdgJDPXLSk3b65EEOjCOaiz85xC\n' + - 'G+6SW4RUzCGSDcOd9F2EXvvY5H9LgQNi1jjlZn6JrPTPJTJ+wXZXzcZmtOXG\n' + - 'EKcwvPbbPY9wd+gavRSOgYLYn5xoZQW/o3hW7AQlbC5Kj6js48Z0HQ==\n' + - '=qLiJ\n' + - '-----END PGP SIGNATURE-----\n', + signature: '-----BEGIN PGP SIGNATURE-----\n' + '\n' + 'wsBzBAEBCAAnBQJjh5tjCRBaJmgmByp5FRYhBJC23yBJT2d/pTAID1omaCYH\n' + 'KnkVAAAZmwf/buPLw6caSZmYnw6D3/p6HF1kWlkGUOTP4RasaU/6dkeDaZs9\n' + 'SJlz2wC8oOpBGWHMJ/5n3ZWmU71E6U7IKIY793MyIv5t32vTNkwsRHUX7IIn\n' + 'QFF+FzTIEtHHVTRlnkqNR2YUk1kqcpZCZWHfahi5W2d/WkXlFNdvyyFH4W8L\n' + 'd03FGhOyXbWwU3xicBz5mSBpIFaaSCXl1SdgJDPXLSk3b65EEOjCOaiz85xC\n' + 'G+6SW4RUzCGSDcOd9F2EXvvY5H9LgQNi1jjlZn6JrPTPJTJ+wXZXzcZmtOXG\n' + 'EKcwvPbbPY9wd+gavRSOgYLYn5xoZQW/o3hW7AQlbC5Kj6js48Z0HQ==\n' + '=qLiJ\n' + '-----END PGP SIGNATURE-----\n', timestamp: 1669831523684, fromCAIP10: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', messageType: 'Text', messageContent: 'Hi', - encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + - '\n' + - 'wcBMA1fn1CNqxQ7nAQgArlo75qe54WerfRKFv1+F9j4NRMvSTgUztvIe51eg\n' + - 'd5MVuj6RYxKERr2bTuBt5cMDJMlNuTnBBkPe4L8+SlsI46L9wmXV9xLoZq1a\n' + - '94JdxD98RGMF99Jde/3hC/X6GS1yVqPpKPKdWx/tkOPeyqeO/wFF7kqShgIi\n' + - 'Wgq6hGz1fzD3GZhKGY0VSLuC3s0aUy/qw5En1Xd0uX0jdXBl07IIj8p1G2zx\n' + - '9BuVlksSK34yvIc0RQfCeRadMHkxbA0Hyj31Wrr+Y310YLTppL0s5bQR9APL\n' + - 'WHsIztJ1fHTnXsPhnA7YG0SQpHTyJhuX3rgBjxGrvbZBArmZ+R/Pq9IkOkJe\n' + - 'z8HATAMOsbaZjGN5JwEH/jYjLN6AFRWeaB5CSBSAF+CvHsUgadGmxTdSHBM6\n' + - 'LM9rfGg/MCnpRBuHckA0NNZh+wepq6TDA54ZopsdP14gHj4MKCdfqZr86Jft\n' + - 'ldtjeSgPTFEEJxPMJ4/Z3UeFU9rvOgfxX6l0eHWS0MYwJ3sVYvSyqqHir1K5\n' + - 'TRdEIgtQ3NvLTKkX4bKTSU+SInrvDA+wsc2BcBsbgNhRiGb+XYrbqXBshL1a\n' + - 'lIdpnomkAQgOZMO2n347uURYoruH3OtFeNABJ9D/nEU+LdhDOPGZPefvPBc5\n' + - 'BxK4ExKZ2Wo/TZw8lgC53uqOljsGV63Hp71LkyesKWu5/+vdVrYx/vU63shh\n' + - 'x/TSQAEiaFYEfkWSOthtH0nrJHhkY7FWgjp/1bj/J4J9HCQrVtt2WlQfhowZ\n' + - 'ILxhKk/vep0sJviM3SfJ4hPtoYpZESc=\n' + - '=43Ta\n' + - '-----END PGP MESSAGE-----\n' - } -] - -``` - -| Param | Type | Remarks | -|----------|---------|--------------------------------------------| -| `fromCAIP10` | string | sender address | -| `toCAIP10` | string | receiver address | -| `fromDID` | string | sender did | -| `toDID` | string | receiver did | -| `messageType` | string | message type | -| `messageContent` | string | message content | -| `signature` | string | signature of the message | -| `sigType` | string | signature type | -| `link` | string | content identifier of the previous messages | -| `timestamp` | number | timestamp of the message | -| `encType` | string | encryption type | -| `encryptedSecret` | string | encrypted secret | + encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + '\n' + 'wcBMA1fn1CNqxQ7nAQgArlo75qe54WerfRKFv1+F9j4NRMvSTgUztvIe51eg\n' + 'd5MVuj6RYxKERr2bTuBt5cMDJMlNuTnBBkPe4L8+SlsI46L9wmXV9xLoZq1a\n' + '94JdxD98RGMF99Jde/3hC/X6GS1yVqPpKPKdWx/tkOPeyqeO/wFF7kqShgIi\n' + 'Wgq6hGz1fzD3GZhKGY0VSLuC3s0aUy/qw5En1Xd0uX0jdXBl07IIj8p1G2zx\n' + '9BuVlksSK34yvIc0RQfCeRadMHkxbA0Hyj31Wrr+Y310YLTppL0s5bQR9APL\n' + 'WHsIztJ1fHTnXsPhnA7YG0SQpHTyJhuX3rgBjxGrvbZBArmZ+R/Pq9IkOkJe\n' + 'z8HATAMOsbaZjGN5JwEH/jYjLN6AFRWeaB5CSBSAF+CvHsUgadGmxTdSHBM6\n' + 'LM9rfGg/MCnpRBuHckA0NNZh+wepq6TDA54ZopsdP14gHj4MKCdfqZr86Jft\n' + 'ldtjeSgPTFEEJxPMJ4/Z3UeFU9rvOgfxX6l0eHWS0MYwJ3sVYvSyqqHir1K5\n' + 'TRdEIgtQ3NvLTKkX4bKTSU+SInrvDA+wsc2BcBsbgNhRiGb+XYrbqXBshL1a\n' + 'lIdpnomkAQgOZMO2n347uURYoruH3OtFeNABJ9D/nEU+LdhDOPGZPefvPBc5\n' + 'BxK4ExKZ2Wo/TZw8lgC53uqOljsGV63Hp71LkyesKWu5/+vdVrYx/vU63shh\n' + 'x/TSQAEiaFYEfkWSOthtH0nrJHhkY7FWgjp/1bj/J4J9HCQrVtt2WlQfhowZ\n' + 'ILxhKk/vep0sJviM3SfJ4hPtoYpZESc=\n' + '=43Ta\n' + '-----END PGP MESSAGE-----\n', + }, +]; +``` + +| Param | Type | Remarks | +| ----------------- | ------ | ------------------------------------------- | +| `fromCAIP10` | string | sender address | +| `toCAIP10` | string | receiver address | +| `fromDID` | string | sender did | +| `toDID` | string | receiver did | +| `messageType` | string | message type | +| `messageContent` | string | message content | +| `signature` | string | signature of the message | +| `sigType` | string | signature type | +| `link` | string | content identifier of the previous messages | +| `timestamp` | number | timestamp of the message | +| `encType` | string | encryption type | +| `encryptedSecret` | string | encrypted secret | ------ - +--- + ### **Fetching chat history between two users** ```typescript @@ -2797,14 +2666,14 @@ const chatHistory = await PushAPI.chat.history({ }); ``` -| Param | Type | Default | Remarks | -|----------|---------|---------|--------------------------------------------| -| account | string | - | user address | -| threadhash | string | - | conversation hash between two users | -| toDecrypt | boolean | false | if "true" the method will return decrypted message content in response| -| limit | number | 10 | number of messages between two users | -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | ENV | 'prod' | API env - 'prod', 'staging', 'dev'| +| Param | Type | Default | Remarks | +| ------------- | ------- | ------- | ---------------------------------------------------------------------- | +| account | string | - | user address | +| threadhash | string | - | conversation hash between two users | +| toDecrypt | boolean | false | if "true" the method will return decrypted message content in response | +| limit | number | 10 | number of messages between two users | +| pgpPrivateKey | string | null | mandatory for users having pgp keys | +| env | ENV | 'prod' | API env - 'prod', 'staging', 'dev' | **Example:** @@ -2812,7 +2681,7 @@ const chatHistory = await PushAPI.chat.history({ // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); @@ -2824,7 +2693,7 @@ const conversationHash = await PushAPI.chat.conversationHash({ conversationId: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', // receiver's address or chatId of a group env: 'staging' }); - + // actual api const chatHistory = await PushAPI.chat.history({ threadhash: conversationHash.threadHash, @@ -2849,39 +2718,12 @@ const chatHistory = await PushAPI.chat.history({ fromDID: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', sigType: 'pgp', toCAIP10: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', - signature: '-----BEGIN PGP SIGNATURE-----\n' + - '\n' + - 'wsBzBAEBCAAnBQJjh5tjCRBaJmgmByp5FRYhBJC23yBJT2d/pTAID1omaCYH\n' + - 'KnkVAAAZmwf/buPLw6caSZmYnw6D3/p6HF1kWlkGUOTP4RasaU/6dkeDaZs9\n' + - 'SJlz2wC8oOpBGWHMJ/5n3ZWmU71E6U7IKIY793MyIv5t32vTNkwsRHUX7IIn\n' + - 'QFF+FzTIEtHHVTRlnkqNR2YUk1kqcpZCZWHfahi5W2d/WkXlFNdvyyFH4W8L\n' + - 'd03FGhOyXbWwU3xicBz5mSBpIFaaSCXl1SdgJDPXLSk3b65EEOjCOaiz85xC\n' + - 'G+6SW4RUzCGSDcOd9F2EXvvY5H9LgQNi1jjlZn6JrPTPJTJ+wXZXzcZmtOXG\n' + - 'EKcwvPbbPY9wd+gavRSOgYLYn5xoZQW/o3hW7AQlbC5Kj6js48Z0HQ==\n' + - '=qLiJ\n' + - '-----END PGP SIGNATURE-----\n', + signature: '-----BEGIN PGP SIGNATURE-----\n' + '\n' + 'wsBzBAEBCAAnBQJjh5tjCRBaJmgmByp5FRYhBJC23yBJT2d/pTAID1omaCYH\n' + 'KnkVAAAZmwf/buPLw6caSZmYnw6D3/p6HF1kWlkGUOTP4RasaU/6dkeDaZs9\n' + 'SJlz2wC8oOpBGWHMJ/5n3ZWmU71E6U7IKIY793MyIv5t32vTNkwsRHUX7IIn\n' + 'QFF+FzTIEtHHVTRlnkqNR2YUk1kqcpZCZWHfahi5W2d/WkXlFNdvyyFH4W8L\n' + 'd03FGhOyXbWwU3xicBz5mSBpIFaaSCXl1SdgJDPXLSk3b65EEOjCOaiz85xC\n' + 'G+6SW4RUzCGSDcOd9F2EXvvY5H9LgQNi1jjlZn6JrPTPJTJ+wXZXzcZmtOXG\n' + 'EKcwvPbbPY9wd+gavRSOgYLYn5xoZQW/o3hW7AQlbC5Kj6js48Z0HQ==\n' + '=qLiJ\n' + '-----END PGP SIGNATURE-----\n', timestamp: 1669831523684, fromCAIP10: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', messageType: 'Text', messageContent: 'Hi', - encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + - '\n' + - 'wcBMA1fn1CNqxQ7nAQgArlo75qe54WerfRKFv1+F9j4NRMvSTgUztvIe51eg\n' + - 'd5MVuj6RYxKERr2bTuBt5cMDJMlNuTnBBkPe4L8+SlsI46L9wmXV9xLoZq1a\n' + - '94JdxD98RGMF99Jde/3hC/X6GS1yVqPpKPKdWx/tkOPeyqeO/wFF7kqShgIi\n' + - 'Wgq6hGz1fzD3GZhKGY0VSLuC3s0aUy/qw5En1Xd0uX0jdXBl07IIj8p1G2zx\n' + - '9BuVlksSK34yvIc0RQfCeRadMHkxbA0Hyj31Wrr+Y310YLTppL0s5bQR9APL\n' + - 'WHsIztJ1fHTnXsPhnA7YG0SQpHTyJhuX3rgBjxGrvbZBArmZ+R/Pq9IkOkJe\n' + - 'z8HATAMOsbaZjGN5JwEH/jYjLN6AFRWeaB5CSBSAF+CvHsUgadGmxTdSHBM6\n' + - 'LM9rfGg/MCnpRBuHckA0NNZh+wepq6TDA54ZopsdP14gHj4MKCdfqZr86Jft\n' + - 'ldtjeSgPTFEEJxPMJ4/Z3UeFU9rvOgfxX6l0eHWS0MYwJ3sVYvSyqqHir1K5\n' + - 'TRdEIgtQ3NvLTKkX4bKTSU+SInrvDA+wsc2BcBsbgNhRiGb+XYrbqXBshL1a\n' + - 'lIdpnomkAQgOZMO2n347uURYoruH3OtFeNABJ9D/nEU+LdhDOPGZPefvPBc5\n' + - 'BxK4ExKZ2Wo/TZw8lgC53uqOljsGV63Hp71LkyesKWu5/+vdVrYx/vU63shh\n' + - 'x/TSQAEiaFYEfkWSOthtH0nrJHhkY7FWgjp/1bj/J4J9HCQrVtt2WlQfhowZ\n' + - 'ILxhKk/vep0sJviM3SfJ4hPtoYpZESc=\n' + - '=43Ta\n' + - '-----END PGP MESSAGE-----\n' + encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + '\n' + 'wcBMA1fn1CNqxQ7nAQgArlo75qe54WerfRKFv1+F9j4NRMvSTgUztvIe51eg\n' + 'd5MVuj6RYxKERr2bTuBt5cMDJMlNuTnBBkPe4L8+SlsI46L9wmXV9xLoZq1a\n' + '94JdxD98RGMF99Jde/3hC/X6GS1yVqPpKPKdWx/tkOPeyqeO/wFF7kqShgIi\n' + 'Wgq6hGz1fzD3GZhKGY0VSLuC3s0aUy/qw5En1Xd0uX0jdXBl07IIj8p1G2zx\n' + '9BuVlksSK34yvIc0RQfCeRadMHkxbA0Hyj31Wrr+Y310YLTppL0s5bQR9APL\n' + 'WHsIztJ1fHTnXsPhnA7YG0SQpHTyJhuX3rgBjxGrvbZBArmZ+R/Pq9IkOkJe\n' + 'z8HATAMOsbaZjGN5JwEH/jYjLN6AFRWeaB5CSBSAF+CvHsUgadGmxTdSHBM6\n' + 'LM9rfGg/MCnpRBuHckA0NNZh+wepq6TDA54ZopsdP14gHj4MKCdfqZr86Jft\n' + 'ldtjeSgPTFEEJxPMJ4/Z3UeFU9rvOgfxX6l0eHWS0MYwJ3sVYvSyqqHir1K5\n' + 'TRdEIgtQ3NvLTKkX4bKTSU+SInrvDA+wsc2BcBsbgNhRiGb+XYrbqXBshL1a\n' + 'lIdpnomkAQgOZMO2n347uURYoruH3OtFeNABJ9D/nEU+LdhDOPGZPefvPBc5\n' + 'BxK4ExKZ2Wo/TZw8lgC53uqOljsGV63Hp71LkyesKWu5/+vdVrYx/vU63shh\n' + 'x/TSQAEiaFYEfkWSOthtH0nrJHhkY7FWgjp/1bj/J4J9HCQrVtt2WlQfhowZ\n' + 'ILxhKk/vep0sJviM3SfJ4hPtoYpZESc=\n' + '=43Ta\n' + '-----END PGP MESSAGE-----\n', }, { link: null, @@ -2895,43 +2737,44 @@ const chatHistory = await PushAPI.chat.history({ fromCAIP10: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', messageType: 'Text', messageContent: 'Hey Fabio!', - encryptedSecret: '' - } -] -``` - -| Param | Type | Remarks | -|----------|---------|--------------------------------------------| -| `fromCAIP10` | string | sender address | -| `toCAIP10` | string | receiver address | -| `fromDID` | string | sender did | -| `toDID` | string | receiver did | -| `messageType` | string | message type | -| `messageContent` | string | message content | -| `signature` | string | signature of the message | -| `sigType` | string | signature type | -| `link` | string | content identifier of the previous messages | -| `timestamp` | number | timestamp of the message | -| `encType` | string | encryption type | -| `encryptedSecret` | string | encrypted secret | + encryptedSecret: '', + }, +]; +``` + +| Param | Type | Remarks | +| ----------------- | ------ | ------------------------------------------- | +| `fromCAIP10` | string | sender address | +| `toCAIP10` | string | receiver address | +| `fromDID` | string | sender did | +| `toDID` | string | receiver did | +| `messageType` | string | message type | +| `messageContent` | string | message content | +| `signature` | string | signature of the message | +| `sigType` | string | signature type | +| `link` | string | content identifier of the previous messages | +| `timestamp` | number | timestamp of the message | +| `encType` | string | encryption type | +| `encryptedSecret` | string | encrypted secret | ------ +--- ### **To send a message** + ```typescript // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); // actual api const response = await PushAPI.chat.send({ messageContent: "Gm gm! It's me... Mario", - messageType: 'Text', // can be "Text" | "Image" | "File" | "GIF" + messageType: 'Text', // can be "Text" | "Image" | "File" | "GIF" receiverAddress: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', signer: _signer, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -2939,15 +2782,15 @@ const response = await PushAPI.chat.send({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| messageContent | string | '' | message to be sent | -| messageType | 'Text' | 'Image' | 'File' | 'GIF' | 'Text'| type of messageContent | -| receiverAddress* | string | - | user address or group chat id (Partial CAIP) | -| signer* | - | - | signer object | -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| messageContent | string | '' | message to be sent | +| messageType | 'Text' | 'Image' | 'File' | 'GIF' | 'Text'| type of messageContent | +| receiverAddress_ | string | - | user address or group chat id (Partial CAIP) | +| signer\* | - | - | signer object | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (send chat message or chat request to a wallet) @@ -2971,28 +2814,30 @@ Allowed Options (params with * are mandatory) } ``` +
------ - +--- + ### **To approve a chat request** + ```typescript const response = await PushAPI.chat.approve({ status: 'Approved', account: '0x18C0Ab0809589c423Ac9eb42897258757b6b3d3d', - senderAddress : '0x873a538254f8162377296326BB3eDDbA7d00F8E9', // receiver's address or chatId of a group - env:'staging', + senderAddress: '0x873a538254f8162377296326BB3eDDbA7d00F8E9', // receiver's address or chatId of a group + env: 'staging', }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| status | 'Approved' | 'Approved' | flag for approving and rejecting chat request, supports only approving for now| -| senderAddress* | string | - | chat request sender's address or chatId of a group | -| signer* | - | - | signer object | -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| status | 'Approved' | 'Approved' | flag for approving and rejecting chat request, supports only approving for now| +| senderAddress_ | string | - | chat request sender's address or chatId of a group | +| signer\* | - | - | signer object | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (approve chat request for a wallet / group chat id) @@ -3000,16 +2845,18 @@ Allowed Options (params with * are mandatory) ```typescript // PushAPI_chat_approve | Response - 204 OK ``` +
------ - +--- + ### **To create a group** + ```typescript // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); @@ -3027,19 +2874,18 @@ const response = await PushAPI.chat.createGroup({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| account* | string | - | user address | -| groupName* | string | - | group name | -| groupDescription* | string | - | group description | -| groupImage* | string | - | group image link | -| members* | Array | - | wallet addresses of all members except admins and groupCreator | -| admins* | Array | - | wallet addresses of all admins except members and groupCreator | -| isPublic* | boolean | - | true for public group, false for private group | -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - +| account_ | string | - | user address | +| groupName* | string | - | group name | +| groupDescription* | string | - | group description | +| groupImage* | string | - | group image link | +| members* | Array | - | wallet addresses of all members except admins and groupCreator | +| admins* | Array | - | wallet addresses of all admins except members and groupCreator | +| isPublic* | boolean | - | true for public group, false for private group | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (create group) @@ -3154,17 +3000,20 @@ Allowed Options (params with * are mandatory) ``` +
------ +--- ### **To update group details** + Note - updateGroup is an idompotent call + ```typescript // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); @@ -3182,35 +3031,34 @@ const response = await PushAPI.chat.updateGroup({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| chatId* | string | - | chatId of the group | -| account* | string | - | user address | -| groupName* | string | - | group name | -| groupDescription* | string | - | group description | -| groupImage* | string | - | group image link | -| members* | Array | - | wallet addresses of all members except admins and groupCreator | -| admins* | Array | - | wallet addresses of all admins except members and groupCreator | -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - - +| chatId_ | string | - | chatId of the group | +| account* | string | - | user address | +| groupName* | string | - | group name | +| groupDescription* | string | - | group description | +| groupImage* | string | - | group image link | +| members* | Array | - | wallet addresses of all members except admins and groupCreator | +| admins* | Array | - | wallet addresses of all admins except members and groupCreator | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + ### **To get group details by group name** ```typescript const response = await PushAPI.chat.getGroupByName({ - groupName: "Push Group Chat 3", + groupName: 'Push Group Chat 3', env: 'staging', }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| groupName* | string | - | name of the group | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - +| groupName_ | string | - | name of the group | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +
Expected response (get group by name) @@ -3323,9 +3171,10 @@ Allowed Options (params with * are mandatory) } ``` +
------ +--- ### **To get group details by chatId** @@ -3336,11 +3185,11 @@ const response = await PushAPI.chat.getGroup({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| chatId* | string | - | group chat id | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| chatId_ | string | - | group chat id | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
Expected response (get group by chat id) @@ -3453,17 +3302,20 @@ Allowed Options (params with * are mandatory) chatId: '870cbb20f0b116d5e461a154dc723dc1485976e97f61a673259698aa7f48371c' } ``` +
------ - +--- + ### **Chat Helper Utils** + #### **Decrypting messages** + ```typescript // pre-requisite API calls that should be made before // need to get user and through that encryptedPvtKey of the user const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); - + // need to decrypt the encryptedPvtKey to pass in the api using helper function const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); @@ -3475,7 +3327,7 @@ const conversationHash = await PushAPI.chat.conversationHash({ conversationId: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', // receiver's address or chatId of a group env: 'staging' }); - + // chat history but with decrypt helper so everything is encrypted const encryptedChats = await PushAPI.chat.history({ threadhash: conversationHash.threadHash, @@ -3485,7 +3337,7 @@ const encryptedChats = await PushAPI.chat.history({ pgpPrivateKey: pgpDecryptedPvtKey, env: 'staging', }); - + // actual api const decryptedChat = await PushAPI.chat.decryptConversation({ messages: encryptedChats, // array of message object fetched from chat.history method @@ -3495,14 +3347,14 @@ const decryptedChat = await PushAPI.chat.decryptConversation({ }); ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| messages* | string | - | array of message object fetched from chat.history method | -| connectedUser* | IUser | false | user meta data object| -| pgpPrivateKey | string | null | mandatory for users having pgp keys| -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| - +| messages_ | string | - | array of message object fetched from chat.history method | +| connectedUser\* | IUser | false | user meta data object| +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +
Expected response (decrypt conversation) @@ -3517,39 +3369,12 @@ Allowed Options (params with * are mandatory) fromDID: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', sigType: 'pgp', toCAIP10: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', - signature: '-----BEGIN PGP SIGNATURE-----\n' + - '\n' + - 'wsBzBAEBCAAnBQJjh5tjCRBaJmgmByp5FRYhBJC23yBJT2d/pTAID1omaCYH\n' + - 'KnkVAAAZmwf/buPLw6caSZmYnw6D3/p6HF1kWlkGUOTP4RasaU/6dkeDaZs9\n' + - 'SJlz2wC8oOpBGWHMJ/5n3ZWmU71E6U7IKIY793MyIv5t32vTNkwsRHUX7IIn\n' + - 'QFF+FzTIEtHHVTRlnkqNR2YUk1kqcpZCZWHfahi5W2d/WkXlFNdvyyFH4W8L\n' + - 'd03FGhOyXbWwU3xicBz5mSBpIFaaSCXl1SdgJDPXLSk3b65EEOjCOaiz85xC\n' + - 'G+6SW4RUzCGSDcOd9F2EXvvY5H9LgQNi1jjlZn6JrPTPJTJ+wXZXzcZmtOXG\n' + - 'EKcwvPbbPY9wd+gavRSOgYLYn5xoZQW/o3hW7AQlbC5Kj6js48Z0HQ==\n' + - '=qLiJ\n' + - '-----END PGP SIGNATURE-----\n', + signature: '-----BEGIN PGP SIGNATURE-----\n' + '\n' + 'wsBzBAEBCAAnBQJjh5tjCRBaJmgmByp5FRYhBJC23yBJT2d/pTAID1omaCYH\n' + 'KnkVAAAZmwf/buPLw6caSZmYnw6D3/p6HF1kWlkGUOTP4RasaU/6dkeDaZs9\n' + 'SJlz2wC8oOpBGWHMJ/5n3ZWmU71E6U7IKIY793MyIv5t32vTNkwsRHUX7IIn\n' + 'QFF+FzTIEtHHVTRlnkqNR2YUk1kqcpZCZWHfahi5W2d/WkXlFNdvyyFH4W8L\n' + 'd03FGhOyXbWwU3xicBz5mSBpIFaaSCXl1SdgJDPXLSk3b65EEOjCOaiz85xC\n' + 'G+6SW4RUzCGSDcOd9F2EXvvY5H9LgQNi1jjlZn6JrPTPJTJ+wXZXzcZmtOXG\n' + 'EKcwvPbbPY9wd+gavRSOgYLYn5xoZQW/o3hW7AQlbC5Kj6js48Z0HQ==\n' + '=qLiJ\n' + '-----END PGP SIGNATURE-----\n', timestamp: 1669831523684, fromCAIP10: 'eip155:0x0F1AAC847B5720DDf01BFa07B7a8Ee641690816d', messageType: 'Text', messageContent: 'Hi', - encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + - '\n' + - 'wcBMA1fn1CNqxQ7nAQgArlo75qe54WerfRKFv1+F9j4NRMvSTgUztvIe51eg\n' + - 'd5MVuj6RYxKERr2bTuBt5cMDJMlNuTnBBkPe4L8+SlsI46L9wmXV9xLoZq1a\n' + - '94JdxD98RGMF99Jde/3hC/X6GS1yVqPpKPKdWx/tkOPeyqeO/wFF7kqShgIi\n' + - 'Wgq6hGz1fzD3GZhKGY0VSLuC3s0aUy/qw5En1Xd0uX0jdXBl07IIj8p1G2zx\n' + - '9BuVlksSK34yvIc0RQfCeRadMHkxbA0Hyj31Wrr+Y310YLTppL0s5bQR9APL\n' + - 'WHsIztJ1fHTnXsPhnA7YG0SQpHTyJhuX3rgBjxGrvbZBArmZ+R/Pq9IkOkJe\n' + - 'z8HATAMOsbaZjGN5JwEH/jYjLN6AFRWeaB5CSBSAF+CvHsUgadGmxTdSHBM6\n' + - 'LM9rfGg/MCnpRBuHckA0NNZh+wepq6TDA54ZopsdP14gHj4MKCdfqZr86Jft\n' + - 'ldtjeSgPTFEEJxPMJ4/Z3UeFU9rvOgfxX6l0eHWS0MYwJ3sVYvSyqqHir1K5\n' + - 'TRdEIgtQ3NvLTKkX4bKTSU+SInrvDA+wsc2BcBsbgNhRiGb+XYrbqXBshL1a\n' + - 'lIdpnomkAQgOZMO2n347uURYoruH3OtFeNABJ9D/nEU+LdhDOPGZPefvPBc5\n' + - 'BxK4ExKZ2Wo/TZw8lgC53uqOljsGV63Hp71LkyesKWu5/+vdVrYx/vU63shh\n' + - 'x/TSQAEiaFYEfkWSOthtH0nrJHhkY7FWgjp/1bj/J4J9HCQrVtt2WlQfhowZ\n' + - 'ILxhKk/vep0sJviM3SfJ4hPtoYpZESc=\n' + - '=43Ta\n' + - '-----END PGP MESSAGE-----\n' + encryptedSecret: '-----BEGIN PGP MESSAGE-----\n' + '\n' + 'wcBMA1fn1CNqxQ7nAQgArlo75qe54WerfRKFv1+F9j4NRMvSTgUztvIe51eg\n' + 'd5MVuj6RYxKERr2bTuBt5cMDJMlNuTnBBkPe4L8+SlsI46L9wmXV9xLoZq1a\n' + '94JdxD98RGMF99Jde/3hC/X6GS1yVqPpKPKdWx/tkOPeyqeO/wFF7kqShgIi\n' + 'Wgq6hGz1fzD3GZhKGY0VSLuC3s0aUy/qw5En1Xd0uX0jdXBl07IIj8p1G2zx\n' + '9BuVlksSK34yvIc0RQfCeRadMHkxbA0Hyj31Wrr+Y310YLTppL0s5bQR9APL\n' + 'WHsIztJ1fHTnXsPhnA7YG0SQpHTyJhuX3rgBjxGrvbZBArmZ+R/Pq9IkOkJe\n' + 'z8HATAMOsbaZjGN5JwEH/jYjLN6AFRWeaB5CSBSAF+CvHsUgadGmxTdSHBM6\n' + 'LM9rfGg/MCnpRBuHckA0NNZh+wepq6TDA54ZopsdP14gHj4MKCdfqZr86Jft\n' + 'ldtjeSgPTFEEJxPMJ4/Z3UeFU9rvOgfxX6l0eHWS0MYwJ3sVYvSyqqHir1K5\n' + 'TRdEIgtQ3NvLTKkX4bKTSU+SInrvDA+wsc2BcBsbgNhRiGb+XYrbqXBshL1a\n' + 'lIdpnomkAQgOZMO2n347uURYoruH3OtFeNABJ9D/nEU+LdhDOPGZPefvPBc5\n' + 'BxK4ExKZ2Wo/TZw8lgC53uqOljsGV63Hp71LkyesKWu5/+vdVrYx/vU63shh\n' + 'x/TSQAEiaFYEfkWSOthtH0nrJHhkY7FWgjp/1bj/J4J9HCQrVtt2WlQfhowZ\n' + 'ILxhKk/vep0sJviM3SfJ4hPtoYpZESc=\n' + '=43Ta\n' + '-----END PGP MESSAGE-----\n', }, { link: null, @@ -3563,61 +3388,75 @@ Allowed Options (params with * are mandatory) fromCAIP10: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', messageType: 'Text', messageContent: 'Hey Fabio!', - encryptedSecret: '' - } -] + encryptedSecret: '', + }, +]; ``` +
------ +--- ## For Video ### **Instance Variables** + #### **peerInstance** + - Used to store the simple peer instance used for the webRTC connection. + ```typescript private peerInstance: any = null; ``` ------ +--- #### **signer** + - Used to store the signer of a user. - Used in the request, acceptRequest and disconnect methods to send notifications. + ```typescript private signer: SignerType; ``` ------ +--- #### **chainId** + The chain id of the chain on which the call is being conducted. + ```typescript private chainId: number; ``` ------ +--- #### **pgpPrivateKey** + - Used to store the PGP private key of a user. - Used in the request, acceptRequest and disconnect methods to send notifications. + ```typescript private pgpPrivateKey: string; ``` ------ +--- #### **env** + - The environment on which the call is being conducted. + ```typescript private env: ENV; ``` ------ +--- ### **data** + - Stores data related to the video call. + ```typescript export type IMediaStream = MediaStream | null; @@ -3665,10 +3504,12 @@ export type VideoCallData = { private data: VideoCallData; ``` ------ +--- #### **setData** -- This function can be used to update the video call ```data``` + +- This function can be used to update the video call `data` + ```typescript setData: (fn: (data: VideoCallData) => VideoCallData) => void; @@ -3684,10 +3525,12 @@ setData((oldData) => { }); ``` ------ +--- ### **Methods** + #### **constructor** + ```typescript constructor({ signer, @@ -3704,20 +3547,22 @@ constructor({ }) {} ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| signer* | SignerType | - | signer object for a user | -| chainId* | number | - | chainId for the video call - Eth Mainnet: 1, Polygon Mainnet: 137 | -| pgpPrivatekey* | string | - | PGP private key of the user, used while sending video call notifications | -| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| -| setData* | ```(fn: (data: VideoCallData) => VideoCallData) => void``` | - | Function to update video call data | +| signer_ | SignerType | - | signer object for a user | +| chainId* | number | - | chainId for the video call - Eth Mainnet: 1, Polygon Mainnet: 137 | +| pgpPrivatekey* | string | - | PGP private key of the user, used while sending video call notifications | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +| setData\* | `(fn: (data: VideoCallData) => VideoCallData) => void` | - | Function to update video call data | ------ +--- #### **create** + - This method is used to create a local stream -- Assigns the local stream obtained from the ```navigator.mediaDevices.getUserMedia``` to `data.local.stream` state. +- Assigns the local stream obtained from the `navigator.mediaDevices.getUserMedia` to `data.local.stream` state. + ```typescript export type VideoCreateInputOptions = { video?: boolean; @@ -3727,19 +3572,21 @@ export type VideoCreateInputOptions = { async create(options: VideoCreateInputOptions): Promise {} ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with \* are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| video | boolean | true | video status for the local stream | -| audio | boolean | true | audio status for the local stream | +| video | boolean | true | video status for the local stream | +| audio | boolean | true | audio status for the local stream | Note - If audio, video aren't enabled in create() then they wont be available during the call respectively. ------ +--- #### **request** + - This method is used to request a push video call. - Will be triggered on the initiator's end. + ```typescript export type VideoRequestInputOptions = { senderAddress: string; @@ -3752,21 +3599,22 @@ export type VideoRequestInputOptions = { async request(options: VideoRequestInputOptions): Promise {} ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| senderAddress* | string | - | Local peer address | -| recipientAddress* | string | - | Incoming/remote peer address | -| chatId* | string | - | Unique identifier for every wallet-to-wallet push chat, will be used during verification proof generation | -| onReceiveMessage | ```(message: string) => void``` | ```(message: string) => {console.log('received a meesage', message);}``` | Function which will be called when the sender receives a message via webRTC data channel | +| senderAddress_ | string | - | Local peer address | +| recipientAddress* | string | - | Incoming/remote peer address | +| chatId* | string | - | Unique identifier for every wallet-to-wallet push chat, will be used during verification proof generation | +| onReceiveMessage | `(message: string) => void` | `(message: string) => {console.log('received a meesage', message);}` | Function which will be called when the sender receives a message via webRTC data channel | | retry | boolean | false | If we are retrying the call, only for internal use | - ------ +--- #### **acceptRequest** + - This method is used to accept a push video call. - Will be triggered on the receiver's end. + ```typescript export type VideoAcceptRequestInputOptions = { signalData: any; @@ -3780,21 +3628,23 @@ export type VideoAcceptRequestInputOptions = { async acceptRequest(options: VideoAcceptRequestInputOptions): Promise {} ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| signalData* | any | - | Signal data received from the initiator peer via psuh notification upon call request | -| senderAddress* | string | - | Local peer address | -| recipientAddress* | string | - | Incoming/remote peer address | -| chatId* | string | - | Unique identifier for every wallet-to-wallet push chat, will be used during verification proof generation | -| onReceiveMessage | ```(message: string) => void``` | ```(message: string) => {console.log('received a meesage', message);}``` | Function which will be called when the sender receives a message via webRTC data channel | +| signalData_ | any | - | Signal data received from the initiator peer via psuh notification upon call request | +| senderAddress* | string | - | Local peer address | +| recipientAddress* | string | - | Incoming/remote peer address | +| chatId\* | string | - | Unique identifier for every wallet-to-wallet push chat, will be used during verification proof generation | +| onReceiveMessage | `(message: string) => void` | `(message: string) => {console.log('received a meesage', message);}` | Function which will be called when the sender receives a message via webRTC data channel | | retry | boolean | false | If we are retrying the call, only for internal use | ------ +--- #### **connect** + - This is the final method which is used to connect a push video call. - Will be triggered on the initiator's end. + ```typescript export type VideoConnectInputOptions = { signalData: any; @@ -3803,71 +3653,82 @@ export type VideoConnectInputOptions = { connect(options: VideoConnectInputOptions): void {} ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| -| signalData* | any | - | Signal data received from the receiver peer via push notification upon call acceptRequest | +| signalData_ | any | - | Signal data received from the receiver peer via push notification upon call acceptRequest | ------ +--- #### **disconnect** + - This method is used to end a push video call. - Can be triggered on the initiator as well as receivers end. + ```typescript disconnect(): void {} ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with \* are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| | - | - | - | - | ------ +--- #### **enableVideo** -- This method is used to enable/disable the video (from ```data.local.stream```) for a push video call. + +- This method is used to enable/disable the video (from `data.local.stream`) for a push video call. - Can be triggered on the initiator as well as receivers end. -- **Note -** If video was not enabled during ```create()``` then it will always remain off. + <<<<<<< HEAD +- # **Note -** If video was not enabled during `create()` then it will always remain off. +- **Note -** If video was not enabled during `create()` then it will always remain off. + > > > > > > > main ```typescript export type EnableVideoInputOptions = { state: boolean; } - + enableVideo(options: EnableVideoInputOptions): void ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with \* are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| | state | boolean | - | true for enable and false for disable | ------ +--- #### **enableAudio** -- This method is used to enable/disable the audio (from ```data.local.stream```) for a push video call. + +- This method is used to enable/disable the audio (from `data.local.stream`) for a push video call. - Can be triggered on the initiator as well as receivers end. -- **Note -** If audio was not enabled during ```create()``` then it will always remain off. + <<<<<<< HEAD +- # **Note -** If audio was not enabled during `create()` then it will always remain off. +- **Note -** If audio was not enabled during `create()` then it will always remain off. + > > > > > > > main ```typescript export type EnableAudioInputOptions = { state: boolean; -} - +} + enableAudio(options: EnableAudioInputOptions): void ``` -Allowed Options (params with * are mandatory) -| Param | Type | Default | Remarks | +Allowed Options (params with \* are mandatory) +| Param | Type | Default | Remarks | |----------|---------|---------|--------------------------------------------| | state | boolean | - | true for enable and false for disable | ------ +--- #### **isInitiator** + - This method is used to tell if the current peer is the initator of the push video call or not. - Can be triggered on the initiator as well as receivers end. ```typescript isInitiator(): boolean -``` \ No newline at end of file +``` diff --git a/packages/restapi/src/lib/chat/helpers/crypto.ts b/packages/restapi/src/lib/chat/helpers/crypto.ts index 2e04ad277..a62037d3e 100644 --- a/packages/restapi/src/lib/chat/helpers/crypto.ts +++ b/packages/restapi/src/lib/chat/helpers/crypto.ts @@ -194,9 +194,6 @@ export const getEncryptedRequest = async ( user: receiverAddress, publicKey: '', encryptedPrivateKey: '', - encryptionType: '', - signature: 'pgp', - sigType: 'pgp', env, }); // If the user is being created here, that means that user don't have a PGP keys. So this intent will be in plaintext diff --git a/packages/restapi/src/lib/chat/helpers/service.ts b/packages/restapi/src/lib/chat/helpers/service.ts index 150512c2d..e0f5863a2 100644 --- a/packages/restapi/src/lib/chat/helpers/service.ts +++ b/packages/restapi/src/lib/chat/helpers/service.ts @@ -14,18 +14,13 @@ import { walletType, } from '../../types'; import { getEip191Signature } from './crypto'; +import { populateDeprecatedUser } from '../../utils/populateIUser'; type CreateUserOptionsType = { user: string; wallet?: walletType; - name?: string; - nftOwner?: string | null; - encryptedPassword?: string | null; publicKey?: string; encryptedPrivateKey?: string; - encryptionType?: string; - signature?: string; - sigType?: string; env?: ENV; }; @@ -34,16 +29,13 @@ export const createUserService = async (options: CreateUserOptionsType) => { wallet, publicKey = '', encryptedPrivateKey = '', - encryptionType = '', env = Constants.ENV.PROD, - encryptedPassword = null, - nftOwner = null, } = options || {}; let { user } = options || {}; const API_BASE_URL = getAPIBaseUrls(env); - const requestUrl = `${API_BASE_URL}/v1/users/`; + const requestUrl = `${API_BASE_URL}/v2/users/`; if (isValidCAIP10NFTAddress(user)) { const epoch = Math.floor(Date.now() / 1000); @@ -56,33 +48,14 @@ export const createUserService = async (options: CreateUserOptionsType) => { did: walletToPCAIP10(user), publicKey, encryptedPrivateKey, - - // DEPRECATED in eip191v2 - - // encryptionType, - // name: '', - // encryptedPassword: encryptedPassword, - // nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, }; const hash = generateHash(data); const signatureObj = await getEip191Signature(wallet!, hash, 'v2'); - // NOTE - To be removed after backend route changes - const updatedData = { - caip10: walletToPCAIP10(user), - did: walletToPCAIP10(user), - publicKey, - encryptedPrivateKey, - encryptionType, - name: '', - encryptedPassword: encryptedPassword, - nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, - }; - const body = { - ...updatedData, + ...data, ...signatureObj, }; @@ -91,12 +64,11 @@ export const createUserService = async (options: CreateUserOptionsType) => { .then((response) => { if (response.data) response.data.publicKey = verifyPGPPublicKey( - response.data.encryptionType, + response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did, - response.data.nftOwner + response.data.did ); - return response.data; + return populateDeprecatedUser(response.data); }) .catch((err) => { console.error(`[Push SDK] - API ${requestUrl}: `, err); @@ -110,62 +82,37 @@ export const authUpdateUserService = async (options: CreateUserOptionsType) => { wallet, publicKey = '', encryptedPrivateKey = '', - encryptionType = '', - name = '', - encryptedPassword = null, - nftOwner = null, env = Constants.ENV.PROD, } = options || {}; const API_BASE_URL = getAPIBaseUrls(env); - const requestUrl = `${API_BASE_URL}/v1/users/${walletToPCAIP10(user)}/auth`; + const requestUrl = `${API_BASE_URL}/v2/users/${walletToPCAIP10(user)}/auth`; const data = { caip10: walletToPCAIP10(user), did: walletToPCAIP10(user), publicKey, encryptedPrivateKey, - - // DEPRECATED in eip191v2 - - // encryptionType, - // name, - // encryptedPassword, - // nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, }; const hash = generateHash(data); const signatureObj = await getEip191Signature(wallet!, hash, 'v2'); - // NOTE - To be removed after backend route changes - const updatedData = { - caip10: walletToPCAIP10(user), - publicKey, - encryptedPrivateKey, - encryptionType, - name, - encryptedPassword, - nftOwner: nftOwner ? nftOwner.toLowerCase() : nftOwner, - }; - - const body = { - ...updatedData, - ...signatureObj, - }; + // Exclude the "did" property from the "body" object + const { did, ...body } = { ...data, ...signatureObj }; return axios .put(requestUrl, body) .then((response) => { if (response.data) response.data.publicKey = verifyPGPPublicKey( - response.data.encryptionType, + response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did, - response.data.nftOwner + response.data.did ); - return response.data; + return populateDeprecatedUser(response.data); }) .catch((err) => { console.error(`[Push SDK] - API ${requestUrl}: `, err); diff --git a/packages/restapi/src/lib/chat/helpers/signature.ts b/packages/restapi/src/lib/chat/helpers/signature.ts index 064b36c5e..96371baa0 100644 --- a/packages/restapi/src/lib/chat/helpers/signature.ts +++ b/packages/restapi/src/lib/chat/helpers/signature.ts @@ -85,8 +85,7 @@ export const getTypedData = ( export const verifyProfileSignature = ( verificationProof: string, signedData: string, - address: string, - nftOwner: string + address: string ): boolean => { const SIG_TYPE_V2 = 'eip712v2'; const SIG_TYPE_V3 = 'eip191'; @@ -138,10 +137,7 @@ export const verifyProfileSignature = ( hashMessage(signedData), signature ); - if ( - recoveredAddress.toLowerCase() === address.toLowerCase() || - recoveredAddress.toLowerCase() === nftOwner.toLowerCase() - ) { + if (recoveredAddress.toLowerCase() === address.toLowerCase()) { return true; } else return false; } diff --git a/packages/restapi/src/lib/helpers/crypto.ts b/packages/restapi/src/lib/helpers/crypto.ts index 6d04cc5c8..6c6aef706 100644 --- a/packages/restapi/src/lib/helpers/crypto.ts +++ b/packages/restapi/src/lib/helpers/crypto.ts @@ -23,7 +23,11 @@ import { IMessageIPFS, ProgressHookType, } from '../types'; -import { isValidETHAddress, pCAIP10ToWallet } from './address'; +import { + isValidCAIP10NFTAddress, + isValidETHAddress, + pCAIP10ToWallet, +} from './address'; import { verifyProfileSignature } from '../chat/helpers/signature'; import { upgrade } from '../user/upgradeUser'; @@ -575,30 +579,35 @@ export const preparePGPPublicKey = async ( }; export const verifyPGPPublicKey = ( - encryptionType: string, + encryptedPrivateKey: string, publicKey: string, - did: string, - nftOwner: string + did: string ): string => { - if (encryptionType && encryptionType !== Constants.ENC_TYPE_V1) { - const { key, signature: verificationProof } = JSON.parse(publicKey); - publicKey = key; - let signedData: string; - if (encryptionType === Constants.ENC_TYPE_V2) - signedData = 'Create Push Chat Profile \n' + generateHash(key); - else signedData = 'Create Push Profile \n' + generateHash(key); - if ( - verifyProfileSignature( - verificationProof, - signedData, - pCAIP10ToWallet(did), - nftOwner ? pCAIP10ToWallet(nftOwner) : nftOwner + try { + if (publicKey !== '' && publicKey.includes('signature')) { + const { key, signature: verificationProof } = JSON.parse(publicKey); + publicKey = key; + let signedData: string; + if (verificationProof.includes('eip712')) + signedData = 'Create Push Chat Profile \n' + generateHash(key); + else signedData = 'Create Push Profile \n' + generateHash(key); + if ( + verifyProfileSignature( + verificationProof, + signedData, + isValidCAIP10NFTAddress(did) + ? pCAIP10ToWallet(JSON.parse(encryptedPrivateKey).owner) + : pCAIP10ToWallet(did) + ) ) - ) - return publicKey; - else throw new Error('Cannot verify Encryption Keys for this user'); + return publicKey; + else throw new Error('Cannot Verify this publicKey Owner!!!'); + } + return publicKey; + } catch (err) { + console.warn('Cannot Verify this publicKey Owner!!!'); + return publicKey; } - return publicKey; }; export const validatePssword = (password: string) => { diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index a0cf03047..f95ae8394 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -169,21 +169,67 @@ export interface IFeeds { deprecatedCode?: string; // scope only at sdk level } export interface IUser { + msgSent: number; + maxMsgPersisted: number; did: string; wallets: string; - profilePicture: string | null; - publicKey: string; + profile: { + name: string | null; + desc: string | null; + picture: string | null; + profileVerificationProof: string | null; + }; encryptedPrivateKey: string; + publicKey: string; + verificationProof: string; + + /** + * @deprecated Use `profile.name` instead. + */ + name: string | null; + /** + * @deprecated Use `profile.desc` instead. + */ + about: string | null; + /** + * @deprecated Use `profile.picture` instead. + */ + profilePicture: string | null; + /** + * @deprecated Use `msgSent` instead. + */ + numMsg: number; + /** + * @deprecated Use `maxMsgPersisted` instead. + */ + allowedNumMsg: number; + /** + * @deprecated Use `encryptedPrivateKey.version` instead. + */ encryptionType: string; + /** + * @deprecated Use `verificationProof` instead. + */ signature: string; + /** + * @deprecated Use `verificationProof` instead. + */ sigType: string; - about: string | null; - name: string | null; + /** + * @deprecated Use `encryptedPrivateKey.encryptedPassword` instead. + */ encryptedPassword: string | null; + /** + * @deprecated + */ nftOwner: string | null; - numMsg: number; - allowedNumMsg: number; + /** + * @deprecated Not recommended to be used anywhere + */ linkedListHash?: string | null; + /** + * @deprecated Not recommended to be used anywhere + */ nfts?: [] | null; } diff --git a/packages/restapi/src/lib/user/auth.updateUser.ts b/packages/restapi/src/lib/user/auth.updateUser.ts index 9e8d564e5..c94679a7a 100644 --- a/packages/restapi/src/lib/user/auth.updateUser.ts +++ b/packages/restapi/src/lib/user/auth.updateUser.ts @@ -133,15 +133,8 @@ export const update = async (options: AuthUpdateProps): Promise => { const body = { user: user.did, wallet, - name: user.name ? user.name : '', - encryptedPassword: null, - nftOwner: - pgpEncryptionVersion === ENCRYPTION_TYPE.NFTPGP_V1 - ? walletToPCAIP10((await signer?.getAddress()) as string) - : null, // check for nft, publicKey: signedPublicKey, encryptedPrivateKey: JSON.stringify(encryptedPgpPrivateKey), - encryptionType: pgpEncryptionVersion, env, }; diff --git a/packages/restapi/src/lib/user/createUser.ts b/packages/restapi/src/lib/user/createUser.ts index b3256ed00..1681c7758 100644 --- a/packages/restapi/src/lib/user/createUser.ts +++ b/packages/restapi/src/lib/user/createUser.ts @@ -131,12 +131,7 @@ export const create = async (options: CreateUserProps): Promise => { wallet, publicKey: publicKey, encryptedPrivateKey: JSON.stringify(encryptedPrivateKey), - encryptionType: encryptionType, env, - nftOwner: - encryptionType === Constants.ENC_TYPE_V4 - ? walletToPCAIP10((await signer?.getAddress()) as string) - : null, // check for nft }; // Report Progress diff --git a/packages/restapi/src/lib/user/getUser.ts b/packages/restapi/src/lib/user/getUser.ts index 7bf82296d..67dfefd9b 100644 --- a/packages/restapi/src/lib/user/getUser.ts +++ b/packages/restapi/src/lib/user/getUser.ts @@ -3,6 +3,7 @@ import { AccountEnvOptionsType, IUser } from '../types'; import { isValidETHAddress, walletToPCAIP10 } from '../helpers/address'; import { getAPIBaseUrls, verifyPGPPublicKey } from '../helpers'; import Constants from '../constants'; +import { populateDeprecatedUser } from '../utils/populateIUser'; export const get = async (options: AccountEnvOptionsType): Promise => { const { account, env = Constants.ENV.PROD } = options || {}; @@ -11,18 +12,18 @@ export const get = async (options: AccountEnvOptionsType): Promise => { } const caip10 = walletToPCAIP10(account); const API_BASE_URL = getAPIBaseUrls(env); - const requestUrl = `${API_BASE_URL}/v1/users/?caip10=${caip10}`; + const requestUrl = `${API_BASE_URL}/v2/users/?caip10=${caip10}`; return axios .get(requestUrl) .then((response) => { - if (response.data) + if (response.data) { response.data.publicKey = verifyPGPPublicKey( - response.data.encryptionType, + response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did, - response.data.nftOwner + response.data.did ); - return response.data; + } + return populateDeprecatedUser(response.data); }) .catch((err) => { console.error(`[Push SDK] - API ${requestUrl}: `, err); diff --git a/packages/restapi/src/lib/user/getUsersBatch.ts b/packages/restapi/src/lib/user/getUsersBatch.ts index 976402832..8997ca348 100644 --- a/packages/restapi/src/lib/user/getUsersBatch.ts +++ b/packages/restapi/src/lib/user/getUsersBatch.ts @@ -3,6 +3,7 @@ import { IUser } from '../types'; import { isValidETHAddress, walletToPCAIP10 } from '../helpers/address'; import { getAPIBaseUrls, verifyPGPPublicKey } from '../helpers'; import Constants, { ENV } from '../constants'; +import { populateDeprecatedUser } from '../utils/populateIUser'; export interface GetBatchType { userIds: string[]; @@ -13,7 +14,7 @@ export const getBatch = async (options: GetBatchType): Promise => { const { env = Constants.ENV.PROD, userIds } = options || {}; const API_BASE_URL = getAPIBaseUrls(env); - const requestUrl = `${API_BASE_URL}/v1/users/batch`; + const requestUrl = `${API_BASE_URL}/v2/users/batch`; const MAX_USER_IDS_LENGTH = 100; if (userIds.length > MAX_USER_IDS_LENGTH) { @@ -36,10 +37,13 @@ export const getBatch = async (options: GetBatchType): Promise => { .then((response) => { response.data.users.forEach((user: any, index: number) => { response.data.users[index].publicKey = verifyPGPPublicKey( - user.encryptionType, + user.encryptedPrivateKey, user.publicKey, - user.did, - user.nftOwner + user.did + ); + + response.data.users[index] = populateDeprecatedUser( + response.data.users[index] ); }); return response.data; diff --git a/packages/restapi/src/lib/user/upgradeUser.ts b/packages/restapi/src/lib/user/upgradeUser.ts index 94e7da209..f4a8d9cf3 100644 --- a/packages/restapi/src/lib/user/upgradeUser.ts +++ b/packages/restapi/src/lib/user/upgradeUser.ts @@ -46,10 +46,11 @@ export const upgrade = async (options: UpgradeUserProps): Promise => { } const recommendedPgpEncryptionVersion = Constants.ENCRYPTION_TYPE.PGP_V3; + const { version } = JSON.parse(user.encryptedPrivateKey); if ( - user.encryptionType === recommendedPgpEncryptionVersion || - user.encryptionType === Constants.ENCRYPTION_TYPE.NFTPGP_V1 + version === recommendedPgpEncryptionVersion || + version === Constants.ENCRYPTION_TYPE.NFTPGP_V1 ) { return user; } diff --git a/packages/restapi/src/lib/utils/populateIUser.ts b/packages/restapi/src/lib/utils/populateIUser.ts new file mode 100644 index 000000000..e8cfe6886 --- /dev/null +++ b/packages/restapi/src/lib/utils/populateIUser.ts @@ -0,0 +1,39 @@ +import { IUser } from '../types'; + +/** + * To be removed in v2 verisons of sdk + * @param user + * @returns User with deprecated params + */ +export const populateDeprecatedUser = (user: IUser): IUser => { + if (!user) return user; + user.name = user.profile.name; + user.about = user.profile.desc; + user.profilePicture = user.profile.picture; + user.numMsg = user.msgSent; + user.allowedNumMsg = user.maxMsgPersisted; + let encryptionType = ''; + let sigType = ''; + let signature = ''; + try { + const { version } = JSON.parse(user.encryptedPrivateKey); + encryptionType = version; + } catch (err) { + //ignore since no encryption found + } + user.encryptionType = encryptionType; + try { + sigType = user.verificationProof.split(':')[0]; + signature = user.verificationProof.split(':')[1]; + } catch (err) { + //ignore since no verification proof found + } + user.signature = signature; + user.sigType = sigType; + user.encryptedPassword = null; + //TODO FOR NFT PROFILE + user.nftOwner = null; + user.linkedListHash = null; + user.nfts = null; + return user; +}; diff --git a/packages/restapi/tests/lib/user/createUser.test.ts b/packages/restapi/tests/lib/user/createUser.test.ts index 0419a09a2..ade9220be 100644 --- a/packages/restapi/tests/lib/user/createUser.test.ts +++ b/packages/restapi/tests/lib/user/createUser.test.ts @@ -55,13 +55,11 @@ describe('Create Push Profile', () => { expect(user.encryptedPrivateKey).to.contains( `"version":"${Constants.ENC_TYPE_V1}"` ); - expect(user.encryptionType).to.be.equal(Constants.ENC_TYPE_V1); - expect(user.encryptedPassword).to.be.null; - expect(user.nftOwner).to.be.null; - expect(user.profilePicture).to.contains('data:image/png;base64,'); - expect(user.about).to.be.null; - expect(user.name).to.be.null; - expect(user.numMsg).to.be.equal(0); + expect(user.profile.name).to.be.null; + expect(user.profile.desc).to.be.null; + expect(user.profile.picture).to.contains('data:image/png;base64,'); + + expect(user.msgSent).to.be.equal(0); }); it('Push Profile V3', async () => { const user = await create({ @@ -80,13 +78,10 @@ describe('Create Push Profile', () => { expect(user.encryptedPrivateKey).to.contains( `"version":"${Constants.ENC_TYPE_V3}"` ); - expect(user.encryptionType).to.be.equal(Constants.ENC_TYPE_V3); - expect(user.encryptedPassword).to.be.null; - expect(user.nftOwner).to.be.null; - expect(user.profilePicture).to.contains('data:image/png;base64,'); - expect(user.about).to.be.null; - expect(user.name).to.be.null; - expect(user.numMsg).to.be.equal(0); + expect(user.profile.name).to.be.null; + expect(user.profile.desc).to.be.null; + expect(user.profile.picture).to.contains('data:image/png;base64,'); + expect(user.msgSent).to.be.equal(0); }); it('Push Profile V4 ( NFT Profile )', async () => { const user = await create({ @@ -105,12 +100,10 @@ describe('Create Push Profile', () => { expect(user.encryptedPrivateKey).to.contains( `"version":"${Constants.ENC_TYPE_V4}"` ); - expect(user.encryptionType).to.be.equal(Constants.ENC_TYPE_V4); - expect(user.encryptedPassword).to.be.null; - expect(user.nftOwner).to.be.equal('eip155:' + _nftWalletAddress1); - expect(user.profilePicture).to.contains('data:image/png;base64,'); - expect(user.about).to.be.null; - expect(user.name).to.be.null; - expect(user.numMsg).to.be.equal(0); + expect(user.profile.name).to.be.null; + expect(user.profile.desc).to.be.null; + expect(user.profile.picture).to.contains('data:image/png;base64,'); + + expect(user.msgSent).to.be.equal(0); }); }); diff --git a/packages/restapi/tests/lib/user/getUser.test.ts b/packages/restapi/tests/lib/user/getUser.test.ts index bcd5c458c..ca8fcbd9a 100644 --- a/packages/restapi/tests/lib/user/getUser.test.ts +++ b/packages/restapi/tests/lib/user/getUser.test.ts @@ -52,6 +52,6 @@ describe('Get user', () => { value.includes(`"version":"${Constants.ENC_TYPE_V3}"`) ); }); - expect(user.profilePicture).to.contains('data:image/png;base64,'); + expect(user.profile.picture).to.contains('data:image/png;base64,'); }); }); diff --git a/packages/restapi/tests/lib/user/upgradeUser.test.ts b/packages/restapi/tests/lib/user/upgradeUser.test.ts index e71ce18a9..1648f369d 100644 --- a/packages/restapi/tests/lib/user/upgradeUser.test.ts +++ b/packages/restapi/tests/lib/user/upgradeUser.test.ts @@ -47,12 +47,10 @@ describe('Upgrade user keys', () => { expect(upgradedUser.encryptedPrivateKey).to.contains( `"version":"${upgradationVersion}"` ); - expect(upgradedUser.encryptionType).to.be.equal(upgradationVersion); - expect(user.encryptedPassword).to.be.equal(upgradedUser.encryptedPassword); - expect(user.nftOwner).to.be.equal(upgradedUser.nftOwner); - expect(user.profilePicture).to.be.equal(upgradedUser.profilePicture); - expect(user.about).to.be.equal(upgradedUser.about); - expect(user.name).to.be.equal(upgradedUser.name); + + expect(user.profile.picture).to.be.equal(upgradedUser.profile.picture); + expect(user.profile.desc).to.be.equal(upgradedUser.profile.desc); + expect(user.profile.name).to.be.equal(upgradedUser.profile.name); const userPrivatePGPKey = await decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer, @@ -87,12 +85,10 @@ describe('Upgrade user keys', () => { expect(upgradedUser.encryptedPrivateKey).to.contains( `"version":"${upgradationVersion}"` ); - expect(upgradedUser.encryptionType).to.be.equal(upgradationVersion); - expect(user.encryptedPassword).to.be.equal(upgradedUser.encryptedPassword); - expect(user.nftOwner).to.be.equal(upgradedUser.nftOwner); - expect(user.profilePicture).to.be.equal(upgradedUser.profilePicture); - expect(user.about).to.be.equal(upgradedUser.about); - expect(user.name).to.be.equal(upgradedUser.name); + + expect(user.profile.picture).to.be.equal(upgradedUser.profile.picture); + expect(user.profile.desc).to.be.equal(upgradedUser.profile.desc); + expect(user.profile.name).to.be.equal(upgradedUser.profile.name); const userPrivatePGPKey = await decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer, @@ -117,7 +113,6 @@ describe('Upgrade user keys', () => { expect(createdUser.encryptedPrivateKey).to.contains( `"version":"${Constants.ENC_TYPE_V1}"` ); - expect(createdUser.encryptionType).to.be.equal(Constants.ENC_TYPE_V1); const userPrivatePGPKey = await decryptPGPKey({ encryptedPGPPrivateKey: createdUser.encryptedPrivateKey, signer: _signer, @@ -128,7 +123,6 @@ describe('Upgrade user keys', () => { expect(user.encryptedPrivateKey).to.contains( `"version":"${upgradationVersion}"` ); - expect(user.encryptionType).to.be.equal(upgradationVersion); const upgradedPrivatePGPKey = await decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer, diff --git a/packages/uiweb/src/lib/components/chat/AddressInfo.tsx b/packages/uiweb/src/lib/components/chat/AddressInfo.tsx index 4034e6125..4ef2bd8ac 100644 --- a/packages/uiweb/src/lib/components/chat/AddressInfo.tsx +++ b/packages/uiweb/src/lib/components/chat/AddressInfo.tsx @@ -27,8 +27,8 @@ export const AddressInfo: React.FC = () => { address profile {
)} {isCopied && ( -
setIsCopied(false)}> +
setIsCopied(false)}> props.theme.textColorPrimary || '#000'}; `; - From fe852e21d456b694cd7f52544ef7fd0d988a4826 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Mon, 29 May 2023 13:38:25 +0530 Subject: [PATCH 115/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.15?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 32fe0da37..b063c8a70 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.14...restapi-0.0.1-alpha.15) (2023-05-29) + + +### Bug Fixes + +* Iuser structure changed ([#365](https://github.com/ethereum-push-notification-service/push-sdk/issues/365)) ([2fc6f54](https://github.com/ethereum-push-notification-service/push-sdk/commit/2fc6f549c80a65a5a6009b0c2fa9635d757bdf11)), closes [#390](https://github.com/ethereum-push-notification-service/push-sdk/issues/390) [#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295) +* Merge branch 'alpha' into alpha-deployment ([a66c9a4](https://github.com/ethereum-push-notification-service/push-sdk/commit/a66c9a4a3628700a450b8e2fb7a5f942d1d84095)) +* merged main to alpha ([067bc5d](https://github.com/ethereum-push-notification-service/push-sdk/commit/067bc5d358c5f218628a980ce23ab3b39615805f)) +* removed undocumented fn ([#419](https://github.com/ethereum-push-notification-service/push-sdk/issues/419)) ([3fff974](https://github.com/ethereum-push-notification-service/push-sdk/commit/3fff974b1e2cfa3499439a246be190aaad2907e3)) + + + ## [0.0.1-alpha.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.13...restapi-0.0.1-alpha.14) (2023-05-22) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index a21a6fc2e..dcbf702f6 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.14", + "version": "0.0.1-alpha.15", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ef769b280e3ec0a0dd04e115b4361cfe0df79508 Mon Sep 17 00:00:00 2001 From: Shoaib Mohammed Date: Wed, 31 May 2023 13:16:10 +0530 Subject: [PATCH 116/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index a3c332e6e..426ff45e6 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.2...restapi-1.3.3) (2023-05-31) + + +### Bug Fixes + +* add profile.update feature ([#410](https://github.com/ethereum-push-notification-service/push-sdk/issues/410)) ([361b930](https://github.com/ethereum-push-notification-service/push-sdk/commit/361b9303c5340238bcb7fa457370707ae864756b)) +* Merge branch 'main' into deployment ([59715aa](https://github.com/ethereum-push-notification-service/push-sdk/commit/59715aa307c0931e86476c18f78d495bc0de891f)) +* Merge branch 'main' into deployment ([1d52d6b](https://github.com/ethereum-push-notification-service/push-sdk/commit/1d52d6ba5aaadd70d7ccfd3904100586ad74d0f0)) +* removed undocumented fn ([#419](https://github.com/ethereum-push-notification-service/push-sdk/issues/419)) ([3fff974](https://github.com/ethereum-push-notification-service/push-sdk/commit/3fff974b1e2cfa3499439a246be190aaad2907e3)) + + + ## [1.3.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.1...restapi-1.3.2) (2023-05-23) ### Bug Fixes diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 6ce3329d6..cc93dfbfe 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.2", + "version": "1.3.3", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From aea015ae478da77ebaa41a4e111ac213027b0b6a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 2 Jun 2023 14:50:00 +0530 Subject: [PATCH 117/298] fix: add spaces for functions (#307) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix --- .../src/app/ChatTest/AddAdminsToGroupTest.tsx | 106 + .../app/ChatTest/AddMembersToGroupTest.tsx | 108 + .../demoreact/src/app/ChatTest/ChatTest.tsx | 12 + .../ChatTest/RemoveAdminsFromGroupTest.tsx | 106 + .../ChatTest/RemoveMembersFromGroupTest.tsx | 92 + packages/demoreact/src/app/ChatTest/helper.ts | 19 + .../app/SpaceTest/AddAdminsToSpaceTest.tsx | 106 + .../app/SpaceTest/AddMembersToSpaceTest.tsx | 104 + .../app/SpaceTest/ApproveSpaceRequestTest.tsx | 101 + .../src/app/SpaceTest/CreateSpaceTest.tsx | 300 ++ .../src/app/SpaceTest/GetSpaceInfoTest.tsx | 78 + .../src/app/SpaceTest/GetSpaceTest.tsx | 78 + .../app/SpaceTest/GetSpacesRequestsTest.tsx | 132 + .../src/app/SpaceTest/GetSpacesTest.tsx | 132 + .../app/SpaceTest/GetSpacesTrendingTest.tsx | 105 + .../SpaceTest/RemoveAdminsFromSpaceTest.tsx | 105 + .../SpaceTest/RemoveMembersFromSpaceTest.tsx | 108 + .../demoreact/src/app/SpaceTest/SpaceTest.tsx | 79 + .../src/app/SpaceTest/StartSpaceTest.tsx | 91 + .../src/app/SpaceTest/StopSpaceTest.tsx | 93 + .../src/app/SpaceTest/UpdateSpaceTest.tsx | 232 ++ packages/demoreact/src/app/app.tsx | 45 + packages/package-lock.json | 6 + packages/restapi/README.md | 122 +- packages/restapi/package-lock.json | 519 ++- .../restapi/src/lib/chat/addAdminsToGroup.ts | 103 + .../restapi/src/lib/chat/addMembersToGroup.ts | 101 + .../restapi/src/lib/chat/approveRequest.ts | 7 +- packages/restapi/src/lib/chat/createGroup.ts | 22 +- .../restapi/src/lib/chat/helpers/inbox.ts | 99 +- .../src/lib/chat/helpers/payloadHelper.ts | 104 +- .../restapi/src/lib/chat/helpers/validator.ts | 89 +- packages/restapi/src/lib/chat/index.ts | 4 + .../src/lib/chat/removeAdminsFromGroup.ts | 111 + .../src/lib/chat/removeMembersFromGroup.ts | 97 + packages/restapi/src/lib/chat/send.ts | 1 + packages/restapi/src/lib/chat/start.ts | 6 +- packages/restapi/src/lib/chat/updateGroup.ts | 27 +- packages/restapi/src/lib/index.ts | 2 + .../restapi/src/lib/space/addAdminsToSpace.ts | 34 + .../src/lib/space/addMembersToSpace.ts | 49 + packages/restapi/src/lib/space/approve.ts | 58 + packages/restapi/src/lib/space/create.ts | 86 + packages/restapi/src/lib/space/get.ts | 39 + packages/restapi/src/lib/space/index.ts | 15 + packages/restapi/src/lib/space/info.ts | 33 + .../src/lib/space/removeAdminsFromSpace.ts | 52 + .../src/lib/space/removeMembersFromSpace.ts | 49 + packages/restapi/src/lib/space/requests.ts | 65 + packages/restapi/src/lib/space/spaces.ts | 62 + packages/restapi/src/lib/space/start.ts | 83 + packages/restapi/src/lib/space/stop.ts | 83 + packages/restapi/src/lib/space/trending.ts | 47 + packages/restapi/src/lib/space/update.ts | 78 + packages/restapi/src/lib/types/index.ts | 57 +- packages/restapi/yarn.lock | 2923 ++++++++++------- 56 files changed, 6094 insertions(+), 1471 deletions(-) create mode 100644 packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx create mode 100644 packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx create mode 100644 packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx create mode 100644 packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx create mode 100644 packages/demoreact/src/app/ChatTest/helper.ts create mode 100644 packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/ApproveSpaceRequestTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/GetSpaceInfoTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/GetSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/GetSpacesRequestsTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/GetSpacesTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/GetSpacesTrendingTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/SpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx create mode 100644 packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx create mode 100644 packages/package-lock.json create mode 100644 packages/restapi/src/lib/chat/addAdminsToGroup.ts create mode 100644 packages/restapi/src/lib/chat/addMembersToGroup.ts create mode 100644 packages/restapi/src/lib/chat/removeAdminsFromGroup.ts create mode 100644 packages/restapi/src/lib/chat/removeMembersFromGroup.ts create mode 100644 packages/restapi/src/lib/space/addAdminsToSpace.ts create mode 100644 packages/restapi/src/lib/space/addMembersToSpace.ts create mode 100644 packages/restapi/src/lib/space/approve.ts create mode 100644 packages/restapi/src/lib/space/create.ts create mode 100644 packages/restapi/src/lib/space/get.ts create mode 100644 packages/restapi/src/lib/space/index.ts create mode 100644 packages/restapi/src/lib/space/info.ts create mode 100644 packages/restapi/src/lib/space/removeAdminsFromSpace.ts create mode 100644 packages/restapi/src/lib/space/removeMembersFromSpace.ts create mode 100644 packages/restapi/src/lib/space/requests.ts create mode 100644 packages/restapi/src/lib/space/spaces.ts create mode 100644 packages/restapi/src/lib/space/start.ts create mode 100644 packages/restapi/src/lib/space/stop.ts create mode 100644 packages/restapi/src/lib/space/trending.ts create mode 100644 packages/restapi/src/lib/space/update.ts diff --git a/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx b/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx new file mode 100644 index 000000000..3bb109652 --- /dev/null +++ b/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx @@ -0,0 +1,106 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import ChatTest from './ChatTest'; + +const AddAdminsToGroupTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [chatId, setChatId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateChatId = (e: React.SyntheticEvent) => { + setChatId((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const addAdminsToGroupTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.chat.addAdminsToGroup({ + chatId: chatId, + admins: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Add Admins to Group Test page

+ + + +
+ + Add Admins to Group + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default AddAdminsToGroupTest; diff --git a/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx b/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx new file mode 100644 index 000000000..23956e45d --- /dev/null +++ b/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx @@ -0,0 +1,108 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import ChatTest from './ChatTest'; + +const AddMembersToGroupTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [chatId, setChatId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateChatId = (e: React.SyntheticEvent) => { + setChatId((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const addMembersToGroupTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.chat.addMembersToGroup({ + chatId: chatId, + members: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + + + return ( +
+ +

Add Member to Group Test page

+ + + +
+ + Add Member to Group + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default AddMembersToGroupTest; diff --git a/packages/demoreact/src/app/ChatTest/ChatTest.tsx b/packages/demoreact/src/app/ChatTest/ChatTest.tsx index feddae531..110f73ed5 100644 --- a/packages/demoreact/src/app/ChatTest/ChatTest.tsx +++ b/packages/demoreact/src/app/ChatTest/ChatTest.tsx @@ -68,6 +68,18 @@ const ChatTest = () => { CHAT.GETGROUP + + CHAT.ADDMEMBERSTOGROUP + + + CHAT.ADDADMINSTOGROUP + + + CHAT.REMOVEMEMBERSFROMGROUP + + + CHAT.REMOVEADMINSFROMGROUP +
diff --git a/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx b/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx new file mode 100644 index 000000000..cec4edbde --- /dev/null +++ b/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx @@ -0,0 +1,106 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import ChatTest from './ChatTest'; + +const RemoveAdminsFromGroupTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [chatId, setChatId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateChatId = (e: React.SyntheticEvent) => { + setChatId((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const removeAdminsFromGroupTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.chat.removeAdminsFromGroup({ + chatId: chatId, + admins: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Remove Admins from Group Test page

+ + + +
+ + Remove Admins from Group + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default RemoveAdminsFromGroupTest; diff --git a/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx b/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx new file mode 100644 index 000000000..5c0928f3d --- /dev/null +++ b/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx @@ -0,0 +1,92 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import ChatTest from './ChatTest'; + +const RemoveMembersFromGroupTest = () => { + const { account,library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [chatId, setChatId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + + const updateChatId = (e: React.SyntheticEvent) => { + setChatId((e.target as HTMLInputElement).value); + }; + +const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const removeMembersFromGroupTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.chat.removeMembersFromGroup({ + chatId: chatId, + members: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Remove Member from Group Test page

+ + + +
+ + Remove Member from Group + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default RemoveMembersFromGroupTest; diff --git a/packages/demoreact/src/app/ChatTest/helper.ts b/packages/demoreact/src/app/ChatTest/helper.ts new file mode 100644 index 000000000..9200ac5ab --- /dev/null +++ b/packages/demoreact/src/app/ChatTest/helper.ts @@ -0,0 +1,19 @@ +import { + ChatStatus +} from "@pushprotocol/restapi"; + +export const stringToChatStatus = (status: string | undefined): ChatStatus => { + if (!status) { + throw new Error(`Invalid ChatStatus string: ${status}`); + } + switch (status.toUpperCase()) { + case 'ACTIVE': + return ChatStatus.ACTIVE; + case 'ENDED': + return ChatStatus.ENDED; + case 'PENDING': + return ChatStatus.PENDING; + default: + throw new Error(`Invalid ChatStatus string: ${status}`); + } +}; \ No newline at end of file diff --git a/packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx new file mode 100644 index 000000000..75794e011 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx @@ -0,0 +1,106 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const AddAdminsToSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const testAddAdminsToSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.space.addAdminsToSpace({ + spaceId: spaceId, + admins: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Add Admins to Space Test page

+ + + +
+ + Add Admins to Space + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default AddAdminsToSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx new file mode 100644 index 000000000..31a930d10 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx @@ -0,0 +1,104 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const AddMembersToSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + const addMembersToSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.space.addMembersToSpace({ + spaceId: spaceId, + members: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + return ( +
+ +

Add Members to Space Test page

+ + + +
+ + Add Members to Space + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default AddMembersToSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/ApproveSpaceRequestTest.tsx b/packages/demoreact/src/app/SpaceTest/ApproveSpaceRequestTest.tsx new file mode 100644 index 000000000..d154d0b35 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/ApproveSpaceRequestTest.tsx @@ -0,0 +1,101 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import { walletToPCAIP10 } from '../helpers'; +import SpaceTest from './SpaceTest'; + +const ApproveRequestTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env, isCAIP } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [senderAddress, setSenderAddress] = useState(''); + const [approveResponse, setApproveResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSenderAddress = (e: React.SyntheticEvent) => { + setSenderAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const testApproveRequest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + + const response = await PushAPI.space.approve({ + status: 'Approved', + account: isCAIP ? walletToPCAIP10(account) : account, + signer: librarySigner, + senderAddress, + env, + }); + + setApproveResponse(response); + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Send Message Test page

+ + + +
+ +
+ + + + + + + + + + + approve request + + +
+
+ + +
+ {approveResponse ? ( + + {JSON.stringify(approveResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default ApproveRequestTest; diff --git a/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx new file mode 100644 index 000000000..9e1e543be --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx @@ -0,0 +1,300 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import { walletToPCAIP10 } from '../helpers'; +import SpaceTest from '../SpaceTest/SpaceTest'; + +const CreateSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env, isCAIP } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceName, setSpaceName] = useState(''); + const [spaceDescription, setSpaceDescription] = useState(''); + const [members, setMembers] = useState(''); + const [spaceImage, setSpaceImage] = useState(''); + const [admins, setAdmins] = useState(''); + const [isPublic, setIsPublic] = useState(''); + const [contractAddressNFT, setContractAddressNFT] = useState(); + const [numberOfNFTs, setNumberOfNFTs] = useState(); + const [contractAddressERC20, setContractAddressERC20] = useState(); + const [numberOfERC20, setNumberOfERC20] = useState(); + const [meta, setMeta] = useState(); + const [scheduleAt, setScheduleAt] = useState(''); + const [scheduleEnd, setScheduleEnd] = useState(); + const [account, setAccount] = useState(acc); + + + const [sendResponse, setSendResponse] = useState(''); + + const updateSpaceName = (e: React.SyntheticEvent) => { + setSpaceName((e.target as HTMLInputElement).value); + }; + + const updateSpaceDescription = (e: React.SyntheticEvent) => { + setSpaceDescription((e.target as HTMLInputElement).value); + }; + + const updateMembers = (e: React.SyntheticEvent) => { + setMembers((e.target as HTMLInputElement).value); + }; + + const updateSpaceImage = (e: React.SyntheticEvent) => { + setSpaceImage((e.target as HTMLInputElement).value); + }; + + const updateAdmins = (e: React.SyntheticEvent) => { + setAdmins((e.target as HTMLInputElement).value); + }; + + const updateIsPublic = (e: React.SyntheticEvent) => { + setIsPublic((e.target as HTMLInputElement).value); + }; + + const updateContractAddressNFT = (e: React.SyntheticEvent) => { + setContractAddressNFT((e.target as HTMLInputElement).value); + }; + + const updateNumberOfNFTs = (e: React.SyntheticEvent) => { + setNumberOfNFTs((e.target as HTMLInputElement).value); + }; + + const updateContractAddressERC20 = (e: React.SyntheticEvent) => { + setContractAddressERC20((e.target as HTMLInputElement).value); + }; + + const updateNumberOfERC20 = (e: React.SyntheticEvent) => { + setNumberOfERC20((e.target as HTMLInputElement).value); + }; + + const updateMeta = (e: React.SyntheticEvent) => { + setMeta((e.target as HTMLInputElement).value); + }; + + const updateScheduleAt = (e: React.SyntheticEvent) => { + setScheduleAt((e.target as HTMLInputElement).value); + }; + + const updateScheduleEnd = (e: React.SyntheticEvent) => { + setScheduleEnd((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const testCreateSpace = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + + const response = await PushAPI.space.create({ + spaceName, + spaceDescription, + members: members.split(','), + spaceImage, + admins: admins.split(','), + isPublic: (isPublic === "true"), + contractAddressNFT, + numberOfNFTs: numberOfNFTs != null ? Number(numberOfNFTs) : undefined, + contractAddressERC20, + numberOfERC20: numberOfERC20 != null ? Number(numberOfERC20) : undefined, + account: isCAIP ? walletToPCAIP10(account) : account, + signer: librarySigner, + env, + meta: meta, + scheduleAt: new Date(scheduleAt) , + scheduleEnd: scheduleEnd ? new Date(scheduleEnd) : null + }); + + setSendResponse(response); + } catch (e:any) { + console.error(e.message); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Create Space Test page

+ + + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + create space + + +
+
+ + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default CreateSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/GetSpaceInfoTest.tsx b/packages/demoreact/src/app/SpaceTest/GetSpaceInfoTest.tsx new file mode 100644 index 000000000..4306a2b14 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/GetSpaceInfoTest.tsx @@ -0,0 +1,78 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const GetSpaceInfoTest = () => { + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const testGetSpace = async () => { + try { + setLoading(true); + + // object for connected user data + const response = await PushAPI.space.info({ + spaceId: spaceId, + env, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + + + return ( +
+ +

Get Space Info Test page

+ + + +
+ + get space data + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetSpaceInfoTest; diff --git a/packages/demoreact/src/app/SpaceTest/GetSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/GetSpaceTest.tsx new file mode 100644 index 000000000..cb331c130 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/GetSpaceTest.tsx @@ -0,0 +1,78 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const GetSpaceTest = () => { + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const testGetSpace = async () => { + try { + setLoading(true); + + // object for connected user data + const response = await PushAPI.space.get({ + spaceId: spaceId, + env, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + + + return ( +
+ +

Get Space Test page

+ + + +
+ + get space data + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/GetSpacesRequestsTest.tsx b/packages/demoreact/src/app/SpaceTest/GetSpacesRequestsTest.tsx new file mode 100644 index 000000000..f046e9fab --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/GetSpacesRequestsTest.tsx @@ -0,0 +1,132 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const GetSpacesRequestsTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [getSpacesReqeustsResponse, setSpacesReqeustsResponse] = useState(''); + const [toDecrypt, setToDecrypt] = useState(false); + const [account, setAccount] = useState(acc); + const [page, setPage] = useState(1); + const [limit, setLimit] = useState(10); + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const updatePage = (e: React.SyntheticEvent) => { + setPage(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateLimit = (e: React.SyntheticEvent) => { + setLimit(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateToDecrypt = (e: React.SyntheticEvent) => { + setToDecrypt((e.target as HTMLInputElement).checked); + }; + const testGetSpaceRequests = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const user = await PushAPI.user.get({ account: account, env }); + let pvtkey = null; + if (user?.encryptedPrivateKey) { + pvtkey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account, + signer: librarySigner, + env, + }); + } + const response = await PushAPI.space.requests({ + account: account, + pgpPrivateKey: pvtkey, + toDecrypt, + env, + page, + limit, + }); + + setSpacesReqeustsResponse(response); + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Get Spaces Requests Test page

+ + + +
+
+ + + + + + + + + + + + + + + + + + get spaces + +
+ +
+ {getSpacesReqeustsResponse ? ( + + {JSON.stringify(getSpacesReqeustsResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetSpacesRequestsTest; diff --git a/packages/demoreact/src/app/SpaceTest/GetSpacesTest.tsx b/packages/demoreact/src/app/SpaceTest/GetSpacesTest.tsx new file mode 100644 index 000000000..4214bfa89 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/GetSpacesTest.tsx @@ -0,0 +1,132 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const GetSpacesTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [getSpacesResponse, setGetSpacesResponse] = useState(''); + const [toDecrypt, setToDecrypt] = useState(false); + const [account, setAccount] = useState(acc); + const [page, setPage] = useState(1); + const [limit, setLimit] = useState(10); + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const updatePage = (e: React.SyntheticEvent) => { + setPage(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateLimit = (e: React.SyntheticEvent) => { + setLimit(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateToDecrypt = (e: React.SyntheticEvent) => { + setToDecrypt((e.target as HTMLInputElement).checked); + }; + const testGetSpaces = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const user = await PushAPI.user.get({ account: account, env }); + let pvtkey = null; + if (user?.encryptedPrivateKey) { + pvtkey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account, + signer: librarySigner, + env, + }); + } + const response = await PushAPI.space.spaces({ + account: account, + pgpPrivateKey: pvtkey, + toDecrypt, + env, + page, + limit, + }); + + setGetSpacesResponse(response); + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Get Spaces Test page

+ + + +
+
+ + + + + + + + + + + + + + + + + + get spaces + +
+ +
+ {getSpacesResponse ? ( + + {JSON.stringify(getSpacesResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetSpacesTest; diff --git a/packages/demoreact/src/app/SpaceTest/GetSpacesTrendingTest.tsx b/packages/demoreact/src/app/SpaceTest/GetSpacesTrendingTest.tsx new file mode 100644 index 000000000..95bccb3e5 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/GetSpacesTrendingTest.tsx @@ -0,0 +1,105 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const GetSpacesTrendingTest = () => { + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [getSpacesTrendingResponse, setGetSpacesTrendingResponse] = useState(''); + const [toDecrypt, setToDecrypt] = useState(false); + const [page, setPage] = useState(1); + const [limit, setLimit] = useState(10); + + + const updatePage = (e: React.SyntheticEvent) => { + setPage(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateLimit = (e: React.SyntheticEvent) => { + setLimit(parseInt((e.target as HTMLInputElement).value)); + }; + + const updateToDecrypt = (e: React.SyntheticEvent) => { + setToDecrypt((e.target as HTMLInputElement).checked); + }; + const testGetSpacesTrending = async () => { + try { + setLoading(true); + + const response = await PushAPI.space.trending({ + env, + page, + limit, + }); + + setGetSpacesTrendingResponse(response); + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Get Spaces Trending Test page

+ + + +
+
+ + + + + + + + + + + + + + get spaces + +
+ +
+ {getSpacesTrendingResponse ? ( + + {JSON.stringify(getSpacesTrendingResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetSpacesTrendingTest; diff --git a/packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx new file mode 100644 index 000000000..b1cb37654 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx @@ -0,0 +1,105 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const RemoveAdminsFromSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const removeAdminsFromSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.space.removeAdminsFromSpace({ + spaceId: spaceId, + admins: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + return ( +
+ +

Remove Admins from Group Test page

+ + + +
+ + Remove Admins from Space + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default RemoveAdminsFromSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx new file mode 100644 index 000000000..67884aca9 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx @@ -0,0 +1,108 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const RemoveMembersFromSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [memberAddress, setMemberAddress] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const updateMemberId = (e: React.SyntheticEvent) => { + setMemberAddress((e.target as HTMLInputElement).value); + }; + + const removeMembersFromSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + const response = await PushAPI.space.removeMembersFromSpace({ + spaceId: spaceId, + members: memberAddress ? memberAddress.split(',') : [], + env, + account: account, + signer: librarySigner, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + + + return ( +
+ +

Remove Member from Space Test page

+ + + +
+ + Remove Member from Space + + + + + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default RemoveMembersFromSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx new file mode 100644 index 000000000..c85cac5ea --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx @@ -0,0 +1,79 @@ +import { useState, useContext } from 'react'; +import styled from 'styled-components'; +import { Link } from 'react-router-dom'; +import { + Section, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; + +const SpaceTest = () => { + const [isLoading, setLoading] = useState(false); + + const NavMenu = styled.div` + display: flex; + flex-wrap: wrap; + gap: 30px; + justify-content: center; + + @media only screen and (max-width: 900px) { + flex-direction: column; + } + `; + + return ( +
+

Space Test page

+ + + +
+ + + SPACE.CREATE + + + SPACE.UPDATE + + + SPACE.GET + + + SPACE.INFO + + + SPACE.APPROVE + + + SPACE.START + + + SPACE.STOP + + + SPACE.ADDMEMBERSTOSPACE + + + SPACE.ADDADMINSTOSPACE + + + SPACE.REMOVEMEMBERSFROMSPACE + + + SPACE.REMOVEADMINSFROMSPACE + + + SPACE.GETSPACES + + + SPACE.GETSPACESREQUESTS + + + SPACE.GETSPACESTRENDING + + +
+
+ ); +}; + +export default SpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx new file mode 100644 index 000000000..d27c48455 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx @@ -0,0 +1,91 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const StartSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const startSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + + const response = await PushAPI.space.start({ + spaceId: spaceId, + signer: librarySigner, + env: env, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Start Space Test page

+ + + +
+ + Start space data + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default StartSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx new file mode 100644 index 000000000..fe361f17c --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx @@ -0,0 +1,93 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import SpaceTest from './SpaceTest'; + +const StopSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + const [account, setAccount] = useState(acc); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const stopSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + + const response = await PushAPI.space.stop({ + spaceId: spaceId, + signer: librarySigner, + env: env, + }); + setSendResponse(response); + + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + + + return ( +
+ +

Stop Space Test page

+ + + +
+ + Stop space data + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default StopSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx new file mode 100644 index 000000000..7e56f3ce4 --- /dev/null +++ b/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx @@ -0,0 +1,232 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { Web3Context, EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; +import { walletToPCAIP10 } from '../helpers'; +import SpaceTest from './SpaceTest'; +import { stringToChatStatus } from './../ChatTest/helper'; + +const UpdateSpaceTest = () => { + const { account: acc, library } = useContext(Web3Context); + const { env, isCAIP } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [spaceId, setSpaceId] = useState(''); + const [spaceName, setSpaceName] = useState(''); + const [spaceImage, setSpaceImage] = useState(''); + const [spaceDescription, setSpaceDescription] = useState(''); + const [members, setMembers] = useState(''); + const [admins, setAdmins] = useState(''); + const [scheduleAt, setScheduleAt] = useState(''); + const [scheduleEnd, setScheduleEnd] = useState(); + const [status, setStatus] = useState(); + const [account, setAccount] = useState(acc); + + const [sendResponse, setSendResponse] = useState(''); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateSpaceName = (e: React.SyntheticEvent) => { + setSpaceName((e.target as HTMLInputElement).value); + }; + const updateSpaceDescription = (e: React.SyntheticEvent) => { + setSpaceDescription((e.target as HTMLInputElement).value); + }; + + const updateSpaceImage= (e: React.SyntheticEvent) => { + setSpaceImage((e.target as HTMLInputElement).value); + }; + + const updateMembers= (e: React.SyntheticEvent) => { + setMembers((e.target as HTMLInputElement).value); + }; + + + const updateAdmins= (e: React.SyntheticEvent) => { + setAdmins((e.target as HTMLInputElement).value); + }; + + const updateScheduleAt = (e: React.SyntheticEvent) => { + setScheduleAt((e.target as HTMLInputElement).value); + }; + + const updateScheduleEnd = (e: React.SyntheticEvent) => { + setScheduleEnd((e.target as HTMLInputElement).value); + }; + + const updateStatus = (e: React.SyntheticEvent) => { + setStatus((e.target as HTMLInputElement).value); + }; + + const updateAccount = (e: React.SyntheticEvent) => { + setAccount((e.target as HTMLInputElement).value); + }; + + const updateSpaceTest = async () => { + try { + setLoading(true); + const librarySigner = await library.getSigner(); + + const response = await PushAPI.space.update({ + spaceId, + spaceName, + spaceImage, + spaceDescription, + members: members.split(','), + admins: admins.split(','), + account: isCAIP ? walletToPCAIP10(account) : account, + signer: librarySigner, + env, + scheduleAt: new Date(scheduleAt) , + scheduleEnd: scheduleEnd ? new Date(scheduleEnd) : null, + status: stringToChatStatus(status) + }); + + setSendResponse(response); + } catch (e:any) { + console.error(e.message); + } finally { + setLoading(false); + } + }; + + return ( +
+ +

Update Space Test page

+ + + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + update space + + +
+
+ + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default UpdateSpaceTest; diff --git a/packages/demoreact/src/app/app.tsx b/packages/demoreact/src/app/app.tsx index 0925ebcfb..d2a769f53 100644 --- a/packages/demoreact/src/app/app.tsx +++ b/packages/demoreact/src/app/app.tsx @@ -27,6 +27,13 @@ import HistoryTest from './ChatTest/History'; import GetRequestsTest from './ChatTest/GetRequests'; import DelegationTest from './DelegationTest'; import CreateGroupTest from './ChatTest/CreateGroupTest'; +import AddMembersToGroupTest from './ChatTest/AddMembersToGroupTest'; +import AddAdminsToGroupTest from './ChatTest/AddAdminsToGroupTest'; +import CreateSpaceTest from './SpaceTest/CreateSpaceTest'; +import UpdateSpaceTest from './SpaceTest/UpdateSpaceTest'; +import GetSpaceTest from './SpaceTest/GetSpaceTest'; +import GetSpaceInfoTest from './SpaceTest/GetSpaceInfoTest'; +import ApproveSpaceRequestTest from './SpaceTest/ApproveSpaceRequestTest'; import UpdateGroupTest from './ChatTest/UpdateGroupTest'; import GetGroupTest from './ChatTest/GetGroupTest'; import GetUsersBatchTest from './ChatTest/GetUsersBatchTest'; @@ -34,6 +41,18 @@ import AuthUpdateUserTest from './ChatTest/AuthUpdateUser'; import UpdateUserProfile from './ChatTest/UpdateUserProfile'; import { Buffer } from 'buffer'; import { ENV } from './helpers'; +import SpaceTest from './SpaceTest/SpaceTest'; +import StartSpaceTest from './SpaceTest/StartSpaceTest'; +import StopSpaceTest from './SpaceTest/StopSpaceTest'; +import RemoveMembersFromGroupTest from './ChatTest/RemoveMembersFromGroupTest'; +import RemoveAdminsFromGroupTest from './ChatTest/RemoveAdminsFromGroupTest'; +import AddAdminsToSpaceTest from './SpaceTest/AddAdminsToSpaceTest'; +import AddMembersToSpaceTest from './SpaceTest/AddMembersToSpaceTest'; +import RemoveMembersFromSpaceTest from './SpaceTest/RemoveMembersFromSpaceTest'; +import RemoveAdminsFromSpaceTest from './SpaceTest/RemoveAdminsFromSpaceTest'; +import GetSpacesTest from './SpaceTest/GetSpacesTest'; +import GetSpacesRequestsTest from './SpaceTest/GetSpacesRequestsTest'; +import GetSpacesTrendingTest from './SpaceTest/GetSpacesTrendingTest'; window.Buffer = window.Buffer || Buffer; @@ -212,6 +231,9 @@ export function App() { CHAT + + SPACE + } /> @@ -231,6 +253,7 @@ export function App() { } /> } /> + } /> {/* chat method routes */} } /> @@ -246,7 +269,29 @@ export function App() { } /> } /> } /> + } /> + } /> + } /> + } /> } /> + + {/* spaces method routes */} + + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + diff --git a/packages/package-lock.json b/packages/package-lock.json new file mode 100644 index 000000000..84593e7d4 --- /dev/null +++ b/packages/package-lock.json @@ -0,0 +1,6 @@ +{ + "name": "packages", + "lockfileVersion": 2, + "requires": true, + "packages": {} +} diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 722c67255..316b85f0e 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -1517,113 +1517,25 @@ Allowed Options (params with _ are mandatory) | env | string | 'prod' | API env - 'prod', 'staging', 'dev'|
- DEPRECATED - Expected response (Get channel's subscribers list) + Expected response (Get channel's subscribers list) ```typescript -// PushAPI.channels._getSubscribers | Response - 200 OK -[ - '0x004f0c30bdad515cb9c554e698b52d71f1227134', - '0x00bce6275dfe75758a4e266e8b7381831676bb0a', - '0x00de74918982b1350b5f1784be594b8b30a5400f', - '0x01080667d6f0a9dd7d5f303c0a57044e93e0c2de', - '0x012eaa22f2286e615e582963c4b8f3f1a5646882', - '0x01382270dc0ec27cca8e84a5c6c9370022b0d9ac', - '0x016ea99b87d0feccdf1097ba932c5d673bededbb', - '0x02045677924949cef7450e0ad427896e8a36a581', - '0x02057aa3359a05da74ba015c661c06877f4b1ec9', - '0x025846389950a13292e63e4794c7d148ff57f995', - '0x0277b0ad0ba9b830797b671f77a1fcd1ba008003', - '0x02b24ac2239b344fbc4577801f7000901e7a3944', - '0x0302cd04ee871672fa3f770dc63ddc764849191d', - '0x03b22d7742fa2a8a8f01b64f40f0f2185e965cb8', - '0x03fad591aeb926bfd95fe1e38d51811167a5ad5c', - '0x04041ee456080b1bc83dc265f133d607124937ea', - '0x04288caaefa55f1e8107a3b1682fdfc58d927f1b', - '0x044b595c9b94a17adc489bd29696af40ccb3e4d2', - '0x044c982efe7ee8443bba5fcc9feef6dc84a61421', - '0x0478c8faa8f9863bfb69b389866d5e2fdad62032', - '0x056397760b973bfb921bc10be9da5034b1e921d7', - '0x05934628535b3e96f30f05258f0ed2a433288744', - '0x05dac6b7daae1b251e8dcc1bc7fcdb2f4c36bcc6', - '0x06a81b13358188de4c6fced42c4f58f81fca3c5c', - '0x072e7399de2fa1711d3d7b8d99ba36e25c21d87d', - '0x073b49dacc79d597aa69be01a6adf1ec3a7b7f93', - '0x07add6f4fc06ac00a9b0a0d2fd3540fa011591b6', - '0x07da8ee7714e5bc9447e5d39eacd3159d90992b1', - '0x08249e6733d85239d91daf62b1862e2cf09ff77c', - '0x0827206a690235b774c3147075c36d897f1c7e80', - '0x087f5052fbcd7c02dd45fb9907c57f1eccc2be25', - '0x08e4d14eb2ca6b67f17c569b01d8bc74084f8b33', - '0x093512f0f6b123ed38fd687f11a9e2ece0c4c5f5', - '0x0984100b68e6e2b3b004934ab0881ac431863283', - '0x09a545f696881b42b118b52a04cc2ee0df365518', - '0x0a4349a6b51c8454fcff20af639da1fbef8a2501', - '0x0a651cf7a9b60082fecdb5f30db7914fd7d2cf93', - '0x0a79058fcd8d50511be32e8620d88c824e730014', - '0x0abc2c830a6757ce28377c05de38edbd4e049ddb', - '0x0bbb52b4fd34b99d0711e07dc072086e98951e6a', - '0x0bffd1d41787ef50f3945aae0100e6c5288a96be', - '0x0c41b769bdc9078ba2da2dac1b7afd2017ed3de9', - '0x0c573fc3729a7b754ea1ed7c25db55e83d860335', - '0x0cccd55a5ac261ea29136831eeaa93bfe07f5db6', - '0x0d94c4dbe58f6fe1566a7302b4e4c3cd03744626', - '0x0da6c279b3f548d189a612f73956d9d2b40909db', - '0x0e1f0a26c4de4d8bbdf220f13eb04836edd07a52', - '0x0e2cbb9d72247f0c8a04dfbaade690dfeb93740d', - '0x0f43eb2e71833319896b01e2412e07a0bb5e5a9d', - '0x0f85d268402ab52cdd72d9a28f95eabb5a653545', - '0x0fc26ce09e56594aa364d0890ae43bdc14152e25', - '0x101598974b6dba36068657986c53b5e178d757d3', - '0x102a2adf909b0ef85ce6d1b5dc61e72907cbb93a', - '0x103aaa8b06d4222b89b2be71d66c9ddf621e232d', - '0x103d189a6bab84f2ec9ab6950e66d31bec4a098e', - '0x10f26d2b7ab670b4f3e7d8ed24cd60152a1caf87', - '0x111771d37525db8c0bb19124f1547b4fbec16b54', - '0x1145b29b49f9b61d6178050b4b5e520255c2e565', - '0x124f7f89889648437c9cda73565862f398930e62', - '0x12519784a33e899718eddecfe0045b19ee6b68d8', - '0x1251a5e5cfba7a6dfd6509d65f6eef3e66ebf320', - '0x127a95027b5c7e1d807433837c9cdd7e6f336803', - '0x12c52f225608774e8e0e05d04e9b4341fd11174b', - '0x140aa50e72b394217ec331396f9b569218820364', - '0x1434a7882cdd877b398df5b83c883e9571c65813', - '0x14c0157f9eea7aee61ba2606e75716e210b4697a', - '0x14ef3ef528aea2887e40f3ea286ab2859a795463', - '0x15287a2893c4c22098f6bf0e97e2e5b933c897ef', - '0x15405d4d57491430fbf00dc032bd5b1fbf72e6e7', - '0x155ddcf7d0871da12c32f1ca3a0b3df7a15aadbe', - '0x15900c698ee356e6976e5645394f027f0704c8eb', - '0x1590a25b46cc85f85dfcc1a3746c766a13af0cb5', - '0x15bc81b35a8498cee37e2c7b857538b006cecaa5', - '0x15faf8d03d669021e341122ab4bb27559e838538', - '0x161f99e11a0d76e4aba84330738dd9c38a4d1daa', - '0x16860bd82bc5a595b47d40a553cf13fae4bc916b', - '0x16c67634b61eb144f8630ccd1ffff9a0d32f4657', - '0x16eb4622f00bed1d27dccb4c0684c0e16512a36f', - '0x18241781b17b878cfc16b109035904c8e5073e73', - '0x186800b7e090271c922450c47ad30c2702c7bfe9', - '0x18770728fe5d4a8a0e3f31eacbf022f7b82a6740', - '0x190e7f3424b23ed9b54ed8ce8688cbca672ad022', - '0x1971b593c77617092b342d63a7f9111b31a0faba', - '0x19b3161b77b1c36d92a1ccad1cd1a301d1576d31', - '0x1a41820f84d090e4afc3066f6d8214d2a6e32870', - '0x1a668e5cdd5ae00d02fadf6c00bf9c9dd98aeb1a', - '0x1aa3127b831a33830ac0fe3ee4b0741d1a4a4e04', - '0x1bbc42f65f49a2efd83eea49c3698bd35ae3e0ec', - '0x1bc5c90cc9bfb632ca432d46176c52b3578f64e2', - '0x1c6f97c400a9804a1bb1d7026c77cd7494e78ca5', - '0x1cb28bbe58891442064a3a1d5813c92c217d2424', - '0x1d0911cfa2bd2a85d610c73a7bb04818fc4c93bd', - '0x1da02db5b4ec5c151a8bd64f1320b5683fba3ff1', - '0x1db67d560813ea7aba48bd8a9429cbecbeb2118e', - '0x1e26b7da859358598bad185c83932aad741e6c10', - '0x1ec0d39981d2dcf253b2b18b945d3310bc254560', - '0x1ef7a2a03d5369ed0b9807adb2b16e87f1f30baf', - '0x1ef7f4c06cb7630fdcb5dd324f22c0a8ec85f93f', - '0x1f771818c74a052226c01ebad909640a3fd97b43', - '0x1f85fd5b55fa2e6f544b84b9852f89ed035fdacd', - ... 656 more items -] +// PushAPI.channels.getSubscribers | Response - 200 OK +{ + "itemcount": 11, + "subscribers": [ + "0x1d4f52775344f9a32093af0ccd03a4fb6dac8e30", + "0x28d615edd8404f8ca1e0271a0b5a48171589921a", + "0x4352639b99689069f9b0b847eee349c3c1b0706c", + "0x50029e62540537045bcfd3d320483865344edb33", + "0x5ac9e6205eaca2bbba6ef716fd9aabd76326eeee", + "0x778d3206374f8ac265728e18e3fe2ae6b93e4ce4", + "0xa44f2994750cf774eab05751d90ade4dedabe7fe", + "0xbcfb7da1dcf40e8cfb331683bb7d6f4eba091b08", + "0xcf5dbf241fc65a5af56c95101ac4e9ec2c57d941", + "0xd8634c39bbfd4033c0d3289c4515275102423681" + ] +} ```
diff --git a/packages/restapi/package-lock.json b/packages/restapi/package-lock.json index 0c5fedb68..a2cdeca0a 100644 --- a/packages/restapi/package-lock.json +++ b/packages/restapi/package-lock.json @@ -1,29 +1,31 @@ { "name": "@pushprotocol/restapi", - "version": "0.8.3", + "version": "0.0.1-alpha.13", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@pushprotocol/restapi", - "version": "0.8.3", + "version": "0.0.1-alpha.13", "dependencies": { "@metamask/eth-sig-util": "^5.0.2", "buffer": "^6.0.3", - "chai": "^4.3.7", "crypto-js": "^4.1.1", - "mocha-typescript": "^1.1.17", + "immer": "^10.0.2", "openpgp": "^5.5.0", - "ts-node": "^10.9.1", - "typescript": "^5.0.2" + "simple-peer": "^9.11.1" }, "devDependencies": { "@types/chai": "^4.3.4", "@types/chai-as-promised": "^7.1.5", "@types/crypto-js": "^4.1.1", "@types/mocha": "^10.0.1", + "chai": "^4.3.7", "chai-as-promised": "^7.1.1", - "mocha": "^10.2.0" + "mocha": "^10.2.0", + "mocha-typescript": "^1.1.17", + "ts-node": "^10.9.1", + "typescript": "^5.0.2" }, "peerDependencies": { "ethers": "^5.6.8" @@ -56,6 +58,7 @@ "version": "0.8.1", "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", + "dev": true, "dependencies": { "@jridgewell/trace-mapping": "0.3.9" }, @@ -804,6 +807,7 @@ "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", + "dev": true, "engines": { "node": ">=6.0.0" } @@ -811,12 +815,14 @@ "node_modules/@jridgewell/sourcemap-codec": { "version": "1.4.14", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", - "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", + "dev": true }, "node_modules/@jridgewell/trace-mapping": { "version": "0.3.9", "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", + "dev": true, "dependencies": { "@jridgewell/resolve-uri": "^3.0.3", "@jridgewell/sourcemap-codec": "^1.4.10" @@ -905,22 +911,26 @@ "node_modules/@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", - "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==" + "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==", + "dev": true }, "node_modules/@tsconfig/node12": { "version": "1.0.11", "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", - "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==" + "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", + "dev": true }, "node_modules/@tsconfig/node14": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", - "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==" + "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", + "dev": true }, "node_modules/@tsconfig/node16": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz", - "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==" + "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==", + "dev": true }, "node_modules/@types/chai": { "version": "4.3.4", @@ -949,10 +959,18 @@ "integrity": "sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q==", "dev": true }, + "node_modules/@types/node": { + "version": "20.2.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.2.5.tgz", + "integrity": "sha512-JJulVEQXmiY9Px5axXHeYGLSjhkZEnD+MDPDGbCbIAbMslkKwmygtZFy1X6s/075Yo94sf8GuSlFfPzysQrWZQ==", + "dev": true, + "peer": true + }, "node_modules/acorn": { "version": "8.8.2", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", + "dev": true, "bin": { "acorn": "bin/acorn" }, @@ -964,6 +982,7 @@ "version": "8.2.0", "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", + "dev": true, "engines": { "node": ">=0.4.0" } @@ -1023,7 +1042,8 @@ "node_modules/arg": { "version": "4.1.3", "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true }, "node_modules/argparse": { "version": "2.0.1", @@ -1046,6 +1066,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", + "dev": true, "engines": { "node": "*" } @@ -1176,6 +1197,7 @@ "version": "4.3.7", "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz", "integrity": "sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A==", + "dev": true, "dependencies": { "assertion-error": "^1.1.0", "check-error": "^1.0.2", @@ -1233,6 +1255,7 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", "integrity": "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==", + "dev": true, "engines": { "node": "*" } @@ -1279,6 +1302,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", "integrity": "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -1310,12 +1334,14 @@ "node_modules/create-require": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==" + "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", + "dev": true }, "node_modules/cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "dev": true, "dependencies": { "nice-try": "^1.0.4", "path-key": "^2.0.1", @@ -1336,7 +1362,6 @@ "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, "dependencies": { "ms": "2.1.2" }, @@ -1352,8 +1377,7 @@ "node_modules/debug/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 + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" }, "node_modules/decamelize": { "version": "4.0.0", @@ -1371,6 +1395,7 @@ "version": "4.1.3", "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz", "integrity": "sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==", + "dev": true, "dependencies": { "type-detect": "^4.0.0" }, @@ -1382,6 +1407,7 @@ "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true, "engines": { "node": ">=0.3.1" } @@ -1411,10 +1437,16 @@ "version": "1.4.4", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dev": true, "dependencies": { "once": "^1.4.0" } }, + "node_modules/err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, "node_modules/escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -1512,6 +1544,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz", "integrity": "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==", + "dev": true, "dependencies": { "cross-spawn": "^6.0.0", "get-stream": "^4.0.0", @@ -1582,6 +1615,11 @@ "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, + "node_modules/get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, "node_modules/get-caller-file": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", @@ -1595,6 +1633,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", "integrity": "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==", + "dev": true, "engines": { "node": "*" } @@ -1603,6 +1642,7 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", + "dev": true, "dependencies": { "pump": "^3.0.0" }, @@ -1712,6 +1752,15 @@ } ] }, + "node_modules/immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, "node_modules/inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", @@ -1731,6 +1780,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==", + "dev": true, "engines": { "node": ">=4" } @@ -1808,6 +1858,7 @@ "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", "integrity": "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -1827,7 +1878,8 @@ "node_modules/isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true }, "node_modules/js-sha3": { "version": "0.8.0", @@ -1851,6 +1903,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", + "dev": true, "dependencies": { "invert-kv": "^2.0.0" }, @@ -1893,6 +1946,7 @@ "version": "2.3.6", "resolved": "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz", "integrity": "sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==", + "dev": true, "dependencies": { "get-func-name": "^2.0.0" } @@ -1900,12 +1954,14 @@ "node_modules/make-error": { "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true }, "node_modules/map-age-cleaner": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", + "dev": true, "dependencies": { "p-defer": "^1.0.0" }, @@ -1917,6 +1973,7 @@ "version": "4.3.0", "resolved": "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz", "integrity": "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==", + "dev": true, "dependencies": { "map-age-cleaner": "^0.1.1", "mimic-fn": "^2.0.0", @@ -1930,6 +1987,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true, "engines": { "node": ">=6" } @@ -2011,6 +2069,7 @@ "resolved": "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz", "integrity": "sha512-Ge6pCQkZumkkhxVNdAf3JxunskShgaynCb30HYD7TT1Yhog/7NW2+6w5RcRHI+nuQrCMTX6z1+qf2pD8qwCoQA==", "deprecated": "mocha-typescript has been deprecated, use @testdeck/mocha instead", + "dev": true, "dependencies": { "@types/mocha": "^5.2.0", "chalk": "^2.4.1", @@ -2024,12 +2083,14 @@ "node_modules/mocha-typescript/node_modules/@types/mocha": { "version": "5.2.7", "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-5.2.7.tgz", - "integrity": "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==" + "integrity": "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==", + "dev": true }, "node_modules/mocha-typescript/node_modules/ansi-regex": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", + "dev": true, "engines": { "node": ">=4" } @@ -2038,6 +2099,7 @@ "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, "dependencies": { "color-convert": "^1.9.0" }, @@ -2049,6 +2111,7 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz", "integrity": "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==", + "dev": true, "engines": { "node": ">=4" } @@ -2057,6 +2120,7 @@ "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, "dependencies": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", @@ -2070,6 +2134,7 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", + "dev": true, "dependencies": { "string-width": "^2.1.1", "strip-ansi": "^4.0.0", @@ -2080,6 +2145,7 @@ "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, "dependencies": { "color-name": "1.1.3" } @@ -2087,12 +2153,14 @@ "node_modules/mocha-typescript/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==" + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "dev": true }, "node_modules/mocha-typescript/node_modules/decamelize": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -2101,6 +2169,7 @@ "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, "engines": { "node": ">=0.8.0" } @@ -2109,6 +2178,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", "integrity": "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==", + "dev": true, "dependencies": { "locate-path": "^2.0.0" }, @@ -2119,12 +2189,14 @@ "node_modules/mocha-typescript/node_modules/get-caller-file": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz", - "integrity": "sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==" + "integrity": "sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==", + "dev": true }, "node_modules/mocha-typescript/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, "engines": { "node": ">=4" } @@ -2133,6 +2205,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", "integrity": "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==", + "dev": true, "engines": { "node": ">=4" } @@ -2141,6 +2214,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", "integrity": "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==", + "dev": true, "dependencies": { "p-locate": "^2.0.0", "path-exists": "^3.0.0" @@ -2153,6 +2227,7 @@ "version": "1.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz", "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==", + "dev": true, "dependencies": { "p-try": "^1.0.0" }, @@ -2164,6 +2239,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", "integrity": "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==", + "dev": true, "dependencies": { "p-limit": "^1.1.0" }, @@ -2175,6 +2251,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", + "dev": true, "engines": { "node": ">=4" } @@ -2183,6 +2260,7 @@ "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, "dependencies": { "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^4.0.0" @@ -2195,6 +2273,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", "integrity": "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==", + "dev": true, "dependencies": { "ansi-regex": "^3.0.0" }, @@ -2206,6 +2285,7 @@ "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, "dependencies": { "has-flag": "^3.0.0" }, @@ -2217,6 +2297,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", "integrity": "sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw==", + "dev": true, "dependencies": { "string-width": "^1.0.1", "strip-ansi": "^3.0.1" @@ -2229,6 +2310,7 @@ "version": "2.1.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -2237,6 +2319,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", + "dev": true, "dependencies": { "number-is-nan": "^1.0.0" }, @@ -2248,6 +2331,7 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", + "dev": true, "dependencies": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -2261,6 +2345,7 @@ "version": "3.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, "dependencies": { "ansi-regex": "^2.0.0" }, @@ -2271,12 +2356,14 @@ "node_modules/mocha-typescript/node_modules/y18n": { "version": "3.2.2", "resolved": "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz", - "integrity": "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==" + "integrity": "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==", + "dev": true }, "node_modules/mocha-typescript/node_modules/yargs": { "version": "11.1.1", "resolved": "https://registry.npmjs.org/yargs/-/yargs-11.1.1.tgz", "integrity": "sha512-PRU7gJrJaXv3q3yQZ/+/X6KBswZiaQ+zOmdprZcouPYtQgvNU35i+68M4b1ZHLZtYFT5QObFLV+ZkmJYcwKdiw==", + "dev": true, "dependencies": { "cliui": "^4.0.0", "decamelize": "^1.1.1", @@ -2296,6 +2383,7 @@ "version": "9.0.2", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz", "integrity": "sha512-CswCfdOgCr4MMsT1GzbEJ7Z2uYudWyrGX8Bgh/0eyCzj/DXWdKq6a/ADufkzI1WAOIW6jYaXJvRyLhDO0kfqBw==", + "dev": true, "dependencies": { "camelcase": "^4.1.0" } @@ -2330,7 +2418,8 @@ "node_modules/nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" + "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", + "dev": true }, "node_modules/normalize-path": { "version": "3.0.0", @@ -2345,6 +2434,7 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", "integrity": "sha512-lJxZYlT4DW/bRUtFh1MQIWqmLwQfAxnqWG4HhEdjMlkrJYnJn0Jrr2u3mgxqaWsdiBc76TYkTG/mhrnYTuzfHw==", + "dev": true, "dependencies": { "path-key": "^2.0.0" }, @@ -2356,6 +2446,7 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -2364,6 +2455,7 @@ "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, "dependencies": { "wrappy": "1" } @@ -2383,6 +2475,7 @@ "version": "3.1.0", "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz", "integrity": "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==", + "dev": true, "dependencies": { "execa": "^1.0.0", "lcid": "^2.0.0", @@ -2396,6 +2489,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz", "integrity": "sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw==", + "dev": true, "engines": { "node": ">=4" } @@ -2404,6 +2498,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", "integrity": "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==", + "dev": true, "engines": { "node": ">=4" } @@ -2412,6 +2507,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz", "integrity": "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==", + "dev": true, "engines": { "node": ">=6" } @@ -2450,6 +2546,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz", "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==", + "dev": true, "engines": { "node": ">=4" } @@ -2476,6 +2573,7 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", "integrity": "sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==", + "dev": true, "engines": { "node": ">=4" } @@ -2484,6 +2582,7 @@ "version": "1.1.1", "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", "integrity": "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==", + "dev": true, "engines": { "node": "*" } @@ -2504,20 +2603,52 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dev": true, "dependencies": { "end-of-stream": "^1.1.0", "once": "^1.3.1" } }, + "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==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, "node_modules/randombytes": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", - "dev": true, "dependencies": { "safe-buffer": "^5.1.0" } }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, "node_modules/readdirp": { "version": "3.6.0", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", @@ -2534,6 +2665,7 @@ "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -2541,13 +2673,13 @@ "node_modules/require-main-filename": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz", - "integrity": "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==" + "integrity": "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==", + "dev": true }, "node_modules/safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true, "funding": [ { "type": "github", @@ -2578,6 +2710,7 @@ "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "dev": true, "bin": { "semver": "bin/semver" } @@ -2594,12 +2727,14 @@ "node_modules/set-blocking": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==" + "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", + "dev": true }, "node_modules/shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", "integrity": "sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==", + "dev": true, "dependencies": { "shebang-regex": "^1.0.0" }, @@ -2611,6 +2746,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", "integrity": "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -2618,7 +2754,44 @@ "node_modules/signal-exit": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true + }, + "node_modules/simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dependencies": { + "safe-buffer": "~5.2.0" + } }, "node_modules/string-width": { "version": "4.2.3", @@ -2650,6 +2823,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", "integrity": "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -2709,6 +2883,7 @@ "version": "10.9.1", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", "integrity": "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==", + "dev": true, "dependencies": { "@cspotcode/source-map-support": "^0.8.0", "@tsconfig/node10": "^1.0.7", @@ -2761,6 +2936,7 @@ "version": "4.0.8", "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true, "engines": { "node": ">=4" } @@ -2769,6 +2945,7 @@ "version": "5.0.2", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz", "integrity": "sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw==", + "dev": true, "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" @@ -2777,15 +2954,22 @@ "node": ">=12.20" } }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, "node_modules/v8-compile-cache-lib": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", - "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==" + "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", + "dev": true }, "node_modules/which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, "dependencies": { "isexe": "^2.0.0" }, @@ -2796,7 +2980,8 @@ "node_modules/which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==" + "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==", + "dev": true }, "node_modules/workerpool": { "version": "6.2.1", @@ -2824,7 +3009,8 @@ "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==" + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true }, "node_modules/ws": { "version": "7.4.6", @@ -2902,6 +3088,7 @@ "version": "3.1.1", "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true, "engines": { "node": ">=6" } @@ -2947,6 +3134,7 @@ "version": "0.8.1", "resolved": "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz", "integrity": "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==", + "dev": true, "requires": { "@jridgewell/trace-mapping": "0.3.9" } @@ -3386,17 +3574,20 @@ "@jridgewell/resolve-uri": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", - "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==" + "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", + "dev": true }, "@jridgewell/sourcemap-codec": { "version": "1.4.14", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", - "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", + "dev": true }, "@jridgewell/trace-mapping": { "version": "0.3.9", "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz", "integrity": "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==", + "dev": true, "requires": { "@jridgewell/resolve-uri": "^3.0.3", "@jridgewell/sourcemap-codec": "^1.4.10" @@ -3452,22 +3643,26 @@ "@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", - "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==" + "integrity": "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==", + "dev": true }, "@tsconfig/node12": { "version": "1.0.11", "resolved": "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz", - "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==" + "integrity": "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==", + "dev": true }, "@tsconfig/node14": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz", - "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==" + "integrity": "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==", + "dev": true }, "@tsconfig/node16": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz", - "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==" + "integrity": "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==", + "dev": true }, "@types/chai": { "version": "4.3.4", @@ -3496,15 +3691,24 @@ "integrity": "sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q==", "dev": true }, + "@types/node": { + "version": "20.2.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-20.2.5.tgz", + "integrity": "sha512-JJulVEQXmiY9Px5axXHeYGLSjhkZEnD+MDPDGbCbIAbMslkKwmygtZFy1X6s/075Yo94sf8GuSlFfPzysQrWZQ==", + "dev": true, + "peer": true + }, "acorn": { "version": "8.8.2", "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", - "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==" + "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", + "dev": true }, "acorn-walk": { "version": "8.2.0", "resolved": "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz", - "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==" + "integrity": "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==", + "dev": true }, "aes-js": { "version": "3.0.0", @@ -3546,7 +3750,8 @@ "arg": { "version": "4.1.3", "resolved": "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz", - "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" + "integrity": "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==", + "dev": true }, "argparse": { "version": "2.0.1", @@ -3568,7 +3773,8 @@ "assertion-error": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz", - "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" + "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", + "dev": true }, "balanced-match": { "version": "1.0.2", @@ -3653,6 +3859,7 @@ "version": "4.3.7", "resolved": "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz", "integrity": "sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A==", + "dev": true, "requires": { "assertion-error": "^1.1.0", "check-error": "^1.0.2", @@ -3696,7 +3903,8 @@ "check-error": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz", - "integrity": "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==" + "integrity": "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==", + "dev": true }, "chokidar": { "version": "3.5.3", @@ -3728,7 +3936,8 @@ "code-point-at": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz", - "integrity": "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==" + "integrity": "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==", + "dev": true }, "color-convert": { "version": "2.0.1", @@ -3754,12 +3963,14 @@ "create-require": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz", - "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==" + "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", + "dev": true }, "cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", "integrity": "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==", + "dev": true, "requires": { "nice-try": "^1.0.4", "path-key": "^2.0.1", @@ -3777,7 +3988,6 @@ "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "dev": true, "requires": { "ms": "2.1.2" }, @@ -3785,8 +3995,7 @@ "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 + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" } } }, @@ -3800,6 +4009,7 @@ "version": "4.1.3", "resolved": "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz", "integrity": "sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==", + "dev": true, "requires": { "type-detect": "^4.0.0" } @@ -3807,7 +4017,8 @@ "diff": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", - "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" + "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", + "dev": true }, "elliptic": { "version": "6.5.4", @@ -3834,10 +4045,16 @@ "version": "1.4.4", "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz", "integrity": "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==", + "dev": true, "requires": { "once": "^1.4.0" } }, + "err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, "escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -3912,6 +4129,7 @@ "version": "1.0.0", "resolved": "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz", "integrity": "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==", + "dev": true, "requires": { "cross-spawn": "^6.0.0", "get-stream": "^4.0.0", @@ -3960,6 +4178,11 @@ "dev": true, "optional": true }, + "get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, "get-caller-file": { "version": "2.0.5", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz", @@ -3969,12 +4192,14 @@ "get-func-name": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz", - "integrity": "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==" + "integrity": "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==", + "dev": true }, "get-stream": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", + "dev": true, "requires": { "pump": "^3.0.0" } @@ -4051,6 +4276,11 @@ "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" }, + "immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==" + }, "inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", @@ -4069,7 +4299,8 @@ "invert-kv": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", - "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" + "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==", + "dev": true }, "is-binary-path": { "version": "2.1.0", @@ -4121,7 +4352,8 @@ "is-stream": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", - "integrity": "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==" + "integrity": "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==", + "dev": true }, "is-unicode-supported": { "version": "0.1.0", @@ -4132,7 +4364,8 @@ "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", - "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", + "dev": true }, "js-sha3": { "version": "0.8.0", @@ -4153,6 +4386,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz", "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", + "dev": true, "requires": { "invert-kv": "^2.0.0" } @@ -4180,6 +4414,7 @@ "version": "2.3.6", "resolved": "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz", "integrity": "sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==", + "dev": true, "requires": { "get-func-name": "^2.0.0" } @@ -4187,12 +4422,14 @@ "make-error": { "version": "1.3.6", "resolved": "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz", - "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" + "integrity": "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==", + "dev": true }, "map-age-cleaner": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz", "integrity": "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==", + "dev": true, "requires": { "p-defer": "^1.0.0" } @@ -4201,6 +4438,7 @@ "version": "4.3.0", "resolved": "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz", "integrity": "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==", + "dev": true, "requires": { "map-age-cleaner": "^0.1.1", "mimic-fn": "^2.0.0", @@ -4210,7 +4448,8 @@ "mimic-fn": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz", - "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" + "integrity": "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==", + "dev": true }, "minimalistic-assert": { "version": "1.0.1", @@ -4284,6 +4523,7 @@ "version": "1.1.17", "resolved": "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz", "integrity": "sha512-Ge6pCQkZumkkhxVNdAf3JxunskShgaynCb30HYD7TT1Yhog/7NW2+6w5RcRHI+nuQrCMTX6z1+qf2pD8qwCoQA==", + "dev": true, "requires": { "@types/mocha": "^5.2.0", "chalk": "^2.4.1", @@ -4294,17 +4534,20 @@ "@types/mocha": { "version": "5.2.7", "resolved": "https://registry.npmjs.org/@types/mocha/-/mocha-5.2.7.tgz", - "integrity": "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==" + "integrity": "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==", + "dev": true }, "ansi-regex": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz", - "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==" + "integrity": "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==", + "dev": true }, "ansi-styles": { "version": "3.2.1", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz", "integrity": "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==", + "dev": true, "requires": { "color-convert": "^1.9.0" } @@ -4312,12 +4555,14 @@ "camelcase": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz", - "integrity": "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==" + "integrity": "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==", + "dev": true }, "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, "requires": { "ansi-styles": "^3.2.1", "escape-string-regexp": "^1.0.5", @@ -4328,6 +4573,7 @@ "version": "4.1.0", "resolved": "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz", "integrity": "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==", + "dev": true, "requires": { "string-width": "^2.1.1", "strip-ansi": "^4.0.0", @@ -4338,6 +4584,7 @@ "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, "requires": { "color-name": "1.1.3" } @@ -4345,22 +4592,26 @@ "color-name": { "version": "1.1.3", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz", - "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" + "integrity": "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==", + "dev": true }, "decamelize": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz", - "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==" + "integrity": "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==", + "dev": true }, "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==" + "integrity": "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==", + "dev": true }, "find-up": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz", "integrity": "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==", + "dev": true, "requires": { "locate-path": "^2.0.0" } @@ -4368,22 +4619,26 @@ "get-caller-file": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz", - "integrity": "sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==" + "integrity": "sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==", + "dev": true }, "has-flag": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", - "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==" + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "dev": true }, "is-fullwidth-code-point": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz", - "integrity": "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==" + "integrity": "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==", + "dev": true }, "locate-path": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz", "integrity": "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==", + "dev": true, "requires": { "p-locate": "^2.0.0", "path-exists": "^3.0.0" @@ -4393,6 +4648,7 @@ "version": "1.3.0", "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz", "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==", + "dev": true, "requires": { "p-try": "^1.0.0" } @@ -4401,6 +4657,7 @@ "version": "2.0.0", "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz", "integrity": "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==", + "dev": true, "requires": { "p-limit": "^1.1.0" } @@ -4408,12 +4665,14 @@ "path-exists": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz", - "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==" + "integrity": "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==", + "dev": true }, "string-width": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz", "integrity": "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==", + "dev": true, "requires": { "is-fullwidth-code-point": "^2.0.0", "strip-ansi": "^4.0.0" @@ -4423,6 +4682,7 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz", "integrity": "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==", + "dev": true, "requires": { "ansi-regex": "^3.0.0" } @@ -4431,6 +4691,7 @@ "version": "5.5.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "dev": true, "requires": { "has-flag": "^3.0.0" } @@ -4439,6 +4700,7 @@ "version": "2.1.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz", "integrity": "sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw==", + "dev": true, "requires": { "string-width": "^1.0.1", "strip-ansi": "^3.0.1" @@ -4447,12 +4709,14 @@ "ansi-regex": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", - "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "dev": true }, "is-fullwidth-code-point": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz", "integrity": "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==", + "dev": true, "requires": { "number-is-nan": "^1.0.0" } @@ -4461,6 +4725,7 @@ "version": "1.0.2", "resolved": "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz", "integrity": "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==", + "dev": true, "requires": { "code-point-at": "^1.0.0", "is-fullwidth-code-point": "^1.0.0", @@ -4471,6 +4736,7 @@ "version": "3.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dev": true, "requires": { "ansi-regex": "^2.0.0" } @@ -4480,12 +4746,14 @@ "y18n": { "version": "3.2.2", "resolved": "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz", - "integrity": "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==" + "integrity": "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==", + "dev": true }, "yargs": { "version": "11.1.1", "resolved": "https://registry.npmjs.org/yargs/-/yargs-11.1.1.tgz", "integrity": "sha512-PRU7gJrJaXv3q3yQZ/+/X6KBswZiaQ+zOmdprZcouPYtQgvNU35i+68M4b1ZHLZtYFT5QObFLV+ZkmJYcwKdiw==", + "dev": true, "requires": { "cliui": "^4.0.0", "decamelize": "^1.1.1", @@ -4505,6 +4773,7 @@ "version": "9.0.2", "resolved": "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz", "integrity": "sha512-CswCfdOgCr4MMsT1GzbEJ7Z2uYudWyrGX8Bgh/0eyCzj/DXWdKq6a/ADufkzI1WAOIW6jYaXJvRyLhDO0kfqBw==", + "dev": true, "requires": { "camelcase": "^4.1.0" } @@ -4526,7 +4795,8 @@ "nice-try": { "version": "1.0.5", "resolved": "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz", - "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" + "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", + "dev": true }, "normalize-path": { "version": "3.0.0", @@ -4538,6 +4808,7 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz", "integrity": "sha512-lJxZYlT4DW/bRUtFh1MQIWqmLwQfAxnqWG4HhEdjMlkrJYnJn0Jrr2u3mgxqaWsdiBc76TYkTG/mhrnYTuzfHw==", + "dev": true, "requires": { "path-key": "^2.0.0" } @@ -4545,12 +4816,14 @@ "number-is-nan": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz", - "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==" + "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==", + "dev": true }, "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, "requires": { "wrappy": "1" } @@ -4567,6 +4840,7 @@ "version": "3.1.0", "resolved": "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz", "integrity": "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==", + "dev": true, "requires": { "execa": "^1.0.0", "lcid": "^2.0.0", @@ -4576,17 +4850,20 @@ "p-defer": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz", - "integrity": "sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw==" + "integrity": "sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw==", + "dev": true }, "p-finally": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", - "integrity": "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==" + "integrity": "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==", + "dev": true }, "p-is-promise": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz", - "integrity": "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==" + "integrity": "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==", + "dev": true }, "p-limit": { "version": "3.1.0", @@ -4609,7 +4886,8 @@ "p-try": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz", - "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==" + "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==", + "dev": true }, "path-exists": { "version": "4.0.0", @@ -4626,12 +4904,14 @@ "path-key": { "version": "2.0.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz", - "integrity": "sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==" + "integrity": "sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==", + "dev": true }, "pathval": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", - "integrity": "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==" + "integrity": "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==", + "dev": true }, "picomatch": { "version": "2.3.1", @@ -4643,20 +4923,35 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", "integrity": "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==", + "dev": true, "requires": { "end-of-stream": "^1.1.0", "once": "^1.3.1" } }, + "queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==" + }, "randombytes": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", - "dev": true, "requires": { "safe-buffer": "^5.1.0" } }, + "readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, "readdirp": { "version": "3.6.0", "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", @@ -4669,18 +4964,19 @@ "require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", - "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==" + "integrity": "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==", + "dev": true }, "require-main-filename": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz", - "integrity": "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==" + "integrity": "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==", + "dev": true }, "safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", - "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", - "dev": true + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" }, "safer-buffer": { "version": "2.1.2", @@ -4696,7 +4992,8 @@ "semver": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", - "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "dev": true }, "serialize-javascript": { "version": "6.0.0", @@ -4710,12 +5007,14 @@ "set-blocking": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz", - "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==" + "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", + "dev": true }, "shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", "integrity": "sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==", + "dev": true, "requires": { "shebang-regex": "^1.0.0" } @@ -4723,12 +5022,36 @@ "shebang-regex": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz", - "integrity": "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==" + "integrity": "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==", + "dev": true }, "signal-exit": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", + "dev": true + }, + "simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "requires": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "requires": { + "safe-buffer": "~5.2.0" + } }, "string-width": { "version": "4.2.3", @@ -4753,7 +5076,8 @@ "strip-eof": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", - "integrity": "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==" + "integrity": "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==", + "dev": true }, "strip-hex-prefix": { "version": "1.0.0", @@ -4791,6 +5115,7 @@ "version": "10.9.1", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", "integrity": "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==", + "dev": true, "requires": { "@cspotcode/source-map-support": "^0.8.0", "@tsconfig/node10": "^1.0.7", @@ -4820,22 +5145,31 @@ "type-detect": { "version": "4.0.8", "resolved": "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz", - "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" + "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", + "dev": true }, "typescript": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz", - "integrity": "sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw==" + "integrity": "sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw==", + "dev": true + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" }, "v8-compile-cache-lib": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz", - "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==" + "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", + "dev": true }, "which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", "integrity": "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==", + "dev": true, "requires": { "isexe": "^2.0.0" } @@ -4843,7 +5177,8 @@ "which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", - "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==" + "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==", + "dev": true }, "workerpool": { "version": "6.2.1", @@ -4865,7 +5200,8 @@ "wrappy": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", - "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true }, "ws": { "version": "7.4.6", @@ -4916,7 +5252,8 @@ "yn": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz", - "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" + "integrity": "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==", + "dev": true }, "yocto-queue": { "version": "0.1.0", diff --git a/packages/restapi/src/lib/chat/addAdminsToGroup.ts b/packages/restapi/src/lib/chat/addAdminsToGroup.ts new file mode 100644 index 000000000..f40cd0581 --- /dev/null +++ b/packages/restapi/src/lib/chat/addAdminsToGroup.ts @@ -0,0 +1,103 @@ +import { isValidETHAddress, walletToPCAIP10 } from '../helpers'; +import Constants from '../constants'; +import { EnvOptionsType, SignerType, GroupDTO } from '../types'; +import { + getMembersList, + getAdminsList, +} from './helpers'; +import { + getGroup +} from './getGroup'; +import { + updateGroup +} from './updateGroup'; +export interface AddAdminsToGroupType extends EnvOptionsType { + chatId: string; + admins: Array; + account?: string | null; + signer?: SignerType | null; + pgpPrivateKey?: string | null; +} + +export const addAdminsToGroup = async ( + options: AddAdminsToGroupType +): Promise => { + const { + chatId, + admins, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + if (!admins || admins.length === 0) { + throw new Error("Admin address array cannot be empty!"); + } + + admins.forEach((admin) => { + if (!isValidETHAddress(admin)) { + throw new Error(`Invalid admin address: ${admin}`); + } + }); + + const group = await getGroup({ + chatId: chatId, + env, + }) + + // TODO: look at user did in updateGroup + const convertedMembers = getMembersList( + group.members, group.pendingMembers + ); + + // TODO: look at user did in updateGroup + const adminsToBeAdded = admins.map((admin) => walletToPCAIP10(admin)); + + adminsToBeAdded.forEach((admin) => { + if (!convertedMembers.includes(admin)) { + convertedMembers.push(admin); + } + }); + + const convertedAdmins = getAdminsList( + group.members, group.pendingMembers + ); + + adminsToBeAdded.forEach((admin) => { + if (convertedAdmins.includes(admin)) { + throw new Error(`Admin ${admin} already exists in the list`); + } + }); + + convertedAdmins.push(...adminsToBeAdded); + + return await updateGroup({ + chatId: chatId, + groupName: group.groupName, + groupImage: group.groupImage, + groupDescription: group.groupDescription, + members: convertedMembers, + admins: convertedAdmins, + scheduleAt: group.scheduleAt, + scheduleEnd: group.scheduleEnd, + status: group.status, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${addAdminsToGroup.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${addAdminsToGroup.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/chat/addMembersToGroup.ts b/packages/restapi/src/lib/chat/addMembersToGroup.ts new file mode 100644 index 000000000..d50c7438f --- /dev/null +++ b/packages/restapi/src/lib/chat/addMembersToGroup.ts @@ -0,0 +1,101 @@ +import { isValidETHAddress, walletToPCAIP10 } from '../helpers'; +import Constants from '../constants'; +import { EnvOptionsType, SignerType, GroupDTO } from '../types'; +import { + getWallet, + getMembersList, + getAdminsList +} from './helpers'; +import { + getGroup +} from './getGroup'; +import { + updateGroup +} from './updateGroup'; +export interface AddMembersToGroupType extends EnvOptionsType { + chatId: string; + members: Array; + account?: string | null; + signer?: SignerType | null; + pgpPrivateKey?: string | null; +} + +/** + * Update Group information + */ +export const addMembersToGroup = async ( + options: AddMembersToGroupType +): Promise => { + const { + chatId, + members, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + if (!members || members.length === 0) { + throw new Error("Member address array cannot be empty!"); + } + + members.forEach((member) => { + if (!isValidETHAddress(member)) { + throw new Error(`Invalid member address: ${member}`); + } + }); + + const wallet = getWallet({ account, signer }); + + const group = await getGroup({ + chatId: chatId, + env, + }) + + const convertedMembers = getMembersList( + group.members, group.pendingMembers + ); + + const membersToBeAdded = members.map((member) => walletToPCAIP10(member)); + + membersToBeAdded.forEach((member) => { + if (convertedMembers.includes(member)) { + throw new Error(`Member ${member} already exists in the list`); + } + }); + + convertedMembers.push(...membersToBeAdded); + + const convertedAdmins = getAdminsList( + group.members, group.pendingMembers + ); + + return await updateGroup({ + chatId: chatId, + groupName: group.groupName, + groupImage: group.groupImage, + groupDescription: group.groupDescription, + members: convertedMembers, + admins: convertedAdmins, + scheduleAt: group.scheduleAt, + scheduleEnd: group.scheduleEnd, + status: group.status, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${addMembersToGroup.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${addMembersToGroup.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/chat/approveRequest.ts b/packages/restapi/src/lib/chat/approveRequest.ts index ae9364263..7d357ffb9 100644 --- a/packages/restapi/src/lib/chat/approveRequest.ts +++ b/packages/restapi/src/lib/chat/approveRequest.ts @@ -12,22 +12,21 @@ import { getUserDID, } from './helpers'; import * as CryptoJS from 'crypto-js'; -import { get } from '../user'; interface ApproveRequestOptionsType extends EnvOptionsType { /** * Chat request sender address */ senderAddress: string; - pgpPrivateKey?: string; + pgpPrivateKey?: string | null; /** * Request state. As of now, only `Approved` is allowed */ status?: 'Approved'; // sigType?: string; - account?: string; - signer?: SignerType; + account?: string | null; + signer?: SignerType | null; } /** diff --git a/packages/restapi/src/lib/chat/createGroup.ts b/packages/restapi/src/lib/chat/createGroup.ts index 6914132a1..0eca88732 100644 --- a/packages/restapi/src/lib/chat/createGroup.ts +++ b/packages/restapi/src/lib/chat/createGroup.ts @@ -10,24 +10,28 @@ import { getWallet, getUserDID, getConnectedUserV2, + validateScheduleDates, } from './helpers'; import * as CryptoJS from 'crypto-js'; export interface ChatCreateGroupType extends EnvOptionsType { - account?: string; - signer?: SignerType; + account?: string | null; + signer?: SignerType | null; groupName: string; groupDescription: string; members: Array; - groupImage: string; + groupImage: string | null; admins: Array; isPublic: boolean; contractAddressNFT?: string; numberOfNFTs?: number; contractAddressERC20?: string; numberOfERC20?: number; - pgpPrivateKey?: string; + pgpPrivateKey?: string | null; meta?: string; + groupType? : string | null, + scheduleAt ?: Date | null; + scheduleEnd?: Date | null; } export const createGroup = async ( @@ -49,6 +53,9 @@ export const createGroup = async ( env = Constants.ENV.PROD, pgpPrivateKey = null, meta, + groupType, + scheduleAt, + scheduleEnd } = options || {}; try { @@ -56,6 +63,8 @@ export const createGroup = async ( throw new Error(`At least one from account or signer is necessary!`); } + validateScheduleDates(scheduleAt, scheduleEnd) + const wallet = getWallet({ account, signer }); createGroupRequestValidator( @@ -120,7 +129,10 @@ export const createGroup = async ( numberOfNFTs, contractAddressERC20, numberOfERC20, - meta + meta, + groupType, + scheduleAt, + scheduleEnd ); return axios diff --git a/packages/restapi/src/lib/chat/helpers/inbox.ts b/packages/restapi/src/lib/chat/helpers/inbox.ts index 3757a59f3..07d4f32b0 100644 --- a/packages/restapi/src/lib/chat/helpers/inbox.ts +++ b/packages/restapi/src/lib/chat/helpers/inbox.ts @@ -4,7 +4,7 @@ import { isValidCAIP10NFTAddress, pCAIP10ToWallet, } from '../../helpers'; -import { IFeeds, IMessageIPFS, IUser } from '../../types'; +import { IFeeds, IMessageIPFS, IUser, SpaceIFeeds } from '../../types'; import { get as getUser } from '../../user'; import { getCID } from '../ipfs'; import { decryptFeeds } from './crypto'; @@ -16,6 +16,20 @@ type InboxListsType = { pgpPrivateKey?: string; env?: ENV; }; + +type SpaceInboxListsType = { + lists: SpaceIFeeds[]; + user: string; //caip10 + toDecrypt: boolean; + pgpPrivateKey?: string; + env?: ENV; +}; + +type TrendingSpaceInboxListsType = { + lists: SpaceIFeeds[]; + env?: ENV; +}; + type DecryptConverationType = { messages: IMessageIPFS[]; connectedUser: IUser; //caip10 @@ -68,6 +82,89 @@ export const getInboxLists = async ( return feeds; }; +export const getSpaceInboxLists = async ( + options: SpaceInboxListsType +): Promise => { + const { + lists, + user, + toDecrypt, + pgpPrivateKey, + env = Constants.ENV.PROD, + } = options || {}; + const connectedUser = await getUser({ account: pCAIP10ToWallet(user), env }); + const feeds: SpaceIFeeds[] = []; + for (const list of lists) { + let message; + if (list.threadhash !== null) { + message = await getCID(list.threadhash, { env }); + } + // This is for groups that are created without any message + else { + message = { + encType: 'PlainText', + encryptedSecret: '', + fromCAIP10: '', + fromDID: '', + link: '', + messageContent: '', + messageType: '', + sigType: '', + signature: '', + toCAIP10: '', + toDID: '', + }; + } + feeds.push({ + ...list, + msg: message, + spaceInformation: list.spaceInformation, + }); + } + + if (toDecrypt) + return decryptFeeds({ feeds, connectedUser, pgpPrivateKey, env }); + return feeds; +}; + +export const getTrendingSpaceInboxLists = async ( + options: TrendingSpaceInboxListsType +): Promise => { + const { + lists, + env = Constants.ENV.PROD, + } = options || {}; + const feeds: SpaceIFeeds[] = []; + for (const list of lists) { + let message; + if (list.threadhash !== null) { + message = await getCID(list.threadhash, { env }); + } + // This is for groups that are created without any message + else { + message = { + encType: 'PlainText', + encryptedSecret: '', + fromCAIP10: '', + fromDID: '', + link: '', + messageContent: '', + messageType: '', + sigType: '', + signature: '', + toCAIP10: '', + toDID: '', + }; + } + feeds.push({ + ...list, + msg: message, + spaceInformation: list.spaceInformation, + }); + } + return feeds; +}; + export const decryptConversation = async (options: DecryptConverationType) => { const { messages, diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index c0b76a8fc..23777288d 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -1,5 +1,5 @@ import { isValidETHAddress, walletToPCAIP10 } from '../../helpers'; -import { IConnectedUser, GroupDTO } from '../../types'; +import { IConnectedUser, GroupDTO, SpaceDTO, ChatStatus } from '../../types'; import { getEncryptedRequest } from './crypto'; import { getGroup } from '../getGroup'; import { ENV } from '../../constants'; @@ -29,9 +29,9 @@ export interface IApproveRequestPayload { export interface ICreateGroupRequestPayload { groupName: string; - groupDescription: string; + groupDescription: string | null; members: Array; - groupImage: string; + groupImage: string | null; admins: Array; isPublic: boolean; contractAddressNFT?: string; @@ -45,7 +45,7 @@ export interface ICreateGroupRequestPayload { export interface IUpdateGroupRequestPayload { groupName: string; - groupImage: string; + groupImage: string | null; members: Array; admins: Array; address: string; @@ -122,9 +122,9 @@ export const approveRequestPayload = ( export const createGroupPayload = ( groupName: string, - groupDescription: string, + groupDescription: string | null, members: Array, - groupImage: string, + groupImage: string | null, admins: Array, isPublic: boolean, groupCreator: string, @@ -133,7 +133,10 @@ export const createGroupPayload = ( numberOfNFTs?: number, contractAddressERC20?: string, numberOfERC20?: number, - meta?: string + meta?: string, + groupType? : string | null, + scheduleAt?: Date | null, + scheduleEnd?: Date | null ): ICreateGroupRequestPayload => { const body = { groupName: groupName, @@ -149,18 +152,46 @@ export const createGroupPayload = ( groupCreator: groupCreator, verificationProof: verificationProof, meta: meta, + groupType: groupType, + scheduleAt: scheduleAt, + scheduleEnd: scheduleEnd }; return body; }; +export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { + const spaceDto: SpaceDTO = { + members: groupDto.members, + pendingMembers: groupDto.pendingMembers, + contractAddressERC20: groupDto.contractAddressERC20, + numberOfERC20: groupDto.numberOfERC20, + contractAddressNFT: groupDto.contractAddressNFT, + numberOfNFTTokens: groupDto.numberOfNFTTokens, + verificationProof: groupDto.verificationProof, + spaceImage: groupDto.groupImage, + spaceName: groupDto.groupName, + isPublic: groupDto.isPublic, + spaceDescription: groupDto.groupDescription, + spaceCreator: groupDto.groupCreator, + spaceId: groupDto.chatId, + scheduleAt: groupDto.scheduleAt, + scheduleEnd: groupDto.scheduleEnd, + status: groupDto.status ?? null + }; + return spaceDto; +}; + export const updateGroupPayload = ( groupName: string, - groupImage: string, - groupDescription: string, + groupImage: string | null, + groupDescription: string | null, members: Array, admins: Array, address: string, - verificationProof: string + verificationProof: string, + scheduleAt?: Date | null, + scheduleEnd?: Date | null, + status?: ChatStatus | null ): IUpdateGroupRequestPayload => { const body = { groupName: groupName, @@ -170,6 +201,59 @@ export const updateGroupPayload = ( admins: admins, address: address, verificationProof: verificationProof, + scheduleAt: scheduleAt, + scheduleEnd: scheduleEnd, + status: status }; return body; }; + +// helper.ts + +export const getAdminsList = ( + members: { + wallet: string; + publicKey: string; + isAdmin: boolean; + image: string; + }[], + pendingMembers: { + wallet: string; + publicKey: string; + isAdmin: boolean; + image: string; + }[] +): Array => { + const adminsFromMembers = members + ? convertToWalletAddressList(members.filter((admin) => admin.isAdmin)) + : []; + + const adminsFromPendingMembers = pendingMembers + ? convertToWalletAddressList(pendingMembers.filter((admin) => admin.isAdmin)) + : []; + + const adminList = [...adminsFromMembers, ...adminsFromPendingMembers]; + return adminList; +}; + +export const convertToWalletAddressList = (memberList: { wallet: string }[]): string[] => { + return memberList ? memberList.map((member) => member.wallet) : []; +}; + +export const getMembersList = ( + members: { + wallet: string; + publicKey: string; + isAdmin: boolean; + image: string; + }[], + pendingMembers: { + wallet: string; + publicKey: string; + isAdmin: boolean; + image: string; + }[] +): Array => { + const allMembers = [...(members || []), ...(pendingMembers || [])]; + return convertToWalletAddressList(allMembers); +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/chat/helpers/validator.ts b/packages/restapi/src/lib/chat/helpers/validator.ts index d21a23cca..a81bfe251 100644 --- a/packages/restapi/src/lib/chat/helpers/validator.ts +++ b/packages/restapi/src/lib/chat/helpers/validator.ts @@ -4,7 +4,7 @@ import { } from '../../helpers'; export const createGroupRequestValidator = ( - groupName: string, groupDescription: string,members: Array < string > , admins: Array < string > , contractAddressNFT ? : string, + groupName: string, groupDescription: string | null,members: Array < string > , admins: Array < string > , contractAddressNFT ? : string, numberOfNFTs ? : number, contractAddressERC20 ? : string, numberOfERC20 ? : number @@ -59,8 +59,89 @@ export const createGroupRequestValidator = ( } }; +export const createSpaceRequestValidator = ( + spaceName: string, spaceDescription: string | null,members: Array < string > , admins: Array < string > , contractAddressNFT ? : string, + numberOfNFTs ? : number, + contractAddressERC20 ? : string, + numberOfERC20 ? : number +): void => { + + if (spaceName == null || spaceName.length == 0) { + throw new Error(`spaceName cannot be null or empty`); + } + + if (spaceName.length > 50) { + throw new Error(`groupName cannot be more than 50 characters`); + } + + if (spaceDescription && spaceDescription.length > 150) { + throw new Error(`spaceDescription cannot be more than 150 characters`); + } + + if (members == null) { + throw new Error(`members cannot be null`); + } + + for (let i = 0; i < members.length; i++) { + if (members[i] && !isValidETHAddress(members[i])) { + throw new Error(`Invalid member address!`); + } + } + + if (admins == null) { + throw new Error(`admins cannot be null`); + } + + for (let i = 0; i < admins.length; i++) { + if (!isValidETHAddress(admins[i])) { + throw new Error(`Invalid admin address!`); + } + } + + if (contractAddressNFT != null && contractAddressNFT?.length > 0 && !isValidNFTCAIP10Address(contractAddressNFT)) { + throw new Error(`Invalid contractAddressNFT address!`); + } + + if (numberOfNFTs != null && numberOfNFTs < 0) { + throw new Error(`numberOfNFTs cannot be negative number`); + } + + if (contractAddressERC20 != null && contractAddressERC20?.length > 0 && !isValidNFTCAIP10Address(contractAddressERC20)) { + throw new Error(`Invalid contractAddressERC20 address!`); + } + + if (numberOfERC20 != null && numberOfERC20 < 0) { + throw new Error(`numberOfERC20 cannot be negative number`); + } +}; + +export const validateScheduleDates = (scheduleAt?: Date | null, + scheduleEnd ? : Date | null): void => { + + if (scheduleAt) { + const start = new Date(scheduleAt) + const now = new Date() + + if (start < now) { + throw new Error('Schedule start time must be in the future.') + } + + if (scheduleEnd) { + const end = new Date(scheduleEnd) + + if (end < now) { + throw new Error('Schedule end time must be in the future.') + } + + if (start >= end) { + throw new Error('Schedule start time must be earlier than end time.') + } + } + } +}; + export const updateGroupRequestValidator = ( - chatId: string, groupName: string, groupDescription: string, profilePicture: string, members: Array < string > , + chatId: string, groupName: string, groupDescription: string | null, members: Array < string > , admins: Array < string > , address: string ): void => { @@ -73,10 +154,6 @@ export const updateGroupRequestValidator = ( throw new Error(`groupName cannot be null or empty`); } - if (profilePicture == null || profilePicture.length == 0) { - throw new Error(`profilePicture cannot be null or empty`); - } - if (groupName != null && groupName.length > 50) { throw new Error(`groupName cannot be more than 50 characters`); } diff --git a/packages/restapi/src/lib/chat/index.ts b/packages/restapi/src/lib/chat/index.ts index 8588cabd3..e67bb2d67 100644 --- a/packages/restapi/src/lib/chat/index.ts +++ b/packages/restapi/src/lib/chat/index.ts @@ -14,3 +14,7 @@ export * from './createGroup'; export * from './updateGroup'; export * from './getGroup'; export * from './getGroupByName'; +export * from './addMembersToGroup'; +export * from './addAdminsToGroup'; +export * from './removeMembersFromGroup'; +export * from './removeAdminsFromGroup'; diff --git a/packages/restapi/src/lib/chat/removeAdminsFromGroup.ts b/packages/restapi/src/lib/chat/removeAdminsFromGroup.ts new file mode 100644 index 000000000..250e28ad1 --- /dev/null +++ b/packages/restapi/src/lib/chat/removeAdminsFromGroup.ts @@ -0,0 +1,111 @@ +import { isValidETHAddress, walletToPCAIP10 } from '../helpers'; +import Constants from '../constants'; +import { EnvOptionsType, SignerType, GroupDTO } from '../types'; +import { + getWallet, + getMembersList, + getAdminsList +} from './helpers'; +import { + getGroup +} from './getGroup'; +import { + updateGroup +} from './updateGroup'; +export interface RemoveAdminsFromGroupType extends EnvOptionsType { + chatId: string; + admins: Array; + account?: string | null; + signer?: SignerType | null; + pgpPrivateKey?: string | null; +} + +/** + * Update Group information + */ +export const removeAdminsFromGroup = async ( + options: RemoveAdminsFromGroupType +): Promise => { + const { + chatId, + admins, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + if (!admins || admins.length === 0) { + throw new Error("Admin address array cannot be empty!"); + } + + admins.forEach((admin) => { + if (!isValidETHAddress(admin)) { + throw new Error(`Invalid admin address: ${admin}`); + } + }); + + const group = await getGroup({ + chatId: chatId, + env, + }) + + let convertedMembers = getMembersList( + group.members, group.pendingMembers + ); + + const adminsToBeRemoved = admins.map((admin) => walletToPCAIP10(admin)); + + adminsToBeRemoved.forEach((admin) => { + if (!convertedMembers.includes(admin)) { + throw new Error(`Member ${admin} not present in the list`); + } + }); + + let convertedAdmins = getAdminsList( + group.members, group.pendingMembers + ); + + adminsToBeRemoved.forEach((admin) => { + if (!convertedAdmins.includes(admin)) { + throw new Error(`Admin ${admin} not present in the list`); + } + }); + + convertedMembers = convertedMembers.filter( + (member) => !adminsToBeRemoved.includes(member) + ); + + convertedAdmins = convertedAdmins.filter( + (member) => !adminsToBeRemoved.includes(member) + ); + + return await updateGroup({ + chatId: chatId, + groupName: group.groupName, + groupImage: group.groupImage, + groupDescription: group.groupDescription, + members: convertedMembers, + admins: convertedAdmins, + scheduleAt: group.scheduleAt, + scheduleEnd: group.scheduleEnd, + status: group.status, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${removeAdminsFromGroup.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${removeAdminsFromGroup.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/chat/removeMembersFromGroup.ts b/packages/restapi/src/lib/chat/removeMembersFromGroup.ts new file mode 100644 index 000000000..7a0b5a592 --- /dev/null +++ b/packages/restapi/src/lib/chat/removeMembersFromGroup.ts @@ -0,0 +1,97 @@ +import { isValidETHAddress, walletToPCAIP10 } from '../helpers'; +import Constants from '../constants'; +import { EnvOptionsType, SignerType, GroupDTO } from '../types'; +import { + getMembersList, + getAdminsList +} from './helpers'; +import { + getGroup +} from './getGroup'; +import { + updateGroup +} from './updateGroup'; +export interface RemoveMembersFromGroupType extends EnvOptionsType { + chatId: string; + members: Array; + account?: string | null; + signer?: SignerType | null; + pgpPrivateKey?: string | null; +} + +export const removeMembersFromGroup = async ( + options: RemoveMembersFromGroupType +): Promise => { + const { + chatId, + members, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + if (!members || members.length === 0) { + throw new Error("Member address array cannot be empty!"); + } + + members.forEach((member) => { + if (!isValidETHAddress(member)) { + throw new Error(`Invalid member address: ${member}`); + } + }); + + const group = await getGroup({ + chatId: chatId, + env, + }) + + let convertedMembers = getMembersList( + group.members, group.pendingMembers + ); + + const membersToBeRemoved = members.map((member) => walletToPCAIP10(member)); + + membersToBeRemoved.forEach((member) => { + if (!convertedMembers.includes(member)) { + throw new Error(`Member ${member} not present in the list`); + } + }); + + convertedMembers = convertedMembers.filter( + (member) => !membersToBeRemoved.includes(member) + ); + + const convertedAdmins = getAdminsList( + group.members, group.pendingMembers + ); + + return await updateGroup({ + chatId: chatId, + groupName: group.groupName, + groupImage: group.groupImage, + groupDescription: group.groupDescription, + members: convertedMembers, + admins: convertedAdmins, + scheduleAt: group.scheduleAt, + scheduleEnd: group.scheduleEnd, + status: group.status, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${removeMembersFromGroup.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${removeMembersFromGroup.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/chat/send.ts b/packages/restapi/src/lib/chat/send.ts index da86fdac8..9ac06ce30 100644 --- a/packages/restapi/src/lib/chat/send.ts +++ b/packages/restapi/src/lib/chat/send.ts @@ -27,6 +27,7 @@ export const send = async ( pgpPrivateKey = null, apiKey = '', env = Constants.ENV.PROD, + } = options || {}; try { diff --git a/packages/restapi/src/lib/chat/start.ts b/packages/restapi/src/lib/chat/start.ts index 880eefe70..d1fa04134 100644 --- a/packages/restapi/src/lib/chat/start.ts +++ b/packages/restapi/src/lib/chat/start.ts @@ -19,9 +19,7 @@ export const start = async ( const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/chat/request`; - const headers = { - authorization: `Bearer ${apiKey}`, - }; + const body: ISendMessagePayload = await sendMessagePayload( receiverAddress, connectedUser, @@ -48,7 +46,7 @@ export const start = async ( body.verificationProof = verificationProof; return axios - .post(apiEndpoint, body, { headers }) + .post(apiEndpoint, body) .then((response) => { return response.data; }) diff --git a/packages/restapi/src/lib/chat/updateGroup.ts b/packages/restapi/src/lib/chat/updateGroup.ts index 77b048d72..bf72e1210 100644 --- a/packages/restapi/src/lib/chat/updateGroup.ts +++ b/packages/restapi/src/lib/chat/updateGroup.ts @@ -1,29 +1,33 @@ import axios from 'axios'; import { getAPIBaseUrls } from '../helpers'; import Constants from '../constants'; -import { EnvOptionsType, GroupDTO, SignerType } from '../types'; +import { ChatStatus, EnvOptionsType, GroupDTO, SignerType } from '../types'; import { IUpdateGroupRequestPayload, updateGroupPayload, sign, - updateGroupRequestValidator, getWallet, getAccountAddress, getUserDID, getConnectedUserV2, + updateGroupRequestValidator, + validateScheduleDates } from './helpers'; import * as CryptoJS from 'crypto-js'; export interface ChatUpdateGroupType extends EnvOptionsType { - account?: string; - signer?: SignerType; + account?: string | null; + signer?: SignerType | null; chatId: string; groupName: string; - groupImage: string; + groupImage: string | null; groupDescription: string; members: Array; admins: Array; - pgpPrivateKey?: string; + pgpPrivateKey?: string | null; + scheduleAt?: Date | null + scheduleEnd?: Date | null + status?: ChatStatus | null } /** @@ -43,6 +47,9 @@ export const updateGroup = async ( signer = null, env = Constants.ENV.PROD, pgpPrivateKey = null, + scheduleAt, + scheduleEnd, + status, } = options || {}; try { if (account == null && signer == null) { @@ -55,11 +62,12 @@ export const updateGroup = async ( chatId, groupName, groupDescription, - groupImage, members, admins, address ); + validateScheduleDates(scheduleAt, scheduleEnd) + const connectedUser = await getConnectedUserV2(wallet, pgpPrivateKey, env); const convertedMembersPromise = members.map(async (each) => { return getUserDID(each, env); @@ -93,7 +101,10 @@ export const updateGroup = async ( convertedMembers, convertedAdmins, connectedUser.did, - verificationProof + verificationProof, + scheduleAt, + scheduleEnd, + status, ); return axios diff --git a/packages/restapi/src/lib/index.ts b/packages/restapi/src/lib/index.ts index e6d504b46..a1d55b3a1 100644 --- a/packages/restapi/src/lib/index.ts +++ b/packages/restapi/src/lib/index.ts @@ -4,6 +4,7 @@ import * as user from './user'; import * as utils from './utils'; import * as payloads from './payloads'; import * as chat from './chat'; +import * as space from './space'; import * as video from "./video" export * from './types'; @@ -15,5 +16,6 @@ export { utils, payloads, chat, + space, video } \ No newline at end of file diff --git a/packages/restapi/src/lib/space/addAdminsToSpace.ts b/packages/restapi/src/lib/space/addAdminsToSpace.ts new file mode 100644 index 000000000..d2c5f6a8e --- /dev/null +++ b/packages/restapi/src/lib/space/addAdminsToSpace.ts @@ -0,0 +1,34 @@ +import Constants from '../constants'; +import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; +import { groupDtoToSpaceDto } from './../chat/helpers'; +import { addAdminsToGroup } from '../chat/addAdminsToGroup'; + +export interface AddAdminsToSpaceType extends EnvOptionsType { + spaceId: string; + admins: Array; + account?: string; + signer?: SignerType; + pgpPrivateKey?: string; +} + +export const addAdminsToSpace = async (options: AddAdminsToSpaceType): Promise => { + const { + spaceId, + admins, + account = null, + signer = null, + env = options?.env ?? Constants.ENV.PROD, + pgpPrivateKey = options?.pgpPrivateKey ?? null, + } = options; + + const group = await addAdminsToGroup({ + chatId: spaceId, + admins: admins, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + + return groupDtoToSpaceDto(group); +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/addMembersToSpace.ts b/packages/restapi/src/lib/space/addMembersToSpace.ts new file mode 100644 index 000000000..0f4c7a6f7 --- /dev/null +++ b/packages/restapi/src/lib/space/addMembersToSpace.ts @@ -0,0 +1,49 @@ +import Constants from '../constants'; +import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; +import { + groupDtoToSpaceDto +} from './../chat/helpers'; + + +import { addMembersToGroup } from '../chat/addMembersToGroup'; + +export interface AddMembersToSpaceType extends EnvOptionsType { + spaceId: string; + members: Array; + account?: string; + signer?: SignerType; + pgpPrivateKey?: string; +} + +export const addMembersToSpace = async ( + options: AddMembersToSpaceType +): Promise => { + const { + spaceId, + members, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + const group = await addMembersToGroup({ + chatId: spaceId, + members: members, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${addMembersToSpace.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${addMembersToSpace.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/space/approve.ts b/packages/restapi/src/lib/space/approve.ts new file mode 100644 index 000000000..0f788e602 --- /dev/null +++ b/packages/restapi/src/lib/space/approve.ts @@ -0,0 +1,58 @@ +import { + isValidETHAddress, +} from '../helpers'; +import Constants from '../constants'; +import { + EnvOptionsType, + SignerType +} from '../types'; +import { + approve as approveRequest +} from '../chat/approveRequest'; +interface ApproveRequestOptionsType extends EnvOptionsType { + senderAddress: string; + pgpPrivateKey ? : string | null; + status ? : 'Approved'; + account ? : string | null; + signer ? : SignerType | null; +} + +export const approve = async ( + options: ApproveRequestOptionsType +): Promise < string > => { + const { + status = 'Approved', + account = null, + signer = null, + senderAddress, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + + try { + + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + if (!isValidETHAddress(senderAddress) && !senderAddress.startsWith("spaces:")) { + throw new Error("Not a valid spaceId or ETH address"); + } + return await approveRequest({ + status: status, + account: account, + signer: signer, + senderAddress: senderAddress, + env: env, + pgpPrivateKey: pgpPrivateKey + }) + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${approve.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${approve.name} -: ${err}` + ); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/create.ts b/packages/restapi/src/lib/space/create.ts new file mode 100644 index 000000000..593aae9fe --- /dev/null +++ b/packages/restapi/src/lib/space/create.ts @@ -0,0 +1,86 @@ +import Constants from '../constants'; +import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; +import { + groupDtoToSpaceDto +} from './../chat/helpers'; +import { createGroup } from '../chat/createGroup'; + +export interface ChatCreateSpaceType extends EnvOptionsType { + account?: string; + signer?: SignerType; + spaceName: string; + spaceDescription: string; + members: Array; + spaceImage: string | null; + admins: Array; + isPublic: boolean; + contractAddressNFT?: string; + numberOfNFTs?: number; + contractAddressERC20?: string; + numberOfERC20?: number; + pgpPrivateKey?: string; + meta?: string; + scheduleAt: Date + scheduleEnd?: Date | null +} + +export const create = async ( + options: ChatCreateSpaceType +): Promise => { + const { + account = null, + signer = null, + spaceName, + spaceDescription, + members, + spaceImage, + admins, + isPublic, + contractAddressNFT, + numberOfNFTs, + contractAddressERC20, + numberOfERC20, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + meta, + scheduleAt, + scheduleEnd, + } = options || {}; + + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + const group = await createGroup({ + account: account, + signer: signer, + groupName: spaceName, + groupDescription: spaceDescription, + members: members, + groupImage: spaceImage, + admins: admins, + isPublic: isPublic, + contractAddressNFT: contractAddressNFT, + numberOfNFTs: numberOfNFTs, + contractAddressERC20: contractAddressERC20, + numberOfERC20: numberOfERC20, + env: env, + pgpPrivateKey: pgpPrivateKey, + meta: meta, + groupType: "spaces", + scheduleAt: scheduleAt, + scheduleEnd: scheduleEnd, + }); + + return groupDtoToSpaceDto(group) + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${create.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${create.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/space/get.ts b/packages/restapi/src/lib/space/get.ts new file mode 100644 index 000000000..75a6c0e79 --- /dev/null +++ b/packages/restapi/src/lib/space/get.ts @@ -0,0 +1,39 @@ +import Constants, { + ENV +} from '../constants'; +import { + SpaceDTO +} from '../types'; +import { + groupDtoToSpaceDto +} from './../chat/helpers'; +import { + getGroup +} from '../chat/getGroup'; + +export interface GetSpaceType { + spaceId: string, + env ? : ENV +} + +export const get = async ( + options: GetSpaceType +): Promise < SpaceDTO > => { + const { + spaceId, + env = Constants.ENV.PROD + } = options || {}; + try { + if (spaceId == null || spaceId.length == 0) { + throw new Error(`spaceId cannot be null or empty`); + } + const group = await getGroup({ + chatId: spaceId, + env + }) + return groupDtoToSpaceDto(group); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${get.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${get.name} -: ${err}`); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/index.ts b/packages/restapi/src/lib/space/index.ts new file mode 100644 index 000000000..508516020 --- /dev/null +++ b/packages/restapi/src/lib/space/index.ts @@ -0,0 +1,15 @@ +export * from './create'; +export * from './update'; +export * from './info'; +export * from './get'; +export * from './approve'; +export * from './start'; +export * from './stop'; +export * from './addAdminsToSpace'; +export * from './addMembersToSpace'; +export * from './removeAdminsFromSpace'; +export * from './removeMembersFromSpace'; +export * from './requests'; +export * from './spaces'; +export * from './trending'; + diff --git a/packages/restapi/src/lib/space/info.ts b/packages/restapi/src/lib/space/info.ts new file mode 100644 index 000000000..d7363372e --- /dev/null +++ b/packages/restapi/src/lib/space/info.ts @@ -0,0 +1,33 @@ +import { + SpaceDTO +} from '../types'; +import { + groupDtoToSpaceDto +} from './../chat/helpers'; +import { GetSpaceType } from './get'; +import { + getGroup +} from '../chat/getGroup'; +import Constants from '../constants'; + +export const info = async ( + options: GetSpaceType +): Promise < SpaceDTO > => { + const { + spaceId, + env = Constants.ENV.PROD + } = options || {}; + try { + if (spaceId == null || spaceId.length == 0) { + throw new Error(`spaceId cannot be null or empty`); + } + const group = await getGroup({ + chatId: spaceId, + env + }) + return groupDtoToSpaceDto(group); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${info.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${info.name} -: ${err}`); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/removeAdminsFromSpace.ts b/packages/restapi/src/lib/space/removeAdminsFromSpace.ts new file mode 100644 index 000000000..a68a9e765 --- /dev/null +++ b/packages/restapi/src/lib/space/removeAdminsFromSpace.ts @@ -0,0 +1,52 @@ +import Constants from '../constants'; +import { + EnvOptionsType, + SignerType, + SpaceDTO +} from '../types'; +import { + groupDtoToSpaceDto +} from './../chat/helpers'; +import { + removeAdminsFromGroup +} from '../chat/removeAdminsFromGroup'; +export interface RemoveAdminsFromSpaceType extends EnvOptionsType { + spaceId: string; + admins: Array < string > ; + account ? : string; + signer ? : SignerType; + pgpPrivateKey ? : string; +} + +export const removeAdminsFromSpace = async ( + options: RemoveAdminsFromSpaceType +): Promise < SpaceDTO > => { + const { + spaceId, + admins, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + const group = await removeAdminsFromGroup({ + chatId: spaceId, + admins: admins, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${removeAdminsFromSpace.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${removeAdminsFromSpace.name} -: ${err}` + ); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/removeMembersFromSpace.ts b/packages/restapi/src/lib/space/removeMembersFromSpace.ts new file mode 100644 index 000000000..b2aa0bdfd --- /dev/null +++ b/packages/restapi/src/lib/space/removeMembersFromSpace.ts @@ -0,0 +1,49 @@ +import Constants from '../constants'; +import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; +import { + groupDtoToSpaceDto +} from './../chat/helpers'; +import { + removeMembersFromGroup +} from '../chat/removeMembersFromGroup'; + +export interface RemoveMembersFromSpaceType extends EnvOptionsType { + spaceId: string; + members: Array; + account?: string; + signer?: SignerType; + pgpPrivateKey?: string; +} + +export const removeMembersFromSpace = async ( + options: RemoveMembersFromSpaceType +): Promise => { + const { + spaceId, + members, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + const group = await removeMembersFromGroup({ + chatId: spaceId, + members: members, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${removeMembersFromSpace.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${removeMembersFromSpace.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/space/requests.ts b/packages/restapi/src/lib/space/requests.ts new file mode 100644 index 000000000..6f85dd131 --- /dev/null +++ b/packages/restapi/src/lib/space/requests.ts @@ -0,0 +1,65 @@ +import axios from 'axios'; +import { getAPIBaseUrls, isValidETHAddress } from '../helpers'; +import Constants, { ENV } from '../constants'; +import { SpaceIFeeds } from '../types'; +import { getSpaceInboxLists, getUserDID } from '../chat/helpers'; + +export type RequestOptionsType = { + account: string; + pgpPrivateKey?: string; + /** + * If true, the method will return decrypted message content in response + */ + toDecrypt?: boolean; + /** + * page index - default 1 + */ + page?: number; + /** + * no of items per page - default 10 - max 30 + */ + limit?: number; + /** + * Environment variable + */ + env?: ENV; +}; + +/** + * The first time an address wants to send a message to another peer, the address sends an intent request. This first message shall not land in this peer Inbox but in its Request box. + * This function will return all the chats that landed on the address' Request box. The user can then approve the request or ignore it for now. + */ +export const requests = async ( + options: RequestOptionsType +): Promise => { + const { + account, + pgpPrivateKey, + env = Constants.ENV.PROD, + toDecrypt = false, + page = 1, + limit = 10, + } = options || {}; + const user = await getUserDID(account, env); + const API_BASE_URL = getAPIBaseUrls(env); + const apiEndpoint = `${API_BASE_URL}/v1/spaces/users/${user}/requests?page=${page}&limit=${limit}`; + try { + if (!isValidETHAddress(user)) { + throw new Error(`Invalid address!`); + } + const response = await axios.get(apiEndpoint); + const requests: SpaceIFeeds[] = response.data.requests; + const Feeds: SpaceIFeeds[] = await getSpaceInboxLists({ + lists: requests, + user, + toDecrypt, + pgpPrivateKey, + env, + }); + + return Feeds; + } catch (err) { + console.error(`[Push SDK] - API ${requests.name}: `, err); + throw Error(`[Push SDK] - API ${requests.name}: ${err}`); + } +}; diff --git a/packages/restapi/src/lib/space/spaces.ts b/packages/restapi/src/lib/space/spaces.ts new file mode 100644 index 000000000..e4cb47dc9 --- /dev/null +++ b/packages/restapi/src/lib/space/spaces.ts @@ -0,0 +1,62 @@ +import axios from 'axios'; +import { getAPIBaseUrls, isValidETHAddress } from '../helpers'; +import Constants, { ENV } from '../constants'; +import { SpaceIFeeds } from '../types'; +import { getSpaceInboxLists, getUserDID } from '../chat/helpers'; + +export type ChatsOptionsType = { + account: string; + pgpPrivateKey?: string; + /** + * If true, the method will return decrypted message content in response + */ + toDecrypt?: boolean; + /** + * page index - default 1 + */ + page?: number; + /** + * no of items per page - default 10 - max 30 + */ + limit?: number; + /** + * Environment variable + */ + env?: ENV; +}; + +/** + * Return the latest message from all wallet addresses you have talked to. This can be used when building the inbox page. + */ +export const spaces = async (options: ChatsOptionsType): Promise => { + const { + account, + pgpPrivateKey, + env = Constants.ENV.PROD, + page = 1, + limit = 10, + } = options || {}; + if (!isValidETHAddress(account)) { + throw new Error(`Invalid address!`); + } + const user = await getUserDID(account, env); + const API_BASE_URL = getAPIBaseUrls(env); + const apiEndpoint = `${API_BASE_URL}/v1/spaces/users/${user}/spaces?page=${page}&limit=${limit}`; + const requestUrl = `${apiEndpoint}`; + try { + const toDecrypt = false; + const response = await axios.get(requestUrl); + const chats: SpaceIFeeds[] = response.data.chats; + const feeds: SpaceIFeeds[] = await getSpaceInboxLists({ + lists: chats, + user: user, + toDecrypt, + pgpPrivateKey, + env, + }); + return feeds; + } catch (err) { + console.error(`[Push SDK] - API ${spaces.name}: `, err); + throw Error(`[Push SDK] - API ${spaces.name}: ${err}`); + } +}; diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts new file mode 100644 index 000000000..f59a385bd --- /dev/null +++ b/packages/restapi/src/lib/space/start.ts @@ -0,0 +1,83 @@ +import Constants from '../constants'; +import { + EnvOptionsType, + SpaceDTO, + SignerType, + ChatStatus +} from '../types'; +import { + groupDtoToSpaceDto, + getMembersList, + getAdminsList +} from './../chat/helpers'; +import { + get +} from './get'; +import { + updateGroup +} from '../chat/updateGroup'; +export interface StartSpaceType extends EnvOptionsType { + spaceId: string; + account ? : string; + signer ? : SignerType; + pgpPrivateKey ? : string; +} + +export const start = async ( + options: StartSpaceType +): Promise < SpaceDTO > => { + const { + spaceId, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + const space = await get({ + spaceId: spaceId, + env, + }) + + if (space.status !== ChatStatus.PENDING) { + throw new Error("Unable to start the space as it is not in the pending state"); + } + + const convertedMembers = getMembersList( + space.members, space.pendingMembers + ); + const convertedAdmins = getAdminsList( + space.members, space.pendingMembers + ); + + const group = await updateGroup({ + chatId: spaceId, + groupName: space.spaceName, + groupImage: space.spaceImage, + groupDescription: space.spaceDescription, + members: convertedMembers, + admins: convertedAdmins, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey, + scheduleAt: space.scheduleAt, + scheduleEnd: space.scheduleEnd, + status: ChatStatus.ACTIVE + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${start.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${start.name} -: ${err}` + ); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/stop.ts b/packages/restapi/src/lib/space/stop.ts new file mode 100644 index 000000000..342a4a3d9 --- /dev/null +++ b/packages/restapi/src/lib/space/stop.ts @@ -0,0 +1,83 @@ +import Constants from '../constants'; +import { + EnvOptionsType, + SpaceDTO, + SignerType, + ChatStatus +} from '../types'; +import { + groupDtoToSpaceDto, + getMembersList, + getAdminsList +} from '../chat/helpers'; +import { + updateGroup +} from '../chat/updateGroup'; +import { + get +} from './get'; +export interface StopSpaceType extends EnvOptionsType { + spaceId: string; + account ? : string; + signer ? : SignerType; + pgpPrivateKey ? : string; +} + +export const stop = async ( + options: StopSpaceType +): Promise < SpaceDTO > => { + const { + spaceId, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + + const space = await get({ + spaceId: spaceId, + env, + }) + + if (space.status === ChatStatus.ENDED) { + throw new Error("Space already ended"); + } + + const convertedMembers = getMembersList( + space.members, space.pendingMembers + ); + const convertedAdmins = getAdminsList( + space.members, space.pendingMembers + ); + + const group = await updateGroup({ + chatId: spaceId, + groupName: space.spaceName, + groupImage: space.spaceImage, + groupDescription: space.spaceDescription, + members: convertedMembers, + admins: convertedAdmins, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey, + scheduleAt: space.scheduleAt, + scheduleEnd: space.scheduleEnd, + status: ChatStatus.ENDED + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${stop.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${stop.name} -: ${err}` + ); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/trending.ts b/packages/restapi/src/lib/space/trending.ts new file mode 100644 index 000000000..67cd8fd36 --- /dev/null +++ b/packages/restapi/src/lib/space/trending.ts @@ -0,0 +1,47 @@ +import axios from 'axios'; +import { getAPIBaseUrls } from '../helpers'; +import Constants, { ENV } from '../constants'; +import { SpaceIFeeds } from '../types'; +import { getTrendingSpaceInboxLists } from '../chat/helpers'; + +export type TrendingOptionsType = { + page?: number; + /** + * no of items per page - default 10 - max 30 + */ + limit?: number; + /** + * Environment variable + */ + env?: ENV; +}; + +/** + * The first time an address wants to send a message to another peer, the address sends an intent request. This first message shall not land in this peer Inbox but in its Request box. + * This function will return all the chats that landed on the address' Request box. The user can then approve the request or ignore it for now. + */ +export const trending = async ( + options: TrendingOptionsType +): Promise => { + const { + env = Constants.ENV.PROD, + page = 1, + limit = 10, + } = options || {}; + const API_BASE_URL = getAPIBaseUrls(env); + const apiEndpoint = `${API_BASE_URL}/v1/spaces/users/trending?page=${page}&limit=${limit}`; + try { + + const response = await axios.get(apiEndpoint); + const requests: SpaceIFeeds[] = response.data.requests; + const Feeds: SpaceIFeeds[] = await getTrendingSpaceInboxLists({ + lists: requests, + env, + }); + + return Feeds; + } catch (err) { + console.error(`[Push SDK] - API ${trending.name}: `, err); + throw Error(`[Push SDK] - API ${trending.name}: ${err}`); + } +}; diff --git a/packages/restapi/src/lib/space/update.ts b/packages/restapi/src/lib/space/update.ts new file mode 100644 index 000000000..a7c54fa7f --- /dev/null +++ b/packages/restapi/src/lib/space/update.ts @@ -0,0 +1,78 @@ +import Constants from '../constants'; +import { + EnvOptionsType, + SpaceDTO, + SignerType, + ChatStatus +} from '../types'; +import { + groupDtoToSpaceDto, +} from './../chat/helpers'; +import { + updateGroup +} from '../chat/updateGroup'; + +export interface ChatUpdateSpaceType extends EnvOptionsType { + account ? : string; + signer ? : SignerType; + spaceId: string; + spaceName: string; + spaceImage: string | null; + spaceDescription: string; + members: Array < string > ; + admins: Array < string > ; + pgpPrivateKey ? : string; + scheduleAt: Date + scheduleEnd ? : Date | null + status: ChatStatus +} + +export const update = async ( + options: ChatUpdateSpaceType +): Promise < SpaceDTO > => { + const { + spaceId, + spaceName, + spaceImage, + spaceDescription, + members, + admins, + account = null, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + scheduleAt, + scheduleEnd, + status, + } = options || {}; + try { + if (account == null && signer == null) { + throw new Error(`At least one from account or signer is necessary!`); + } + const group = await updateGroup({ + chatId: spaceId, + groupName: spaceName, + groupImage: spaceImage, + groupDescription: spaceDescription, + members: members, + admins: admins, + account: account, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey, + scheduleAt: scheduleAt, + scheduleEnd: scheduleEnd, + status: status + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${update.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${update.name} -: ${err}` + ); + } +}; \ No newline at end of file diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index f95ae8394..96321891c 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -168,6 +168,24 @@ export interface IFeeds { deprecated?: boolean; // scope only at sdk level deprecatedCode?: string; // scope only at sdk level } + +export interface SpaceIFeeds { + msg: IMessageIPFS; + did: string; + wallets: string; + profilePicture: string | null; + publicKey: string | null; + about: string | null; + threadhash: string | null; + intent: string | null; + intentSentBy: string | null; + intentTimestamp: Date; + combinedDID: string; + cid?: string; + spaceId?: string; + spaceInformation?: SpaceDTO; +} + export interface IUser { msgSent: number; maxMsgPersisted: number; @@ -238,6 +256,11 @@ export interface Member { publicKey: string; } +export enum ChatStatus { + ACTIVE = 'ACTIVE', + PENDING = 'PENDING', + ENDED = 'ENDED' +} export interface GroupDTO { members: { wallet: string; @@ -259,12 +282,42 @@ export interface GroupDTO { groupImage: string | null; groupName: string; isPublic: boolean; - groupDescription: string | null; + groupDescription: string; groupCreator: string; chatId: string; scheduleAt?: Date | null; scheduleEnd?: Date | null; - groupType: string; + groupType?: string; + status?: ChatStatus | null; +} + +export interface SpaceDTO { + members: { + wallet: string; + publicKey: string; + isAdmin: boolean; + image: string; + }[]; + pendingMembers: { + wallet: string; + publicKey: string; + isAdmin: boolean; + image: string; + }[]; + contractAddressERC20: string | null; + numberOfERC20: number; + contractAddressNFT: string | null; + numberOfNFTTokens: number; + verificationProof: string; + spaceImage: string | null; + spaceName: string; + isPublic: boolean; + spaceDescription: string; + spaceCreator: string; + spaceId: string; + scheduleAt?: Date | null; + scheduleEnd?: Date | null; + status: ChatStatus | null } export interface Subscribers { diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index 1a880b108..ebb32538b 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -3,1345 +3,1798 @@ "@chainsafe/as-sha256@^0.3.1": - version "0.3.1" - resolved "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" - integrity sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg== + "integrity" "sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg==" + "resolved" "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" + "version" "0.3.1" "@chainsafe/persistent-merkle-tree@^0.4.2": - version "0.4.2" - resolved "https://registry.npmjs.org/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz" - integrity sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ== + "integrity" "sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ==" + "resolved" "https://registry.npmjs.org/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz" + "version" "0.4.2" dependencies: "@chainsafe/as-sha256" "^0.3.1" "@chainsafe/ssz@0.9.4": - version "0.9.4" - resolved "https://registry.npmjs.org/@chainsafe/ssz/-/ssz-0.9.4.tgz" - integrity sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ== + "integrity" "sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ==" + "resolved" "https://registry.npmjs.org/@chainsafe/ssz/-/ssz-0.9.4.tgz" + "version" "0.9.4" dependencies: "@chainsafe/as-sha256" "^0.3.1" "@chainsafe/persistent-merkle-tree" "^0.4.2" - case "^1.6.3" + "case" "^1.6.3" "@cspotcode/source-map-support@^0.8.0": - version "0.8.1" - resolved "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz" - integrity sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw== + "integrity" "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==" + "resolved" "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz" + "version" "0.8.1" dependencies: "@jridgewell/trace-mapping" "0.3.9" "@ethereumjs/rlp@^4.0.1": - version "4.0.1" - resolved "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz" - integrity sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw== + "integrity" "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==" + "resolved" "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz" + "version" "4.0.1" "@ethereumjs/util@^8.0.0": - version "8.0.5" - resolved "https://registry.npmjs.org/@ethereumjs/util/-/util-8.0.5.tgz" - integrity sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw== + "integrity" "sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw==" + "resolved" "https://registry.npmjs.org/@ethereumjs/util/-/util-8.0.5.tgz" + "version" "8.0.5" dependencies: "@chainsafe/ssz" "0.9.4" "@ethereumjs/rlp" "^4.0.1" - ethereum-cryptography "^1.1.2" + "ethereum-cryptography" "^1.1.2" + +"@ethersproject/abi@^5.7.0", "@ethersproject/abi@5.7.0": + "integrity" "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==" + "resolved" "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/abstract-provider@^5.7.0", "@ethersproject/abstract-provider@5.7.0": + "integrity" "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==" + "resolved" "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/networks" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/web" "^5.7.0" + +"@ethersproject/abstract-signer@^5.7.0", "@ethersproject/abstract-signer@5.7.0": + "integrity" "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==" + "resolved" "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + +"@ethersproject/address@^5.7.0", "@ethersproject/address@5.7.0": + "integrity" "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==" + "resolved" "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + +"@ethersproject/base64@^5.7.0", "@ethersproject/base64@5.7.0": + "integrity" "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==" + "resolved" "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + +"@ethersproject/basex@^5.7.0", "@ethersproject/basex@5.7.0": + "integrity" "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==" + "resolved" "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + +"@ethersproject/bignumber@^5.7.0", "@ethersproject/bignumber@5.7.0": + "integrity" "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==" + "resolved" "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "bn.js" "^5.2.1" + +"@ethersproject/bytes@^5.7.0", "@ethersproject/bytes@5.7.0": + "integrity" "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==" + "resolved" "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/constants@^5.7.0", "@ethersproject/constants@5.7.0": + "integrity" "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==" + "resolved" "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bignumber" "^5.7.0" + +"@ethersproject/contracts@5.7.0": + "integrity" "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==" + "resolved" "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/abi" "^5.7.0" + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + +"@ethersproject/hash@^5.7.0", "@ethersproject/hash@5.7.0": + "integrity" "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==" + "resolved" "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/base64" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/hdnode@^5.7.0", "@ethersproject/hdnode@5.7.0": + "integrity" "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==" + "resolved" "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/basex" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/pbkdf2" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/wordlists" "^5.7.0" + +"@ethersproject/json-wallets@^5.7.0", "@ethersproject/json-wallets@5.7.0": + "integrity" "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==" + "resolved" "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hdnode" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/pbkdf2" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "aes-js" "3.0.0" + "scrypt-js" "3.0.1" + +"@ethersproject/keccak256@^5.7.0", "@ethersproject/keccak256@5.7.0": + "integrity" "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==" + "resolved" "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "js-sha3" "0.8.0" + +"@ethersproject/logger@^5.7.0", "@ethersproject/logger@5.7.0": + "integrity" "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" + "resolved" "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz" + "version" "5.7.0" + +"@ethersproject/networks@^5.7.0", "@ethersproject/networks@5.7.1": + "integrity" "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==" + "resolved" "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz" + "version" "5.7.1" + dependencies: + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/pbkdf2@^5.7.0", "@ethersproject/pbkdf2@5.7.0": + "integrity" "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==" + "resolved" "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + +"@ethersproject/properties@^5.7.0", "@ethersproject/properties@5.7.0": + "integrity" "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==" + "resolved" "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/providers@5.7.2": + "integrity" "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==" + "resolved" "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz" + "version" "5.7.2" + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/base64" "^5.7.0" + "@ethersproject/basex" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/networks" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/web" "^5.7.0" + "bech32" "1.1.4" + "ws" "7.4.6" + +"@ethersproject/random@^5.7.0", "@ethersproject/random@5.7.0": + "integrity" "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==" + "resolved" "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/rlp@^5.7.0", "@ethersproject/rlp@5.7.0": + "integrity" "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==" + "resolved" "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/sha2@^5.7.0", "@ethersproject/sha2@5.7.0": + "integrity" "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==" + "resolved" "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "hash.js" "1.1.7" + +"@ethersproject/signing-key@^5.7.0", "@ethersproject/signing-key@5.7.0": + "integrity" "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==" + "resolved" "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "bn.js" "^5.2.1" + "elliptic" "6.5.4" + "hash.js" "1.1.7" + +"@ethersproject/solidity@5.7.0": + "integrity" "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==" + "resolved" "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/strings@^5.7.0", "@ethersproject/strings@5.7.0": + "integrity" "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==" + "resolved" "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/transactions@^5.7.0", "@ethersproject/transactions@5.7.0": + "integrity" "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==" + "resolved" "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + +"@ethersproject/units@5.7.0": + "integrity" "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==" + "resolved" "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/wallet@5.7.0": + "integrity" "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==" + "resolved" "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/hdnode" "^5.7.0" + "@ethersproject/json-wallets" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/wordlists" "^5.7.0" + +"@ethersproject/web@^5.7.0", "@ethersproject/web@5.7.1": + "integrity" "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==" + "resolved" "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz" + "version" "5.7.1" + dependencies: + "@ethersproject/base64" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/wordlists@^5.7.0", "@ethersproject/wordlists@5.7.0": + "integrity" "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==" + "resolved" "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz" + "version" "5.7.0" + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" "@jridgewell/resolve-uri@^3.0.3": - version "3.1.0" - resolved "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz" - integrity sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w== + "integrity" "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==" + "resolved" "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz" + "version" "3.1.0" "@jridgewell/sourcemap-codec@^1.4.10": - version "1.4.14" - resolved "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz" - integrity sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw== + "integrity" "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" + "resolved" "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz" + "version" "1.4.14" "@jridgewell/trace-mapping@0.3.9": - version "0.3.9" - resolved "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz" - integrity sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ== + "integrity" "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==" + "resolved" "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz" + "version" "0.3.9" dependencies: "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" "@metamask/eth-sig-util@^5.0.2": - version "5.0.2" - resolved "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" - integrity sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q== + "integrity" "sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q==" + "resolved" "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" + "version" "5.0.2" dependencies: "@ethereumjs/util" "^8.0.0" - bn.js "^4.11.8" - ethereum-cryptography "^1.1.2" - ethjs-util "^0.1.6" - tweetnacl "^1.0.3" - tweetnacl-util "^0.15.1" - -"@noble/hashes@1.2.0", "@noble/hashes@~1.2.0": - version "1.2.0" - resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz" - integrity sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ== - -"@noble/secp256k1@1.7.1", "@noble/secp256k1@~1.7.0": - version "1.7.1" - resolved "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" - integrity sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw== + "bn.js" "^4.11.8" + "ethereum-cryptography" "^1.1.2" + "ethjs-util" "^0.1.6" + "tweetnacl" "^1.0.3" + "tweetnacl-util" "^0.15.1" + +"@noble/hashes@~1.2.0", "@noble/hashes@1.2.0": + "integrity" "sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==" + "resolved" "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz" + "version" "1.2.0" + +"@noble/secp256k1@~1.7.0", "@noble/secp256k1@1.7.1": + "integrity" "sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==" + "resolved" "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" + "version" "1.7.1" "@scure/base@~1.1.0": - version "1.1.1" - resolved "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" - integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== + "integrity" "sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA==" + "resolved" "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" + "version" "1.1.1" "@scure/bip32@1.1.5": - version "1.1.5" - resolved "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz" - integrity sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw== + "integrity" "sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==" + "resolved" "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz" + "version" "1.1.5" dependencies: "@noble/hashes" "~1.2.0" "@noble/secp256k1" "~1.7.0" "@scure/base" "~1.1.0" "@scure/bip39@1.1.1": - version "1.1.1" - resolved "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz" - integrity sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg== + "integrity" "sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==" + "resolved" "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz" + "version" "1.1.1" dependencies: "@noble/hashes" "~1.2.0" "@scure/base" "~1.1.0" "@tsconfig/node10@^1.0.7": - version "1.0.9" - resolved "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" - integrity sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA== + "integrity" "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==" + "resolved" "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" + "version" "1.0.9" "@tsconfig/node12@^1.0.7": - version "1.0.11" - resolved "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz" - integrity sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag== + "integrity" "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==" + "resolved" "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz" + "version" "1.0.11" "@tsconfig/node14@^1.0.0": - version "1.0.3" - resolved "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz" - integrity sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow== + "integrity" "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==" + "resolved" "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz" + "version" "1.0.3" "@tsconfig/node16@^1.0.2": - version "1.0.3" - resolved "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz" - integrity sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ== + "integrity" "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==" + "resolved" "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz" + "version" "1.0.3" "@types/chai-as-promised@^7.1.5": - version "7.1.5" - resolved "https://registry.npmjs.org/@types/chai-as-promised/-/chai-as-promised-7.1.5.tgz" - integrity sha512-jStwss93SITGBwt/niYrkf2C+/1KTeZCZl1LaeezTlqppAKeoQC7jxyqYuP72sxBGKCIbw7oHgbYssIRzT5FCQ== + "integrity" "sha512-jStwss93SITGBwt/niYrkf2C+/1KTeZCZl1LaeezTlqppAKeoQC7jxyqYuP72sxBGKCIbw7oHgbYssIRzT5FCQ==" + "resolved" "https://registry.npmjs.org/@types/chai-as-promised/-/chai-as-promised-7.1.5.tgz" + "version" "7.1.5" dependencies: "@types/chai" "*" "@types/chai@*", "@types/chai@^4.3.4": - version "4.3.4" - resolved "https://registry.npmjs.org/@types/chai/-/chai-4.3.4.tgz" - integrity sha512-KnRanxnpfpjUTqTCXslZSEdLfXExwgNxYPdiO2WGUj8+HDjFi8R3k5RVKPeSCzLjCcshCAtVO2QBbVuAV4kTnw== + "integrity" "sha512-KnRanxnpfpjUTqTCXslZSEdLfXExwgNxYPdiO2WGUj8+HDjFi8R3k5RVKPeSCzLjCcshCAtVO2QBbVuAV4kTnw==" + "resolved" "https://registry.npmjs.org/@types/chai/-/chai-4.3.4.tgz" + "version" "4.3.4" "@types/crypto-js@^4.1.1": - version "4.1.1" - resolved "https://registry.npmjs.org/@types/crypto-js/-/crypto-js-4.1.1.tgz" - integrity sha512-BG7fQKZ689HIoc5h+6D2Dgq1fABRa0RbBWKBd9SP/MVRVXROflpm5fhwyATX5duFmbStzyzyycPB8qUYKDH3NA== + "integrity" "sha512-BG7fQKZ689HIoc5h+6D2Dgq1fABRa0RbBWKBd9SP/MVRVXROflpm5fhwyATX5duFmbStzyzyycPB8qUYKDH3NA==" + "resolved" "https://registry.npmjs.org/@types/crypto-js/-/crypto-js-4.1.1.tgz" + "version" "4.1.1" "@types/mocha@^10.0.1": - version "10.0.1" - resolved "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz" - integrity sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q== + "integrity" "sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q==" + "resolved" "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz" + "version" "10.0.1" "@types/mocha@^5.2.0": - version "5.2.7" - resolved "https://registry.npmjs.org/@types/mocha/-/mocha-5.2.7.tgz" - integrity sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ== - -acorn-walk@^8.1.1: - version "8.2.0" - resolved "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz" - integrity sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA== - -acorn@^8.4.1: - version "8.8.2" - resolved "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz" - integrity sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw== - -ansi-colors@4.1.1: - version "4.1.1" - resolved "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz" - integrity sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA== - -ansi-regex@^2.0.0: - version "2.1.1" - resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz" - integrity sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA== - -ansi-regex@^3.0.0: - version "3.0.1" - resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz" - integrity sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw== - -ansi-regex@^5.0.1: - version "5.0.1" - resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" - integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== - -ansi-styles@^3.2.1: - 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== - dependencies: - color-convert "^1.9.0" - -ansi-styles@^4.0.0, ansi-styles@^4.1.0: - version "4.3.0" - resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz" - integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== - dependencies: - color-convert "^2.0.1" - -anymatch@~3.1.2: - version "3.1.3" - resolved "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz" - integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== - dependencies: - normalize-path "^3.0.0" - picomatch "^2.0.4" - -arg@^4.1.0: - version "4.1.3" - resolved "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz" - integrity sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA== - -argparse@^2.0.1: - version "2.0.1" - resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" - integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== - -asn1.js@^5.0.0: - version "5.4.1" - resolved "https://registry.yarnpkg.com/asn1.js/-/asn1.js-5.4.1.tgz#11a980b84ebb91781ce35b0fdc2ee294e3783f07" - integrity sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA== - dependencies: - bn.js "^4.0.0" - inherits "^2.0.1" - minimalistic-assert "^1.0.0" - safer-buffer "^2.1.0" - -assertion-error@^1.1.0: - version "1.1.0" - resolved "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz" - integrity sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw== - -balanced-match@^1.0.0: - version "1.0.2" - resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" - integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== - -base64-js@^1.3.1: - version "1.5.1" - resolved "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" - integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== - -binary-extensions@^2.0.0: - version "2.2.0" - resolved "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz" - integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== - -bn.js@^4.0.0, bn.js@^4.11.8: - version "4.12.0" - resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" - integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== - -brace-expansion@^1.1.7: - version "1.1.11" - resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" - integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== - dependencies: - balanced-match "^1.0.0" - concat-map "0.0.1" - -brace-expansion@^2.0.1: - version "2.0.1" - resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz" - integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA== - dependencies: - balanced-match "^1.0.0" - -braces@~3.0.2: - version "3.0.2" - resolved "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" - integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== - dependencies: - fill-range "^7.0.1" - -browser-stdout@1.3.1: - version "1.3.1" - resolved "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz" - integrity sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw== - -buffer@^6.0.3: - version "6.0.3" - resolved "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" - integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== - dependencies: - base64-js "^1.3.1" - ieee754 "^1.2.1" - -camelcase@^4.1.0: - version "4.1.0" - resolved "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz" - integrity sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw== - -camelcase@^6.0.0: - version "6.3.0" - resolved "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz" - integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== - -case@^1.6.3: - version "1.6.3" - resolved "https://registry.npmjs.org/case/-/case-1.6.3.tgz" - integrity sha512-mzDSXIPaFwVDvZAHqZ9VlbyF4yyXRuX6IvB06WvPYkqJVO24kX1PPhv9bfpKNFZyxYFmmgo03HUiD8iklmJYRQ== - -chai-as-promised@^7.1.1: - version "7.1.1" - resolved "https://registry.yarnpkg.com/chai-as-promised/-/chai-as-promised-7.1.1.tgz#08645d825deb8696ee61725dbf590c012eb00ca0" - integrity sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA== - dependencies: - check-error "^1.0.2" - -chai@^4.3.7: - version "4.3.7" - resolved "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz" - integrity sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A== - dependencies: - assertion-error "^1.1.0" - check-error "^1.0.2" - deep-eql "^4.1.2" - get-func-name "^2.0.0" - loupe "^2.3.1" - pathval "^1.1.1" - type-detect "^4.0.5" - -chalk@^2.4.1: - version "2.4.2" - resolved "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" - integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== - dependencies: - ansi-styles "^3.2.1" - escape-string-regexp "^1.0.5" - supports-color "^5.3.0" - -chalk@^4.1.0: - version "4.1.2" - resolved "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" - integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== - dependencies: - ansi-styles "^4.1.0" - supports-color "^7.1.0" - -check-error@^1.0.2: - version "1.0.2" - resolved "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz" - integrity sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA== - -chokidar@3.5.3: - version "3.5.3" - resolved "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz" - integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== - dependencies: - anymatch "~3.1.2" - braces "~3.0.2" - glob-parent "~5.1.2" - is-binary-path "~2.1.0" - is-glob "~4.0.1" - normalize-path "~3.0.0" - readdirp "~3.6.0" + "integrity" "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==" + "resolved" "https://registry.npmjs.org/@types/mocha/-/mocha-5.2.7.tgz" + "version" "5.2.7" + +"@types/node@*": + "integrity" "sha512-JJulVEQXmiY9Px5axXHeYGLSjhkZEnD+MDPDGbCbIAbMslkKwmygtZFy1X6s/075Yo94sf8GuSlFfPzysQrWZQ==" + "resolved" "https://registry.npmjs.org/@types/node/-/node-20.2.5.tgz" + "version" "20.2.5" + +"acorn-walk@^8.1.1": + "integrity" "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==" + "resolved" "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz" + "version" "8.2.0" + +"acorn@^8.4.1": + "integrity" "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==" + "resolved" "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz" + "version" "8.8.2" + +"aes-js@3.0.0": + "integrity" "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + "resolved" "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz" + "version" "3.0.0" + +"ansi-colors@4.1.1": + "integrity" "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==" + "resolved" "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz" + "version" "4.1.1" + +"ansi-regex@^2.0.0": + "integrity" "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz" + "version" "2.1.1" + +"ansi-regex@^3.0.0": + "integrity" "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==" + "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz" + "version" "3.0.1" + +"ansi-regex@^5.0.1": + "integrity" "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" + "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" + "version" "5.0.1" + +"ansi-styles@^3.2.1": + "integrity" "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==" + "resolved" "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz" + "version" "3.2.1" + dependencies: + "color-convert" "^1.9.0" + +"ansi-styles@^4.0.0", "ansi-styles@^4.1.0": + "integrity" "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==" + "resolved" "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz" + "version" "4.3.0" + dependencies: + "color-convert" "^2.0.1" + +"anymatch@~3.1.2": + "integrity" "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==" + "resolved" "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz" + "version" "3.1.3" + dependencies: + "normalize-path" "^3.0.0" + "picomatch" "^2.0.4" + +"arg@^4.1.0": + "integrity" "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" + "resolved" "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz" + "version" "4.1.3" + +"argparse@^2.0.1": + "integrity" "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==" + "resolved" "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" + "version" "2.0.1" + +"asn1.js@^5.0.0": + "integrity" "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==" + "resolved" "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz" + "version" "5.4.1" + dependencies: + "bn.js" "^4.0.0" + "inherits" "^2.0.1" + "minimalistic-assert" "^1.0.0" + "safer-buffer" "^2.1.0" + +"assertion-error@^1.1.0": + "integrity" "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" + "resolved" "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz" + "version" "1.1.0" + +"balanced-match@^1.0.0": + "integrity" "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + "resolved" "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" + "version" "1.0.2" + +"base64-js@^1.3.1": + "integrity" "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==" + "resolved" "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" + "version" "1.5.1" + +"bech32@1.1.4": + "integrity" "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + "resolved" "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz" + "version" "1.1.4" + +"binary-extensions@^2.0.0": + "integrity" "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==" + "resolved" "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz" + "version" "2.2.0" + +"bn.js@^4.0.0", "bn.js@^4.11.8", "bn.js@^4.11.9": + "integrity" "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + "resolved" "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" + "version" "4.12.0" + +"bn.js@^5.2.1": + "integrity" "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + "resolved" "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" + "version" "5.2.1" + +"brace-expansion@^1.1.7": + "integrity" "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==" + "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" + "version" "1.1.11" + dependencies: + "balanced-match" "^1.0.0" + "concat-map" "0.0.1" + +"brace-expansion@^2.0.1": + "integrity" "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==" + "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz" + "version" "2.0.1" + dependencies: + "balanced-match" "^1.0.0" + +"braces@~3.0.2": + "integrity" "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==" + "resolved" "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" + "version" "3.0.2" + dependencies: + "fill-range" "^7.0.1" + +"brorand@^1.1.0": + "integrity" "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + "resolved" "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" + "version" "1.1.0" + +"browser-stdout@1.3.1": + "integrity" "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" + "resolved" "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz" + "version" "1.3.1" + +"buffer@^6.0.3": + "integrity" "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==" + "resolved" "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" + "version" "6.0.3" + dependencies: + "base64-js" "^1.3.1" + "ieee754" "^1.2.1" + +"camelcase@^4.1.0": + "integrity" "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==" + "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz" + "version" "4.1.0" + +"camelcase@^6.0.0": + "integrity" "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==" + "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz" + "version" "6.3.0" + +"case@^1.6.3": + "integrity" "sha512-mzDSXIPaFwVDvZAHqZ9VlbyF4yyXRuX6IvB06WvPYkqJVO24kX1PPhv9bfpKNFZyxYFmmgo03HUiD8iklmJYRQ==" + "resolved" "https://registry.npmjs.org/case/-/case-1.6.3.tgz" + "version" "1.6.3" + +"chai-as-promised@^7.1.1": + "integrity" "sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA==" + "resolved" "https://registry.npmjs.org/chai-as-promised/-/chai-as-promised-7.1.1.tgz" + "version" "7.1.1" + dependencies: + "check-error" "^1.0.2" + +"chai@^4.3.7", "chai@>= 2.1.2 < 5": + "integrity" "sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A==" + "resolved" "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz" + "version" "4.3.7" + dependencies: + "assertion-error" "^1.1.0" + "check-error" "^1.0.2" + "deep-eql" "^4.1.2" + "get-func-name" "^2.0.0" + "loupe" "^2.3.1" + "pathval" "^1.1.1" + "type-detect" "^4.0.5" + +"chalk@^2.4.1": + "integrity" "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==" + "resolved" "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" + "version" "2.4.2" + dependencies: + "ansi-styles" "^3.2.1" + "escape-string-regexp" "^1.0.5" + "supports-color" "^5.3.0" + +"chalk@^4.1.0": + "integrity" "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==" + "resolved" "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" + "version" "4.1.2" + dependencies: + "ansi-styles" "^4.1.0" + "supports-color" "^7.1.0" + +"check-error@^1.0.2": + "integrity" "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==" + "resolved" "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz" + "version" "1.0.2" + +"chokidar@3.5.3": + "integrity" "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==" + "resolved" "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz" + "version" "3.5.3" + dependencies: + "anymatch" "~3.1.2" + "braces" "~3.0.2" + "glob-parent" "~5.1.2" + "is-binary-path" "~2.1.0" + "is-glob" "~4.0.1" + "normalize-path" "~3.0.0" + "readdirp" "~3.6.0" optionalDependencies: - fsevents "~2.3.2" - -cliui@^4.0.0: - version "4.1.0" - resolved "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" - integrity sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ== - dependencies: - string-width "^2.1.1" - strip-ansi "^4.0.0" - wrap-ansi "^2.0.0" - -cliui@^7.0.2: - version "7.0.4" - resolved "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz" - integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== - dependencies: - string-width "^4.2.0" - strip-ansi "^6.0.0" - wrap-ansi "^7.0.0" - -code-point-at@^1.0.0: - version "1.1.0" - resolved "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" - integrity sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA== - -color-convert@^1.9.0: - version "1.9.3" - resolved "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" - integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== - dependencies: - color-name "1.1.3" - -color-convert@^2.0.1: - version "2.0.1" - resolved "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" - integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== - dependencies: - color-name "~1.1.4" - -color-name@1.1.3: - version "1.1.3" - resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" - integrity sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw== - -color-name@~1.1.4: - version "1.1.4" - resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" - integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== - -concat-map@0.0.1: - version "0.0.1" - resolved "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" - integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== - -create-require@^1.1.0: - version "1.1.1" - resolved "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz" - integrity sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ== - -cross-spawn@^6.0.0, cross-spawn@^6.0.5: - version "6.0.5" - resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" - integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== - dependencies: - nice-try "^1.0.4" - path-key "^2.0.1" - semver "^5.5.0" - shebang-command "^1.2.0" - which "^1.2.9" - -crypto-js@^4.1.1: - version "4.1.1" - resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" - integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== - -debug@4.3.4, debug@^4.3.2: - version "4.3.4" - resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" - integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== - dependencies: - ms "2.1.2" - -decamelize@^1.1.1: - version "1.2.0" - resolved "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" - integrity sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA== - -decamelize@^4.0.0: - version "4.0.0" - resolved "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" - integrity sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ== - -deep-eql@^4.1.2: - version "4.1.3" - resolved "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz" - integrity sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw== - dependencies: - type-detect "^4.0.0" - -diff@5.0.0: - version "5.0.0" - resolved "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" - integrity sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w== - -diff@^4.0.1: - version "4.0.2" - resolved "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz" - integrity sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A== - -emoji-regex@^8.0.0: - version "8.0.0" - resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" - integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== - -end-of-stream@^1.1.0: - version "1.4.4" - resolved "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz" - integrity sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q== - dependencies: - once "^1.4.0" - -err-code@^3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/err-code/-/err-code-3.0.1.tgz#a444c7b992705f2b120ee320b09972eef331c920" - integrity sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA== - -escalade@^3.1.1: - version "3.1.1" - resolved "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" - integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== - -escape-string-regexp@4.0.0: - version "4.0.0" - resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" - integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== - -escape-string-regexp@^1.0.5: - version "1.0.5" - resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" - integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== - -ethereum-cryptography@^1.1.2: - version "1.2.0" - resolved "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz" - integrity sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw== + "fsevents" "~2.3.2" + +"cliui@^4.0.0": + "integrity" "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==" + "resolved" "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" + "version" "4.1.0" + dependencies: + "string-width" "^2.1.1" + "strip-ansi" "^4.0.0" + "wrap-ansi" "^2.0.0" + +"cliui@^7.0.2": + "integrity" "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==" + "resolved" "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz" + "version" "7.0.4" + dependencies: + "string-width" "^4.2.0" + "strip-ansi" "^6.0.0" + "wrap-ansi" "^7.0.0" + +"code-point-at@^1.0.0": + "integrity" "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==" + "resolved" "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" + "version" "1.1.0" + +"color-convert@^1.9.0": + "integrity" "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==" + "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" + "version" "1.9.3" + dependencies: + "color-name" "1.1.3" + +"color-convert@^2.0.1": + "integrity" "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==" + "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" + "version" "2.0.1" + dependencies: + "color-name" "~1.1.4" + +"color-name@~1.1.4": + "integrity" "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" + "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" + "version" "1.1.4" + +"color-name@1.1.3": + "integrity" "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" + "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" + "version" "1.1.3" + +"concat-map@0.0.1": + "integrity" "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + "resolved" "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" + "version" "0.0.1" + +"create-require@^1.1.0": + "integrity" "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==" + "resolved" "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz" + "version" "1.1.1" + +"cross-spawn@^6.0.0", "cross-spawn@^6.0.5": + "integrity" "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==" + "resolved" "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" + "version" "6.0.5" + dependencies: + "nice-try" "^1.0.4" + "path-key" "^2.0.1" + "semver" "^5.5.0" + "shebang-command" "^1.2.0" + "which" "^1.2.9" + +"crypto-js@^4.1.1": + "integrity" "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + "resolved" "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" + "version" "4.1.1" + +"debug@^4.3.2", "debug@4.3.4": + "integrity" "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==" + "resolved" "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" + "version" "4.3.4" + dependencies: + "ms" "2.1.2" + +"decamelize@^1.1.1": + "integrity" "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==" + "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" + "version" "1.2.0" + +"decamelize@^4.0.0": + "integrity" "sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==" + "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" + "version" "4.0.0" + +"deep-eql@^4.1.2": + "integrity" "sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==" + "resolved" "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz" + "version" "4.1.3" + dependencies: + "type-detect" "^4.0.0" + +"diff@^4.0.1": + "integrity" "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" + "resolved" "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz" + "version" "4.0.2" + +"diff@5.0.0": + "integrity" "sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==" + "resolved" "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" + "version" "5.0.0" + +"elliptic@6.5.4": + "integrity" "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==" + "resolved" "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz" + "version" "6.5.4" + dependencies: + "bn.js" "^4.11.9" + "brorand" "^1.1.0" + "hash.js" "^1.0.0" + "hmac-drbg" "^1.0.1" + "inherits" "^2.0.4" + "minimalistic-assert" "^1.0.1" + "minimalistic-crypto-utils" "^1.0.1" + +"emoji-regex@^8.0.0": + "integrity" "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + "resolved" "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" + "version" "8.0.0" + +"end-of-stream@^1.1.0": + "integrity" "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==" + "resolved" "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz" + "version" "1.4.4" + dependencies: + "once" "^1.4.0" + +"err-code@^3.0.1": + "integrity" "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + "resolved" "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz" + "version" "3.0.1" + +"escalade@^3.1.1": + "integrity" "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==" + "resolved" "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" + "version" "3.1.1" + +"escape-string-regexp@^1.0.5": + "integrity" "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==" + "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" + "version" "1.0.5" + +"escape-string-regexp@4.0.0": + "integrity" "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" + "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" + "version" "4.0.0" + +"ethereum-cryptography@^1.1.2": + "integrity" "sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==" + "resolved" "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz" + "version" "1.2.0" dependencies: "@noble/hashes" "1.2.0" "@noble/secp256k1" "1.7.1" "@scure/bip32" "1.1.5" "@scure/bip39" "1.1.1" -ethjs-util@^0.1.6: - version "0.1.6" - resolved "https://registry.yarnpkg.com/ethjs-util/-/ethjs-util-0.1.6.tgz#f308b62f185f9fe6237132fb2a9818866a5cd536" - integrity sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w== - dependencies: - is-hex-prefixed "1.0.0" - strip-hex-prefix "1.0.0" - -execa@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz" - integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA== - dependencies: - cross-spawn "^6.0.0" - get-stream "^4.0.0" - is-stream "^1.1.0" - npm-run-path "^2.0.0" - p-finally "^1.0.0" - signal-exit "^3.0.0" - strip-eof "^1.0.0" - -fill-range@^7.0.1: - version "7.0.1" - resolved "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" - integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== - dependencies: - to-regex-range "^5.0.1" - -find-up@5.0.0: - version "5.0.0" - resolved "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz" - integrity sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng== - dependencies: - locate-path "^6.0.0" - path-exists "^4.0.0" - -find-up@^2.1.0: - version "2.1.0" - resolved "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz" - integrity sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ== - dependencies: - locate-path "^2.0.0" - -flat@^5.0.2: - version "5.0.2" - resolved "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz" - integrity sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ== - -fs.realpath@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" - integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== - -fsevents@~2.3.2: - version "2.3.2" - resolved "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz" - integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== - -get-browser-rtc@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz#d1494e299b00f33fc8e9d6d3343ba4ba99711a2c" - integrity sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ== - -get-caller-file@^1.0.1: - version "1.0.3" - resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz" - integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== - -get-caller-file@^2.0.5: - version "2.0.5" - resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" - integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== - -get-func-name@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz" - integrity sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig== - -get-stream@^4.0.0: - version "4.1.0" - resolved "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" - integrity sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w== - dependencies: - pump "^3.0.0" - -glob-parent@~5.1.2: - version "5.1.2" - resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" - integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== - dependencies: - is-glob "^4.0.1" - -glob@7.2.0: - version "7.2.0" - resolved "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz" - integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== - dependencies: - fs.realpath "^1.0.0" - inflight "^1.0.4" - inherits "2" - minimatch "^3.0.4" - once "^1.3.0" - path-is-absolute "^1.0.0" - -has-flag@^3.0.0: - version "3.0.0" - resolved "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" - integrity sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw== - -has-flag@^4.0.0: - version "4.0.0" - resolved "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" - integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== - -he@1.2.0: - version "1.2.0" - resolved "https://registry.npmjs.org/he/-/he-1.2.0.tgz" - integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== - -ieee754@^1.2.1: - version "1.2.1" - resolved "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" - integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== - -immer@^10.0.2: - version "10.0.2" - resolved "https://registry.yarnpkg.com/immer/-/immer-10.0.2.tgz#11636c5b77acf529e059582d76faf338beb56141" - integrity sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA== - -inflight@^1.0.4: - version "1.0.6" - resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" - integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== - dependencies: - once "^1.3.0" - wrappy "1" - -inherits@2, inherits@^2.0.1, inherits@^2.0.3: - version "2.0.4" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" - integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== - -invert-kv@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" - integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== - -is-binary-path@~2.1.0: - version "2.1.0" - resolved "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" - integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== - dependencies: - binary-extensions "^2.0.0" - -is-extglob@^2.1.1: - version "2.1.1" - resolved "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" - integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== - -is-fullwidth-code-point@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" - integrity sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw== - dependencies: - number-is-nan "^1.0.0" - -is-fullwidth-code-point@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" - integrity sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w== - -is-fullwidth-code-point@^3.0.0: - version "3.0.0" - resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz" - integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== - -is-glob@^4.0.1, is-glob@~4.0.1: - version "4.0.3" - resolved "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz" - integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== - dependencies: - is-extglob "^2.1.1" - -is-hex-prefixed@1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz" - integrity sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA== - -is-number@^7.0.0: - version "7.0.0" - resolved "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" - integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== - -is-plain-obj@^2.1.0: - version "2.1.0" - resolved "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz" - integrity sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA== - -is-stream@^1.1.0: - version "1.1.0" - resolved "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" - integrity sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ== - -is-unicode-supported@^0.1.0: - version "0.1.0" - resolved "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz" - integrity sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw== - -isexe@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" - integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== - -js-yaml@4.1.0: - version "4.1.0" - resolved "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz" - integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== - dependencies: - argparse "^2.0.1" - -lcid@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz" - integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== - dependencies: - invert-kv "^2.0.0" - -locate-path@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz" - integrity sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA== - dependencies: - p-locate "^2.0.0" - path-exists "^3.0.0" - -locate-path@^6.0.0: - version "6.0.0" - resolved "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz" - integrity sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw== - dependencies: - p-locate "^5.0.0" +"ethers@^5.6.8": + "integrity" "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==" + "resolved" "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz" + "version" "5.7.2" + dependencies: + "@ethersproject/abi" "5.7.0" + "@ethersproject/abstract-provider" "5.7.0" + "@ethersproject/abstract-signer" "5.7.0" + "@ethersproject/address" "5.7.0" + "@ethersproject/base64" "5.7.0" + "@ethersproject/basex" "5.7.0" + "@ethersproject/bignumber" "5.7.0" + "@ethersproject/bytes" "5.7.0" + "@ethersproject/constants" "5.7.0" + "@ethersproject/contracts" "5.7.0" + "@ethersproject/hash" "5.7.0" + "@ethersproject/hdnode" "5.7.0" + "@ethersproject/json-wallets" "5.7.0" + "@ethersproject/keccak256" "5.7.0" + "@ethersproject/logger" "5.7.0" + "@ethersproject/networks" "5.7.1" + "@ethersproject/pbkdf2" "5.7.0" + "@ethersproject/properties" "5.7.0" + "@ethersproject/providers" "5.7.2" + "@ethersproject/random" "5.7.0" + "@ethersproject/rlp" "5.7.0" + "@ethersproject/sha2" "5.7.0" + "@ethersproject/signing-key" "5.7.0" + "@ethersproject/solidity" "5.7.0" + "@ethersproject/strings" "5.7.0" + "@ethersproject/transactions" "5.7.0" + "@ethersproject/units" "5.7.0" + "@ethersproject/wallet" "5.7.0" + "@ethersproject/web" "5.7.1" + "@ethersproject/wordlists" "5.7.0" + +"ethjs-util@^0.1.6": + "integrity" "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==" + "resolved" "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz" + "version" "0.1.6" + dependencies: + "is-hex-prefixed" "1.0.0" + "strip-hex-prefix" "1.0.0" + +"execa@^1.0.0": + "integrity" "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==" + "resolved" "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz" + "version" "1.0.0" + dependencies: + "cross-spawn" "^6.0.0" + "get-stream" "^4.0.0" + "is-stream" "^1.1.0" + "npm-run-path" "^2.0.0" + "p-finally" "^1.0.0" + "signal-exit" "^3.0.0" + "strip-eof" "^1.0.0" + +"fill-range@^7.0.1": + "integrity" "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==" + "resolved" "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" + "version" "7.0.1" + dependencies: + "to-regex-range" "^5.0.1" + +"find-up@^2.1.0": + "integrity" "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==" + "resolved" "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz" + "version" "2.1.0" + dependencies: + "locate-path" "^2.0.0" + +"find-up@5.0.0": + "integrity" "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==" + "resolved" "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz" + "version" "5.0.0" + dependencies: + "locate-path" "^6.0.0" + "path-exists" "^4.0.0" + +"flat@^5.0.2": + "integrity" "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==" + "resolved" "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz" + "version" "5.0.2" + +"fs.realpath@^1.0.0": + "integrity" "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + "resolved" "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" + "version" "1.0.0" + +"fsevents@~2.3.2": + "integrity" "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==" + "resolved" "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz" + "version" "2.3.2" + +"get-browser-rtc@^1.1.0": + "integrity" "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + "resolved" "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz" + "version" "1.1.0" + +"get-caller-file@^1.0.1": + "integrity" "sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==" + "resolved" "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz" + "version" "1.0.3" + +"get-caller-file@^2.0.5": + "integrity" "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" + "resolved" "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" + "version" "2.0.5" + +"get-func-name@^2.0.0": + "integrity" "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==" + "resolved" "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz" + "version" "2.0.0" + +"get-stream@^4.0.0": + "integrity" "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==" + "resolved" "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" + "version" "4.1.0" + dependencies: + "pump" "^3.0.0" + +"glob-parent@~5.1.2": + "integrity" "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==" + "resolved" "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" + "version" "5.1.2" + dependencies: + "is-glob" "^4.0.1" + +"glob@7.2.0": + "integrity" "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==" + "resolved" "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz" + "version" "7.2.0" + dependencies: + "fs.realpath" "^1.0.0" + "inflight" "^1.0.4" + "inherits" "2" + "minimatch" "^3.0.4" + "once" "^1.3.0" + "path-is-absolute" "^1.0.0" + +"has-flag@^3.0.0": + "integrity" "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==" + "resolved" "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" + "version" "3.0.0" + +"has-flag@^4.0.0": + "integrity" "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" + "resolved" "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" + "version" "4.0.0" + +"hash.js@^1.0.0", "hash.js@^1.0.3", "hash.js@1.1.7": + "integrity" "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==" + "resolved" "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" + "version" "1.1.7" + dependencies: + "inherits" "^2.0.3" + "minimalistic-assert" "^1.0.1" + +"he@1.2.0": + "integrity" "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" + "resolved" "https://registry.npmjs.org/he/-/he-1.2.0.tgz" + "version" "1.2.0" + +"hmac-drbg@^1.0.1": + "integrity" "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==" + "resolved" "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz" + "version" "1.0.1" + dependencies: + "hash.js" "^1.0.3" + "minimalistic-assert" "^1.0.0" + "minimalistic-crypto-utils" "^1.0.1" + +"ieee754@^1.2.1": + "integrity" "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" + "resolved" "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" + "version" "1.2.1" + +"immer@^10.0.2": + "integrity" "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==" + "resolved" "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz" + "version" "10.0.2" + +"inflight@^1.0.4": + "integrity" "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==" + "resolved" "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" + "version" "1.0.6" + dependencies: + "once" "^1.3.0" + "wrappy" "1" + +"inherits@^2.0.1", "inherits@^2.0.3", "inherits@^2.0.4", "inherits@2": + "integrity" "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + "resolved" "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + "version" "2.0.4" + +"invert-kv@^2.0.0": + "integrity" "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" + "resolved" "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" + "version" "2.0.0" + +"is-binary-path@~2.1.0": + "integrity" "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==" + "resolved" "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" + "version" "2.1.0" + dependencies: + "binary-extensions" "^2.0.0" + +"is-extglob@^2.1.1": + "integrity" "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==" + "resolved" "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" + "version" "2.1.1" + +"is-fullwidth-code-point@^1.0.0": + "integrity" "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==" + "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" + "version" "1.0.0" + dependencies: + "number-is-nan" "^1.0.0" + +"is-fullwidth-code-point@^2.0.0": + "integrity" "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==" + "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" + "version" "2.0.0" + +"is-fullwidth-code-point@^3.0.0": + "integrity" "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==" + "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz" + "version" "3.0.0" + +"is-glob@^4.0.1", "is-glob@~4.0.1": + "integrity" "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==" + "resolved" "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz" + "version" "4.0.3" + dependencies: + "is-extglob" "^2.1.1" + +"is-hex-prefixed@1.0.0": + "integrity" "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==" + "resolved" "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz" + "version" "1.0.0" + +"is-number@^7.0.0": + "integrity" "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" + "resolved" "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" + "version" "7.0.0" + +"is-plain-obj@^2.1.0": + "integrity" "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==" + "resolved" "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz" + "version" "2.1.0" + +"is-stream@^1.1.0": + "integrity" "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==" + "resolved" "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" + "version" "1.1.0" + +"is-unicode-supported@^0.1.0": + "integrity" "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==" + "resolved" "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz" + "version" "0.1.0" + +"isexe@^2.0.0": + "integrity" "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + "resolved" "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" + "version" "2.0.0" + +"js-sha3@0.8.0": + "integrity" "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + "resolved" "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz" + "version" "0.8.0" + +"js-yaml@4.1.0": + "integrity" "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==" + "resolved" "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz" + "version" "4.1.0" + dependencies: + "argparse" "^2.0.1" + +"lcid@^2.0.0": + "integrity" "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==" + "resolved" "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz" + "version" "2.0.0" + dependencies: + "invert-kv" "^2.0.0" + +"locate-path@^2.0.0": + "integrity" "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==" + "resolved" "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz" + "version" "2.0.0" + dependencies: + "p-locate" "^2.0.0" + "path-exists" "^3.0.0" + +"locate-path@^6.0.0": + "integrity" "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==" + "resolved" "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz" + "version" "6.0.0" + dependencies: + "p-locate" "^5.0.0" -log-symbols@4.1.0: - version "4.1.0" - resolved "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" - integrity sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg== +"log-symbols@4.1.0": + "integrity" "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==" + "resolved" "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" + "version" "4.1.0" dependencies: - chalk "^4.1.0" - is-unicode-supported "^0.1.0" - -loupe@^2.3.1: - version "2.3.6" - resolved "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz" - integrity sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA== - dependencies: - get-func-name "^2.0.0" - -make-error@^1.1.1: - version "1.3.6" - resolved "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz" - integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== - -map-age-cleaner@^0.1.1: - version "0.1.3" - resolved "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" - integrity sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w== - dependencies: - p-defer "^1.0.0" - -mem@^4.0.0: - version "4.3.0" - resolved "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz" - integrity sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w== + "chalk" "^4.1.0" + "is-unicode-supported" "^0.1.0" + +"loupe@^2.3.1": + "integrity" "sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==" + "resolved" "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz" + "version" "2.3.6" + dependencies: + "get-func-name" "^2.0.0" + +"make-error@^1.1.1": + "integrity" "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" + "resolved" "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz" + "version" "1.3.6" + +"map-age-cleaner@^0.1.1": + "integrity" "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==" + "resolved" "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" + "version" "0.1.3" + dependencies: + "p-defer" "^1.0.0" + +"mem@^4.0.0": + "integrity" "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==" + "resolved" "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz" + "version" "4.3.0" dependencies: - map-age-cleaner "^0.1.1" - mimic-fn "^2.0.0" - p-is-promise "^2.0.0" + "map-age-cleaner" "^0.1.1" + "mimic-fn" "^2.0.0" + "p-is-promise" "^2.0.0" -mimic-fn@^2.0.0: - version "2.1.0" - resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" - integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== +"mimic-fn@^2.0.0": + "integrity" "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" + "resolved" "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" + "version" "2.1.0" -minimalistic-assert@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" - integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== +"minimalistic-assert@^1.0.0", "minimalistic-assert@^1.0.1": + "integrity" "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + "resolved" "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" + "version" "1.0.1" -minimatch@5.0.1: - version "5.0.1" - resolved "https://registry.npmjs.org/minimatch/-/minimatch-5.0.1.tgz" - integrity sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g== - dependencies: - brace-expansion "^2.0.1" +"minimalistic-crypto-utils@^1.0.1": + "integrity" "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + "resolved" "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz" + "version" "1.0.1" -minimatch@^3.0.4: - version "3.1.2" - resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" - integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== +"minimatch@^3.0.4": + "integrity" "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==" + "resolved" "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" + "version" "3.1.2" dependencies: - brace-expansion "^1.1.7" + "brace-expansion" "^1.1.7" -mocha-typescript@^1.1.17: - version "1.1.17" - resolved "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz" - integrity sha512-Ge6pCQkZumkkhxVNdAf3JxunskShgaynCb30HYD7TT1Yhog/7NW2+6w5RcRHI+nuQrCMTX6z1+qf2pD8qwCoQA== +"minimatch@5.0.1": + "integrity" "sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g==" + "resolved" "https://registry.npmjs.org/minimatch/-/minimatch-5.0.1.tgz" + "version" "5.0.1" dependencies: - "@types/mocha" "^5.2.0" - chalk "^2.4.1" - cross-spawn "^6.0.5" - yargs "^11.0.0" - -mocha@^10.2.0: - version "10.2.0" - resolved "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz" - integrity sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg== - dependencies: - ansi-colors "4.1.1" - browser-stdout "1.3.1" - chokidar "3.5.3" - debug "4.3.4" - diff "5.0.0" - escape-string-regexp "4.0.0" - find-up "5.0.0" - glob "7.2.0" - he "1.2.0" - js-yaml "4.1.0" - log-symbols "4.1.0" - minimatch "5.0.1" - ms "2.1.3" - nanoid "3.3.3" - serialize-javascript "6.0.0" - strip-json-comments "3.1.1" - supports-color "8.1.1" - workerpool "6.2.1" - yargs "16.2.0" - yargs-parser "20.2.4" - yargs-unparser "2.0.0" - -ms@2.1.2: - version "2.1.2" - resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" - integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== - -ms@2.1.3: - version "2.1.3" - resolved "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz" - integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== - -nanoid@3.3.3: - version "3.3.3" - resolved "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz" - integrity sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w== - -nice-try@^1.0.4: - version "1.0.5" - resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" - integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== - -normalize-path@^3.0.0, normalize-path@~3.0.0: - version "3.0.0" - resolved "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz" - integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== - -npm-run-path@^2.0.0: - version "2.0.2" - resolved "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz" - integrity sha512-lJxZYlT4DW/bRUtFh1MQIWqmLwQfAxnqWG4HhEdjMlkrJYnJn0Jrr2u3mgxqaWsdiBc76TYkTG/mhrnYTuzfHw== - dependencies: - path-key "^2.0.0" - -number-is-nan@^1.0.0: - version "1.0.1" - resolved "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" - integrity sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ== - -once@^1.3.0, once@^1.3.1, once@^1.4.0: - version "1.4.0" - resolved "https://registry.npmjs.org/once/-/once-1.4.0.tgz" - integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== - dependencies: - wrappy "1" - -openpgp@^5.5.0: - version "5.5.0" - resolved "https://registry.npmjs.org/openpgp/-/openpgp-5.5.0.tgz" - integrity sha512-SpwcJnxrK9Y0HRM6KxSFqkAEOSWEabCH/c8dII/+y2e5f6KvuDG5ZE7JXaPBaVJNE4VUZZeTphxXDoZD0KOHrw== - dependencies: - asn1.js "^5.0.0" - -os-locale@^3.1.0: - version "3.1.0" - resolved "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz" - integrity sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q== - dependencies: - execa "^1.0.0" - lcid "^2.0.0" - mem "^4.0.0" - -p-defer@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz" - integrity sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw== - -p-finally@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz" - integrity sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow== - -p-is-promise@^2.0.0: - version "2.1.0" - resolved "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz" - integrity sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg== - -p-limit@^1.1.0: - version "1.3.0" - resolved "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz" - integrity sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q== - dependencies: - p-try "^1.0.0" - -p-limit@^3.0.2: - version "3.1.0" - resolved "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz" - integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== - dependencies: - yocto-queue "^0.1.0" - -p-locate@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz" - integrity sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg== - dependencies: - p-limit "^1.1.0" - -p-locate@^5.0.0: - 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== - dependencies: - p-limit "^3.0.2" - -p-try@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz" - integrity sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww== - -path-exists@^3.0.0: - version "3.0.0" - resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" - integrity sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ== - -path-exists@^4.0.0: - version "4.0.0" - resolved "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz" - integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== - -path-is-absolute@^1.0.0: - version "1.0.1" - resolved "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" - integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== - -path-key@^2.0.0, path-key@^2.0.1: - version "2.0.1" - resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" - integrity sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw== - -pathval@^1.1.1: - version "1.1.1" - resolved "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz" - integrity sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ== - -picomatch@^2.0.4, picomatch@^2.2.1: - version "2.3.1" - resolved "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" - integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== - -pump@^3.0.0: - version "3.0.0" - resolved "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz" - integrity sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww== - dependencies: - end-of-stream "^1.1.0" - once "^1.3.1" - -queue-microtask@^1.2.3: - version "1.2.3" - resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" - integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== - -randombytes@^2.1.0: - version "2.1.0" - resolved "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz" - integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== - dependencies: - safe-buffer "^5.1.0" - -readable-stream@^3.6.0: - version "3.6.2" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" - integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== - dependencies: - inherits "^2.0.3" - string_decoder "^1.1.1" - util-deprecate "^1.0.1" - -readdirp@~3.6.0: - version "3.6.0" - resolved "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" - integrity sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA== - dependencies: - picomatch "^2.2.1" - -require-directory@^2.1.1: - version "2.1.1" - resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" - integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== - -require-main-filename@^1.0.1: - version "1.0.1" - resolved "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz" - integrity sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug== - -safe-buffer@^5.1.0, safe-buffer@~5.2.0: - version "5.2.1" - resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" - integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== - -safer-buffer@^2.1.0: - version "2.1.2" - resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" - integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== - -semver@^5.5.0: - version "5.7.1" - resolved "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz" - integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== - -serialize-javascript@6.0.0: - version "6.0.0" - resolved "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz" - integrity sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag== - dependencies: - randombytes "^2.1.0" - -set-blocking@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" - integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== - -shebang-command@^1.2.0: - version "1.2.0" - resolved "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" - integrity sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg== - dependencies: - shebang-regex "^1.0.0" - -shebang-regex@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" - integrity sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ== - -signal-exit@^3.0.0: - version "3.0.7" - resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" - integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== - -simple-peer@^9.11.1: - version "9.11.1" - resolved "https://registry.yarnpkg.com/simple-peer/-/simple-peer-9.11.1.tgz#9814d5723f821b778b7fb011bdefcbd1e788e6cc" - integrity sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw== - dependencies: - buffer "^6.0.3" - debug "^4.3.2" - err-code "^3.0.1" - get-browser-rtc "^1.1.0" - queue-microtask "^1.2.3" - randombytes "^2.1.0" - readable-stream "^3.6.0" - -string-width@^1.0.1: - version "1.0.2" - resolved "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" - integrity sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw== - dependencies: - code-point-at "^1.0.0" - is-fullwidth-code-point "^1.0.0" - strip-ansi "^3.0.0" - -string-width@^2.0.0, string-width@^2.1.1: - version "2.1.1" - resolved "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz" - integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== - dependencies: - is-fullwidth-code-point "^2.0.0" - strip-ansi "^4.0.0" - -string-width@^4.1.0, string-width@^4.2.0: - version "4.2.3" - resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" - integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.1" + "brace-expansion" "^2.0.1" -string_decoder@^1.1.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" - integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== +"mocha-typescript@^1.1.17": + "integrity" "sha512-Ge6pCQkZumkkhxVNdAf3JxunskShgaynCb30HYD7TT1Yhog/7NW2+6w5RcRHI+nuQrCMTX6z1+qf2pD8qwCoQA==" + "resolved" "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz" + "version" "1.1.17" dependencies: - safe-buffer "~5.2.0" - -strip-ansi@^3.0.0, strip-ansi@^3.0.1: - version "3.0.1" - resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" - integrity sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg== + "@types/mocha" "^5.2.0" + "chalk" "^2.4.1" + "cross-spawn" "^6.0.5" + "yargs" "^11.0.0" + +"mocha@^10.2.0": + "integrity" "sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg==" + "resolved" "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz" + "version" "10.2.0" + dependencies: + "ansi-colors" "4.1.1" + "browser-stdout" "1.3.1" + "chokidar" "3.5.3" + "debug" "4.3.4" + "diff" "5.0.0" + "escape-string-regexp" "4.0.0" + "find-up" "5.0.0" + "glob" "7.2.0" + "he" "1.2.0" + "js-yaml" "4.1.0" + "log-symbols" "4.1.0" + "minimatch" "5.0.1" + "ms" "2.1.3" + "nanoid" "3.3.3" + "serialize-javascript" "6.0.0" + "strip-json-comments" "3.1.1" + "supports-color" "8.1.1" + "workerpool" "6.2.1" + "yargs" "16.2.0" + "yargs-parser" "20.2.4" + "yargs-unparser" "2.0.0" + +"ms@2.1.2": + "integrity" "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + "resolved" "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" + "version" "2.1.2" + +"ms@2.1.3": + "integrity" "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + "resolved" "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz" + "version" "2.1.3" + +"nanoid@3.3.3": + "integrity" "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==" + "resolved" "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz" + "version" "3.3.3" + +"nice-try@^1.0.4": + "integrity" "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" + "resolved" "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" + "version" "1.0.5" + +"normalize-path@^3.0.0", "normalize-path@~3.0.0": + "integrity" "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" + "resolved" "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz" + "version" "3.0.0" + +"npm-run-path@^2.0.0": + "integrity" "sha512-lJxZYlT4DW/bRUtFh1MQIWqmLwQfAxnqWG4HhEdjMlkrJYnJn0Jrr2u3mgxqaWsdiBc76TYkTG/mhrnYTuzfHw==" + "resolved" "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz" + "version" "2.0.2" + dependencies: + "path-key" "^2.0.0" + +"number-is-nan@^1.0.0": + "integrity" "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==" + "resolved" "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" + "version" "1.0.1" + +"once@^1.3.0", "once@^1.3.1", "once@^1.4.0": + "integrity" "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==" + "resolved" "https://registry.npmjs.org/once/-/once-1.4.0.tgz" + "version" "1.4.0" + dependencies: + "wrappy" "1" + +"openpgp@^5.5.0": + "integrity" "sha512-SpwcJnxrK9Y0HRM6KxSFqkAEOSWEabCH/c8dII/+y2e5f6KvuDG5ZE7JXaPBaVJNE4VUZZeTphxXDoZD0KOHrw==" + "resolved" "https://registry.npmjs.org/openpgp/-/openpgp-5.5.0.tgz" + "version" "5.5.0" + dependencies: + "asn1.js" "^5.0.0" + +"os-locale@^3.1.0": + "integrity" "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==" + "resolved" "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz" + "version" "3.1.0" + dependencies: + "execa" "^1.0.0" + "lcid" "^2.0.0" + "mem" "^4.0.0" + +"p-defer@^1.0.0": + "integrity" "sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw==" + "resolved" "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz" + "version" "1.0.0" + +"p-finally@^1.0.0": + "integrity" "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==" + "resolved" "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz" + "version" "1.0.0" + +"p-is-promise@^2.0.0": + "integrity" "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==" + "resolved" "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz" + "version" "2.1.0" + +"p-limit@^1.1.0": + "integrity" "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==" + "resolved" "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz" + "version" "1.3.0" + dependencies: + "p-try" "^1.0.0" + +"p-limit@^3.0.2": + "integrity" "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==" + "resolved" "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz" + "version" "3.1.0" + dependencies: + "yocto-queue" "^0.1.0" + +"p-locate@^2.0.0": + "integrity" "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==" + "resolved" "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz" + "version" "2.0.0" + dependencies: + "p-limit" "^1.1.0" + +"p-locate@^5.0.0": + "integrity" "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==" + "resolved" "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz" + "version" "5.0.0" + dependencies: + "p-limit" "^3.0.2" + +"p-try@^1.0.0": + "integrity" "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==" + "resolved" "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz" + "version" "1.0.0" + +"path-exists@^3.0.0": + "integrity" "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==" + "resolved" "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" + "version" "3.0.0" + +"path-exists@^4.0.0": + "integrity" "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==" + "resolved" "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz" + "version" "4.0.0" + +"path-is-absolute@^1.0.0": + "integrity" "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==" + "resolved" "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + "version" "1.0.1" + +"path-key@^2.0.0", "path-key@^2.0.1": + "integrity" "sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==" + "resolved" "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" + "version" "2.0.1" + +"pathval@^1.1.1": + "integrity" "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==" + "resolved" "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz" + "version" "1.1.1" + +"picomatch@^2.0.4", "picomatch@^2.2.1": + "integrity" "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==" + "resolved" "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" + "version" "2.3.1" + +"pump@^3.0.0": + "integrity" "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==" + "resolved" "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz" + "version" "3.0.0" + dependencies: + "end-of-stream" "^1.1.0" + "once" "^1.3.1" + +"queue-microtask@^1.2.3": + "integrity" "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==" + "resolved" "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz" + "version" "1.2.3" + +"randombytes@^2.1.0": + "integrity" "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==" + "resolved" "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz" + "version" "2.1.0" + dependencies: + "safe-buffer" "^5.1.0" + +"readable-stream@^3.6.0": + "integrity" "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==" + "resolved" "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz" + "version" "3.6.2" + dependencies: + "inherits" "^2.0.3" + "string_decoder" "^1.1.1" + "util-deprecate" "^1.0.1" + +"readdirp@~3.6.0": + "integrity" "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==" + "resolved" "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" + "version" "3.6.0" + dependencies: + "picomatch" "^2.2.1" + +"require-directory@^2.1.1": + "integrity" "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==" + "resolved" "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" + "version" "2.1.1" + +"require-main-filename@^1.0.1": + "integrity" "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==" + "resolved" "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz" + "version" "1.0.1" + +"safe-buffer@^5.1.0", "safe-buffer@~5.2.0": + "integrity" "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + "resolved" "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" + "version" "5.2.1" + +"safer-buffer@^2.1.0": + "integrity" "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + "resolved" "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" + "version" "2.1.2" + +"scrypt-js@3.0.1": + "integrity" "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + "resolved" "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz" + "version" "3.0.1" + +"semver@^5.5.0": + "integrity" "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + "resolved" "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz" + "version" "5.7.1" + +"serialize-javascript@6.0.0": + "integrity" "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==" + "resolved" "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz" + "version" "6.0.0" + dependencies: + "randombytes" "^2.1.0" + +"set-blocking@^2.0.0": + "integrity" "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==" + "resolved" "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" + "version" "2.0.0" + +"shebang-command@^1.2.0": + "integrity" "sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==" + "resolved" "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" + "version" "1.2.0" + dependencies: + "shebang-regex" "^1.0.0" + +"shebang-regex@^1.0.0": + "integrity" "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==" + "resolved" "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" + "version" "1.0.0" + +"signal-exit@^3.0.0": + "integrity" "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + "resolved" "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" + "version" "3.0.7" + +"simple-peer@^9.11.1": + "integrity" "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==" + "resolved" "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz" + "version" "9.11.1" + dependencies: + "buffer" "^6.0.3" + "debug" "^4.3.2" + "err-code" "^3.0.1" + "get-browser-rtc" "^1.1.0" + "queue-microtask" "^1.2.3" + "randombytes" "^2.1.0" + "readable-stream" "^3.6.0" + +"string_decoder@^1.1.1": + "integrity" "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==" + "resolved" "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz" + "version" "1.3.0" + dependencies: + "safe-buffer" "~5.2.0" + +"string-width@^1.0.1": + "integrity" "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==" + "resolved" "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" + "version" "1.0.2" + dependencies: + "code-point-at" "^1.0.0" + "is-fullwidth-code-point" "^1.0.0" + "strip-ansi" "^3.0.0" + +"string-width@^2.0.0", "string-width@^2.1.1": + "integrity" "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==" + "resolved" "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz" + "version" "2.1.1" + dependencies: + "is-fullwidth-code-point" "^2.0.0" + "strip-ansi" "^4.0.0" + +"string-width@^4.1.0", "string-width@^4.2.0": + "integrity" "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==" + "resolved" "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" + "version" "4.2.3" + dependencies: + "emoji-regex" "^8.0.0" + "is-fullwidth-code-point" "^3.0.0" + "strip-ansi" "^6.0.1" + +"strip-ansi@^3.0.0", "strip-ansi@^3.0.1": + "integrity" "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==" + "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" + "version" "3.0.1" dependencies: - ansi-regex "^2.0.0" - -strip-ansi@^4.0.0: - version "4.0.0" - resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz" - integrity sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow== - dependencies: - ansi-regex "^3.0.0" + "ansi-regex" "^2.0.0" + +"strip-ansi@^4.0.0": + "integrity" "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==" + "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz" + "version" "4.0.0" + dependencies: + "ansi-regex" "^3.0.0" -strip-ansi@^6.0.0, strip-ansi@^6.0.1: - version "6.0.1" - resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" - integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== +"strip-ansi@^6.0.0", "strip-ansi@^6.0.1": + "integrity" "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==" + "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" + "version" "6.0.1" dependencies: - ansi-regex "^5.0.1" + "ansi-regex" "^5.0.1" -strip-eof@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz" - integrity sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q== +"strip-eof@^1.0.0": + "integrity" "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==" + "resolved" "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz" + "version" "1.0.0" -strip-hex-prefix@1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz" - integrity sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A== +"strip-hex-prefix@1.0.0": + "integrity" "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==" + "resolved" "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz" + "version" "1.0.0" dependencies: - is-hex-prefixed "1.0.0" + "is-hex-prefixed" "1.0.0" -strip-json-comments@3.1.1: - 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== +"strip-json-comments@3.1.1": + "integrity" "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==" + "resolved" "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz" + "version" "3.1.1" -supports-color@8.1.1: - version "8.1.1" - resolved "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz" - integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== +"supports-color@^5.3.0": + "integrity" "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==" + "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" + "version" "5.5.0" dependencies: - has-flag "^4.0.0" + "has-flag" "^3.0.0" -supports-color@^5.3.0: - version "5.5.0" - resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" - integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== +"supports-color@^7.1.0": + "integrity" "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==" + "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz" + "version" "7.2.0" dependencies: - has-flag "^3.0.0" + "has-flag" "^4.0.0" -supports-color@^7.1.0: - version "7.2.0" - resolved "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz" - integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== +"supports-color@8.1.1": + "integrity" "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==" + "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz" + "version" "8.1.1" dependencies: - has-flag "^4.0.0" + "has-flag" "^4.0.0" -to-regex-range@^5.0.1: - 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== +"to-regex-range@^5.0.1": + "integrity" "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==" + "resolved" "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" + "version" "5.0.1" dependencies: - is-number "^7.0.0" + "is-number" "^7.0.0" -ts-node@^10.9.1: - version "10.9.1" - resolved "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz" - integrity sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw== +"ts-node@^10.9.1": + "integrity" "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==" + "resolved" "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz" + "version" "10.9.1" dependencies: "@cspotcode/source-map-support" "^0.8.0" "@tsconfig/node10" "^1.0.7" "@tsconfig/node12" "^1.0.7" "@tsconfig/node14" "^1.0.0" "@tsconfig/node16" "^1.0.2" - acorn "^8.4.1" - acorn-walk "^8.1.1" - arg "^4.1.0" - create-require "^1.1.0" - diff "^4.0.1" - make-error "^1.1.1" - v8-compile-cache-lib "^3.0.1" - yn "3.1.1" - -tweetnacl-util@^0.15.1: - version "0.15.1" - resolved "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz" - integrity sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw== - -tweetnacl@^1.0.3: - version "1.0.3" - resolved "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz" - integrity sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw== - -type-detect@^4.0.0, type-detect@^4.0.5: - version "4.0.8" - resolved "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz" - integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== - -typescript@^5.0.2: - version "5.0.2" - resolved "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz" - integrity sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw== - -util-deprecate@^1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" - integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== - -v8-compile-cache-lib@^3.0.1: - version "3.0.1" - resolved "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz" - integrity sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg== - -which-module@^2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" - integrity sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q== - -which@^1.2.9: - version "1.3.1" - resolved "https://registry.npmjs.org/which/-/which-1.3.1.tgz" - integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== - dependencies: - isexe "^2.0.0" - -workerpool@6.2.1: - version "6.2.1" - resolved "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz" - integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw== - -wrap-ansi@^2.0.0: - version "2.1.0" - resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz" - integrity sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw== - dependencies: - string-width "^1.0.1" - strip-ansi "^3.0.1" - -wrap-ansi@^7.0.0: - version "7.0.0" - resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" - integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== - dependencies: - ansi-styles "^4.0.0" - string-width "^4.1.0" - strip-ansi "^6.0.0" - -wrappy@1: - version "1.0.2" - resolved "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" - integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== - -y18n@^3.2.1: - version "3.2.2" - resolved "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz" - integrity sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ== - -y18n@^5.0.5: - version "5.0.8" - resolved "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz" - integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== - -yargs-parser@20.2.4, yargs-parser@^20.2.2: - version "20.2.4" - resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.4.tgz" - integrity sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA== - -yargs-parser@^9.0.2: - version "9.0.2" - resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz" - integrity sha512-CswCfdOgCr4MMsT1GzbEJ7Z2uYudWyrGX8Bgh/0eyCzj/DXWdKq6a/ADufkzI1WAOIW6jYaXJvRyLhDO0kfqBw== - dependencies: - camelcase "^4.1.0" - -yargs-unparser@2.0.0: - version "2.0.0" - resolved "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz" - integrity sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA== - dependencies: - camelcase "^6.0.0" - decamelize "^4.0.0" - flat "^5.0.2" - is-plain-obj "^2.1.0" - -yargs@16.2.0: - version "16.2.0" - resolved "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz" - integrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw== - dependencies: - cliui "^7.0.2" - escalade "^3.1.1" - get-caller-file "^2.0.5" - require-directory "^2.1.1" - string-width "^4.2.0" - y18n "^5.0.5" - yargs-parser "^20.2.2" - -yargs@^11.0.0: - version "11.1.1" - resolved "https://registry.npmjs.org/yargs/-/yargs-11.1.1.tgz" - integrity sha512-PRU7gJrJaXv3q3yQZ/+/X6KBswZiaQ+zOmdprZcouPYtQgvNU35i+68M4b1ZHLZtYFT5QObFLV+ZkmJYcwKdiw== - dependencies: - cliui "^4.0.0" - decamelize "^1.1.1" - find-up "^2.1.0" - get-caller-file "^1.0.1" - os-locale "^3.1.0" - require-directory "^2.1.1" - require-main-filename "^1.0.1" - set-blocking "^2.0.0" - string-width "^2.0.0" - which-module "^2.0.0" - y18n "^3.2.1" - yargs-parser "^9.0.2" - -yn@3.1.1: - version "3.1.1" - resolved "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz" - integrity sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q== - -yocto-queue@^0.1.0: - version "0.1.0" - resolved "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz" - integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== + "acorn" "^8.4.1" + "acorn-walk" "^8.1.1" + "arg" "^4.1.0" + "create-require" "^1.1.0" + "diff" "^4.0.1" + "make-error" "^1.1.1" + "v8-compile-cache-lib" "^3.0.1" + "yn" "3.1.1" + +"tweetnacl-util@^0.15.1": + "integrity" "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + "resolved" "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz" + "version" "0.15.1" + +"tweetnacl@^1.0.3": + "integrity" "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + "resolved" "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz" + "version" "1.0.3" + +"type-detect@^4.0.0", "type-detect@^4.0.5": + "integrity" "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" + "resolved" "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz" + "version" "4.0.8" + +"typescript@^5.0.2", "typescript@>=2.7": + "integrity" "sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw==" + "resolved" "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz" + "version" "5.0.2" + +"util-deprecate@^1.0.1": + "integrity" "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + "resolved" "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" + "version" "1.0.2" + +"v8-compile-cache-lib@^3.0.1": + "integrity" "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==" + "resolved" "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz" + "version" "3.0.1" + +"which-module@^2.0.0": + "integrity" "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==" + "resolved" "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" + "version" "2.0.0" + +"which@^1.2.9": + "integrity" "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==" + "resolved" "https://registry.npmjs.org/which/-/which-1.3.1.tgz" + "version" "1.3.1" + dependencies: + "isexe" "^2.0.0" + +"workerpool@6.2.1": + "integrity" "sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==" + "resolved" "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz" + "version" "6.2.1" + +"wrap-ansi@^2.0.0": + "integrity" "sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw==" + "resolved" "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz" + "version" "2.1.0" + dependencies: + "string-width" "^1.0.1" + "strip-ansi" "^3.0.1" + +"wrap-ansi@^7.0.0": + "integrity" "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==" + "resolved" "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" + "version" "7.0.0" + dependencies: + "ansi-styles" "^4.0.0" + "string-width" "^4.1.0" + "strip-ansi" "^6.0.0" + +"wrappy@1": + "integrity" "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + "resolved" "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" + "version" "1.0.2" + +"ws@7.4.6": + "integrity" "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==" + "resolved" "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz" + "version" "7.4.6" + +"y18n@^3.2.1": + "integrity" "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==" + "resolved" "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz" + "version" "3.2.2" + +"y18n@^5.0.5": + "integrity" "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==" + "resolved" "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz" + "version" "5.0.8" + +"yargs-parser@^20.2.2", "yargs-parser@20.2.4": + "integrity" "sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==" + "resolved" "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.4.tgz" + "version" "20.2.4" + +"yargs-parser@^9.0.2": + "integrity" "sha512-CswCfdOgCr4MMsT1GzbEJ7Z2uYudWyrGX8Bgh/0eyCzj/DXWdKq6a/ADufkzI1WAOIW6jYaXJvRyLhDO0kfqBw==" + "resolved" "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz" + "version" "9.0.2" + dependencies: + "camelcase" "^4.1.0" + +"yargs-unparser@2.0.0": + "integrity" "sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==" + "resolved" "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz" + "version" "2.0.0" + dependencies: + "camelcase" "^6.0.0" + "decamelize" "^4.0.0" + "flat" "^5.0.2" + "is-plain-obj" "^2.1.0" + +"yargs@^11.0.0": + "integrity" "sha512-PRU7gJrJaXv3q3yQZ/+/X6KBswZiaQ+zOmdprZcouPYtQgvNU35i+68M4b1ZHLZtYFT5QObFLV+ZkmJYcwKdiw==" + "resolved" "https://registry.npmjs.org/yargs/-/yargs-11.1.1.tgz" + "version" "11.1.1" + dependencies: + "cliui" "^4.0.0" + "decamelize" "^1.1.1" + "find-up" "^2.1.0" + "get-caller-file" "^1.0.1" + "os-locale" "^3.1.0" + "require-directory" "^2.1.1" + "require-main-filename" "^1.0.1" + "set-blocking" "^2.0.0" + "string-width" "^2.0.0" + "which-module" "^2.0.0" + "y18n" "^3.2.1" + "yargs-parser" "^9.0.2" + +"yargs@16.2.0": + "integrity" "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==" + "resolved" "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz" + "version" "16.2.0" + dependencies: + "cliui" "^7.0.2" + "escalade" "^3.1.1" + "get-caller-file" "^2.0.5" + "require-directory" "^2.1.1" + "string-width" "^4.2.0" + "y18n" "^5.0.5" + "yargs-parser" "^20.2.2" + +"yn@3.1.1": + "integrity" "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" + "resolved" "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz" + "version" "3.1.1" + +"yocto-queue@^0.1.0": + "integrity" "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==" + "resolved" "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz" + "version" "0.1.0" From 706a1e5e023646f5a2073cb1e4ef281719929b7f Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 2 Jun 2023 14:51:20 +0530 Subject: [PATCH 118/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.16?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8fbe73bac..616b8d44b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.15...restapi-0.0.1-alpha.16) (2023-06-02) + + +### Bug Fixes + +* add profile.update feature ([#410](https://github.com/ethereum-push-notification-service/push-sdk/issues/410)) ([361b930](https://github.com/ethereum-push-notification-service/push-sdk/commit/361b9303c5340238bcb7fa457370707ae864756b)) +* add spaces for functions ([#307](https://github.com/ethereum-push-notification-service/push-sdk/issues/307)) ([aea015a](https://github.com/ethereum-push-notification-service/push-sdk/commit/aea015ae478da77ebaa41a4e111ac213027b0b6a)) +* Merge branch 'alpha' into alpha-deployment ([ad6a56b](https://github.com/ethereum-push-notification-service/push-sdk/commit/ad6a56be24c326b7fb1f6eddb01b20b489eee27d)) +* merge main ([3959345](https://github.com/ethereum-push-notification-service/push-sdk/commit/39593456140e152e53f4bd7c10a19e0d8f05dfc9)) + + + ## [0.0.1-alpha.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.14...restapi-0.0.1-alpha.15) (2023-05-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index dcbf702f6..90ff72264 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.15", + "version": "0.0.1-alpha.16", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 029aa49528c25127101da013287d82a058592be8 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 5 Jun 2023 13:16:09 +0530 Subject: [PATCH 119/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 426ff45e6..fc33be748 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.3...restapi-1.3.4) (2023-06-05) + + +### Bug Fixes + +* fix subset for take whole array ([#429](https://github.com/ethereum-push-notification-service/push-sdk/issues/429)) ([88b5a4d](https://github.com/ethereum-push-notification-service/push-sdk/commit/88b5a4d8df6363087895c9f8c635b91253237a44)) + + + ## [1.3.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.2...restapi-1.3.3) (2023-05-31) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index cc93dfbfe..1aaef6fc9 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.3", + "version": "1.3.4", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 1c4521d080546301531c8a4dac0f3e53a5cb44fb Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 8 Jun 2023 16:43:07 +0530 Subject: [PATCH 120/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index fc33be748..25554c318 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.4...restapi-1.3.5) (2023-06-08) + + +### Bug Fixes + +* **video:** fix error on repeated acceptRequest calls ([#439](https://github.com/ethereum-push-notification-service/push-sdk/issues/439)) ([4936d1f](https://github.com/ethereum-push-notification-service/push-sdk/commit/4936d1f9d747401d341a7dc502e9044c00290c8a)) + + + ## [1.3.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.3...restapi-1.3.4) (2023-06-05) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 1aaef6fc9..dcb66a49b 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.4", + "version": "1.3.5", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From f34bfa09cf88e812e07c0dcf7fabf792726c577f Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Thu, 8 Jun 2023 19:06:56 +0530 Subject: [PATCH 121/298] fix(video): fix error on repeated acceptRequest calls (#442) --- packages/restapi/src/lib/video/Video.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index e3b5c2c6b..0fc2146dd 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -274,9 +274,17 @@ export class Video { 'options', options, 'localStream', - this.data.local.stream + this.data.local.stream, + "peerInstance", + this.peerInstance ); + // if peerInstance is not null -> acceptRequest/request was called before + if (this.peerInstance) { + // to prevent connection error we stop the exec of acceptRequest + return Promise.resolve(); + } + this.peerInstance = new Peer({ initiator: false, trickle: false, From e07391fd391791929c7d5c95eb078a7fc6456d88 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 8 Jun 2023 19:14:07 +0530 Subject: [PATCH 122/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.17?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 616b8d44b..b44a5360b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.17](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.16...restapi-0.0.1-alpha.17) (2023-06-08) + + +### Bug Fixes + +* fix subset for take whole array ([#429](https://github.com/ethereum-push-notification-service/push-sdk/issues/429)) ([88b5a4d](https://github.com/ethereum-push-notification-service/push-sdk/commit/88b5a4d8df6363087895c9f8c635b91253237a44)) +* Merge branch 'alpha' into alpha-deployment ([a9d8ff1](https://github.com/ethereum-push-notification-service/push-sdk/commit/a9d8ff18bcad950e40b966e5b4020e29b493aa28)) +* merge main ([78c020a](https://github.com/ethereum-push-notification-service/push-sdk/commit/78c020ac61decc2d3b78d3749c8ec5df7478842f)) +* **video:** fix error on repeated acceptRequest calls ([#439](https://github.com/ethereum-push-notification-service/push-sdk/issues/439)) ([4936d1f](https://github.com/ethereum-push-notification-service/push-sdk/commit/4936d1f9d747401d341a7dc502e9044c00290c8a)) +* **video:** fix error on repeated acceptRequest calls ([#442](https://github.com/ethereum-push-notification-service/push-sdk/issues/442)) ([f34bfa0](https://github.com/ethereum-push-notification-service/push-sdk/commit/f34bfa09cf88e812e07c0dcf7fabf792726c577f)) + + + ## [0.0.1-alpha.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.15...restapi-0.0.1-alpha.16) (2023-06-02) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 90ff72264..3e19c51a5 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.16", + "version": "0.0.1-alpha.17", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 712a5e59d495b7dfbbfb484177afe14115b2216a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 9 Jun 2023 11:19:44 +0530 Subject: [PATCH 123/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 25554c318..ddfe7723b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.5...restapi-1.3.6) (2023-06-09) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([af582f7](https://github.com/ethereum-push-notification-service/push-sdk/commit/af582f7efba83b69f5d29a97f772a00de16a0c25)) +* **video:** clear the peer instance in disconnect ([#445](https://github.com/ethereum-push-notification-service/push-sdk/issues/445)) ([db32d2c](https://github.com/ethereum-push-notification-service/push-sdk/commit/db32d2c901d8a208d409b6c09a716dee653b06f9)) + + + ## [1.3.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.4...restapi-1.3.5) (2023-06-08) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index dcb66a49b..2c35b1870 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.5", + "version": "1.3.6", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 36a5c072747d5c98df4abdf625e1b4ec80539a17 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 12 Jun 2023 14:08:58 +0530 Subject: [PATCH 124/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index ddfe7723b..1a248ace7 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.6...restapi-1.3.7) (2023-06-12) + + +### Bug Fixes + +* destroy peer instance in disconnect ([#451](https://github.com/ethereum-push-notification-service/push-sdk/issues/451)) ([439fd96](https://github.com/ethereum-push-notification-service/push-sdk/commit/439fd9627168e31b8626c88368eebb3a4443a092)) +* Merge branch 'main' into deployment ([494916b](https://github.com/ethereum-push-notification-service/push-sdk/commit/494916b3b4140f44cb5ae1d7d674a31a420d1995)) + + + ## [1.3.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.5...restapi-1.3.6) (2023-06-09) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 2c35b1870..d4a2d5a5f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.6", + "version": "1.3.7", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 183e9c244e402eb00dc94d4ae40ddbaf5038dde8 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 12 Jun 2023 20:09:53 +0530 Subject: [PATCH 125/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 1a248ace7..21a5a2522 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.7...restapi-1.3.8) (2023-06-12) + + +### Bug Fixes + +* added types for Env and name in Ifeeds ([#452](https://github.com/ethereum-push-notification-service/push-sdk/issues/452)) ([301808e](https://github.com/ethereum-push-notification-service/push-sdk/commit/301808e81fc66df10a0f64b65eb7d13375702e00)) + + + ## [1.3.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.6...restapi-1.3.7) (2023-06-12) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index d4a2d5a5f..bfbe50baf 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.7", + "version": "1.3.8", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 10d62b1a017b3d0a5044a4ab33bdce183f795f51 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 20 Jun 2023 12:49:37 +0530 Subject: [PATCH 126/298] fix: update path --- packages/restapi/src/lib/space/trending.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/restapi/src/lib/space/trending.ts b/packages/restapi/src/lib/space/trending.ts index 67cd8fd36..94b079129 100644 --- a/packages/restapi/src/lib/space/trending.ts +++ b/packages/restapi/src/lib/space/trending.ts @@ -29,7 +29,7 @@ export const trending = async ( limit = 10, } = options || {}; const API_BASE_URL = getAPIBaseUrls(env); - const apiEndpoint = `${API_BASE_URL}/v1/spaces/users/trending?page=${page}&limit=${limit}`; + const apiEndpoint = `${API_BASE_URL}/v1/spaces/trending?page=${page}&limit=${limit}`; try { const response = await axios.get(apiEndpoint); From 9c222715d0f15ae912b90661f9d18d42bddc4c89 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 20 Jun 2023 12:56:13 +0530 Subject: [PATCH 127/298] fix: add name to SpaceIFeeds --- packages/restapi/src/lib/types/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index b84340b34..7043a15f0 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -177,6 +177,7 @@ export interface SpaceIFeeds { did: string; wallets: string; profilePicture: string | null; + name: string | null; publicKey: string | null; about: string | null; threadhash: string | null; From bb491854540a6fe4d226d2e142622ad5ddc6ff94 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 20 Jun 2023 13:03:34 +0530 Subject: [PATCH 128/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.18?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 17 +++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index b44a5360b..513ad72fc 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,23 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.18](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.17...restapi-0.0.1-alpha.18) (2023-06-20) + + +### Bug Fixes + +* add blockedUsersList functionality to SDK ([#444](https://github.com/ethereum-push-notification-service/push-sdk/issues/444)) ([d66e3ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/d66e3ff9fcb7b775705315654a759800b367122d)) +* add name to SpaceIFeeds ([9c22271](https://github.com/ethereum-push-notification-service/push-sdk/commit/9c222715d0f15ae912b90661f9d18d42bddc4c89)) +* added types for Env and name in Ifeeds ([#452](https://github.com/ethereum-push-notification-service/push-sdk/issues/452)) ([301808e](https://github.com/ethereum-push-notification-service/push-sdk/commit/301808e81fc66df10a0f64b65eb7d13375702e00)) +* destroy peer instance in disconnect ([#451](https://github.com/ethereum-push-notification-service/push-sdk/issues/451)) ([439fd96](https://github.com/ethereum-push-notification-service/push-sdk/commit/439fd9627168e31b8626c88368eebb3a4443a092)) +* Merge branch 'alpha' into alpha-deployment ([b521522](https://github.com/ethereum-push-notification-service/push-sdk/commit/b521522c3b147b789a03b2683da4b6cefac795fe)) +* Merge branch 'main' into alpha ([64de06f](https://github.com/ethereum-push-notification-service/push-sdk/commit/64de06fc3cfd4359cf0d7fb70212e775ce9e51b9)) +* merge main ([27105a2](https://github.com/ethereum-push-notification-service/push-sdk/commit/27105a247fe4bd4db78a41be06ef6a2d52fb6b21)) +* update path ([10d62b1](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d62b1a017b3d0a5044a4ab33bdce183f795f51)) +* **video:** clear the peer instance in disconnect ([#445](https://github.com/ethereum-push-notification-service/push-sdk/issues/445)) ([db32d2c](https://github.com/ethereum-push-notification-service/push-sdk/commit/db32d2c901d8a208d409b6c09a716dee653b06f9)) + + + ## [0.0.1-alpha.17](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.16...restapi-0.0.1-alpha.17) (2023-06-08) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 3e19c51a5..e42524d35 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.17", + "version": "0.0.1-alpha.18", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 3fe41c43e27291f5fda705c1a40ef3ea54fe564a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 26 Jun 2023 21:37:19 +0530 Subject: [PATCH 129/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.3.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 21a5a2522..4d1b4a228 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.3.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.8...restapi-1.3.9) (2023-06-26) + + +### Bug Fixes + +* add blockedUsersList functionality to SDK ([#444](https://github.com/ethereum-push-notification-service/push-sdk/issues/444)) ([d66e3ff](https://github.com/ethereum-push-notification-service/push-sdk/commit/d66e3ff9fcb7b775705315654a759800b367122d)) +* Merge branch 'main' into deployment ([a95a1aa](https://github.com/ethereum-push-notification-service/push-sdk/commit/a95a1aaef0b2ae579e40e17e898f7df58a00388f)) +* **video:** add error handlers and turn server config ([#466](https://github.com/ethereum-push-notification-service/push-sdk/issues/466)) ([cda9a28](https://github.com/ethereum-push-notification-service/push-sdk/commit/cda9a28bbb99bf8bd40bcd13f3c486cbf1ebe5a2)) + + + ## [1.3.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.7...restapi-1.3.8) (2023-06-12) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index bfbe50baf..143b636d7 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.3.8", + "version": "1.3.9", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 0e34479b1581abd59e0f853d6547e23a0afb5e28 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 3 Jul 2023 20:48:51 +0530 Subject: [PATCH 130/298] fix: rename based on new convention --- .../src/app/ChatTest/AddAdminsToGroupTest.tsx | 2 +- .../app/ChatTest/AddMembersToGroupTest.tsx | 2 +- .../ChatTest/RemoveAdminsFromGroupTest.tsx | 2 +- .../ChatTest/RemoveMembersFromGroupTest.tsx | 2 +- ...ceTest.tsx => AddListenersToSpaceTest.tsx} | 26 +++++++++---------- ...aceTest.tsx => AddSpeakersToSpaceTest.tsx} | 26 +++++++++---------- ...t.tsx => RemoveListenersFromSpaceTest.tsx} | 26 +++++++++---------- ...st.tsx => RemoveSpeakersFromSpaceTest.tsx} | 26 +++++++++---------- .../demoreact/src/app/SpaceTest/SpaceTest.tsx | 16 ++++++------ packages/demoreact/src/app/app.tsx | 16 ++++++------ .../{addAdminsToGroup.ts => addAdmins.ts} | 6 ++--- .../{addMembersToGroup.ts => addMembers.ts} | 6 ++--- .../src/lib/chat/helpers/payloadHelper.ts | 14 ++++++++-- packages/restapi/src/lib/chat/index.ts | 8 +++--- ...moveAdminsFromGroup.ts => removeAdmins.ts} | 6 ++--- ...veMembersFromGroup.ts => removeMembers.ts} | 6 ++--- .../{addMembersToSpace.ts => addListeners.ts} | 22 ++++++++-------- .../{addAdminsToSpace.ts => addSpeakers.ts} | 16 ++++++------ packages/restapi/src/lib/space/index.ts | 8 +++--- ...MembersFromSpace.ts => removeListeners.ts} | 24 ++++++++--------- ...veAdminsFromSpace.ts => removeSpeakers.ts} | 24 ++++++++--------- packages/restapi/src/lib/types/index.ts | 4 +-- 22 files changed, 149 insertions(+), 139 deletions(-) rename packages/demoreact/src/app/SpaceTest/{AddMembersToSpaceTest.tsx => AddListenersToSpaceTest.tsx} (76%) rename packages/demoreact/src/app/SpaceTest/{AddAdminsToSpaceTest.tsx => AddSpeakersToSpaceTest.tsx} (76%) rename packages/demoreact/src/app/SpaceTest/{RemoveMembersFromSpaceTest.tsx => RemoveListenersFromSpaceTest.tsx} (75%) rename packages/demoreact/src/app/SpaceTest/{RemoveAdminsFromSpaceTest.tsx => RemoveSpeakersFromSpaceTest.tsx} (76%) rename packages/restapi/src/lib/chat/{addAdminsToGroup.ts => addAdmins.ts} (93%) rename packages/restapi/src/lib/chat/{addMembersToGroup.ts => addMembers.ts} (92%) rename packages/restapi/src/lib/chat/{removeAdminsFromGroup.ts => removeAdmins.ts} (92%) rename packages/restapi/src/lib/chat/{removeMembersFromGroup.ts => removeMembers.ts} (91%) rename packages/restapi/src/lib/space/{addMembersToSpace.ts => addListeners.ts} (57%) rename packages/restapi/src/lib/space/{addAdminsToSpace.ts => addSpeakers.ts} (58%) rename packages/restapi/src/lib/space/{removeMembersFromSpace.ts => removeListeners.ts} (56%) rename packages/restapi/src/lib/space/{removeAdminsFromSpace.ts => removeSpeakers.ts} (57%) diff --git a/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx b/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx index 3bb109652..b1d807e46 100644 --- a/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx +++ b/packages/demoreact/src/app/ChatTest/AddAdminsToGroupTest.tsx @@ -35,7 +35,7 @@ const AddAdminsToGroupTest = () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.chat.addAdminsToGroup({ + const response = await PushAPI.chat.addAdmins({ chatId: chatId, admins: memberAddress ? memberAddress.split(',') : [], env, diff --git a/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx b/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx index 23956e45d..2ee6452e1 100644 --- a/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx +++ b/packages/demoreact/src/app/ChatTest/AddMembersToGroupTest.tsx @@ -35,7 +35,7 @@ const AddMembersToGroupTest = () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.chat.addMembersToGroup({ + const response = await PushAPI.chat.addMembers({ chatId: chatId, members: memberAddress ? memberAddress.split(',') : [], env, diff --git a/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx b/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx index cec4edbde..b875c7c46 100644 --- a/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx +++ b/packages/demoreact/src/app/ChatTest/RemoveAdminsFromGroupTest.tsx @@ -35,7 +35,7 @@ const RemoveAdminsFromGroupTest = () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.chat.removeAdminsFromGroup({ + const response = await PushAPI.chat.removeAdmins({ chatId: chatId, admins: memberAddress ? memberAddress.split(',') : [], env, diff --git a/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx b/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx index 5c0928f3d..b2b3974d0 100644 --- a/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx +++ b/packages/demoreact/src/app/ChatTest/RemoveMembersFromGroupTest.tsx @@ -30,7 +30,7 @@ const updateMemberId = (e: React.SyntheticEvent) => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.chat.removeMembersFromGroup({ + const response = await PushAPI.chat.removeMembers({ chatId: chatId, members: memberAddress ? memberAddress.split(',') : [], env, diff --git a/packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/AddListenersToSpaceTest.tsx similarity index 76% rename from packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx rename to packages/demoreact/src/app/SpaceTest/AddListenersToSpaceTest.tsx index 31a930d10..7afbaa113 100644 --- a/packages/demoreact/src/app/SpaceTest/AddMembersToSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/AddListenersToSpaceTest.tsx @@ -10,12 +10,12 @@ import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; import SpaceTest from './SpaceTest'; -const AddMembersToSpaceTest = () => { +const AddListenersToSpaceTest = () => { const { account: acc, library } = useContext(Web3Context); const { env } = useContext(EnvContext); const [isLoading, setLoading] = useState(false); const [spaceId, setSpaceId] = useState(''); - const [memberAddress, setMemberAddress] = useState(''); + const [listenerAddress, setListenerAddress] = useState(''); const [sendResponse, setSendResponse] = useState(''); const [account, setAccount] = useState(acc); @@ -23,20 +23,20 @@ const AddMembersToSpaceTest = () => { setSpaceId((e.target as HTMLInputElement).value); }; - const updateMemberId = (e: React.SyntheticEvent) => { - setMemberAddress((e.target as HTMLInputElement).value); + const updateListenerId = (e: React.SyntheticEvent) => { + setListenerAddress((e.target as HTMLInputElement).value); }; const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; - const addMembersToSpaceTest = async () => { + const addListenersToSpaceTest = async () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.space.addMembersToSpace({ + const response = await PushAPI.space.addListeners({ spaceId: spaceId, - members: memberAddress ? memberAddress.split(',') : [], + listeners: listenerAddress ? listenerAddress.split(',') : [], env, account: account, signer: librarySigner, @@ -52,13 +52,13 @@ const AddMembersToSpaceTest = () => { return (
-

Add Members to Space Test page

+

Add Listeners to Space Test page

- Add Members to Space + Add Listeners to Space @@ -70,11 +70,11 @@ const AddMembersToSpaceTest = () => { /> - + @@ -101,4 +101,4 @@ const AddMembersToSpaceTest = () => { ); }; -export default AddMembersToSpaceTest; +export default AddListenersToSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx similarity index 76% rename from packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx rename to packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx index 75794e011..ab4b31b42 100644 --- a/packages/demoreact/src/app/SpaceTest/AddAdminsToSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx @@ -10,12 +10,12 @@ import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; import SpaceTest from './SpaceTest'; -const AddAdminsToSpaceTest = () => { +const AddSpeakersToSpaceTest = () => { const { account: acc, library } = useContext(Web3Context); const { env } = useContext(EnvContext); const [isLoading, setLoading] = useState(false); const [spaceId, setSpaceId] = useState(''); - const [memberAddress, setMemberAddress] = useState(''); + const [speakerAddress, setSpeakerAddress] = useState(''); const [sendResponse, setSendResponse] = useState(''); const [account, setAccount] = useState(acc); @@ -23,21 +23,21 @@ const AddAdminsToSpaceTest = () => { setSpaceId((e.target as HTMLInputElement).value); }; - const updateMemberId = (e: React.SyntheticEvent) => { - setMemberAddress((e.target as HTMLInputElement).value); + const updateSpeakerId = (e: React.SyntheticEvent) => { + setSpeakerAddress((e.target as HTMLInputElement).value); }; const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; - const testAddAdminsToSpaceTest = async () => { + const testAddSpeakersToSpaceTest = async () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.space.addAdminsToSpace({ + const response = await PushAPI.space.addSpeakers({ spaceId: spaceId, - admins: memberAddress ? memberAddress.split(',') : [], + speakers: speakerAddress ? speakerAddress.split(',') : [], env, account: account, signer: librarySigner, @@ -54,13 +54,13 @@ const AddAdminsToSpaceTest = () => { return (
-

Add Admins to Space Test page

+

Add Speakers to Space Test page

- Add Admins to Space + Add Speakers to Space @@ -72,11 +72,11 @@ const AddAdminsToSpaceTest = () => { /> - + @@ -103,4 +103,4 @@ const AddAdminsToSpaceTest = () => { ); }; -export default AddAdminsToSpaceTest; +export default AddSpeakersToSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/RemoveListenersFromSpaceTest.tsx similarity index 75% rename from packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx rename to packages/demoreact/src/app/SpaceTest/RemoveListenersFromSpaceTest.tsx index 67884aca9..fe0b3b4c1 100644 --- a/packages/demoreact/src/app/SpaceTest/RemoveMembersFromSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/RemoveListenersFromSpaceTest.tsx @@ -10,12 +10,12 @@ import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; import SpaceTest from './SpaceTest'; -const RemoveMembersFromSpaceTest = () => { +const RemoveListenersFromSpaceTest = () => { const { account: acc, library } = useContext(Web3Context); const { env } = useContext(EnvContext); const [isLoading, setLoading] = useState(false); const [spaceId, setSpaceId] = useState(''); - const [memberAddress, setMemberAddress] = useState(''); + const [listenerAddress, setListenerAddress] = useState(''); const [sendResponse, setSendResponse] = useState(''); const [account, setAccount] = useState(acc); @@ -27,17 +27,17 @@ const RemoveMembersFromSpaceTest = () => { setAccount((e.target as HTMLInputElement).value); }; - const updateMemberId = (e: React.SyntheticEvent) => { - setMemberAddress((e.target as HTMLInputElement).value); + const updateListenerId = (e: React.SyntheticEvent) => { + setListenerAddress((e.target as HTMLInputElement).value); }; - const removeMembersFromSpaceTest = async () => { + const removeListenersFromSpaceTest = async () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.space.removeMembersFromSpace({ + const response = await PushAPI.space.removeListeners({ spaceId: spaceId, - members: memberAddress ? memberAddress.split(',') : [], + listeners: listenerAddress ? listenerAddress.split(',') : [], env, account: account, signer: librarySigner, @@ -56,13 +56,13 @@ const RemoveMembersFromSpaceTest = () => { return (
-

Remove Member from Space Test page

+

Remove Listener from Space Test page

- Remove Member from Space + Remove Listeners from Space @@ -74,11 +74,11 @@ const RemoveMembersFromSpaceTest = () => { /> - + @@ -105,4 +105,4 @@ const RemoveMembersFromSpaceTest = () => { ); }; -export default RemoveMembersFromSpaceTest; +export default RemoveListenersFromSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx similarity index 76% rename from packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx rename to packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx index b1cb37654..117f13135 100644 --- a/packages/demoreact/src/app/SpaceTest/RemoveAdminsFromSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx @@ -10,12 +10,12 @@ import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; import SpaceTest from './SpaceTest'; -const RemoveAdminsFromSpaceTest = () => { +const RemoveSpeakersFromSpaceTest = () => { const { account: acc, library } = useContext(Web3Context); const { env } = useContext(EnvContext); const [isLoading, setLoading] = useState(false); const [spaceId, setSpaceId] = useState(''); - const [memberAddress, setMemberAddress] = useState(''); + const [speakerAddress, setSpeakerAddress] = useState(''); const [sendResponse, setSendResponse] = useState(''); const [account, setAccount] = useState(acc); @@ -23,21 +23,21 @@ const RemoveAdminsFromSpaceTest = () => { setSpaceId((e.target as HTMLInputElement).value); }; - const updateMemberId = (e: React.SyntheticEvent) => { - setMemberAddress((e.target as HTMLInputElement).value); + const updateSpeakerId = (e: React.SyntheticEvent) => { + setSpeakerAddress((e.target as HTMLInputElement).value); }; const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; - const removeAdminsFromSpaceTest = async () => { + const removeSpeakersFromSpaceTest = async () => { try { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.space.removeAdminsFromSpace({ + const response = await PushAPI.space.removeSpeakers({ spaceId: spaceId, - admins: memberAddress ? memberAddress.split(',') : [], + speakers: speakerAddress ? speakerAddress.split(',') : [], env, account: account, signer: librarySigner, @@ -53,13 +53,13 @@ const RemoveAdminsFromSpaceTest = () => { return (
-

Remove Admins from Group Test page

+

Remove Speakers from Group Test page

- Remove Admins from Space + Remove Speakers from Space @@ -71,11 +71,11 @@ const RemoveAdminsFromSpaceTest = () => { /> - + @@ -102,4 +102,4 @@ const RemoveAdminsFromSpaceTest = () => { ); }; -export default RemoveAdminsFromSpaceTest; +export default RemoveSpeakersFromSpaceTest; diff --git a/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx index c85cac5ea..6c35791ab 100644 --- a/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/SpaceTest.tsx @@ -49,17 +49,17 @@ const SpaceTest = () => { SPACE.STOP - - SPACE.ADDMEMBERSTOSPACE + + SPACE.ADDLISTENERSTOSPACE - - SPACE.ADDADMINSTOSPACE + + SPACE.ADDSPEAKERSTOSPACE - - SPACE.REMOVEMEMBERSFROMSPACE + + SPACE.REMOVELISTENERSFROMSPACE - - SPACE.REMOVEADMINSFROMSPACE + + SPACE.REMOVESPEAKERSFROMSPACE SPACE.GETSPACES diff --git a/packages/demoreact/src/app/app.tsx b/packages/demoreact/src/app/app.tsx index d2a769f53..fb971e471 100644 --- a/packages/demoreact/src/app/app.tsx +++ b/packages/demoreact/src/app/app.tsx @@ -46,10 +46,10 @@ import StartSpaceTest from './SpaceTest/StartSpaceTest'; import StopSpaceTest from './SpaceTest/StopSpaceTest'; import RemoveMembersFromGroupTest from './ChatTest/RemoveMembersFromGroupTest'; import RemoveAdminsFromGroupTest from './ChatTest/RemoveAdminsFromGroupTest'; -import AddAdminsToSpaceTest from './SpaceTest/AddAdminsToSpaceTest'; -import AddMembersToSpaceTest from './SpaceTest/AddMembersToSpaceTest'; -import RemoveMembersFromSpaceTest from './SpaceTest/RemoveMembersFromSpaceTest'; -import RemoveAdminsFromSpaceTest from './SpaceTest/RemoveAdminsFromSpaceTest'; +import AddSpeakersToSpaceTest from './SpaceTest/AddSpeakersToSpaceTest'; +import AddListenersToSpaceTest from './SpaceTest/AddListenersToSpaceTest'; +import RemoveListenersFromSpaceTest from './SpaceTest/RemoveListenersFromSpaceTest'; +import RemoveSpeakersFromSpaceTest from './SpaceTest/RemoveSpeakersFromSpaceTest'; import GetSpacesTest from './SpaceTest/GetSpacesTest'; import GetSpacesRequestsTest from './SpaceTest/GetSpacesRequestsTest'; import GetSpacesTrendingTest from './SpaceTest/GetSpacesTrendingTest'; @@ -284,10 +284,10 @@ export function App() { } /> } /> } /> - } /> - } /> - } /> - } /> + } /> + } /> + } /> + } /> } /> } /> } /> diff --git a/packages/restapi/src/lib/chat/addAdminsToGroup.ts b/packages/restapi/src/lib/chat/addAdmins.ts similarity index 93% rename from packages/restapi/src/lib/chat/addAdminsToGroup.ts rename to packages/restapi/src/lib/chat/addAdmins.ts index f40cd0581..f45eef5b9 100644 --- a/packages/restapi/src/lib/chat/addAdminsToGroup.ts +++ b/packages/restapi/src/lib/chat/addAdmins.ts @@ -19,7 +19,7 @@ export interface AddAdminsToGroupType extends EnvOptionsType { pgpPrivateKey?: string | null; } -export const addAdminsToGroup = async ( +export const addAdmins = async ( options: AddAdminsToGroupType ): Promise => { const { @@ -93,11 +93,11 @@ export const addAdminsToGroup = async ( }); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${addAdminsToGroup.name} -: `, + `[Push SDK] - API - Error - API ${addAdmins.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${addAdminsToGroup.name} -: ${err}` + `[Push SDK] - API - Error - API ${addAdmins.name} -: ${err}` ); } }; diff --git a/packages/restapi/src/lib/chat/addMembersToGroup.ts b/packages/restapi/src/lib/chat/addMembers.ts similarity index 92% rename from packages/restapi/src/lib/chat/addMembersToGroup.ts rename to packages/restapi/src/lib/chat/addMembers.ts index d50c7438f..cbec53f3b 100644 --- a/packages/restapi/src/lib/chat/addMembersToGroup.ts +++ b/packages/restapi/src/lib/chat/addMembers.ts @@ -23,7 +23,7 @@ export interface AddMembersToGroupType extends EnvOptionsType { /** * Update Group information */ -export const addMembersToGroup = async ( +export const addMembers = async ( options: AddMembersToGroupType ): Promise => { const { @@ -91,11 +91,11 @@ export const addMembersToGroup = async ( }); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${addMembersToGroup.name} -: `, + `[Push SDK] - API - Error - API ${addMembers.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${addMembersToGroup.name} -: ${err}` + `[Push SDK] - API - Error - API ${addMembers.name} -: ${err}` ); } }; diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index 23777288d..c7c7e8340 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -161,8 +161,18 @@ export const createGroupPayload = ( export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { const spaceDto: SpaceDTO = { - members: groupDto.members, - pendingMembers: groupDto.pendingMembers, + members: groupDto.members.map((member) => ({ + wallet: member.wallet, + publicKey: member.publicKey, + isSpeaker: member.isAdmin, + image: member.image, + })), + pendingMembers: groupDto.pendingMembers.map((pendingMember) => ({ + wallet: pendingMember.wallet, + publicKey: pendingMember.publicKey, + isSpeaker: pendingMember.isAdmin, + image: pendingMember.image, + })), contractAddressERC20: groupDto.contractAddressERC20, numberOfERC20: groupDto.numberOfERC20, contractAddressNFT: groupDto.contractAddressNFT, diff --git a/packages/restapi/src/lib/chat/index.ts b/packages/restapi/src/lib/chat/index.ts index e67bb2d67..0a5c3fdbd 100644 --- a/packages/restapi/src/lib/chat/index.ts +++ b/packages/restapi/src/lib/chat/index.ts @@ -14,7 +14,7 @@ export * from './createGroup'; export * from './updateGroup'; export * from './getGroup'; export * from './getGroupByName'; -export * from './addMembersToGroup'; -export * from './addAdminsToGroup'; -export * from './removeMembersFromGroup'; -export * from './removeAdminsFromGroup'; +export * from './addMembers'; +export * from './addAdmins'; +export * from './removeMembers'; +export * from './removeAdmins'; diff --git a/packages/restapi/src/lib/chat/removeAdminsFromGroup.ts b/packages/restapi/src/lib/chat/removeAdmins.ts similarity index 92% rename from packages/restapi/src/lib/chat/removeAdminsFromGroup.ts rename to packages/restapi/src/lib/chat/removeAdmins.ts index 250e28ad1..c0d49936b 100644 --- a/packages/restapi/src/lib/chat/removeAdminsFromGroup.ts +++ b/packages/restapi/src/lib/chat/removeAdmins.ts @@ -23,7 +23,7 @@ export interface RemoveAdminsFromGroupType extends EnvOptionsType { /** * Update Group information */ -export const removeAdminsFromGroup = async ( +export const removeAdmins = async ( options: RemoveAdminsFromGroupType ): Promise => { const { @@ -101,11 +101,11 @@ export const removeAdminsFromGroup = async ( }); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${removeAdminsFromGroup.name} -: `, + `[Push SDK] - API - Error - API ${removeAdmins.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${removeAdminsFromGroup.name} -: ${err}` + `[Push SDK] - API - Error - API ${removeAdmins.name} -: ${err}` ); } }; diff --git a/packages/restapi/src/lib/chat/removeMembersFromGroup.ts b/packages/restapi/src/lib/chat/removeMembers.ts similarity index 91% rename from packages/restapi/src/lib/chat/removeMembersFromGroup.ts rename to packages/restapi/src/lib/chat/removeMembers.ts index 7a0b5a592..4cc513df8 100644 --- a/packages/restapi/src/lib/chat/removeMembersFromGroup.ts +++ b/packages/restapi/src/lib/chat/removeMembers.ts @@ -19,7 +19,7 @@ export interface RemoveMembersFromGroupType extends EnvOptionsType { pgpPrivateKey?: string | null; } -export const removeMembersFromGroup = async ( +export const removeMembers = async ( options: RemoveMembersFromGroupType ): Promise => { const { @@ -87,11 +87,11 @@ export const removeMembersFromGroup = async ( }); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${removeMembersFromGroup.name} -: `, + `[Push SDK] - API - Error - API ${removeMembers.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${removeMembersFromGroup.name} -: ${err}` + `[Push SDK] - API - Error - API ${removeMembers.name} -: ${err}` ); } }; diff --git a/packages/restapi/src/lib/space/addMembersToSpace.ts b/packages/restapi/src/lib/space/addListeners.ts similarity index 57% rename from packages/restapi/src/lib/space/addMembersToSpace.ts rename to packages/restapi/src/lib/space/addListeners.ts index 0f4c7a6f7..995959456 100644 --- a/packages/restapi/src/lib/space/addMembersToSpace.ts +++ b/packages/restapi/src/lib/space/addListeners.ts @@ -2,34 +2,34 @@ import Constants from '../constants'; import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; import { groupDtoToSpaceDto -} from './../chat/helpers'; +} from '../chat/helpers'; -import { addMembersToGroup } from '../chat/addMembersToGroup'; +import { addMembers } from '../chat/addMembers'; -export interface AddMembersToSpaceType extends EnvOptionsType { +export interface AddListenersToSpaceType extends EnvOptionsType { spaceId: string; - members: Array; + listeners: Array; account?: string; signer?: SignerType; pgpPrivateKey?: string; } -export const addMembersToSpace = async ( - options: AddMembersToSpaceType +export const addListeners = async ( + options: AddListenersToSpaceType ): Promise => { const { spaceId, - members, + listeners, account = null, signer = null, env = Constants.ENV.PROD, pgpPrivateKey = null, } = options || {}; try { - const group = await addMembersToGroup({ + const group = await addMembers({ chatId: spaceId, - members: members, + members: listeners, account: account, signer: signer, env: env, @@ -39,11 +39,11 @@ export const addMembersToSpace = async ( return groupDtoToSpaceDto(group); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${addMembersToSpace.name} -: `, + `[Push SDK] - API - Error - API ${addListeners.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${addMembersToSpace.name} -: ${err}` + `[Push SDK] - API - Error - API ${addListeners.name} -: ${err}` ); } }; diff --git a/packages/restapi/src/lib/space/addAdminsToSpace.ts b/packages/restapi/src/lib/space/addSpeakers.ts similarity index 58% rename from packages/restapi/src/lib/space/addAdminsToSpace.ts rename to packages/restapi/src/lib/space/addSpeakers.ts index d2c5f6a8e..e7311506d 100644 --- a/packages/restapi/src/lib/space/addAdminsToSpace.ts +++ b/packages/restapi/src/lib/space/addSpeakers.ts @@ -1,29 +1,29 @@ import Constants from '../constants'; import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; -import { groupDtoToSpaceDto } from './../chat/helpers'; -import { addAdminsToGroup } from '../chat/addAdminsToGroup'; +import { groupDtoToSpaceDto } from '../chat/helpers'; +import { addAdmins } from '../chat/addAdmins'; -export interface AddAdminsToSpaceType extends EnvOptionsType { +export interface AddSpeakersToSpaceType extends EnvOptionsType { spaceId: string; - admins: Array; + speakers: Array; account?: string; signer?: SignerType; pgpPrivateKey?: string; } -export const addAdminsToSpace = async (options: AddAdminsToSpaceType): Promise => { +export const addSpeakers = async (options: AddSpeakersToSpaceType): Promise => { const { spaceId, - admins, + speakers, account = null, signer = null, env = options?.env ?? Constants.ENV.PROD, pgpPrivateKey = options?.pgpPrivateKey ?? null, } = options; - const group = await addAdminsToGroup({ + const group = await addAdmins({ chatId: spaceId, - admins: admins, + admins: speakers, account: account, signer: signer, env: env, diff --git a/packages/restapi/src/lib/space/index.ts b/packages/restapi/src/lib/space/index.ts index 508516020..52feea71a 100644 --- a/packages/restapi/src/lib/space/index.ts +++ b/packages/restapi/src/lib/space/index.ts @@ -5,10 +5,10 @@ export * from './get'; export * from './approve'; export * from './start'; export * from './stop'; -export * from './addAdminsToSpace'; -export * from './addMembersToSpace'; -export * from './removeAdminsFromSpace'; -export * from './removeMembersFromSpace'; +export * from './addSpeakers'; +export * from './addListeners'; +export * from './removeSpeakers'; +export * from './removeListeners'; export * from './requests'; export * from './spaces'; export * from './trending'; diff --git a/packages/restapi/src/lib/space/removeMembersFromSpace.ts b/packages/restapi/src/lib/space/removeListeners.ts similarity index 56% rename from packages/restapi/src/lib/space/removeMembersFromSpace.ts rename to packages/restapi/src/lib/space/removeListeners.ts index b2aa0bdfd..30ab12f5e 100644 --- a/packages/restapi/src/lib/space/removeMembersFromSpace.ts +++ b/packages/restapi/src/lib/space/removeListeners.ts @@ -2,34 +2,34 @@ import Constants from '../constants'; import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; import { groupDtoToSpaceDto -} from './../chat/helpers'; +} from '../chat/helpers'; import { - removeMembersFromGroup -} from '../chat/removeMembersFromGroup'; + removeMembers +} from '../chat/removeMembers'; -export interface RemoveMembersFromSpaceType extends EnvOptionsType { +export interface RemoveListenersFromSpaceType extends EnvOptionsType { spaceId: string; - members: Array; + listeners: Array; account?: string; signer?: SignerType; pgpPrivateKey?: string; } -export const removeMembersFromSpace = async ( - options: RemoveMembersFromSpaceType +export const removeListeners = async ( + options: RemoveListenersFromSpaceType ): Promise => { const { spaceId, - members, + listeners, account = null, signer = null, env = Constants.ENV.PROD, pgpPrivateKey = null, } = options || {}; try { - const group = await removeMembersFromGroup({ + const group = await removeMembers({ chatId: spaceId, - members: members, + members: listeners, account: account, signer: signer, env: env, @@ -39,11 +39,11 @@ export const removeMembersFromSpace = async ( return groupDtoToSpaceDto(group); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${removeMembersFromSpace.name} -: `, + `[Push SDK] - API - Error - API ${removeListeners.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${removeMembersFromSpace.name} -: ${err}` + `[Push SDK] - API - Error - API ${removeListeners.name} -: ${err}` ); } }; diff --git a/packages/restapi/src/lib/space/removeAdminsFromSpace.ts b/packages/restapi/src/lib/space/removeSpeakers.ts similarity index 57% rename from packages/restapi/src/lib/space/removeAdminsFromSpace.ts rename to packages/restapi/src/lib/space/removeSpeakers.ts index a68a9e765..79cd12e58 100644 --- a/packages/restapi/src/lib/space/removeAdminsFromSpace.ts +++ b/packages/restapi/src/lib/space/removeSpeakers.ts @@ -6,33 +6,33 @@ import { } from '../types'; import { groupDtoToSpaceDto -} from './../chat/helpers'; +} from '../chat/helpers'; import { - removeAdminsFromGroup -} from '../chat/removeAdminsFromGroup'; -export interface RemoveAdminsFromSpaceType extends EnvOptionsType { + removeAdmins +} from '../chat/removeAdmins'; +export interface RemoveSpeakersFromSpaceType extends EnvOptionsType { spaceId: string; - admins: Array < string > ; + speakers: Array < string > ; account ? : string; signer ? : SignerType; pgpPrivateKey ? : string; } -export const removeAdminsFromSpace = async ( - options: RemoveAdminsFromSpaceType +export const removeSpeakers = async ( + options: RemoveSpeakersFromSpaceType ): Promise < SpaceDTO > => { const { spaceId, - admins, + speakers, account = null, signer = null, env = Constants.ENV.PROD, pgpPrivateKey = null, } = options || {}; try { - const group = await removeAdminsFromGroup({ + const group = await removeAdmins({ chatId: spaceId, - admins: admins, + admins: speakers, account: account, signer: signer, env: env, @@ -42,11 +42,11 @@ export const removeAdminsFromSpace = async ( return groupDtoToSpaceDto(group); } catch (err) { console.error( - `[Push SDK] - API - Error - API ${removeAdminsFromSpace.name} -: `, + `[Push SDK] - API - Error - API ${removeSpeakers.name} -: `, err ); throw Error( - `[Push SDK] - API - Error - API ${removeAdminsFromSpace.name} -: ${err}` + `[Push SDK] - API - Error - API ${removeSpeakers.name} -: ${err}` ); } }; \ No newline at end of file diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 7043a15f0..703d55ac0 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -300,13 +300,13 @@ export interface SpaceDTO { members: { wallet: string; publicKey: string; - isAdmin: boolean; + isSpeaker: boolean; image: string; }[]; pendingMembers: { wallet: string; publicKey: string; - isAdmin: boolean; + isSpeaker: boolean; image: string; }[]; contractAddressERC20: string | null; From f905ad40bd7ce1070437341182c88f6caf0e5ee1 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 3 Jul 2023 21:15:23 +0530 Subject: [PATCH 131/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.19?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 513ad72fc..1df4e8723 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.19](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.18...restapi-0.0.1-alpha.19) (2023-07-03) + + +### Bug Fixes + +* added silent notifications ([#467](https://github.com/ethereum-push-notification-service/push-sdk/issues/467)) ([88bafe4](https://github.com/ethereum-push-notification-service/push-sdk/commit/88bafe49d489cfe399efa7166407a50574995b16)) +* Merge branch 'alpha' into alpha-deployment ([a15e368](https://github.com/ethereum-push-notification-service/push-sdk/commit/a15e368241215e2e2219792afd718567d621bf2a)) +* merge main ([6998d35](https://github.com/ethereum-push-notification-service/push-sdk/commit/6998d35aa181f17a5ad8d9501943a6a867814650)) +* rename based on new convention ([0e34479](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e34479b1581abd59e0f853d6547e23a0afb5e28)) +* **video:** add error handlers and turn server config ([#466](https://github.com/ethereum-push-notification-service/push-sdk/issues/466)) ([cda9a28](https://github.com/ethereum-push-notification-service/push-sdk/commit/cda9a28bbb99bf8bd40bcd13f3c486cbf1ebe5a2)) + + + ## [0.0.1-alpha.18](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.17...restapi-0.0.1-alpha.18) (2023-06-20) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index e42524d35..b69ceb00d 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.18", + "version": "0.0.1-alpha.19", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From de2b1208724c186c7a30e5be9545d564fbb97703 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 3 Jul 2023 21:19:12 +0530 Subject: [PATCH 132/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.19?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 1df4e8723..6d921c8b0 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -15,6 +15,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/s +## [0.0.1-alpha.19](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.18...restapi-0.0.1-alpha.19) (2023-07-03) + + +### Bug Fixes + +* added silent notifications ([#467](https://github.com/ethereum-push-notification-service/push-sdk/issues/467)) ([88bafe4](https://github.com/ethereum-push-notification-service/push-sdk/commit/88bafe49d489cfe399efa7166407a50574995b16)) +* Merge branch 'alpha' into alpha-deployment ([a15e368](https://github.com/ethereum-push-notification-service/push-sdk/commit/a15e368241215e2e2219792afd718567d621bf2a)) +* merge main ([6998d35](https://github.com/ethereum-push-notification-service/push-sdk/commit/6998d35aa181f17a5ad8d9501943a6a867814650)) +* rename based on new convention ([0e34479](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e34479b1581abd59e0f853d6547e23a0afb5e28)) +* **video:** add error handlers and turn server config ([#466](https://github.com/ethereum-push-notification-service/push-sdk/issues/466)) ([cda9a28](https://github.com/ethereum-push-notification-service/push-sdk/commit/cda9a28bbb99bf8bd40bcd13f3c486cbf1ebe5a2)) + + + ## [0.0.1-alpha.18](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.17...restapi-0.0.1-alpha.18) (2023-06-20) From 8f80f8dd3d438850299049dfb001db6f627e83a5 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 3 Jul 2023 21:27:09 +0530 Subject: [PATCH 133/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.19?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/lib/chat/helpers/payloadHelper.ts | 44 +++++++++++++++++++ packages/restapi/src/lib/space/start.ts | 8 ++-- packages/restapi/src/lib/space/stop.ts | 8 ++-- 3 files changed, 52 insertions(+), 8 deletions(-) diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index c7c7e8340..53882d2ce 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -246,6 +246,32 @@ export const getAdminsList = ( return adminList; }; +export const getSpaceAdminsList = ( + members: { + wallet: string; + publicKey: string; + isSpeaker: boolean; + image: string; + }[], + pendingMembers: { + wallet: string; + publicKey: string; + isSpeaker: boolean; + image: string; + }[] +): Array => { + const adminsFromMembers = members + ? convertToWalletAddressList(members.filter((admin) => admin.isSpeaker)) + : []; + + const adminsFromPendingMembers = pendingMembers + ? convertToWalletAddressList(pendingMembers.filter((admin) => admin.isSpeaker)) + : []; + + const adminList = [...adminsFromMembers, ...adminsFromPendingMembers]; + return adminList; +}; + export const convertToWalletAddressList = (memberList: { wallet: string }[]): string[] => { return memberList ? memberList.map((member) => member.wallet) : []; }; @@ -266,4 +292,22 @@ export const getMembersList = ( ): Array => { const allMembers = [...(members || []), ...(pendingMembers || [])]; return convertToWalletAddressList(allMembers); +}; + +export const getSpacesMembersList = ( + members: { + wallet: string; + publicKey: string; + isSpeaker: boolean; + image: string; + }[], + pendingMembers: { + wallet: string; + publicKey: string; + isSpeaker: boolean; + image: string; + }[] +): Array => { + const allMembers = [...(members || []), ...(pendingMembers || [])]; + return convertToWalletAddressList(allMembers); }; \ No newline at end of file diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts index f59a385bd..d98e4889e 100644 --- a/packages/restapi/src/lib/space/start.ts +++ b/packages/restapi/src/lib/space/start.ts @@ -7,8 +7,8 @@ import { } from '../types'; import { groupDtoToSpaceDto, - getMembersList, - getAdminsList + getSpacesMembersList, + getSpaceAdminsList } from './../chat/helpers'; import { get @@ -47,10 +47,10 @@ export const start = async ( throw new Error("Unable to start the space as it is not in the pending state"); } - const convertedMembers = getMembersList( + const convertedMembers = getSpacesMembersList( space.members, space.pendingMembers ); - const convertedAdmins = getAdminsList( + const convertedAdmins = getSpaceAdminsList( space.members, space.pendingMembers ); diff --git a/packages/restapi/src/lib/space/stop.ts b/packages/restapi/src/lib/space/stop.ts index 342a4a3d9..ea7b8e78d 100644 --- a/packages/restapi/src/lib/space/stop.ts +++ b/packages/restapi/src/lib/space/stop.ts @@ -7,8 +7,8 @@ import { } from '../types'; import { groupDtoToSpaceDto, - getMembersList, - getAdminsList + getSpacesMembersList, + getSpaceAdminsList } from '../chat/helpers'; import { updateGroup @@ -47,10 +47,10 @@ export const stop = async ( throw new Error("Space already ended"); } - const convertedMembers = getMembersList( + const convertedMembers = getSpacesMembersList( space.members, space.pendingMembers ); - const convertedAdmins = getAdminsList( + const convertedAdmins = getSpaceAdminsList( space.members, space.pendingMembers ); From 25f2725efb0e1017ee2a0460259b27f252471014 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 3 Jul 2023 21:30:25 +0530 Subject: [PATCH 134/298] fix: new commit --- packages/restapi/src/lib/space/stop.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/restapi/src/lib/space/stop.ts b/packages/restapi/src/lib/space/stop.ts index ea7b8e78d..828c34f09 100644 --- a/packages/restapi/src/lib/space/stop.ts +++ b/packages/restapi/src/lib/space/stop.ts @@ -80,4 +80,4 @@ export const stop = async ( `[Push SDK] - API - Error - API ${stop.name} -: ${err}` ); } -}; \ No newline at end of file +}; From e66ac5ca935b8139fa47a02b8f0474f43539d3ba Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 3 Jul 2023 21:34:47 +0530 Subject: [PATCH 135/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 6d921c8b0..ab3fe4cdb 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.20](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.19...restapi-0.0.1-alpha.20) (2023-07-03) + + +### Bug Fixes + +* new commit ([25f2725](https://github.com/ethereum-push-notification-service/push-sdk/commit/25f2725efb0e1017ee2a0460259b27f252471014)) + + + ## [0.0.1-alpha.19](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.18...restapi-0.0.1-alpha.19) (2023-07-03) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index b69ceb00d..5b0c37ec1 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.19", + "version": "0.0.1-alpha.20", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 6db7fc09b680060f022040feb2a22aeed9c652d0 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 6 Jul 2023 14:11:17 +0530 Subject: [PATCH 136/298] fix: spaces naming --- packages/restapi/src/lib/space/trending.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/restapi/src/lib/space/trending.ts b/packages/restapi/src/lib/space/trending.ts index 94b079129..73c6d8eda 100644 --- a/packages/restapi/src/lib/space/trending.ts +++ b/packages/restapi/src/lib/space/trending.ts @@ -33,9 +33,9 @@ export const trending = async ( try { const response = await axios.get(apiEndpoint); - const requests: SpaceIFeeds[] = response.data.requests; + const chats: SpaceIFeeds[] = response.data.chats; const Feeds: SpaceIFeeds[] = await getTrendingSpaceInboxLists({ - lists: requests, + lists: chats, env, }); From 81d2cc9830b507a1ac7d20b158f79c0598533191 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 7 Jul 2023 15:51:09 +0530 Subject: [PATCH 137/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.21?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index ab3fe4cdb..6f5959ece 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.21](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.20...restapi-0.0.1-alpha.21) (2023-07-07) + + +### Bug Fixes + +* added messageObj and Meta Messages support ([#485](https://github.com/ethereum-push-notification-service/push-sdk/issues/485)) ([2769aa6](https://github.com/ethereum-push-notification-service/push-sdk/commit/2769aa6bb0da6e7a4d28fca6b481db6cc2958d47)) +* Merge branch 'alpha' into alpha-deployment ([c05d024](https://github.com/ethereum-push-notification-service/push-sdk/commit/c05d024415bb1cb9e1fe59714d7db5516d161c06)) +* merged main ([46cf04e](https://github.com/ethereum-push-notification-service/push-sdk/commit/46cf04e75c314065c77a5a77d9351d9ccc7e0a58)) +* spaces naming ([6db7fc0](https://github.com/ethereum-push-notification-service/push-sdk/commit/6db7fc09b680060f022040feb2a22aeed9c652d0)) + + + ## [0.0.1-alpha.20](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.19...restapi-0.0.1-alpha.20) (2023-07-03) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 5b0c37ec1..4c7a3a9c4 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.20", + "version": "0.0.1-alpha.21", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 61d15a7350de6309ba8265885bde75dfa077d7ff Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 8 Jul 2023 00:17:10 +0530 Subject: [PATCH 138/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.22?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 6f5959ece..0115cfb1a 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.22](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.21...restapi-0.0.1-alpha.22) (2023-07-07) + + +### Bug Fixes + +* add tc fix null meta ([#502](https://github.com/ethereum-push-notification-service/push-sdk/issues/502)) ([6e48314](https://github.com/ethereum-push-notification-service/push-sdk/commit/6e48314c0e58989849f66a4ffe387d906623ef69)) +* Merge branch 'alpha' into alpha-deployment ([5c84e2f](https://github.com/ethereum-push-notification-service/push-sdk/commit/5c84e2f07667fe4e9d94561544807b11c103ac49)) +* merged maain ([942cc65](https://github.com/ethereum-push-notification-service/push-sdk/commit/942cc65a60aa043054cebb143990711fb6e2efdb)) + + + ## [0.0.1-alpha.21](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.20...restapi-0.0.1-alpha.21) (2023-07-07) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 4c7a3a9c4..08e3fc3da 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.21", + "version": "0.0.1-alpha.22", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 6aad1b0f84a7c443ce05eb414ee195d7ef9cba83 Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Mon, 10 Jul 2023 11:42:58 +0530 Subject: [PATCH 139/298] Add alpha version of Spaces SDK (#513) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * refactor: added initial SpacesUI class architecture * Update packages/uiweb/src/lib/components/space/SpacesUI.tsx Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> * Update packages/uiweb/src/lib/components/space/SpacesUI.tsx Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> * fix: refine code structure * refactor: change structure and added a test sample * feat: added themeprovider for spaces ui components (#436) * feat: feat: add themeprovider for spaces * fix: resolved conflicts * refactor: cleaned up provider * refactor: resolved comments * feat: added colors and themeing in demoreactapp * refactor: cleaned code * refactor: resolved comments * refactor: added a basic style structure for ease of use (#453) * feat: SpaceBanner Component (#438) * feat: SpaceBanner * refactor: removed-optionals * feat: space-banner functionality * fix: reverted app.tsx * fix: reverted app.tsx * fix: removed test svg file * refactor: change structure and added a test sample * feat: space-banner functionality * refactor: api-implementation * fix: removed-svg * refactor: mobile version * Revert "fix: removed test svg file" This reverts commit 7af756badaeb8435db60712c42ca57ef9ce9f74c. * Revert "refactor: change structure and added a test sample" This reverts commit b1e8745948a9ce5e0485ad51a8cffd07010a5186. * fix: revert * refactor: lastest-pull * feat: added-spaceBanner-test * refactor: cache-to-context * refactor: custom hook added for data * refactor: spaceDTO * fix: SpaceDTO implementation * refactor: participant-container * refactor: cleanups * fix: ui-fixes * fix: EOF newlines * fix: overflow-fixed * refactor: tweaked context structure a bit --------- Co-authored-by: Samarendra Gouda Co-authored-by: Nilesh Gupta * refactor: updated theme object along with light and dark theme * feat: Create Space Component (#454) * refactor: resolved merge conflicts * feat: added modals and modal behaviour logic * feat: modal inputs * feat: change modal logic + integr8 API * feat: added CSS for modals and inputs * fix: resolved PR comments * refactor: improve css * refactor: rft create modal * feat: added search input component * Refactor/space widget component (#458) * refactor: added basic design * refactor: added full widget with style * refactor: reduced fixed height of scheduled widget content * refactor: changes requested * refactor: resolved review comments * feat: add spaces info component (#474) * Feat/added members modal (#477) * refactor: added modal * refactor: added members modal * refactor: review comments * refactor: resolve review comments * fix: review comments * 424 spaces functions webrtc logic (#482) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class --------- Co-authored-by: Shoaib Mohammed Co-authored-by: Madhur Gupta * refactor: spaces UI Components refactor (#478) > replaced hardcoded styles with context theme >added smoother animations on collapsoble components >added profile cards to invite modal * refactor: added spaceUI class variables into context as well (#488) * refactor: added spaceUI class variables into context as well * refactor: resolve review comments * refactor: added a clickHandler in spaceBanner component for extra flexibility (#489) * fix(spaces): fix console errs and refactor create, update methods (#492) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class * fix: Merge branch 'alpha' into 424-spaces-functions-webrtc-logic * fix(spaces): fix console errors and move out create, update functions from Space class --------- Co-authored-by: Shoaib Mohammed * refactor: modified init class method * refactor/added-space-feed-component(#481) * feat: space-feed * refactor: space-feed * Deployment (#440) * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.1 * ci(restapi): 🎉 cut release to restapi-v1.0.1 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * fix: success progressHook * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.1.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * fix(component): dummy * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.2.1 * fix: local for local development (#295) Co-Authored-By: aman035 * fix: version update * ci(restapi): 🎉 cut release to restapi-v1.2.2 * ci(restapi): 🎉 cut release to restapi-v1.2.3 * ci(restapi): 🎉 cut release to restapi-v1.2.4 * ci(restapi): 🎉 cut release to restapi-v1.2.5 * ci(restapi): 🎉 cut release to restapi-v1.2.6 * ci(restapi): 🎉 cut release to restapi-v1.2.7 * ci(socket): 🎉 cut release to socket-v0.5.0 * fix: test commit * ci(restapi): 🎉 cut release to restapi-v1.2.8 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.1 * fix: added ci-version-beta * fix: added ci-version-beta * ci(restapi): 🎉 cut beta release to restapi-v1.2.9 * fix: added releaseType * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.1 * ci(restapi): 🎉 cut release to restapi-v1.2.11 * fix: linkedListHash test cases removed & CI version corrected * fix: update name to beta * ci(restapi): 🎉 cut release to restapi-v1.2.12 * ci(restapi): 🎉 cut release to restapi-v1.2.12 * ci(restapi): 🎉 cut release to restapi-v1.2.13 * ci(restapi): 🎉 cut release to restapi-v1.2.14 * ci(restapi): 🎉 cut release to restapi-v1.2.15 * fix: update package json * fix: updated socket version * ci(uiweb): 🎉 cut release to uiweb-v1.0.2 * fix: socket lib update * ci(uiweb): 🎉 cut release to uiweb-v1.0.2 * ci(restapi): 🎉 cut release to restapi-v1.2.16 * ci(restapi): 🎉 cut release to restapi-v1.3.0 * ci(restapi): 🎉 cut release to restapi-v1.3.1 * ci(socket): 🎉 cut release to socket-v0.5.1 * ci(restapi): 🎉 cut release to restapi-v1.3.2 * ci(restapi): 🎉 cut release to restapi-v1.3.3 * ci(restapi): 🎉 cut release to restapi-v1.3.4 --------- Co-authored-by: aman035 * feat: space-feed * refactor: space-feed * fix: api-call-custom-hooks * fix: api-call * refactor: enums/changes * fix: scrollable * fix: scrolling-issue * feat: filter-changes * fix: added types * fix: loader-issue * fix: tab-button-color * feat: new-filter and prop * fix: ended-logic && participant-number logic * refactor: add onBannerClick * fix: conflicts * revert: messed-up spaceBanner * fix: onClick issue * fix: onClick and cleanups * refactor: new pagination interface * fix: scroll-logic * fix: scroll-final * fix: .. * fix: removed any * fix: onClick-issue * fix: loading-context-to-state * refactor: add-NoSpaceIcons * refactor: new-ui-layout * refactor: new-ui-layout --------- Co-authored-by: Mohammed S Co-authored-by: aman035 Co-authored-by: Nilesh Gupta * refactor: added structure for spaces invites modal component * refactor: invite-component * fix: minor-bug * feat: Create Space API Integration (#494) * feat: create spaces integration * feat: added datetime picker * feat: completed create space API integration * feat: changed flow and time component * feat(spaces): initiate livepeer playback in start method (#499) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class * fix: Merge branch 'alpha' into 424-spaces-functions-webrtc-logic * fix(spaces): fix console errors and move out create, update functions from Space class * feat(spaces): initiate livepeer playback in start method * feat(spaces): store livepeer playback id in space description --------- Co-authored-by: Shoaib Mohammed * Add initialize method (#505) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class * fix: Merge branch 'alpha' into 424-spaces-functions-webrtc-logic * fix(spaces): fix console errors and move out create, update functions from Space class * feat(spaces): initiate livepeer playback in start method * feat(spaces): store livepeer playback id in space description * feat(spaces): add intitialize method --------- Co-authored-by: Shoaib Mohammed * refactor: resolved css in space banner * refactor: added a skeleton loading effect on space Banner component * feat: add invite functionality to create space (#506) * feat: added invite functionality * fix: add logic for time selector * fix: css fixes * refactor: info-on-widget (#504) * refactor: info-on-widget * refactor: add Space class to context * fix: padding, added new mic icons * fix: added-ref to context * feat: start added * fix: remove optional spaceId * fix: inf-bug * fix: effectAdded * fix(spaces): add is supported check in start * refactor: added-join-functionalities (#507) * refactor: added-join-functionalities * fix: screens * fix(spaces): fix livepeer stream creation in start --------- Co-authored-by: Madhur Gupta * Fix join and pgpPrivateKey in demoreact (#508) * refactor: info-on-widget * refactor: add Space class to context * fix: padding, added new mic icons * fix: added-ref to context * feat: start added * fix: remove optional spaceId * fix: inf-bug * fix: effectAdded * fix(spaces): add is supported check in start * refactor: added-join-functionalities * fix: screens * refactor: added-join-functionalities (#507) * refactor: added-join-functionalities * fix: screens * fix(spaces): fix livepeer stream creation in start * fix: join function --------- Co-authored-by: samarendra-push Co-authored-by: Samarendra Gouda <134079446+samarendra-push@users.noreply.github.com> * refactor: added feature of triggering widget from sdk * fix(spaces): fix join as speaker and listner * fix: resolved updating env and other class variables * Spaces/UI migration (#510) * fix: ui-migration * fix: migration fixes * refactor: added notification socket for space in uiweb * feat: add remove and admin func to invite modal (#509) * feat: add remove and admin func to invite modal * fix: fix null * fix(spaces): fix start * feat: add join functionality to invited spaces (#512) * feat: add join functionality to invited spaces * fix: open space widget after joining * refactor: add audio playback from space speakers (#511) * refactor: added a hidden Video container * fix: migrated initSpaceObject to parent component * feat(spaces): add user feeds socket handler logic --------- Co-authored-by: Nilesh Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Samarendra Gouda <134079446+samarendra-push@users.noreply.github.com> Co-authored-by: Samarendra Gouda Co-authored-by: Shoaib Mohammed Co-authored-by: aman035 Co-authored-by: samarendra-push --- .gitignore | 1 + .../app/SpaceTest/AddSpeakersToSpaceTest.tsx | 1 - .../src/app/SpaceTest/CreateSpaceTest.tsx | 1 - .../SpaceTest/RemoveSpeakersFromSpaceTest.tsx | 1 - .../src/app/SpaceTest/StartSpaceTest.tsx | 12 +- .../src/app/SpaceTest/StopSpaceTest.tsx | 12 +- .../src/app/SpaceTest/UpdateSpaceTest.tsx | 5 +- .../app/SpaceUITest/CreateSpaceComponent.tsx | 7 + .../src/app/SpaceUITest/SpaceBanner.tsx | 63 + .../src/app/SpaceUITest/SpaceFeed.tsx | 85 + .../src/app/SpaceUITest/SpaceInvites.tsx | 9 + .../src/app/SpaceUITest/SpaceUITest.tsx | 52 + .../src/app/SpaceUITest/SpaceWidget.tsx | 155 + .../demoreact/src/app/SpaceUITest/index.tsx | 29 + .../app/SpaceUITest/useSpaceComponents.tsx | 64 + packages/demoreact/src/app/app.tsx | 264 +- .../sdk-frontend/{video => }/README.md | 0 .../components/Spaces/Checkbox.tsx | 15 + .../components/Spaces/Dropdown.tsx | 35 + .../components/Spaces/StyledComponents.tsx | 61 + .../sdk-frontend/components/Spaces/index.ts | 0 .../components/Spaces/useSpaceComponent.tsx | 72 + .../{video => }/components/VideoPlayer.tsx | 0 .../{video => }/helpers/getCAIPAddress.ts | 0 .../{video => }/hooks/usePushSocket.ts | 0 .../sdk-frontend/{video => }/next-env.d.ts | 0 .../sdk-frontend/{video => }/next.config.js | 0 .../sdk-frontend/{video => }/package.json | 3 +- .../sdk-frontend/{video => }/pages/_app.tsx | 25 +- .../examples/sdk-frontend/pages/index.tsx | 43 + .../sdk-frontend/pages/spaces/banner.tsx | 71 + .../sdk-frontend/pages/spaces/create.tsx | 16 + .../sdk-frontend/pages/spaces/feed.tsx | 90 + .../sdk-frontend/pages/spaces/index.tsx | 66 + .../sdk-frontend/pages/spaces/invites.tsx | 16 + .../sdk-frontend/pages/spaces/widget.tsx | 163 + .../pages/index.tsx => pages/video.tsx} | 0 .../{video => }/styles/globals.css | 0 .../sdk-frontend/{video => }/tsconfig.json | 0 .../sdk-frontend/video/pages/spaces/index.tsx | 0 packages/restapi/package.json | 5 +- .../restapi/src/lib/payloads/constants.ts | 30 + packages/restapi/src/lib/payloads/index.ts | 9 +- packages/restapi/src/lib/space/Space.ts | 230 ++ .../src/lib/space/acceptPromotionInvite.ts | 28 + .../src/lib/space/acceptPromotionRequest.ts | 33 + packages/restapi/src/lib/space/addSpeaker.ts | 34 + packages/restapi/src/lib/space/addSpeakers.ts | 13 +- packages/restapi/src/lib/space/approve.ts | 4 +- .../restapi/src/lib/space/connectInvitee.ts | 30 + .../restapi/src/lib/space/connectPromotor.ts | 13 + packages/restapi/src/lib/space/create.ts | 74 +- .../lib/space/helpers/addToMergedStream.ts | 10 + .../lib/space/helpers/getMergeStreamObject.ts | 14 + packages/restapi/src/lib/space/index.ts | 17 +- packages/restapi/src/lib/space/initialize.ts | 17 + .../restapi/src/lib/space/inviteToPromote.ts | 35 + packages/restapi/src/lib/space/join.ts | 96 + packages/restapi/src/lib/space/leave.ts | 34 + .../src/lib/space/rejectPromotionInvite.ts | 18 + .../src/lib/space/rejectPromotionRequest.ts | 17 + .../restapi/src/lib/space/removeSpeaker.ts | 37 + .../restapi/src/lib/space/removeSpeakers.ts | 67 +- .../src/lib/space/requestToBePromoted.ts | 28 + packages/restapi/src/lib/space/start.ts | 224 +- packages/restapi/src/lib/space/stop.ts | 139 +- packages/restapi/src/lib/space/update.ts | 135 +- packages/restapi/src/lib/space/update_out.ts | 72 + packages/restapi/src/lib/types/index.ts | 36 +- packages/restapi/src/lib/video/Video.ts | 649 +++- .../video/helpers/getConnectToAddresses.ts | 17 + .../video/helpers/getConnectedAddresses.ts | 17 + .../lib/video/helpers/getIceServerConfig.ts | 14 +- .../helpers/getIncomingIndexFromAddress.ts | 7 + .../helpers/sendVideoCallNotification.ts | 32 +- packages/restapi/src/lib/video/index.ts | 1 + packages/restapi/yarn.lock | 3177 ++++++++--------- packages/uiweb/package.json | 8 +- packages/uiweb/src/lib/components/index.ts | 3 +- .../space/SpaceBanner/SpaceBanner.tsx | 238 ++ .../SpaceBannerLoadingSkeleton.tsx | 137 + .../lib/components/space/SpaceBanner/index.ts | 1 + .../SCWButton/SCWButton.tsx | 57 + .../SpaceCreationWidget/SCWButton/index.ts | 1 + .../SCWCreateModal/SCWCreateModal.tsx | 90 + .../SCWCreateModal/index.ts | 1 + .../SCWInviteModal/SCWInviteModal.tsx | 367 ++ .../SCWInviteModal/index.ts | 1 + .../SCWScheduleModal/SCWScheduleModal.tsx | 59 + .../SCWScheduleModal/index.ts | 1 + .../SpaceCreationWidget.tsx | 174 + .../space/SpaceCreationWidget/index.ts | 1 + .../components/space/SpaceFeed/SpaceFeed.tsx | 478 +++ .../lib/components/space/SpaceFeed/index.ts | 1 + .../space/SpaceInvites/SpaceInvites.tsx | 144 + .../components/space/SpaceInvites/index.ts | 1 + .../SpaceWidget/LiveSpaceProfileContainer.tsx | 90 + .../space/SpaceWidget/LiveWidgetContent.tsx | 174 + .../SpaceWidget/ScheduledWidgetContent.tsx | 215 ++ .../SpaceWidget/SpaceMembersSectionModal.tsx | 256 ++ .../space/SpaceWidget/SpaceWidget.tsx | 142 + .../space/SpaceWidget/SpacesInfo.tsx | 124 + .../space/SpaceWidget/VideoPlayer.tsx | 25 + .../space/SpaceWidget/WidgetContent.tsx | 75 + .../space/SpaceWidget/WidgetHeader.tsx | 211 ++ .../space/SpaceWidget/helpers/utils.ts | 31 + .../lib/components/space/SpaceWidget/index.ts | 1 + .../src/lib/components/space/SpacesUI.tsx | 78 + .../src/lib/components/space/exportedTypes.ts | 30 + .../src/lib/components/space/helpers/date.ts | 48 + .../src/lib/components/space/helpers/space.ts | 12 + .../uiweb/src/lib/components/space/index.ts | 15 + .../components/space/reusables/Accordion.tsx | 89 + .../lib/components/space/reusables/Button.tsx | 82 + .../components/space/reusables/Checkbox.tsx | 18 + .../space/reusables/DateTimePicker.tsx | 148 + .../space/reusables/HostPfpContainer.tsx | 111 + .../lib/components/space/reusables/Modal.tsx | 83 + .../space/reusables/ModalHeader.tsx | 101 + .../space/reusables/ParticipantContainer.tsx | 98 + .../space/reusables/ProfileContainer.tsx | 194 + .../space/reusables/SearchInput.tsx | 76 + .../components/space/reusables/Spinner.tsx | 35 + .../components/space/reusables/TextInput.tsx | 71 + .../lib/components/space/reusables/index.ts | 2 + .../components/space/theme/ThemeProvider.tsx | 19 + .../src/lib/components/space/theme/index.ts | 58 + packages/uiweb/src/lib/config/index.ts | 3 +- packages/uiweb/src/lib/config/styles.tsx | 75 + packages/uiweb/src/lib/context/index.ts | 4 +- .../uiweb/src/lib/context/spacesContext.ts | 113 + .../lib/dataProviders/SpaceDataProvider.tsx | 222 ++ packages/uiweb/src/lib/dataProviders/index.ts | 1 + packages/uiweb/src/lib/helpers/apiHelper.ts | 9 + packages/uiweb/src/lib/helpers/date.ts | 6 + packages/uiweb/src/lib/helpers/index.ts | 4 +- packages/uiweb/src/lib/hooks/index.ts | 3 +- packages/uiweb/src/lib/hooks/space/index.ts | 7 + .../src/lib/hooks/space/useFeedScroll.ts | 13 + .../src/lib/hooks/space/useGetSpaceInfo.ts | 37 + .../uiweb/src/lib/hooks/space/useMySpaces.ts | 44 + .../src/lib/hooks/space/usePopularSpaces.ts | 41 + .../uiweb/src/lib/hooks/space/useSpaceData.ts | 11 + .../hooks/space/useSpaceNotificationSocket.ts | 141 + .../src/lib/hooks/space/useSpaceRequests.ts | 45 + packages/uiweb/src/lib/hooks/useChatScroll.ts | 2 +- packages/uiweb/src/lib/icons/ArrowLeft.svg | 4 + packages/uiweb/src/lib/icons/ArrowLeft.tsx | 9 + .../uiweb/src/lib/icons/CalendarPurple.tsx | 28 + packages/uiweb/src/lib/icons/CaretDown.svg | 3 + .../uiweb/src/lib/icons/CaretDownGrey.svg | 3 + packages/uiweb/src/lib/icons/CaretUp.svg | 3 + packages/uiweb/src/lib/icons/CaretUpGrey.svg | 3 + packages/uiweb/src/lib/icons/CloseSvg.tsx | 12 +- packages/uiweb/src/lib/icons/Members.svg | 18 + packages/uiweb/src/lib/icons/MicEngage.svg | 3 + packages/uiweb/src/lib/icons/Minimize.tsx | 29 + packages/uiweb/src/lib/icons/Muted.svg | 3 + packages/uiweb/src/lib/icons/Share.svg | 14 + packages/uiweb/src/lib/icons/Spaces.svg | 19 + packages/uiweb/src/lib/icons/atVector.svg | 4 + packages/uiweb/src/lib/icons/calendar.svg | 6 + .../uiweb/src/lib/icons/calendarPurple.svg | 4 + packages/uiweb/src/lib/icons/checkIcon.svg | 3 + packages/uiweb/src/lib/icons/copyVector.svg | 4 + packages/uiweb/src/lib/icons/filter.svg | 3 + packages/uiweb/src/lib/icons/hand.svg | 11 + packages/uiweb/src/lib/icons/live.svg | 13 + packages/uiweb/src/lib/icons/micoff.svg | 3 + packages/uiweb/src/lib/icons/micon.svg | 5 + packages/uiweb/src/lib/icons/scheduled.svg | 6 + packages/uiweb/src/lib/icons/settings.svg | 5 + .../uiweb/src/lib/icons/settingsBlack.svg | 5 + .../uiweb/src/lib/icons/twitterVector.svg | 3 + packages/uiweb/src/lib/index.ts | 1 + packages/uiweb/yarn.lock | 761 ++++ 176 files changed, 10739 insertions(+), 2355 deletions(-) create mode 100644 packages/demoreact/src/app/SpaceUITest/CreateSpaceComponent.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/SpaceBanner.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/SpaceFeed.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/SpaceInvites.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/SpaceUITest.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/SpaceWidget.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/index.tsx create mode 100644 packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx rename packages/examples/sdk-frontend/{video => }/README.md (100%) create mode 100644 packages/examples/sdk-frontend/components/Spaces/Checkbox.tsx create mode 100644 packages/examples/sdk-frontend/components/Spaces/Dropdown.tsx create mode 100644 packages/examples/sdk-frontend/components/Spaces/StyledComponents.tsx create mode 100644 packages/examples/sdk-frontend/components/Spaces/index.ts create mode 100644 packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx rename packages/examples/sdk-frontend/{video => }/components/VideoPlayer.tsx (100%) rename packages/examples/sdk-frontend/{video => }/helpers/getCAIPAddress.ts (100%) rename packages/examples/sdk-frontend/{video => }/hooks/usePushSocket.ts (100%) rename packages/examples/sdk-frontend/{video => }/next-env.d.ts (100%) rename packages/examples/sdk-frontend/{video => }/next.config.js (100%) rename packages/examples/sdk-frontend/{video => }/package.json (85%) rename packages/examples/sdk-frontend/{video => }/pages/_app.tsx (56%) create mode 100644 packages/examples/sdk-frontend/pages/index.tsx create mode 100644 packages/examples/sdk-frontend/pages/spaces/banner.tsx create mode 100644 packages/examples/sdk-frontend/pages/spaces/create.tsx create mode 100644 packages/examples/sdk-frontend/pages/spaces/feed.tsx create mode 100644 packages/examples/sdk-frontend/pages/spaces/index.tsx create mode 100644 packages/examples/sdk-frontend/pages/spaces/invites.tsx create mode 100644 packages/examples/sdk-frontend/pages/spaces/widget.tsx rename packages/examples/sdk-frontend/{video/pages/index.tsx => pages/video.tsx} (100%) rename packages/examples/sdk-frontend/{video => }/styles/globals.css (100%) rename packages/examples/sdk-frontend/{video => }/tsconfig.json (100%) create mode 100644 packages/examples/sdk-frontend/video/pages/spaces/index.tsx create mode 100644 packages/restapi/src/lib/space/Space.ts create mode 100644 packages/restapi/src/lib/space/acceptPromotionInvite.ts create mode 100644 packages/restapi/src/lib/space/acceptPromotionRequest.ts create mode 100644 packages/restapi/src/lib/space/addSpeaker.ts create mode 100644 packages/restapi/src/lib/space/connectInvitee.ts create mode 100644 packages/restapi/src/lib/space/connectPromotor.ts create mode 100644 packages/restapi/src/lib/space/helpers/addToMergedStream.ts create mode 100644 packages/restapi/src/lib/space/helpers/getMergeStreamObject.ts create mode 100644 packages/restapi/src/lib/space/initialize.ts create mode 100644 packages/restapi/src/lib/space/inviteToPromote.ts create mode 100644 packages/restapi/src/lib/space/join.ts create mode 100644 packages/restapi/src/lib/space/leave.ts create mode 100644 packages/restapi/src/lib/space/rejectPromotionInvite.ts create mode 100644 packages/restapi/src/lib/space/rejectPromotionRequest.ts create mode 100644 packages/restapi/src/lib/space/removeSpeaker.ts create mode 100644 packages/restapi/src/lib/space/requestToBePromoted.ts create mode 100644 packages/restapi/src/lib/space/update_out.ts create mode 100644 packages/restapi/src/lib/video/helpers/getConnectToAddresses.ts create mode 100644 packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts create mode 100644 packages/restapi/src/lib/video/helpers/getIncomingIndexFromAddress.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceBanner/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/SCWScheduleModal.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceCreationWidget/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceFeed/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceInvites/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/SpaceMembersSectionModal.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/index.ts create mode 100644 packages/uiweb/src/lib/components/space/SpacesUI.tsx create mode 100644 packages/uiweb/src/lib/components/space/exportedTypes.ts create mode 100644 packages/uiweb/src/lib/components/space/helpers/date.ts create mode 100644 packages/uiweb/src/lib/components/space/helpers/space.ts create mode 100644 packages/uiweb/src/lib/components/space/index.ts create mode 100644 packages/uiweb/src/lib/components/space/reusables/Accordion.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/Button.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/Checkbox.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/Modal.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/Spinner.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/TextInput.tsx create mode 100644 packages/uiweb/src/lib/components/space/reusables/index.ts create mode 100644 packages/uiweb/src/lib/components/space/theme/ThemeProvider.tsx create mode 100644 packages/uiweb/src/lib/components/space/theme/index.ts create mode 100644 packages/uiweb/src/lib/config/styles.tsx create mode 100644 packages/uiweb/src/lib/context/spacesContext.ts create mode 100644 packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx create mode 100644 packages/uiweb/src/lib/dataProviders/index.ts create mode 100644 packages/uiweb/src/lib/helpers/apiHelper.ts create mode 100644 packages/uiweb/src/lib/helpers/date.ts create mode 100644 packages/uiweb/src/lib/hooks/space/index.ts create mode 100644 packages/uiweb/src/lib/hooks/space/useFeedScroll.ts create mode 100644 packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts create mode 100644 packages/uiweb/src/lib/hooks/space/useMySpaces.ts create mode 100644 packages/uiweb/src/lib/hooks/space/usePopularSpaces.ts create mode 100644 packages/uiweb/src/lib/hooks/space/useSpaceData.ts create mode 100644 packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts create mode 100644 packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts create mode 100644 packages/uiweb/src/lib/icons/ArrowLeft.svg create mode 100644 packages/uiweb/src/lib/icons/ArrowLeft.tsx create mode 100644 packages/uiweb/src/lib/icons/CalendarPurple.tsx create mode 100644 packages/uiweb/src/lib/icons/CaretDown.svg create mode 100644 packages/uiweb/src/lib/icons/CaretDownGrey.svg create mode 100644 packages/uiweb/src/lib/icons/CaretUp.svg create mode 100644 packages/uiweb/src/lib/icons/CaretUpGrey.svg create mode 100644 packages/uiweb/src/lib/icons/Members.svg create mode 100644 packages/uiweb/src/lib/icons/MicEngage.svg create mode 100644 packages/uiweb/src/lib/icons/Minimize.tsx create mode 100644 packages/uiweb/src/lib/icons/Muted.svg create mode 100644 packages/uiweb/src/lib/icons/Share.svg create mode 100644 packages/uiweb/src/lib/icons/Spaces.svg create mode 100644 packages/uiweb/src/lib/icons/atVector.svg create mode 100644 packages/uiweb/src/lib/icons/calendar.svg create mode 100644 packages/uiweb/src/lib/icons/calendarPurple.svg create mode 100644 packages/uiweb/src/lib/icons/checkIcon.svg create mode 100644 packages/uiweb/src/lib/icons/copyVector.svg create mode 100644 packages/uiweb/src/lib/icons/filter.svg create mode 100644 packages/uiweb/src/lib/icons/hand.svg create mode 100644 packages/uiweb/src/lib/icons/live.svg create mode 100644 packages/uiweb/src/lib/icons/micoff.svg create mode 100644 packages/uiweb/src/lib/icons/micon.svg create mode 100644 packages/uiweb/src/lib/icons/scheduled.svg create mode 100644 packages/uiweb/src/lib/icons/settings.svg create mode 100644 packages/uiweb/src/lib/icons/settingsBlack.svg create mode 100644 packages/uiweb/src/lib/icons/twitterVector.svg diff --git a/.gitignore b/.gitignore index 2eb9aa0f6..1d4900b27 100644 --- a/.gitignore +++ b/.gitignore @@ -288,3 +288,4 @@ buck-out/ packages/restapi/yarn.lock yarn.lock *.env +**/.next diff --git a/packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx index ab4b31b42..2b95f9c6b 100644 --- a/packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/AddSpeakersToSpaceTest.tsx @@ -39,7 +39,6 @@ const AddSpeakersToSpaceTest = () => { spaceId: spaceId, speakers: speakerAddress ? speakerAddress.split(',') : [], env, - account: account, signer: librarySigner, }); setSendResponse(response); diff --git a/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx index 9e1e543be..ab4bcf2f3 100644 --- a/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/CreateSpaceTest.tsx @@ -105,7 +105,6 @@ const CreateSpaceTest = () => { numberOfNFTs: numberOfNFTs != null ? Number(numberOfNFTs) : undefined, contractAddressERC20, numberOfERC20: numberOfERC20 != null ? Number(numberOfERC20) : undefined, - account: isCAIP ? walletToPCAIP10(account) : account, signer: librarySigner, env, meta: meta, diff --git a/packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx index 117f13135..411a0f398 100644 --- a/packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/RemoveSpeakersFromSpaceTest.tsx @@ -39,7 +39,6 @@ const RemoveSpeakersFromSpaceTest = () => { spaceId: spaceId, speakers: speakerAddress ? speakerAddress.split(',') : [], env, - account: account, signer: librarySigner, }); setSendResponse(response); diff --git a/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx index d27c48455..90364c22d 100644 --- a/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/StartSpaceTest.tsx @@ -31,12 +31,12 @@ const StartSpaceTest = () => { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.space.start({ - spaceId: spaceId, - signer: librarySigner, - env: env, - }); - setSendResponse(response); + // const response = await PushAPI.space.start({ + // spaceId: spaceId, + // signer: librarySigner, + // env: env, + // }); + // setSendResponse(response); } catch (e) { console.error(e); diff --git a/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx index fe361f17c..a2182ee3d 100644 --- a/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/StopSpaceTest.tsx @@ -31,12 +31,12 @@ const StopSpaceTest = () => { setLoading(true); const librarySigner = await library.getSigner(); - const response = await PushAPI.space.stop({ - spaceId: spaceId, - signer: librarySigner, - env: env, - }); - setSendResponse(response); + // const response = await PushAPI.space.stop({ + // spaceId: spaceId, + // signer: librarySigner, + // env: env, + // }); + // setSendResponse(response); } catch (e) { console.error(e); diff --git a/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx b/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx index 7e56f3ce4..6a893f472 100644 --- a/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx +++ b/packages/demoreact/src/app/SpaceTest/UpdateSpaceTest.tsx @@ -48,7 +48,7 @@ const UpdateSpaceTest = () => { setMembers((e.target as HTMLInputElement).value); }; - + const updateAdmins= (e: React.SyntheticEvent) => { setAdmins((e.target as HTMLInputElement).value); }; @@ -81,7 +81,6 @@ const UpdateSpaceTest = () => { spaceDescription, members: members.split(','), admins: admins.split(','), - account: isCAIP ? walletToPCAIP10(account) : account, signer: librarySigner, env, scheduleAt: new Date(scheduleAt) , @@ -148,7 +147,7 @@ const UpdateSpaceTest = () => { style={{ width: 400, height: 30 }} /> - + { + const { CreateSpaceComponent } = useSpaceComponents(); + + return +} diff --git a/packages/demoreact/src/app/SpaceUITest/SpaceBanner.tsx b/packages/demoreact/src/app/SpaceUITest/SpaceBanner.tsx new file mode 100644 index 000000000..44c50caee --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/SpaceBanner.tsx @@ -0,0 +1,63 @@ +import React, { useState } from 'react'; + +import { useSpaceComponents } from './useSpaceComponents'; +import { Section, SectionItem } from '../components/StyledComponents'; +import Dropdown from '../components/Dropdown'; + +export const SpaceBanner = () => { + const { SpaceBannerComponent } = useSpaceComponents(); + + const [spaceId, setSpaceId] = useState(''); + const [orientation, setOrientation] = useState('maximized'); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateOrientation = (e: any) => { + setOrientation(e.target.value); + }; + + const onClickHandler = (arg: string) => { + console.log(arg); + } + + return ( +
+
+ + + + + +
+ +
+ ); +}; diff --git a/packages/demoreact/src/app/SpaceUITest/SpaceFeed.tsx b/packages/demoreact/src/app/SpaceUITest/SpaceFeed.tsx new file mode 100644 index 000000000..5b204b591 --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/SpaceFeed.tsx @@ -0,0 +1,85 @@ +import React, { useState } from 'react'; +import { useSpaceComponents } from './useSpaceComponents'; +import { Checkbox } from '../components/Checkbox'; + +export const SpaceFeed = () => { + const { SpaceFeedComponent } = useSpaceComponents(); + const [address, setAddress] = useState(); + const [showTab, setShowTab] = useState(true); + const [horizontal, setHorizontal] = useState(false); + const [width, setWidth] = useState(); + const [height, setHeight] = useState(500); + const [sortingOrder, setSortingOrder] = useState([]); + + const handleShowTab = () => { + setShowTab(!showTab); + }; + + const handleHorizontal = () => { + setHorizontal(!horizontal); + }; + + const handleAddressChange = (e: React.SyntheticEvent) => { + setAddress((e.target as HTMLInputElement).value); + }; + + const handleWidthChange = (e: React.SyntheticEvent) => { + setWidth((e.target as HTMLInputElement).value as unknown as number); + }; + + const handleHeightChange = (e: React.SyntheticEvent) => { + setHeight((e.target as HTMLInputElement).value as unknown as number); + }; + + return ( + <> + + + +
+ +
+ +
+ +
+ +
+ + { + console.log('spaceId: ', spaceId); + }} + /> + + ); +}; diff --git a/packages/demoreact/src/app/SpaceUITest/SpaceInvites.tsx b/packages/demoreact/src/app/SpaceUITest/SpaceInvites.tsx new file mode 100644 index 000000000..8b1493262 --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/SpaceInvites.tsx @@ -0,0 +1,9 @@ +import { useSpaceComponents } from "./useSpaceComponents" + +export const SpaceInvitesComponent = () => { + const { SpaceInvitesComponent } = useSpaceComponents(); + + return ( + + ) +} diff --git a/packages/demoreact/src/app/SpaceUITest/SpaceUITest.tsx b/packages/demoreact/src/app/SpaceUITest/SpaceUITest.tsx new file mode 100644 index 000000000..ce3f9c8bf --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/SpaceUITest.tsx @@ -0,0 +1,52 @@ +import { useState } from 'react'; +import styled from 'styled-components'; +import { Link } from 'react-router-dom'; +import { + Section, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; + +const SpaceUITest = () => { + const [isLoading, setIsLoading] = useState(false); + + const NavMenu = styled.div` + display: flex; + flex-wrap: wrap; + gap: 30px; + justify-content: center; + + @media only screen and (max-width: 900px) { + flex-direction: column; + } + `; + + return ( +
+

Space UI Test page

+ + + +
+ + + SPACES WIDGET + + + SPACES FEED + + + SPACES BANNER + + + CREATE SPACE + + + SPACES INVITES + + +
+
+ ); +}; + +export default SpaceUITest; diff --git a/packages/demoreact/src/app/SpaceUITest/SpaceWidget.tsx b/packages/demoreact/src/app/SpaceUITest/SpaceWidget.tsx new file mode 100644 index 000000000..1bb487857 --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/SpaceWidget.tsx @@ -0,0 +1,155 @@ +import { useState } from "react"; +import { Section, SectionItem } from "../components/StyledComponents"; +import SpaceUITest from "./SpaceUITest"; +import { useSpaceComponents } from "./useSpaceComponents" + +export const SpaceWidget = () => { + const { SpaceWidgetComponent } = useSpaceComponents(); + const [spaceId, setSpaceId] = useState(''); + const [width, setWidth] = useState(''); + const [zIndex, setZIndex] = useState('1000'); + const [shareUrl, setShareUrl] = useState(''); + const [isHost, setisHost] = useState(false); + const [isLive, setisLive] = useState(false); + const [isMember, setisMember] = useState(false); + const [isJoined, setisJoined] = useState(false); + const [isTimeToStartSpace, setisTimeToStartSpace] = useState(false); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateWidgetWidth = (e: React.SyntheticEvent) => { + setWidth((e.target as HTMLInputElement).value); + }; + + const updateZIndex = (e: React.SyntheticEvent) => { + setZIndex((e.target as HTMLInputElement).value); + }; + + const updateShareUrl = (e: React.SyntheticEvent) => { + setShareUrl((e.target as HTMLInputElement).value); + }; + + const updateIsHost = (e: React.SyntheticEvent) => { + setisHost((e.target as HTMLInputElement).checked); + }; + + const updateIsLive = (e: React.SyntheticEvent) => { + setisLive((e.target as HTMLInputElement).checked); + }; + + const updateIsMember = (e: React.SyntheticEvent) => { + setisMember((e.target as HTMLInputElement).checked); + }; + + const updateIsJoined = (e: React.SyntheticEvent) => { + setisJoined((e.target as HTMLInputElement).checked); + }; + + const updateIsTimeToStartSpace = (e: React.SyntheticEvent) => { + setisTimeToStartSpace((e.target as HTMLInputElement).checked); + }; + + return ( +
+ +

Space Widget Test page

+
+ + + + + + + + + + + + + + + + +
Temp Props
+ + + + + + + + + + + + + + + + + + + + +
+ +
+ ); +} diff --git a/packages/demoreact/src/app/SpaceUITest/index.tsx b/packages/demoreact/src/app/SpaceUITest/index.tsx new file mode 100644 index 000000000..5e3c4137f --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/index.tsx @@ -0,0 +1,29 @@ +import { SpacesUIProvider } from '@pushprotocol/uiweb'; +import { useSpaceComponents } from './useSpaceComponents'; + +export * from './SpaceUITest'; +export * from './SpaceWidget'; +export * from './SpaceFeed'; +export * from "./SpaceBanner"; +export * from "./CreateSpaceComponent"; +export * from "./SpaceInvites"; + +export interface ISpacesComponentProps { + children: React.ReactNode; +} + +export const SpacesComponentProvider = ({ + children, +}: ISpacesComponentProps) => { + const { spaceUI } = useSpaceComponents(); + + const customtheme = { + statusColorError: 'red', + } + + return ( + + {children} + + ); +}; diff --git a/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx b/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx new file mode 100644 index 000000000..5c0ee9ffc --- /dev/null +++ b/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx @@ -0,0 +1,64 @@ +import { + ISpaceFeedProps, + ISpaceBannerProps, + ISpaceWidgetProps, + ISpaceCreateWidgetProps, + SpacesUI, + ISpaceInvitesProps, +} from '@pushprotocol/uiweb'; +import React, { useContext, useEffect, useState } from 'react'; +import { EnvContext, Web3Context } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; + +export interface IUseSpaceReturnValues { + spaceUI: SpacesUI; + SpaceInvitesComponent: React.FC; + SpaceWidgetComponent: React.FC; + SpaceFeedComponent: React.FC; + SpaceBannerComponent: React.FC; + CreateSpaceComponent: React.FC; +} + +export const useSpaceComponents = (): IUseSpaceReturnValues => { + const { account, library } = useContext(Web3Context); + const { env } = useContext(EnvContext); + const librarySigner = library?.getSigner(); + + const [pgpPrivateKey, setPgpPrivateKey] = useState(''); + + const spaceUI = new SpacesUI({ + account: account, + signer: librarySigner, + pgpPrivateKey: pgpPrivateKey, + env: env, + }); + + useEffect(() => { + (async () => { + if (!account || !env || !library) return; + + const user = await PushAPI.user.get({ account, env }); + let pgpPrivateKey; + const librarySigner = await library.getSigner(account); + if (user?.encryptedPrivateKey) { + pgpPrivateKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account, + signer: librarySigner, + env, + }); + } + + setPgpPrivateKey(pgpPrivateKey); + })(); + }, [account, env, library]); + + return { + spaceUI, + SpaceInvitesComponent: spaceUI.SpaceInvites, + SpaceWidgetComponent: spaceUI.SpaceWidget, + SpaceBannerComponent: spaceUI.SpaceBanner, + SpaceFeedComponent: spaceUI.SpaceFeed, + CreateSpaceComponent: spaceUI.SpaceCreationButtonWidget, + }; +}; diff --git a/packages/demoreact/src/app/app.tsx b/packages/demoreact/src/app/app.tsx index fb971e471..69d9c8f35 100644 --- a/packages/demoreact/src/app/app.tsx +++ b/packages/demoreact/src/app/app.tsx @@ -53,6 +53,16 @@ import RemoveSpeakersFromSpaceTest from './SpaceTest/RemoveSpeakersFromSpaceTest import GetSpacesTest from './SpaceTest/GetSpacesTest'; import GetSpacesRequestsTest from './SpaceTest/GetSpacesRequestsTest'; import GetSpacesTrendingTest from './SpaceTest/GetSpacesTrendingTest'; +import SpaceUITest from './SpaceUITest/SpaceUITest'; +import { + SpacesComponentProvider, + SpaceWidget, + SpaceBanner, + SpaceFeed, + CreateSpaceComponent, + SpaceInvitesComponent +} from './SpaceUITest'; +import { useSpaceComponents } from './SpaceUITest/useSpaceComponents'; window.Buffer = window.Buffer || Buffer; @@ -74,7 +84,7 @@ const StyledApp = styled.div` justify-content: center; text-decoration: none; - &: hover { + &:hover { text-decoration: underline; } } @@ -127,6 +137,7 @@ const StyledApp = styled.div` const NavMenu = styled.div` display: flex; + flex-flow: wrap; gap: 30px; justify-content: center; @@ -150,6 +161,9 @@ export function App() { const [env, setEnv] = useState(ENV.PROD); const [isCAIP, setIsCAIP] = useState(false); + const { SpaceWidgetComponent } = useSpaceComponents(); + const [spaceId, setSpaceId] = useState(''); + const socketData = useSDKSocket({ account: web3Data.account, chainId: web3Data.chainId, @@ -199,101 +213,159 @@ export function App() { {checkForWeb3Data(web3Data) ? ( - - - - NOTIFICATIONS - - - SECRET NOTIFICATION - - - CHANNELS - - - ALIAS - - - DELEGATIONS - - - PAYLOADS - - - SOCKET - - - EMBED - - - CHAT - - - SPACE - - - } - /> - } /> - } /> - - } /> - - } /> - - } /> - - } /> - - } /> - - } /> - - } /> - } /> - - {/* chat method routes */} - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - - {/* spaces method routes */} - - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - - - + + + + + NOTIFICATIONS + + + SECRET NOTIFICATION + + + CHANNELS + + + ALIAS + + + DELEGATIONS + + + PAYLOADS + + + SOCKET + + + EMBED + + + CHAT + + + SPACE + + + SPACE UI + + + } + /> + } + /> + } /> + + } /> + + } /> + + } /> + + } /> + + } /> + + } /> + + } /> + } /> + + } /> + + {/* chat method routes */} + } /> + } + /> + } /> + } + /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } + /> + } + /> + } + /> + } + /> + } /> + + {/* spaces method routes */} + } /> + } /> + } /> + } /> + } + /> + } /> + } /> + } + /> + } + /> + } + /> + } + /> + } /> + } + /> + } + /> + + {/* spaces ui components routes */} + } /> + } /> + } /> + } /> + } + /> + + + + ) : null} diff --git a/packages/examples/sdk-frontend/video/README.md b/packages/examples/sdk-frontend/README.md similarity index 100% rename from packages/examples/sdk-frontend/video/README.md rename to packages/examples/sdk-frontend/README.md diff --git a/packages/examples/sdk-frontend/components/Spaces/Checkbox.tsx b/packages/examples/sdk-frontend/components/Spaces/Checkbox.tsx new file mode 100644 index 000000000..58e759c59 --- /dev/null +++ b/packages/examples/sdk-frontend/components/Spaces/Checkbox.tsx @@ -0,0 +1,15 @@ +import React from 'react'; + +export const Checkbox = (props: { id: string, label: string, value?: boolean, onChange: () => void }) => { + return ( +
+ + +
+ ); + }; \ No newline at end of file diff --git a/packages/examples/sdk-frontend/components/Spaces/Dropdown.tsx b/packages/examples/sdk-frontend/components/Spaces/Dropdown.tsx new file mode 100644 index 000000000..b97e8e9ee --- /dev/null +++ b/packages/examples/sdk-frontend/components/Spaces/Dropdown.tsx @@ -0,0 +1,35 @@ +import React from 'react'; + +type DropdownOptionsType = { + value: string, + label: string +}; + +const Dropdown = ({ + style, + label, + value, + width, + options, + onChange +}: { + style?: any, + label: string, + value?: string, + width?: string | number, + options: DropdownOptionsType[], + onChange: (arg0: any) => void +}) => { + return ( + + ); +}; + +export default Dropdown; \ No newline at end of file diff --git a/packages/examples/sdk-frontend/components/Spaces/StyledComponents.tsx b/packages/examples/sdk-frontend/components/Spaces/StyledComponents.tsx new file mode 100644 index 000000000..cb13603e4 --- /dev/null +++ b/packages/examples/sdk-frontend/components/Spaces/StyledComponents.tsx @@ -0,0 +1,61 @@ +import styled from 'styled-components'; + +export const Section = styled.section` + border: 2px solid #ccc; + padding: 25px; + margin: 10px 0; + display: flex; + flex-direction: column; + background-color: ${(props) => props.theme === 'dark' ? '#000' : '#fff'}; + + & .headerText { + color: ${(props) => props.theme === 'dark' ? '#fff' : '#000'}; + font-size: 2rem; + } + + & .subHeaderText { + color: ${(props) => props.theme === 'dark' ? '#fff' : '#000'}; + font-size: 1.2rem; + } +` + +export const SectionItem = styled.div` + display: flex; + gap: 15px; + align-items: center; + + & label.consoleLabel { + color: green; + } +`; + +export const SectionItemCustom = styled(SectionItem)` + justify-content: flex-end; + align-items: center; + margin: 20px 0px; +`; + +export const CodeFormatter = styled.pre` + background: #eeebeb; + padding: 15px; + border-radius: 7px; +`; + +export const SectionButton = styled.button` + font-family: "Source Sans Pro",Arial,sans-serif; + font-size: 16px; + display: flex; + margin-right: 15px; + padding: 15px 20px; + background: #674C9F; + border: 0; + border-radius: 7px; + box-shadow: rgb(0 0 0 / 52%) 0px 0px 5px; + color: #fff; + justify-content: center; + + &:hover { + cursor: pointer; + background: rgb(226, 8, 128); + } +`; diff --git a/packages/examples/sdk-frontend/components/Spaces/index.ts b/packages/examples/sdk-frontend/components/Spaces/index.ts new file mode 100644 index 000000000..e69de29bb diff --git a/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx b/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx new file mode 100644 index 000000000..ccad60268 --- /dev/null +++ b/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx @@ -0,0 +1,72 @@ +import { + ISpaceFeedProps, + ISpaceBannerProps, + ISpaceWidgetProps, + ISpaceCreateWidgetProps, + SpacesUI, + ISpaceInvitesProps, +} from '@pushprotocol/uiweb'; +import { useAccount, useNetwork, useSigner } from 'wagmi'; +import React, { useContext, useEffect, useState } from 'react'; +import { ENV } from '@pushprotocol/restapi/src/lib/constants'; +import * as PushAPI from '@pushprotocol/restapi'; +import { is } from 'date-fns/locale'; + +export interface IUseSpaceReturnValues { + spaceUI: SpacesUI; + SpaceInvitesComponent: React.FC; + SpaceWidgetComponent: React.FC; + SpaceFeedComponent: React.FC; + SpaceBannerComponent: React.FC; + CreateSpaceComponent: React.FC; +} + +export const useSpaceComponents = (): IUseSpaceReturnValues => { + const env = ENV.DEV; + + const { address, isConnected } = useAccount(); + const { chain } = useNetwork(); + const { data: signer } = useSigner(); + + const [pgpPrivateKey, setPgpPrivateKey] = useState(''); + + console.log('address: ', address, isConnected); + + const spaceUI = new SpacesUI({ + account: address as string, + signer: signer as PushAPI.SignerType, + pgpPrivateKey: pgpPrivateKey, + env: env, + }); + + useEffect(() => { + (async () => { + if (!signer || !address || !chain?.id) return; + + const user = await PushAPI.user.get({ + account: address, + env, + }); + let pgpPrivateKey = null; + if (user?.encryptedPrivateKey) { + pgpPrivateKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account: address, + signer, + env, + }); + } + + setPgpPrivateKey(pgpPrivateKey); + })(); + }, [address, env, signer, chain]); + + return { + spaceUI, + SpaceInvitesComponent: spaceUI.SpaceInvites, + SpaceWidgetComponent: spaceUI.SpaceWidget, + SpaceBannerComponent: spaceUI.SpaceBanner, + SpaceFeedComponent: spaceUI.SpaceFeed, + CreateSpaceComponent: spaceUI.SpaceCreationButtonWidget, + }; +}; diff --git a/packages/examples/sdk-frontend/video/components/VideoPlayer.tsx b/packages/examples/sdk-frontend/components/VideoPlayer.tsx similarity index 100% rename from packages/examples/sdk-frontend/video/components/VideoPlayer.tsx rename to packages/examples/sdk-frontend/components/VideoPlayer.tsx diff --git a/packages/examples/sdk-frontend/video/helpers/getCAIPAddress.ts b/packages/examples/sdk-frontend/helpers/getCAIPAddress.ts similarity index 100% rename from packages/examples/sdk-frontend/video/helpers/getCAIPAddress.ts rename to packages/examples/sdk-frontend/helpers/getCAIPAddress.ts diff --git a/packages/examples/sdk-frontend/video/hooks/usePushSocket.ts b/packages/examples/sdk-frontend/hooks/usePushSocket.ts similarity index 100% rename from packages/examples/sdk-frontend/video/hooks/usePushSocket.ts rename to packages/examples/sdk-frontend/hooks/usePushSocket.ts diff --git a/packages/examples/sdk-frontend/video/next-env.d.ts b/packages/examples/sdk-frontend/next-env.d.ts similarity index 100% rename from packages/examples/sdk-frontend/video/next-env.d.ts rename to packages/examples/sdk-frontend/next-env.d.ts diff --git a/packages/examples/sdk-frontend/video/next.config.js b/packages/examples/sdk-frontend/next.config.js similarity index 100% rename from packages/examples/sdk-frontend/video/next.config.js rename to packages/examples/sdk-frontend/next.config.js diff --git a/packages/examples/sdk-frontend/video/package.json b/packages/examples/sdk-frontend/package.json similarity index 85% rename from packages/examples/sdk-frontend/video/package.json rename to packages/examples/sdk-frontend/package.json index e4f26153e..c5791072e 100644 --- a/packages/examples/sdk-frontend/video/package.json +++ b/packages/examples/sdk-frontend/package.json @@ -9,7 +9,8 @@ "lint": "next lint" }, "dependencies": { - "@pushprotocol/restapi": "^1.3.3", + "@pushprotocol/restapi": "../../../dist/packages/restapi", + "@pushprotocol/uiweb": "../../../dist/packages/uiweb", "@pushprotocol/socket": "^0.5.1", "@rainbow-me/rainbowkit": "0.12.14", "ethers": "^5", diff --git a/packages/examples/sdk-frontend/video/pages/_app.tsx b/packages/examples/sdk-frontend/pages/_app.tsx similarity index 56% rename from packages/examples/sdk-frontend/video/pages/_app.tsx rename to packages/examples/sdk-frontend/pages/_app.tsx index 5237f95e3..6013004e0 100644 --- a/packages/examples/sdk-frontend/video/pages/_app.tsx +++ b/packages/examples/sdk-frontend/pages/_app.tsx @@ -1,23 +1,24 @@ -import type { AppProps } from "next/app"; +import type { AppProps } from 'next/app'; import { getDefaultWallets, RainbowKitProvider, darkTheme, -} from "@rainbow-me/rainbowkit"; -import { configureChains, createClient, WagmiConfig } from "wagmi"; -import { goerli } from "wagmi/chains"; -import { publicProvider } from "wagmi/providers/public"; +} from '@rainbow-me/rainbowkit'; +import { configureChains, createClient, WagmiConfig } from 'wagmi'; +import { goerli } from 'wagmi/chains'; +import { publicProvider } from 'wagmi/providers/public'; -import "@rainbow-me/rainbowkit/styles.css"; -import "../styles/globals.css"; -import { useEffect, useState } from "react"; +import '@rainbow-me/rainbowkit/styles.css'; +import '../styles/globals.css'; +import { useEffect, useState } from 'react'; +import { SpacesComponentProvider } from './spaces'; const { chains, provider } = configureChains([goerli], [publicProvider()]); const { connectors } = getDefaultWallets({ - appName: "Connect", - projectId: "connect", + appName: 'Connect', + projectId: 'connect', chains, }); @@ -40,7 +41,9 @@ function MyApp({ Component, pageProps }: AppProps) { {loadWagmi ? ( - + + + ) : null} diff --git a/packages/examples/sdk-frontend/pages/index.tsx b/packages/examples/sdk-frontend/pages/index.tsx new file mode 100644 index 000000000..aff02dff0 --- /dev/null +++ b/packages/examples/sdk-frontend/pages/index.tsx @@ -0,0 +1,43 @@ +import { ConnectButton } from '@rainbow-me/rainbowkit'; +import { NextPage } from 'next'; +import Link from 'next/link'; +import styled from 'styled-components'; + +const Index: NextPage = () => { + return ( + +

Hello Next.js 👋

+ + + +
+ ); +}; + +export default Index; + +export const Container = styled.div` + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + gap: 20px; +}`; + +export const Button = styled.button` + background: #000; + color: #fff; + border: none; + border-radius: 10px; + padding: 10px 20px; + font-size: 1.2rem; + cursor: pointer; + transition: 0.3s; + &:hover { + opacity: 0.7; + } +}`; diff --git a/packages/examples/sdk-frontend/pages/spaces/banner.tsx b/packages/examples/sdk-frontend/pages/spaces/banner.tsx new file mode 100644 index 000000000..bc0a6a01c --- /dev/null +++ b/packages/examples/sdk-frontend/pages/spaces/banner.tsx @@ -0,0 +1,71 @@ +import React, { useState } from 'react'; + +import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; +import { + Section, + SectionItem, +} from './../../components/Spaces/StyledComponents'; +import Dropdown from './../../components/Spaces/Dropdown'; +import { NextPage } from 'next'; +import Spaces from '.'; + +const SpaceBanner: NextPage = () => { + const { SpaceBannerComponent } = useSpaceComponents(); + + const [spaceId, setSpaceId] = useState(''); + const [orientation, setOrientation] = useState('maximized'); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateOrientation = (e: any) => { + setOrientation(e.target.value); + }; + + const onClickHandler = (arg: string) => { + console.log(arg); + }; + + return ( +
+ +
+ + + + + +
+ +
+ ); +}; + +export default SpaceBanner; diff --git a/packages/examples/sdk-frontend/pages/spaces/create.tsx b/packages/examples/sdk-frontend/pages/spaces/create.tsx new file mode 100644 index 000000000..c45a327ba --- /dev/null +++ b/packages/examples/sdk-frontend/pages/spaces/create.tsx @@ -0,0 +1,16 @@ +import { NextPage } from 'next'; +import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; +import Spaces from '.'; + +const CreateSpaceComponent: NextPage = () => { + const { CreateSpaceComponent } = useSpaceComponents(); + + return ( + <> + + + + ); +}; + +export default CreateSpaceComponent; diff --git a/packages/examples/sdk-frontend/pages/spaces/feed.tsx b/packages/examples/sdk-frontend/pages/spaces/feed.tsx new file mode 100644 index 000000000..b15b4faa5 --- /dev/null +++ b/packages/examples/sdk-frontend/pages/spaces/feed.tsx @@ -0,0 +1,90 @@ +import React, { useState } from 'react'; +import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; +import { Checkbox } from './../../components/Spaces/Checkbox'; +import { NextPage } from 'next'; +import Spaces from '.'; + +const SpaceFeed: NextPage = () => { + const { SpaceFeedComponent } = useSpaceComponents(); + const [address, setAddress] = useState(); + const [showTab, setShowTab] = useState(true); + const [horizontal, setHorizontal] = useState(false); + const [width, setWidth] = useState(); + const [height, setHeight] = useState(500); + const [sortingOrder, setSortingOrder] = useState([]); + + const handleShowTab = () => { + setShowTab(!showTab); + }; + + const handleHorizontal = () => { + setHorizontal(!horizontal); + }; + + const handleAddressChange = (e: React.SyntheticEvent) => { + setAddress((e.target as HTMLInputElement).value); + }; + + const handleWidthChange = (e: React.SyntheticEvent) => { + setWidth((e.target as HTMLInputElement).value as unknown as number); + }; + + const handleHeightChange = (e: React.SyntheticEvent) => { + setHeight((e.target as HTMLInputElement).value as unknown as number); + }; + + return ( + <> + + + + +
+ +
+ +
+ +
+ +
+ + { + console.log('spaceId: ', spaceId); + }} + /> + + ); +}; + +export default SpaceFeed; diff --git a/packages/examples/sdk-frontend/pages/spaces/index.tsx b/packages/examples/sdk-frontend/pages/spaces/index.tsx new file mode 100644 index 000000000..2441d1181 --- /dev/null +++ b/packages/examples/sdk-frontend/pages/spaces/index.tsx @@ -0,0 +1,66 @@ +import { NextPage } from 'next'; +import styled from 'styled-components'; +import { Button, Container } from '..'; +import Link from 'next/link'; + +import { SpacesUIProvider } from '@pushprotocol/uiweb'; +import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; + + +export interface ISpacesComponentProps { + children: React.ReactNode; +} + +export const SpacesComponentProvider = ({ + children, +}: ISpacesComponentProps) => { + const { spaceUI } = useSpaceComponents(); + + const customtheme = { + statusColorError: 'red', + }; + + return ( + + {children} + + ); +}; + +const Spaces: NextPage = () => { + return ( + + +

Spaces UI Test

+
+ + + + + +
+
+
+ ); +}; + +export default Spaces; + +const Section = styled.div` + display: flex; + flex-direction: row; + justify-content: center; + align-items: center; + gap: 20px; + wrap: wrap; +}`; diff --git a/packages/examples/sdk-frontend/pages/spaces/invites.tsx b/packages/examples/sdk-frontend/pages/spaces/invites.tsx new file mode 100644 index 000000000..0cf3aeca0 --- /dev/null +++ b/packages/examples/sdk-frontend/pages/spaces/invites.tsx @@ -0,0 +1,16 @@ +import { NextPage } from 'next'; +import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; +import Spaces from '.'; + +const SpaceInvitesComponent: NextPage = () => { + const { SpaceInvitesComponent } = useSpaceComponents(); + + return ( + <> + + + + ); +}; + +export default SpaceInvitesComponent; diff --git a/packages/examples/sdk-frontend/pages/spaces/widget.tsx b/packages/examples/sdk-frontend/pages/spaces/widget.tsx new file mode 100644 index 000000000..3283285ca --- /dev/null +++ b/packages/examples/sdk-frontend/pages/spaces/widget.tsx @@ -0,0 +1,163 @@ +import { useState } from 'react'; +import { + Section, + SectionItem, +} from './../../components/Spaces/StyledComponents'; +import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; +import Spaces from '.'; +import { NextPage } from 'next'; + +const SpaceWidget: NextPage = () => { + const { SpaceWidgetComponent } = useSpaceComponents(); + const [spaceId, setSpaceId] = useState(''); + const [width, setWidth] = useState(''); + const [zIndex, setZIndex] = useState('1000'); + const [shareUrl, setShareUrl] = useState(''); + const [isHost, setisHost] = useState(false); + const [isLive, setisLive] = useState(false); + const [isMember, setisMember] = useState(false); + const [isJoined, setisJoined] = useState(false); + const [isTimeToStartSpace, setisTimeToStartSpace] = useState(false); + + const updateSpaceId = (e: React.SyntheticEvent) => { + setSpaceId((e.target as HTMLInputElement).value); + }; + + const updateWidgetWidth = (e: React.SyntheticEvent) => { + setWidth((e.target as HTMLInputElement).value); + }; + + const updateZIndex = (e: React.SyntheticEvent) => { + setZIndex((e.target as HTMLInputElement).value); + }; + + const updateShareUrl = (e: React.SyntheticEvent) => { + setShareUrl((e.target as HTMLInputElement).value); + }; + + const updateIsHost = (e: React.SyntheticEvent) => { + setisHost((e.target as HTMLInputElement).checked); + }; + + const updateIsLive = (e: React.SyntheticEvent) => { + setisLive((e.target as HTMLInputElement).checked); + }; + + const updateIsMember = (e: React.SyntheticEvent) => { + setisMember((e.target as HTMLInputElement).checked); + }; + + const updateIsJoined = (e: React.SyntheticEvent) => { + setisJoined((e.target as HTMLInputElement).checked); + }; + + const updateIsTimeToStartSpace = (e: React.SyntheticEvent) => { + setisTimeToStartSpace((e.target as HTMLInputElement).checked); + }; + + return ( +
+ +

Space Widget Test page

+
+ + + + + + + + + + + + + + + + +
+ Temp Props +
+ + + + + + + + + + + + + + + + + + + + +
+ +
+ ); +}; + +export default SpaceWidget; diff --git a/packages/examples/sdk-frontend/video/pages/index.tsx b/packages/examples/sdk-frontend/pages/video.tsx similarity index 100% rename from packages/examples/sdk-frontend/video/pages/index.tsx rename to packages/examples/sdk-frontend/pages/video.tsx diff --git a/packages/examples/sdk-frontend/video/styles/globals.css b/packages/examples/sdk-frontend/styles/globals.css similarity index 100% rename from packages/examples/sdk-frontend/video/styles/globals.css rename to packages/examples/sdk-frontend/styles/globals.css diff --git a/packages/examples/sdk-frontend/video/tsconfig.json b/packages/examples/sdk-frontend/tsconfig.json similarity index 100% rename from packages/examples/sdk-frontend/video/tsconfig.json rename to packages/examples/sdk-frontend/tsconfig.json diff --git a/packages/examples/sdk-frontend/video/pages/spaces/index.tsx b/packages/examples/sdk-frontend/video/pages/spaces/index.tsx new file mode 100644 index 000000000..e69de29bb diff --git a/packages/restapi/package.json b/packages/restapi/package.json index b69ceb00d..587d56fc1 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -9,12 +9,15 @@ "ethers": "^5.6.8" }, "dependencies": { + "@livepeer/webrtmp-sdk": "^0.2.3", "@metamask/eth-sig-util": "^5.0.2", "buffer": "^6.0.3", "crypto-js": "^4.1.1", "immer": "^10.0.2", + "livepeer": "^2.5.8", "openpgp": "^5.5.0", - "simple-peer": "^9.11.1" + "simple-peer": "^9.11.1", + "video-stream-merger": "^4.0.1" }, "scripts": { "test": "TS_NODE_PROJECT='./tsconfig.mocha.json' NODE_OPTIONS='--loader ts-node/esm' mocha -r ts-node/register 'tests/**/*.test.ts' --timeout 120000 --require tests/root.ts --serial" diff --git a/packages/restapi/src/lib/payloads/constants.ts b/packages/restapi/src/lib/payloads/constants.ts index fc0eca252..8930689f9 100644 --- a/packages/restapi/src/lib/payloads/constants.ts +++ b/packages/restapi/src/lib/payloads/constants.ts @@ -46,6 +46,36 @@ export enum NOTIFICATION_TYPE { export enum ADDITIONAL_META_TYPE { CUSTOM = 0, PUSH_VIDEO = 1, + PUSH_SPACE = 2, +} + +// Subset of ADDITIONAL_META_TYPE, to be used exclusively for Push Video, Spaces +export enum VIDEO_CALL_TYPE { + PUSH_VIDEO = 1, + PUSH_SPACE = 2, +} + +export enum SPACE_REQUEST_TYPE { + JOIN_SPEAKER, // space has started, join as a speaker + ESTABLISH_MESH, // request to establish mesh connection + INVITE_TO_PROMOTE, // host invites someone to be promoted as the speaker + REQUEST_TO_PROMOTE, // someone requests the host to be promoted to a spaeker +} + +export enum SPACE_ACCEPT_REQUEST_TYPE { + ACCEPT_JOIN_SPEAKER, + ACCEPT_INVITE, + ACCEPT_PROMOTION, +} + +export enum SPACE_DISCONNECT_TYPE { + STOP, // space is stopped/ended + LEAVE // speaker leaves a space +} + +export enum SPACE_INVITE_ROLES { + CO_HOST, + SPEAKER, } export const DEFAULT_DOMAIN = 'push.org'; diff --git a/packages/restapi/src/lib/payloads/index.ts b/packages/restapi/src/lib/payloads/index.ts index 67ef80fe5..22436ff9a 100644 --- a/packages/restapi/src/lib/payloads/index.ts +++ b/packages/restapi/src/lib/payloads/index.ts @@ -1,2 +1,9 @@ export * from './sendNotifications'; -export {NOTIFICATION_TYPE, IDENTITY_TYPE} from './constants' +export { + NOTIFICATION_TYPE, + IDENTITY_TYPE, + ADDITIONAL_META_TYPE, + SPACE_REQUEST_TYPE, + SPACE_ACCEPT_REQUEST_TYPE, + SPACE_DISCONNECT_TYPE +} from './constants'; diff --git a/packages/restapi/src/lib/space/Space.ts b/packages/restapi/src/lib/space/Space.ts new file mode 100644 index 000000000..942271874 --- /dev/null +++ b/packages/restapi/src/lib/space/Space.ts @@ -0,0 +1,230 @@ +import { produce } from 'immer'; + +import Constants from '../constants'; +import { Video, initVideoCallData } from '../video'; +import { update } from './update'; +import { start } from './start'; +import { inviteToPromote } from './inviteToPromote'; +import { acceptPromotionInvite } from './acceptPromotionInvite'; +import { connectInvitee } from './connectInvitee'; +import { rejectPromotionInvite } from './rejectPromotionInvite'; +import { requestToBePromoted } from './requestToBePromoted'; +import { acceptPromotionRequest } from './acceptPromotionRequest'; +import { rejectPromotionRequest } from './rejectPromotionRequest'; +import { connectPromotor } from './connectPromotor'; +import { addSpeaker } from './addSpeaker'; +import { removeSpeaker } from './removeSpeaker'; +import { join } from './join'; +import { leave } from './leave'; +import { stop } from './stop'; +import { initialize } from './initialize'; +import addToMergedStream from './helpers/addToMergedStream'; + +import { VideoStreamMerger } from 'video-stream-merger'; +import { + ChatStatus, + EnvOptionsType, + SignerType, + SpaceDTO, + SpaceData, +} from '../types'; +import { VIDEO_CALL_TYPE } from '../payloads/constants'; + +const initSpaceSpecificData = { + members: [], + pendingMembers: [], + contractAddressERC20: null, + numberOfERC20: -1, + contractAddressNFT: null, + numberOfNFTTokens: -1, + verificationProof: '', + spaceImage: null, + spaceName: '', + isPublic: false, + spaceDescription: '', + spaceCreator: '', + spaceId: '', + scheduleAt: null, + scheduleEnd: null, + status: null, + inviteeDetails: {}, +}; + +export const initSpaceData = { + ...initSpaceSpecificData, + connectionData: initVideoCallData, +}; + +export interface SpaceConstructorType extends EnvOptionsType { + signer: SignerType; + pgpPrivateKey: string; + chainId: number; + address: string; + setSpaceData: (fn: (data: SpaceData) => SpaceData) => void; +} + +// declaring the Space class + export class Space extends Video { + /* + - temporarily store the streamKey on the class + - will be used by the host to cast to the stream + */ + // protected streamKey: string | null = null; + + protected mergeStreamObject: VideoStreamMerger | null = null; + + protected spaceSpecificData: SpaceDTO; + protected setSpaceSpecificData: (fn: (data: SpaceDTO) => SpaceDTO) => void; + + // will be exposed and should be used from outside the class to change state + setSpaceData: (fn: (data: SpaceData) => SpaceData) => void; + + constructor(options: SpaceConstructorType) { + const { + signer, + pgpPrivateKey, + address, + chainId, + env = Constants.ENV.PROD, + setSpaceData, // to update the 'spaceData' state maintained by the developer + } = options || {}; + + // init the Video class + super({ + signer, + chainId, + pgpPrivateKey, + env, + callType: VIDEO_CALL_TYPE.PUSH_SPACE, + onReceiveStream: (receivedStream: MediaStream) => { + // for a space, that has started broadcast & the local peer is the host + if ( + this.spaceSpecificData.status === ChatStatus.ACTIVE && + this.data.meta.broadcast?.hostAddress && + this.data.meta.broadcast.hostAddress === this.data.local.address + ) { + addToMergedStream(this.mergeStreamObject!, receivedStream); + } + }, + setData: function () { + return; + }, // setData will be overridden below + }); + + // setting state changing functions + + /* + - Will be used internally in the class + - Overriding setData (Video) + - To be used when we only want to modify video call 'data' + */ + this.setData = function (fn) { + const newVideoData = fn(this.data); + + // update the react state + setSpaceData(() => ({ + ...this.spaceSpecificData, + connectionData: newVideoData, + })); + + // update the video class variable + this.data = newVideoData; + }; + + /* + - Will be used internally in the class + - To be used when we only want to modify space specific 'data' + */ + this.setSpaceSpecificData = function (fn) { + const newSpaceSpecificData = fn(this.spaceSpecificData); + + // update the react state + setSpaceData(() => ({ + ...newSpaceSpecificData, + connectionData: this.data, + })); + + // update the video class variable + this.spaceSpecificData = newSpaceSpecificData; + }; + + // set the space state updating function + this.setSpaceData = function (fn) { + const { connectionData: newConnectionData, ...newSpaceSpecificData } = fn( + { + ...this.spaceSpecificData, + connectionData: this.data, + } + ); + + // update the space specific data + this.spaceSpecificData = newSpaceSpecificData; + + // update the video data and update the external state + this.setData(() => newConnectionData); + }; + + // initializing state + + // set the local address inside video call 'data' + this.setData((oldVideoCallData) => { + return produce(oldVideoCallData, (draft) => { + draft.local.address = address; + }); + }); + + // init the state maintained by the developer + setSpaceData(() => initSpaceData); + + // init the spaceSpecificData class variable + this.spaceSpecificData = initSpaceSpecificData; + }; + + + // adding instance methods + + public initialize = initialize; + + public update = update; + + public createAudioStream = async () => { + await this.create({ audio: true, video: false }); + }; + + public start = start; + + // to promote a listener to a speaker/co-host + public inviteToPromote = inviteToPromote; + public acceptPromotionInvite = acceptPromotionInvite; + public connectInvitee = connectInvitee; + public rejectPromotionInvite = rejectPromotionInvite; + + // listener requests to be promoted to a speaker + public requestToBePromoted = requestToBePromoted; + public acceptPromotionRequest = acceptPromotionRequest; + public connectPromotor = connectPromotor; + public rejectPromotionRequest = rejectPromotionRequest; + + /* + - add/remove speaker to the space group as admins + - these methods are only to be used when the space hasnt started yet + */ + public addSpeaker = addSpeaker; + public removeSpeaker = removeSpeaker; + + /* + - add/remove co-host to the space group as admins + - add/remove them from the meta message + - these methods are only to be used when the space hasnt started yet + */ + // public addCoHost = addCoHost; + // public removeCoHost = removeCoHost; + + // add listner to the space group as member + public join = join; + + public leave = leave; + public stop = stop; +} + +export default Space; diff --git a/packages/restapi/src/lib/space/acceptPromotionInvite.ts b/packages/restapi/src/lib/space/acceptPromotionInvite.ts new file mode 100644 index 000000000..bb7765e05 --- /dev/null +++ b/packages/restapi/src/lib/space/acceptPromotionInvite.ts @@ -0,0 +1,28 @@ +import { SPACE_ACCEPT_REQUEST_TYPE } from '../payloads/constants'; +import type Space from './Space'; + +export interface AcceptPromotionInviteType { + signalData: any; + invitorAddress: string; + spaceId: string; +} + +export async function acceptPromotionInvite( + this: Space, + options: AcceptPromotionInviteType +) { + const { signalData, invitorAddress, spaceId } = + options || {}; + + // accept the promotion invite + this.acceptRequest({ + signalData, + senderAddress: this.data.local.address, + recipientAddress: invitorAddress, + chatId: spaceId, + details: { + type: SPACE_ACCEPT_REQUEST_TYPE.ACCEPT_INVITE, + data: {}, + }, + }); +} diff --git a/packages/restapi/src/lib/space/acceptPromotionRequest.ts b/packages/restapi/src/lib/space/acceptPromotionRequest.ts new file mode 100644 index 000000000..1d733d12e --- /dev/null +++ b/packages/restapi/src/lib/space/acceptPromotionRequest.ts @@ -0,0 +1,33 @@ +import { + SPACE_ACCEPT_REQUEST_TYPE, + SPACE_INVITE_ROLES, +} from '../payloads/constants'; +import type Space from './Space'; + +export interface AcceptPromotionRequestType { + signalData: any; + promoteeAddress: string; + role: SPACE_INVITE_ROLES; + spaceId: string; +} + +export async function acceptPromotionRequest( + this: Space, + options: AcceptPromotionRequestType +) { + const { signalData, promoteeAddress, spaceId, role } = options || {}; + + // TODO: change the role of promoteeAddress from listner to 'role' + + // accept the promotion request + this.acceptRequest({ + signalData, + senderAddress: this.data.local.address, + recipientAddress: promoteeAddress, + chatId: spaceId, + details: { + type: SPACE_ACCEPT_REQUEST_TYPE.ACCEPT_PROMOTION, + data: {}, + }, + }); +} diff --git a/packages/restapi/src/lib/space/addSpeaker.ts b/packages/restapi/src/lib/space/addSpeaker.ts new file mode 100644 index 000000000..37924f724 --- /dev/null +++ b/packages/restapi/src/lib/space/addSpeaker.ts @@ -0,0 +1,34 @@ +import { EnvOptionsType } from '../types'; +import { groupDtoToSpaceDto } from '../chat/helpers'; +import { addAdmins } from '../chat/addAdmins'; + +import type Space from './Space'; + +export interface AddSpeakerType extends EnvOptionsType { + address: string; +} + +export async function addSpeaker( + this: Space, + options: AddSpeakerType +): Promise { + const { address } = options; + try { + const group = await addAdmins({ + chatId: this.spaceSpecificData.spaceId, + admins: [address], + signer: this.signer, + env: this.env, + pgpPrivateKey: this.pgpPrivateKey, + }); + + // update space specific data + this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${addSpeaker.name} -: `, + err + ); + throw Error(`[Push SDK] - API - Error - API ${addSpeaker.name} -: ${err}`); + } +} diff --git a/packages/restapi/src/lib/space/addSpeakers.ts b/packages/restapi/src/lib/space/addSpeakers.ts index e7311506d..f7121363f 100644 --- a/packages/restapi/src/lib/space/addSpeakers.ts +++ b/packages/restapi/src/lib/space/addSpeakers.ts @@ -6,16 +6,16 @@ import { addAdmins } from '../chat/addAdmins'; export interface AddSpeakersToSpaceType extends EnvOptionsType { spaceId: string; speakers: Array; - account?: string; - signer?: SignerType; + signer: SignerType; pgpPrivateKey?: string; } -export const addSpeakers = async (options: AddSpeakersToSpaceType): Promise => { +export const addSpeakers = async ( + options: AddSpeakersToSpaceType +): Promise => { const { spaceId, speakers, - account = null, signer = null, env = options?.env ?? Constants.ENV.PROD, pgpPrivateKey = options?.pgpPrivateKey ?? null, @@ -24,11 +24,10 @@ export const addSpeakers = async (options: AddSpeakersToSpaceType): Promise { + return produce(oldData, (draft) => { + if (draft.inviteeDetails) delete draft.inviteeDetails[inviteeAddress]; + }); + }); + // TODO: On backend change the role of inviteeAddress + + // complete the webRTC connection + this.connect({ signalData, peerAddress: inviteeAddress }); +} diff --git a/packages/restapi/src/lib/space/connectPromotor.ts b/packages/restapi/src/lib/space/connectPromotor.ts new file mode 100644 index 000000000..4d3151239 --- /dev/null +++ b/packages/restapi/src/lib/space/connectPromotor.ts @@ -0,0 +1,13 @@ +import type Space from './Space'; + +export interface ConnectPromotorType { + signalData: any; + promotorAddress: string; +} + +export async function connectPromotor(this: Space, options: ConnectPromotorType) { + const { signalData, promotorAddress } = options || {}; + + // complete the webRTC connection + this.connect({ signalData, peerAddress: promotorAddress }); +} diff --git a/packages/restapi/src/lib/space/create.ts b/packages/restapi/src/lib/space/create.ts index 593aae9fe..899bfbe67 100644 --- a/packages/restapi/src/lib/space/create.ts +++ b/packages/restapi/src/lib/space/create.ts @@ -1,13 +1,10 @@ import Constants from '../constants'; import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; -import { - groupDtoToSpaceDto -} from './../chat/helpers'; +import { groupDtoToSpaceDto } from './../chat/helpers'; import { createGroup } from '../chat/createGroup'; export interface ChatCreateSpaceType extends EnvOptionsType { - account?: string; - signer?: SignerType; + signer: SignerType; spaceName: string; spaceDescription: string; members: Array; @@ -20,16 +17,13 @@ export interface ChatCreateSpaceType extends EnvOptionsType { numberOfERC20?: number; pgpPrivateKey?: string; meta?: string; - scheduleAt: Date - scheduleEnd?: Date | null + scheduleAt: Date; + scheduleEnd?: Date | null; } -export const create = async ( - options: ChatCreateSpaceType -): Promise => { +export async function create(options: ChatCreateSpaceType): Promise { const { - account = null, - signer = null, + signer, spaceName, spaceDescription, members, @@ -48,39 +42,29 @@ export const create = async ( } = options || {}; try { - if (account == null && signer == null) { - throw new Error(`At least one from account or signer is necessary!`); - } - - const group = await createGroup({ - account: account, - signer: signer, - groupName: spaceName, - groupDescription: spaceDescription, - members: members, - groupImage: spaceImage, - admins: admins, - isPublic: isPublic, - contractAddressNFT: contractAddressNFT, - numberOfNFTs: numberOfNFTs, - contractAddressERC20: contractAddressERC20, - numberOfERC20: numberOfERC20, - env: env, - pgpPrivateKey: pgpPrivateKey, - meta: meta, - groupType: "spaces", - scheduleAt: scheduleAt, - scheduleEnd: scheduleEnd, + const group = await createGroup({ + signer, + groupName: spaceName, + groupDescription: spaceDescription, + members: members, + groupImage: spaceImage, + admins: admins, + isPublic: isPublic, + contractAddressNFT: contractAddressNFT, + numberOfNFTs: numberOfNFTs, + contractAddressERC20: contractAddressERC20, + numberOfERC20: numberOfERC20, + env, + pgpPrivateKey, + meta: meta, + groupType: 'spaces', + scheduleAt: scheduleAt, + scheduleEnd: scheduleEnd, }); - - return groupDtoToSpaceDto(group) + + return groupDtoToSpaceDto(group); } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${create.name} -: `, - err - ); - throw Error( - `[Push SDK] - API - Error - API ${create.name} -: ${err}` - ); + console.error(`[Push SDK] - API - Error - API ${create.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${create.name} -: ${err}`); } -}; +} diff --git a/packages/restapi/src/lib/space/helpers/addToMergedStream.ts b/packages/restapi/src/lib/space/helpers/addToMergedStream.ts new file mode 100644 index 000000000..9e939e893 --- /dev/null +++ b/packages/restapi/src/lib/space/helpers/addToMergedStream.ts @@ -0,0 +1,10 @@ +import type { VideoStreamMerger } from 'video-stream-merger'; + +const addToMergedStream = ( + mergeObject: VideoStreamMerger, + streamToBeAdded: MediaStream +) => { + mergeObject.addStream(streamToBeAdded, undefined); +}; + +export default addToMergedStream; diff --git a/packages/restapi/src/lib/space/helpers/getMergeStreamObject.ts b/packages/restapi/src/lib/space/helpers/getMergeStreamObject.ts new file mode 100644 index 000000000..a1322f823 --- /dev/null +++ b/packages/restapi/src/lib/space/helpers/getMergeStreamObject.ts @@ -0,0 +1,14 @@ +import { VideoStreamMerger } from 'video-stream-merger'; + +const getMergeStreamObject = (hostStream: MediaStream) => { + const mergeStreamObject = new VideoStreamMerger(); + + // add the audio stream of host + mergeStreamObject.addStream(hostStream, undefined); + + mergeStreamObject.start(); + + return mergeStreamObject; +}; + +export default getMergeStreamObject; diff --git a/packages/restapi/src/lib/space/index.ts b/packages/restapi/src/lib/space/index.ts index 52feea71a..6891e3d60 100644 --- a/packages/restapi/src/lib/space/index.ts +++ b/packages/restapi/src/lib/space/index.ts @@ -1,15 +1,14 @@ -export * from './create'; -export * from './update'; -export * from './info'; +export * from './spaces'; +export * from './trending'; export * from './get'; -export * from './approve'; -export * from './start'; -export * from './stop'; +export * from './info'; +export * from './create'; +export * from './update_out'; export * from './addSpeakers'; -export * from './addListeners'; export * from './removeSpeakers'; +export * from './addListeners'; export * from './removeListeners'; +export * from './approve'; export * from './requests'; -export * from './spaces'; -export * from './trending'; +export * from './Space' diff --git a/packages/restapi/src/lib/space/initialize.ts b/packages/restapi/src/lib/space/initialize.ts new file mode 100644 index 000000000..85f3dc682 --- /dev/null +++ b/packages/restapi/src/lib/space/initialize.ts @@ -0,0 +1,17 @@ +import type Space from './Space'; +import { get } from './get'; + +export interface InitializeType { + spaceId: string; +} + +export async function initialize(this: Space, options: InitializeType) { + const { spaceId } = options || {}; + + const space = await get({ + spaceId, + env: this.env, + }); + + this.setSpaceSpecificData(() => space); +} diff --git a/packages/restapi/src/lib/space/inviteToPromote.ts b/packages/restapi/src/lib/space/inviteToPromote.ts new file mode 100644 index 000000000..dd5644be3 --- /dev/null +++ b/packages/restapi/src/lib/space/inviteToPromote.ts @@ -0,0 +1,35 @@ +import { produce } from 'immer'; +import { SPACE_INVITE_ROLES, SPACE_REQUEST_TYPE } from '../payloads/constants'; +import type Space from './Space'; + +export interface InviteToPromoteType { + inviteeAddress: string; + role: SPACE_INVITE_ROLES; +} + +export async function inviteToPromote( + this: Space, + options: InviteToPromoteType +) { + const { inviteeAddress, role } = options || {}; + + // adding address to the invitee map + this.setSpaceSpecificData((oldData) => { + return produce(oldData, (draft) => { + if (draft.inviteeDetails) draft.inviteeDetails[inviteeAddress] = role; + }); + }); + + // we send a request to 'inviteeAddress' and try to add them to the mesh connection + this.request({ + senderAddress: this.data.local.address, + recipientAddress: inviteeAddress, + chatId: this.spaceSpecificData.spaceId, + details: { + type: SPACE_REQUEST_TYPE.INVITE_TO_PROMOTE, + data: { + role, + }, + }, + }); +} diff --git a/packages/restapi/src/lib/space/join.ts b/packages/restapi/src/lib/space/join.ts new file mode 100644 index 000000000..d1b640595 --- /dev/null +++ b/packages/restapi/src/lib/space/join.ts @@ -0,0 +1,96 @@ +import { SPACE_ACCEPT_REQUEST_TYPE } from '../payloads/constants'; +import { ChatStatus } from '../types'; +import { VideoDataType } from '../video/helpers/sendVideoCallNotification'; +import { approve } from './approve'; +import { get } from './get'; +import type Space from './Space'; + +export interface JoinSpaceType { + recievedVideoData?: VideoDataType; // only required when joining as a speaker +} + +/** + * + * @param options + * recievedVideoData: only required when joining as a speaker + */ +export async function join(this: Space, options: JoinSpaceType) { + const { recievedVideoData = null } = options || {}; + + try { + const space = await get({ + spaceId: this.spaceSpecificData.spaceId, + env: this.env, + }); + + if (space.status !== ChatStatus.ACTIVE) + throw new Error('Space not active yet'); + + // checking what is the current role of caller address + + let isSpeaker = false; + let isListner = false; + space.members.forEach((member) => { + if (member.wallet === this.data.local.address) { + if (member.isSpeaker) { + isSpeaker = true; + } else { + isListner = true; + } + } + }); + let isSpeakerPending = false; + space.pendingMembers.forEach((pendingMember) => { + if ( + pendingMember.wallet === this.data.local.address && + pendingMember.isSpeaker + ) { + isSpeakerPending = true; + } + }); + + // acc to the found role (speaker or listner), executing req logic + + // if speaker is pending then approve first or if listner is pending/not found then approve first + if (isSpeakerPending || !isListner) { + await approve({ + signer: this.signer, + pgpPrivateKey: this.pgpPrivateKey, + senderAddress: this.spaceSpecificData.spaceId, + env: this.env + }); + } + + if (isSpeaker || isSpeakerPending) { + if (!recievedVideoData) + throw new Error('Joining as a speaker failed due to bad video data'); + + if (recievedVideoData.chatId !== this.spaceSpecificData.spaceId) + throw new Error( + 'Joining as a speaker failed due to mismatch in space id' + ); + + // call acceptRequest to initiate connection + await this.acceptRequest({ + senderAddress: recievedVideoData.recipientAddress, + recipientAddress: recievedVideoData.senderAddress, + signalData: recievedVideoData.signalData, + chatId: recievedVideoData.chatId, + details: { + type: SPACE_ACCEPT_REQUEST_TYPE.ACCEPT_JOIN_SPEAKER, + data: {}, + }, + }); + } + + const updatedSpace = await get({ + spaceId: this.spaceSpecificData.spaceId, + env: this.env, + }); + // update space specific data + this.setSpaceSpecificData(() => updatedSpace); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${join.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${join.name} -: ${err}`); + } +} diff --git a/packages/restapi/src/lib/space/leave.ts b/packages/restapi/src/lib/space/leave.ts new file mode 100644 index 000000000..53b85d56e --- /dev/null +++ b/packages/restapi/src/lib/space/leave.ts @@ -0,0 +1,34 @@ +import { + groupDtoToSpaceDto, + getMembersList, + getAdminsList, +} from '../chat/helpers'; +import { updateGroup } from '../chat/updateGroup'; +import { get } from './get'; + +import type Space from './Space'; +import { SPACE_DISCONNECT_TYPE } from '../payloads/constants'; + +export async function leave(this: Space): Promise { + try { + // should be only called by the host or the speakers + + // if the host is leaving then we need to make someone else the host + + // handle the case where a listner is leaving + + // disconnect with every incoming peer in the mesh connection + this.data.incoming.forEach(({ address }) => { + this.disconnect({ + peerAddress: address, + details: { + type: SPACE_DISCONNECT_TYPE.LEAVE, + data: {}, + }, + }); + }); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${stop.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${stop.name} -: ${err}`); + } +} diff --git a/packages/restapi/src/lib/space/rejectPromotionInvite.ts b/packages/restapi/src/lib/space/rejectPromotionInvite.ts new file mode 100644 index 000000000..6eff90156 --- /dev/null +++ b/packages/restapi/src/lib/space/rejectPromotionInvite.ts @@ -0,0 +1,18 @@ +import type Space from './Space'; + +export interface RejectPromotionInviteType { + invitorAddress: string; +} + +export async function rejectPromotionInvite( + this: Space, + options: RejectPromotionInviteType +) { + const { invitorAddress } = + options || {}; + + // reject the promotion invite + this.disconnect({ + peerAddress: invitorAddress, + }); +} diff --git a/packages/restapi/src/lib/space/rejectPromotionRequest.ts b/packages/restapi/src/lib/space/rejectPromotionRequest.ts new file mode 100644 index 000000000..b4eddee56 --- /dev/null +++ b/packages/restapi/src/lib/space/rejectPromotionRequest.ts @@ -0,0 +1,17 @@ +import type Space from './Space'; + +export interface RejectPromotionRequestType { + promoteeAddress: string; +} + +export async function rejectPromotionRequest( + this: Space, + options: RejectPromotionRequestType +) { + const { promoteeAddress } = options || {}; + + // reject the promotion request + this.disconnect({ + peerAddress: promoteeAddress, + }); +} diff --git a/packages/restapi/src/lib/space/removeSpeaker.ts b/packages/restapi/src/lib/space/removeSpeaker.ts new file mode 100644 index 000000000..84c214d02 --- /dev/null +++ b/packages/restapi/src/lib/space/removeSpeaker.ts @@ -0,0 +1,37 @@ +import { EnvOptionsType } from '../types'; +import { groupDtoToSpaceDto } from '../chat/helpers'; +import { + removeAdmins +} from '../chat/removeAdmins'; +import type Space from './Space'; + +export interface RemoveSpeakerType extends EnvOptionsType { + address: string; +} + +export async function removeSpeaker( + this: Space, + options: RemoveSpeakerType +): Promise { + const { address } = options; + try { + const group = await removeAdmins({ + chatId: this.spaceSpecificData.spaceId, + admins: [address], + signer: this.signer, + env: this.env, + pgpPrivateKey: this.pgpPrivateKey, + }); + + // update space specific data + this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${removeSpeaker.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${removeSpeaker.name} -: ${err}` + ); + } +} diff --git a/packages/restapi/src/lib/space/removeSpeakers.ts b/packages/restapi/src/lib/space/removeSpeakers.ts index 79cd12e58..e72137957 100644 --- a/packages/restapi/src/lib/space/removeSpeakers.ts +++ b/packages/restapi/src/lib/space/removeSpeakers.ts @@ -1,52 +1,41 @@ import Constants from '../constants'; -import { - EnvOptionsType, - SignerType, - SpaceDTO -} from '../types'; -import { - groupDtoToSpaceDto -} from '../chat/helpers'; -import { - removeAdmins -} from '../chat/removeAdmins'; +import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; +import { groupDtoToSpaceDto } from '../chat/helpers'; +import { removeAdmins } from '../chat/removeAdmins'; export interface RemoveSpeakersFromSpaceType extends EnvOptionsType { spaceId: string; - speakers: Array < string > ; - account ? : string; - signer ? : SignerType; - pgpPrivateKey ? : string; + speakers: Array; + signer: SignerType; + pgpPrivateKey?: string; } export const removeSpeakers = async ( options: RemoveSpeakersFromSpaceType -): Promise < SpaceDTO > => { +): Promise => { const { - spaceId, - speakers, - account = null, - signer = null, - env = Constants.ENV.PROD, - pgpPrivateKey = null, + spaceId, + speakers, + signer = null, + env = Constants.ENV.PROD, + pgpPrivateKey = null, } = options || {}; try { - const group = await removeAdmins({ - chatId: spaceId, - admins: speakers, - account: account, - signer: signer, - env: env, - pgpPrivateKey: pgpPrivateKey - }); + const group = await removeAdmins({ + chatId: spaceId, + admins: speakers, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey, + }); - return groupDtoToSpaceDto(group); + return groupDtoToSpaceDto(group); } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${removeSpeakers.name} -: `, - err - ); - throw Error( - `[Push SDK] - API - Error - API ${removeSpeakers.name} -: ${err}` - ); + console.error( + `[Push SDK] - API - Error - API ${removeSpeakers.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${removeSpeakers.name} -: ${err}` + ); } -}; \ No newline at end of file +}; diff --git a/packages/restapi/src/lib/space/requestToBePromoted.ts b/packages/restapi/src/lib/space/requestToBePromoted.ts new file mode 100644 index 000000000..b52992841 --- /dev/null +++ b/packages/restapi/src/lib/space/requestToBePromoted.ts @@ -0,0 +1,28 @@ +import { SPACE_INVITE_ROLES, SPACE_REQUEST_TYPE } from '../payloads/constants'; +import type Space from './Space'; + +export interface RequestToBePromotedType { + role: SPACE_INVITE_ROLES; + spaceId: string; + promotorAddress: string; +} + +export async function requestToBePromoted( + this: Space, + options: RequestToBePromotedType +) { + const { role, spaceId, promotorAddress } = options || {}; + + // requesting host to include local computer into the mesh connection + this.request({ + senderAddress: this.data.local.address, + recipientAddress: promotorAddress, + chatId: spaceId, + details: { + type: SPACE_REQUEST_TYPE.REQUEST_TO_PROMOTE, + data: { + role, + }, + }, + }); +} diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts index d98e4889e..5d5d3c2db 100644 --- a/packages/restapi/src/lib/space/start.ts +++ b/packages/restapi/src/lib/space/start.ts @@ -1,83 +1,161 @@ -import Constants from '../constants'; +import { EnvOptionsType, SignerType, ChatStatus } from '../types'; import { - EnvOptionsType, - SpaceDTO, - SignerType, - ChatStatus -} from '../types'; -import { - groupDtoToSpaceDto, - getSpacesMembersList, - getSpaceAdminsList + groupDtoToSpaceDto, + getSpacesMembersList, + getSpaceAdminsList, } from './../chat/helpers'; -import { - get -} from './get'; -import { - updateGroup -} from '../chat/updateGroup'; +import { get } from './get'; +import { updateGroup } from '../chat/updateGroup'; +import getMergeStreamObject from './helpers/getMergeStreamObject'; +import axios from 'axios'; +import { Client, isSupported } from '@livepeer/webrtmp-sdk'; + export interface StartSpaceType extends EnvOptionsType { - spaceId: string; - account ? : string; - signer ? : SignerType; - pgpPrivateKey ? : string; + spaceId: string; + account?: string; + signer?: SignerType; + pgpPrivateKey?: string; } -export const start = async ( - options: StartSpaceType -): Promise < SpaceDTO > => { - const { - spaceId, - account = null, - signer = null, - env = Constants.ENV.PROD, - pgpPrivateKey = null, - } = options || {}; - try { - if (account == null && signer == null) { - throw new Error(`At least one from account or signer is necessary!`); - } +import type Space from './Space'; +import { SPACE_REQUEST_TYPE } from '../payloads/constants'; +import { produce } from 'immer'; + +type StartType = { + livepeerApiKey: string; +}; + +export async function start(this: Space, options: StartType): Promise { + const { livepeerApiKey } = options || {}; + + try { + // TODO: Only allow the host to execute this function + + // host should have there audio stream + if (!this.data.local.stream) { + throw new Error('Local audio stream not found'); + } + + const space = await get({ + spaceId: this.spaceSpecificData.spaceId, + env: this.env, + }); + + if (space.status !== ChatStatus.PENDING) { + throw new Error( + 'Unable to start the space as it is not in the pending state' + ); + } + + const convertedMembers = getSpacesMembersList( + space.members, + space.pendingMembers + ); + const convertedAdmins = getSpaceAdminsList( + space.members, + space.pendingMembers + ); - const space = await get({ - spaceId: spaceId, - env, - }) + const group = await updateGroup({ + chatId: this.spaceSpecificData.spaceId, + groupName: space.spaceName, + groupImage: space.spaceImage, + groupDescription: space.spaceDescription, + members: convertedMembers, + admins: convertedAdmins, + signer: this.signer, + env: this.env, + pgpPrivateKey: this.pgpPrivateKey, + scheduleAt: space.scheduleAt, + scheduleEnd: space.scheduleEnd, + status: ChatStatus.ACTIVE, + }); - if (space.status !== ChatStatus.PENDING) { - throw new Error("Unable to start the space as it is not in the pending state"); + // update space data + this.setSpaceData((oldSpaceData) => { + return produce(oldSpaceData, (draft) => { + draft = { + ...groupDtoToSpaceDto(group), + connectionData: draft.connectionData, + }; + draft.connectionData.meta.broadcast = { + livepeerInfo: null, + hostAddress: this.data.local.address, + }; + }); + }); + + /* + - Try calling all the speakers (admins) + - Create a mesh based webRTC connection with all those who pick up + */ + this.request({ + senderAddress: this.data.local.address, + recipientAddress: convertedAdmins.map((convertedAdmin) => { + if (convertedAdmin.startsWith('eip155:')) { + return convertedAdmin.split('eip155:')[1]; } + return convertedAdmin; + }), + chatId: this.spaceSpecificData.spaceId, + details: { + type: SPACE_REQUEST_TYPE.JOIN_SPEAKER, + data: {}, + }, + }); + + // start the livepeer playback and store the playback URL group meta + // send a notification/meta message to all the added listeners (members) telling the space has started + + // create the mergeStream object + const mergeStreamObject = getMergeStreamObject(this.data.local.stream); + // store the mergeStreamObject + this.mergeStreamObject = mergeStreamObject; + + const url = 'https://livepeer.studio/api/stream'; + const data = { + name: this.spaceSpecificData.spaceName, + record: true, + }; + + const { data: responseData } = await axios.post(url, data, { + headers: { + Authorization: 'Bearer ' + livepeerApiKey, + }, + }); + + const { streamKey, playbackId } = responseData; + + console.log('livepeer details', streamKey, playbackId); - const convertedMembers = getSpacesMembersList( - space.members, space.pendingMembers - ); - const convertedAdmins = getSpaceAdminsList( - space.members, space.pendingMembers - ); - - const group = await updateGroup({ - chatId: spaceId, - groupName: space.spaceName, - groupImage: space.spaceImage, - groupDescription: space.spaceDescription, - members: convertedMembers, - admins: convertedAdmins, - account: account, - signer: signer, - env: env, - pgpPrivateKey: pgpPrivateKey, - scheduleAt: space.scheduleAt, - scheduleEnd: space.scheduleEnd, - status: ChatStatus.ACTIVE - }); - - return groupDtoToSpaceDto(group); - } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${start.name} -: `, - err - ); - throw Error( - `[Push SDK] - API - Error - API ${start.name} -: ${err}` - ); + // TODO: store the playbackId on group meta data, temp -> groupDescription + this.update({ spaceDescription: playbackId }); + + if (!isSupported()) { + console.log('webrtmp-sdk is not currently supported on this browser'); } -}; \ No newline at end of file + + console.log('stream key', streamKey); + + // cast to the stream + const client = new Client(); + const session = client.cast(mergeStreamObject.result!, streamKey); + session.on('open', () => { + console.log('Live stream started.'); + // TODO: Update the space data + }); + + session.on('close', () => { + console.log('Live stream stopped.'); + // TODO: Update the space data + }); + + session.on('error', (err) => { + console.log('Live stream error.', err.message); + // TODO: Update the space data + }); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${start.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${start.name} -: ${err}`); + } +} diff --git a/packages/restapi/src/lib/space/stop.ts b/packages/restapi/src/lib/space/stop.ts index 828c34f09..4f69914ec 100644 --- a/packages/restapi/src/lib/space/stop.ts +++ b/packages/restapi/src/lib/space/stop.ts @@ -1,83 +1,72 @@ -import Constants from '../constants'; import { - EnvOptionsType, - SpaceDTO, - SignerType, - ChatStatus -} from '../types'; -import { - groupDtoToSpaceDto, - getSpacesMembersList, - getSpaceAdminsList + groupDtoToSpaceDto, + getSpacesMembersList, + getSpaceAdminsList, } from '../chat/helpers'; -import { - updateGroup -} from '../chat/updateGroup'; -import { - get -} from './get'; -export interface StopSpaceType extends EnvOptionsType { - spaceId: string; - account ? : string; - signer ? : SignerType; - pgpPrivateKey ? : string; -} +import { updateGroup } from '../chat/updateGroup'; +import { get } from './get'; + +import type Space from './Space'; +import { ChatStatus } from '../types'; +import { SPACE_DISCONNECT_TYPE } from '../payloads/constants'; -export const stop = async ( - options: StopSpaceType -): Promise < SpaceDTO > => { - const { - spaceId, - account = null, - signer = null, - env = Constants.ENV.PROD, - pgpPrivateKey = null, - } = options || {}; - try { - if (account == null && signer == null) { - throw new Error(`At least one from account or signer is necessary!`); - } +export async function stop(this: Space): Promise { + try { + // should be only called by the host - const space = await get({ - spaceId: spaceId, - env, - }) + const space = await get({ + spaceId: this.spaceSpecificData.spaceId, + env: this.env, + }); - if (space.status === ChatStatus.ENDED) { - throw new Error("Space already ended"); - } + if (space.status === ChatStatus.ENDED) { + throw new Error('Space already ended'); + } - const convertedMembers = getSpacesMembersList( - space.members, space.pendingMembers - ); - const convertedAdmins = getSpaceAdminsList( - space.members, space.pendingMembers - ); + const convertedMembers = getSpacesMembersList( + space.members, + space.pendingMembers + ); + const convertedAdmins = getSpaceAdminsList( + space.members, + space.pendingMembers + ); - const group = await updateGroup({ - chatId: spaceId, - groupName: space.spaceName, - groupImage: space.spaceImage, - groupDescription: space.spaceDescription, - members: convertedMembers, - admins: convertedAdmins, - account: account, - signer: signer, - env: env, - pgpPrivateKey: pgpPrivateKey, - scheduleAt: space.scheduleAt, - scheduleEnd: space.scheduleEnd, - status: ChatStatus.ENDED - }); + const group = await updateGroup({ + chatId: this.spaceSpecificData.spaceId, + groupName: space.spaceName, + groupImage: space.spaceImage, + groupDescription: space.spaceDescription, + members: convertedMembers, + admins: convertedAdmins, + signer: this.signer, + env: this.env, + pgpPrivateKey: this.pgpPrivateKey, + scheduleAt: space.scheduleAt, + scheduleEnd: space.scheduleEnd, + status: ChatStatus.ENDED, + }); - return groupDtoToSpaceDto(group); - } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${stop.name} -: `, - err - ); - throw Error( - `[Push SDK] - API - Error - API ${stop.name} -: ${err}` - ); - } -}; + // update space specific data + this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); + + // stop livepeer playback + + /* + - disconnect with every incoming peer in the mesh connection + - other peers should also end their connections as we want to destroy the mesh connection + */ + this.data.incoming.forEach(({ address }) => { + this.disconnect({ + peerAddress: address, + details: { + type: SPACE_DISCONNECT_TYPE.STOP, + data: {}, + }, + }); + }); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${stop.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${stop.name} -: ${err}`); + } +} diff --git a/packages/restapi/src/lib/space/update.ts b/packages/restapi/src/lib/space/update.ts index a7c54fa7f..266baf456 100644 --- a/packages/restapi/src/lib/space/update.ts +++ b/packages/restapi/src/lib/space/update.ts @@ -1,78 +1,71 @@ -import Constants from '../constants'; +import { ChatStatus } from '../types'; import { - EnvOptionsType, - SpaceDTO, - SignerType, - ChatStatus -} from '../types'; -import { - groupDtoToSpaceDto, + getSpaceAdminsList, + getSpacesMembersList, + groupDtoToSpaceDto, } from './../chat/helpers'; -import { - updateGroup -} from '../chat/updateGroup'; +import { updateGroup } from '../chat/updateGroup'; +import { get } from './get'; + +import type Space from './Space'; -export interface ChatUpdateSpaceType extends EnvOptionsType { - account ? : string; - signer ? : SignerType; - spaceId: string; - spaceName: string; - spaceImage: string | null; - spaceDescription: string; - members: Array < string > ; - admins: Array < string > ; - pgpPrivateKey ? : string; - scheduleAt: Date - scheduleEnd ? : Date | null - status: ChatStatus +export interface ChatUpdateSpaceType { + spaceName?: string; + spaceImage?: string | null; + spaceDescription?: string; + scheduleAt?: Date; + scheduleEnd?: Date | null; } -export const update = async ( - options: ChatUpdateSpaceType -): Promise < SpaceDTO > => { - const { - spaceId, - spaceName, - spaceImage, - spaceDescription, - members, - admins, - account = null, - signer = null, - env = Constants.ENV.PROD, - pgpPrivateKey = null, - scheduleAt, - scheduleEnd, - status, - } = options || {}; - try { - if (account == null && signer == null) { - throw new Error(`At least one from account or signer is necessary!`); - } - const group = await updateGroup({ - chatId: spaceId, - groupName: spaceName, - groupImage: spaceImage, - groupDescription: spaceDescription, - members: members, - admins: admins, - account: account, - signer: signer, - env: env, - pgpPrivateKey: pgpPrivateKey, - scheduleAt: scheduleAt, - scheduleEnd: scheduleEnd, - status: status - }); +export async function update( + this: Space, + options: ChatUpdateSpaceType +): Promise { + const { spaceName, spaceImage, spaceDescription, scheduleAt, scheduleEnd } = + options || {}; + try { + const space = await get({ + spaceId: this.spaceSpecificData.spaceId, + env: this.env, + }); - return groupDtoToSpaceDto(group); - } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${update.name} -: `, - err - ); - throw Error( - `[Push SDK] - API - Error - API ${update.name} -: ${err}` - ); + const convertedMembers = getSpacesMembersList( + space.members, + space.pendingMembers + ); + const convertedAdmins = getSpaceAdminsList( + space.members, + space.pendingMembers + ); + + if (space.status === ChatStatus.ACTIVE && scheduleAt) { + throw new Error('Unable change the start date/time of an active space'); } -}; \ No newline at end of file + + if (space.status === ChatStatus.ENDED && scheduleEnd) { + throw new Error('Unable change the end date/time of an ended space'); + } + + const group = await updateGroup({ + chatId: this.spaceSpecificData.spaceId, + groupName: spaceName ? spaceName : space.spaceName, + groupImage: spaceImage ? spaceImage : space.spaceImage, + groupDescription: spaceDescription + ? spaceDescription + : space.spaceDescription, + members: convertedMembers, + admins: convertedAdmins, + signer: this.signer, + env: this.env, + pgpPrivateKey: this.pgpPrivateKey, + scheduleAt: scheduleAt ? scheduleAt : space.scheduleAt, + scheduleEnd: scheduleEnd ? scheduleEnd : space.scheduleEnd, + }); + + // update space specific data + this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${update.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${update.name} -: ${err}`); + } +} diff --git a/packages/restapi/src/lib/space/update_out.ts b/packages/restapi/src/lib/space/update_out.ts new file mode 100644 index 000000000..66e6e6f7a --- /dev/null +++ b/packages/restapi/src/lib/space/update_out.ts @@ -0,0 +1,72 @@ +import Constants from '../constants'; +import { EnvOptionsType, SpaceDTO, SignerType, ChatStatus } from '../types'; +import { groupDtoToSpaceDto } from './../chat/helpers'; +import { updateGroup } from '../chat/updateGroup'; +import { get } from './get'; + +export interface ChatUpdateSpaceType extends EnvOptionsType { + signer: SignerType; + spaceId: string; + spaceName: string; + spaceImage: string | null; + spaceDescription: string; + members: Array; + admins: Array; + pgpPrivateKey?: string; + scheduleAt: Date; + scheduleEnd?: Date | null; + status: ChatStatus; +} + +export const update = async ( + options: ChatUpdateSpaceType +): Promise => { + const { + spaceId, + spaceName, + spaceImage, + spaceDescription, + members, + admins, + signer, + env = Constants.ENV.PROD, + pgpPrivateKey = null, + scheduleAt, + scheduleEnd, + status, + } = options || {}; + try { + const space = await get({ + spaceId, + env, + }); + + if (space.status === ChatStatus.ACTIVE && scheduleAt) { + throw new Error('Unable change the start date/time of an active space'); + } + + if (space.status === ChatStatus.ENDED && scheduleEnd) { + throw new Error('Unable change the end date/time of an ended space'); + } + + const group = await updateGroup({ + chatId: spaceId, + groupName: spaceName, + groupImage: spaceImage, + groupDescription: spaceDescription, + members: members, + admins: admins, + signer: signer, + env: env, + pgpPrivateKey: pgpPrivateKey, + scheduleAt: scheduleAt, + scheduleEnd: scheduleEnd, + status: status, + }); + + return groupDtoToSpaceDto(group); + } catch (err) { + console.error(`[Push SDK] - API - Error - API ${update.name} -: `, err); + throw Error(`[Push SDK] - API - Error - API ${update.name} -: ${err}`); + } +}; diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 48c643a85..a3b440803 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -3,6 +3,10 @@ import { ADDITIONAL_META_TYPE, IDENTITY_TYPE, NOTIFICATION_TYPE, + SPACE_ACCEPT_REQUEST_TYPE, + SPACE_DISCONNECT_TYPE, + SPACE_INVITE_ROLES, + SPACE_REQUEST_TYPE, } from '../../lib/payloads/constants'; import { ENV, MessageType } from '../constants'; import { EthEncryptedData } from '@metamask/eth-sig-util'; @@ -360,7 +364,12 @@ export interface SpaceDTO { spaceId: string; scheduleAt?: Date | null; scheduleEnd?: Date | null; - status: ChatStatus | null + status: ChatStatus | null; + inviteeDetails?: { [key: string]: SPACE_INVITE_ROLES }; +} + +export interface SpaceData extends SpaceDTO { + connectionData: VideoCallData; } export interface Subscribers { @@ -540,7 +549,7 @@ export type VideoCallData = { broadcast?: { livepeerInfo: any; hostAddress: string; - coHostAddress: string; + coHostAddress?: string; }; }; local: { @@ -549,7 +558,7 @@ export type VideoCallData = { video: boolean | null; address: string; }; - incoming: [PeerData]; + incoming: PeerData[]; }; export type VideoCreateInputOptions = { @@ -560,10 +569,14 @@ export type VideoCreateInputOptions = { export type VideoRequestInputOptions = { senderAddress: string; - recipientAddress: string; + recipientAddress: string | string[]; chatId: string; onReceiveMessage?: (message: string) => void; retry?: boolean; + details?: { + type: SPACE_REQUEST_TYPE; + data: Record; + }; }; export type VideoAcceptRequestInputOptions = { @@ -573,16 +586,31 @@ export type VideoAcceptRequestInputOptions = { chatId: string; onReceiveMessage?: (message: string) => void; retry?: boolean; + details?: { + type: SPACE_ACCEPT_REQUEST_TYPE; + data: Record; + }; }; export type VideoConnectInputOptions = { signalData: any; + peerAddress: string; +}; + +export type VideoDisconnectOptions = { + peerAddress: string; + details?: { + type: SPACE_DISCONNECT_TYPE; + data: Record; + }; }; export type EnableVideoInputOptions = { state: boolean; + peerAddress: string; }; export type EnableAudioInputOptions = { state: boolean; + peerAddress: string; }; diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index 92e5fb349..f1d340979 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -25,7 +25,16 @@ import { VideoCallStatus, EnableAudioInputOptions, EnableVideoInputOptions, + VideoDisconnectOptions, } from '../types'; +import getIncomingIndexFromAddress from './helpers/getIncomingIndexFromAddress'; +import getConnectedAddresses from './helpers/getConnectedAddresses'; +import getConnectToAddresses from './helpers/getConnectToAddresses'; +import { + SPACE_DISCONNECT_TYPE, + SPACE_REQUEST_TYPE, + VIDEO_CALL_TYPE, +} from '../payloads/constants'; export const initVideoCallData: VideoCallData = { meta: { @@ -34,6 +43,11 @@ export const initVideoCallData: VideoCallData = { address: '', signal: null, }, + broadcast: { + livepeerInfo: null, + hostAddress: '', + coHostAddress: '', + }, }, local: { stream: null, @@ -55,34 +69,46 @@ export const initVideoCallData: VideoCallData = { export class Video { // user, call related info - private signer: SignerType; - private chainId: number; - private pgpPrivateKey: string; - private env: ENV; + protected signer: SignerType; + protected chainId: number; + protected pgpPrivateKey: string; + protected env: ENV; + protected callType: VIDEO_CALL_TYPE; + protected onReceiveStream: (receivedStream: MediaStream) => void; // storing the peer instance - private peerInstance: any = null; + private peerInstances: { + [key: string]: any; + } = {}; - private data: VideoCallData; + protected data: VideoCallData; setData: (fn: (data: VideoCallData) => VideoCallData) => void; constructor({ signer, chainId, pgpPrivateKey, - env, + env = Constants.ENV.PROD, setData, + callType = VIDEO_CALL_TYPE.PUSH_VIDEO, + onReceiveStream = () => { + return; + }, }: { signer: SignerType; chainId: number; pgpPrivateKey: string; - env?: ENV; setData: (fn: (data: VideoCallData) => VideoCallData) => void; + env?: ENV; + callType?: VIDEO_CALL_TYPE; + onReceiveStream?: (receivedStream: MediaStream) => void; }) { this.signer = signer; this.chainId = chainId; this.pgpPrivateKey = pgpPrivateKey; - this.env = env ? env : Constants.ENV.PROD; + this.env = env; + this.callType = callType; + this.onReceiveStream = onReceiveStream; // init the react state setData(() => initVideoCallData); @@ -127,165 +153,260 @@ export class Video { async request(options: VideoRequestInputOptions): Promise { const { - senderAddress, // notification sender - recipientAddress, // notification receiver + senderAddress, + recipientAddress, chatId, onReceiveMessage = (message: string) => { console.log('received a meesage', message); }, retry = false, + details, } = options || {}; - try { - console.log( - 'request', - 'options', - options, - 'localStream', - this.data.local.stream - ); - - // fetching the iceServers config - const iceServerConfig = await getIceServerConfig(this.env); + console.log('request', 'options', options); - this.peerInstance = new Peer({ - initiator: true, - trickle: false, - stream: this.data.local.stream, - config: { - iceServers: iceServerConfig, - }, - }); + const recipientAddresses = Array.isArray(recipientAddress) + ? recipientAddress + : [recipientAddress]; - this.peerInstance.on('signal', (data: any) => { + for (const recipientAddress of recipientAddresses) { + try { + // set videoCallInfo state with status 1 (call initiated) this.setData((oldData) => { return produce(oldData, (draft) => { - draft.meta.initiator.signal = data; + draft.local.address = senderAddress; + draft.meta.chatId = chatId; + draft.meta.initiator.address = senderAddress; + + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + + if (incomingIndex === -1) { + draft.incoming.push({ + stream: null, + audio: null, + video: null, + address: recipientAddress, + status: retry + ? VideoCallStatus.RETRY_INITIALIZED + : VideoCallStatus.INITIALIZED, + retryCount: retry ? 1 : 0, + }); + } else { + draft.incoming[incomingIndex].address = recipientAddress; + draft.incoming[incomingIndex].status = retry + ? VideoCallStatus.RETRY_INITIALIZED + : VideoCallStatus.INITIALIZED; + draft.incoming[incomingIndex].retryCount += retry ? 1 : 0; + } }); }); - // sending notification to the recipientAddress with video call signaling data - sendVideoCallNotification( - { - signer: this.signer, - chainId: this.chainId, - pgpPrivateKey: this.pgpPrivateKey, + // fetching the iceServers config + const iceServerConfig = await getIceServerConfig(this.env); + this.peerInstances[recipientAddress] = new Peer({ + initiator: true, + trickle: false, + stream: this.data.local.stream, + config: { + iceServers: iceServerConfig, }, - { - senderAddress, - recipientAddress, - status: retry - ? VideoCallStatus.RETRY_INITIALIZED - : VideoCallStatus.INITIALIZED, - chatId, - signalData: data, - env: this.env, - } - ); - }); + }); - this.peerInstance.on('connect', () => { - this.peerInstance.send(`initial message from ${senderAddress}`); - this.peerInstance.send( - JSON.stringify({ - type: 'isVideoOn', - isVideoOn: this.data.local.video, - }) - ); - this.peerInstance.send( - JSON.stringify({ - type: 'isAudioOn', - isAudioOn: this.data.local.audio, - }) - ); - }); + this.peerInstances[recipientAddress].on('signal', (data: any) => { + this.setData((oldData) => { + return produce(oldData, (draft) => { + draft.meta.initiator.signal = data; + }); + }); - this.peerInstance.on('data', (data: any) => { - if (isJSON(data)) { - const parsedData = JSON.parse(data); - if (parsedData.type === 'isVideoOn') { - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.incoming[0].video = parsedData.isVideoOn; + // sending notification to the recipientAddress with video call signaling data + sendVideoCallNotification( + { + signer: this.signer, + chainId: this.chainId, + pgpPrivateKey: this.pgpPrivateKey, + }, + { + senderAddress, + recipientAddress, + status: retry + ? VideoCallStatus.RETRY_INITIALIZED + : VideoCallStatus.INITIALIZED, + chatId, + signalData: data, + env: this.env, + callType: this.callType, + callDetails: details, + } + ); + }); + + this.peerInstances[recipientAddress].on('connect', () => { + this.peerInstances[recipientAddress].send( + JSON.stringify({ + type: 'isVideoOn', + value: this.data.local.video, + }) + ); + this.peerInstances[recipientAddress].send( + JSON.stringify({ + type: 'isAudioOn', + value: this.data.local.audio, + }) + ); + }); + + this.peerInstances[recipientAddress].on('data', (data: any) => { + if (isJSON(data)) { + const parsedData = JSON.parse(data); + + if (parsedData.type === 'connectedAddress') { + console.log('CONNECTED ADDRESSES', parsedData.value); + + const receivedConnectedAddresses = parsedData.value; + const localConnectedAddresses = getConnectedAddresses({ + incomingPeers: this.data.incoming, }); - }); - } - if (parsedData.type === 'isAudioOn') { - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.incoming[0].audio = parsedData.isAudioOn; + // find out the address to which local peer is not connected to but the remote peer is + // then connect with them + const connectToAddresses = getConnectToAddresses({ + localAddress: senderAddress, + localConnectedAddresses, + receivedConnectedAddresses, }); - }); - } + for (const connectToAddress of connectToAddresses) { + this.request({ + senderAddress, + recipientAddress: connectToAddress, + chatId, + details: { + type: SPACE_REQUEST_TYPE.ESTABLISH_MESH, + data: {}, + }, + }); + } + } - if (parsedData.type === 'endCall') { - // destroy the peerInstance - this.peerInstance?.destroy(); - this.peerInstance = null; + if (parsedData.type === 'isVideoOn') { + console.log('IS VIDEO ON', parsedData.value); + this.setData((oldData) => { + return produce(oldData, (draft) => { + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].video = parsedData.value; + }); + }); + } - // destroy the local stream - if (this.data.local.stream) { - endStream(this.data.local.stream); + if (parsedData.type === 'isAudioOn') { + console.log('IS AUDIO ON', parsedData.value); + this.setData((oldData) => { + return produce(oldData, (draft) => { + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].audio = parsedData.value; + }); + }); } - // reset the state - this.setData(() => initVideoCallData); + if (parsedData.type === 'endCall') { + console.log('END CALL'); + + if ( + this.callType === VIDEO_CALL_TYPE.PUSH_SPACE && + parsedData?.details?.type === SPACE_DISCONNECT_TYPE.LEAVE + ) { + // destroy connection to only the current peer + this.peerInstances[recipientAddress]?.destroy(); + this.peerInstances[recipientAddress] = null; + this.setData((oldData) => { + return produce(oldData, (draft) => { + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming.splice(incomingIndex, 1); + }); + }); + } + if ( + this.callType === VIDEO_CALL_TYPE.PUSH_SPACE && + parsedData?.details?.type === SPACE_DISCONNECT_TYPE.STOP + ) { + // destroy connection to all the peers + for (const connectedAddress in this.peerInstances) { + this.peerInstances[connectedAddress]?.destroy(); + this.peerInstances[connectedAddress] = null; + } + } + + if ( + this.callType === VIDEO_CALL_TYPE.PUSH_VIDEO || + (this.callType === VIDEO_CALL_TYPE.PUSH_SPACE && + parsedData?.details?.type === SPACE_DISCONNECT_TYPE.STOP) + ) { + // destroy the local stream + if (this.data.local.stream) { + endStream(this.data.local.stream); + } + + // reset the state + this.setData(() => initVideoCallData); + } + } + } else { + onReceiveMessage(data); } - } else { - onReceiveMessage(data); - } - }); - - this.peerInstance.on('stream', (currentStream: MediaStream) => { - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.incoming[0].stream = currentStream; - }); }); - }); - // set videoCallInfo state with status 1 (call initiated) - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.local.address = senderAddress; - draft.incoming[0].address = recipientAddress; - draft.meta.chatId = chatId; - draft.meta.initiator.address = senderAddress; - draft.incoming[0].status = retry - ? VideoCallStatus.RETRY_INITIALIZED - : VideoCallStatus.INITIALIZED; - draft.incoming[0].retryCount += retry ? 1 : 0; - }); - }); - } catch (err) { - console.log('error in request', err); + this.peerInstances[recipientAddress].on( + 'stream', + (currentStream: MediaStream) => { + console.log('received incoming stream', currentStream); + this.onReceiveStream(currentStream); + this.setData((oldData) => { + return produce(oldData, (draft) => { + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].stream = currentStream; + }); + }); + } + ); + } catch (err) { + console.log('error in request', err); + } } } async acceptRequest(options: VideoAcceptRequestInputOptions): Promise { const { signalData, - senderAddress, // notification sender - recipientAddress, // notification receiver + senderAddress, + recipientAddress, chatId, onReceiveMessage = (message: string) => { console.log('received a meesage', message); }, retry = false, + details, } = options || {}; try { - console.log( - 'accept request', - 'options', - options, - 'peerInstance', - this.peerInstance - ); + console.log('accept request', 'options', options); // if peerInstance is not null -> acceptRequest/request was called before - if (this.peerInstance) { + if (this.peerInstances[recipientAddress]) { // to prevent connection error we stop the exec of acceptRequest return Promise.resolve(); } @@ -294,20 +415,39 @@ export class Video { this.setData((oldData) => { return produce(oldData, (draft) => { draft.local.address = senderAddress; - draft.incoming[0].address = recipientAddress; draft.meta.chatId = chatId; draft.meta.initiator.address = senderAddress; - draft.incoming[0].status = retry - ? VideoCallStatus.RETRY_RECEIVED - : VideoCallStatus.RECEIVED; - draft.incoming[0].retryCount += retry ? 1 : 0; + + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + + if (incomingIndex === -1) { + draft.incoming.push({ + stream: null, + audio: null, + video: null, + address: recipientAddress, + status: retry + ? VideoCallStatus.RETRY_INITIALIZED + : VideoCallStatus.INITIALIZED, + retryCount: retry ? 1 : 0, + }); + } else { + draft.incoming[incomingIndex].address = recipientAddress; + draft.incoming[incomingIndex].status = retry + ? VideoCallStatus.RETRY_RECEIVED + : VideoCallStatus.RECEIVED; + draft.incoming[incomingIndex].retryCount += retry ? 1 : 0; + } }); }); // fetching the iceServers config const iceServerConfig = await getIceServerConfig(this.env); - this.peerInstance = new Peer({ + this.peerInstances[recipientAddress] = new Peer({ initiator: false, trickle: false, stream: this.data.local.stream, @@ -317,12 +457,12 @@ export class Video { }); // setup error handler - this.peerInstance.on('error', (err: any) => { + this.peerInstances[recipientAddress].on('error', (err: any) => { console.log('error in accept request', err); if (this.data.incoming[0].retryCount >= 5) { console.log('Max retries exceeded, please try again.'); - this.disconnect(); + this.disconnect({ peerAddress: recipientAddress }); } // retrying in case of connection error @@ -343,9 +483,9 @@ export class Video { ); }); - this.peerInstance.signal(signalData); + this.peerInstances[recipientAddress].signal(signalData); - this.peerInstance.on('signal', (data: any) => { + this.peerInstances[recipientAddress].on('signal', (data: any) => { this.setData((oldData) => { return produce(oldData, (draft) => { draft.meta.initiator.signal = data; @@ -367,112 +507,225 @@ export class Video { chatId, signalData: data, env: this.env, + callType: this.callType, + callDetails: details, } ); }); - this.peerInstance.on('connect', () => { - this.peerInstance.send('initial message from receiver'); - this.peerInstance.send( + this.peerInstances[recipientAddress].on('connect', () => { + this.peerInstances[recipientAddress].send( JSON.stringify({ type: 'isVideoOn', - isVideoOn: this.data.local.video, + value: this.data.local.video, }) ); - this.peerInstance.send( + this.peerInstances[recipientAddress].send( JSON.stringify({ type: 'isAudioOn', - isAudioOn: this.data.local.audio, + value: this.data.local.audio, }) ); // set videoCallInfo state with status connected for the receiver's end this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming[0].status = VideoCallStatus.CONNECTED; + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].status = VideoCallStatus.CONNECTED; }); }); }); - this.peerInstance.on('data', (data: any) => { + this.peerInstances[recipientAddress].on('data', (data: any) => { if (isJSON(data)) { const parsedData = JSON.parse(data); + + if (parsedData.type === 'connectedAddress') { + console.log('CONNECTED ADDRESSES', parsedData.value); + + const receivedConnectedAddresses = parsedData.value; + const localConnectedAddresses = getConnectedAddresses({ + incomingPeers: this.data.incoming, + }); + + // find out the address to which local peer is not connected to but the remote peer is + // then connect with them + const connectToAddresses = getConnectToAddresses({ + localAddress: senderAddress, + localConnectedAddresses, + receivedConnectedAddresses, + }); + for (const connectToAddress of connectToAddresses) { + this.request({ + senderAddress, + recipientAddress: connectToAddress, + chatId, + details: { + type: SPACE_REQUEST_TYPE.ESTABLISH_MESH, + data: {}, + }, + }); + } + + // send the addresses the local peer is connected to remote peer + this.peerInstances[recipientAddress].send( + JSON.stringify({ + type: 'connectedAddresses', + value: localConnectedAddresses, + }) + ); + } + if (parsedData.type === 'isVideoOn') { + console.log('IS VIDEO ON', parsedData.value); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming[0].video = parsedData.isVideoOn; + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].video = parsedData.value; }); }); } if (parsedData.type === 'isAudioOn') { + console.log('IS AUDIO ON', parsedData.value); this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming[0].audio = parsedData.isAudioOn; + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].audio = parsedData.value; }); }); } if (parsedData.type === 'endCall') { - // destroy the peerInstance - this.peerInstance?.destroy(); - this.peerInstance = null; - - // destroy the local stream - if (this.data.local.stream) { - endStream(this.data.local.stream); + console.log('END CALL'); + + if ( + this.callType === VIDEO_CALL_TYPE.PUSH_SPACE && + parsedData?.details?.type === SPACE_DISCONNECT_TYPE.LEAVE + ) { + // destroy connection to only the current peer + this.peerInstances[recipientAddress]?.destroy(); + this.peerInstances[recipientAddress] = null; + this.setData((oldData) => { + return produce(oldData, (draft) => { + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming.splice(incomingIndex, 1); + }); + }); + } + if ( + this.callType === VIDEO_CALL_TYPE.PUSH_SPACE && + parsedData?.details?.type === SPACE_DISCONNECT_TYPE.STOP + ) { + // destroy connection to all the peers + for (const connectedAddress in this.peerInstances) { + this.peerInstances[connectedAddress]?.destroy(); + this.peerInstances[connectedAddress] = null; + } } - // reset the state - this.setData(() => initVideoCallData); + if ( + this.callType === VIDEO_CALL_TYPE.PUSH_VIDEO || + (this.callType === VIDEO_CALL_TYPE.PUSH_SPACE && + parsedData?.details?.type === SPACE_DISCONNECT_TYPE.STOP) + ) { + // destroy the local stream + if (this.data.local.stream) { + endStream(this.data.local.stream); + } + + // reset the state + this.setData(() => initVideoCallData); + } } } else { onReceiveMessage(data); } }); - this.peerInstance.on('stream', (currentStream: MediaStream) => { - this.setData((oldData) => { - return produce(oldData, (draft) => { - draft.incoming[0].stream = currentStream; + this.peerInstances[recipientAddress].on( + 'stream', + (currentStream: MediaStream) => { + console.log('received incoming stream', currentStream); + this.onReceiveStream(currentStream); + this.setData((oldData) => { + return produce(oldData, (draft) => { + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + recipientAddress + ); + draft.incoming[incomingIndex].stream = currentStream; + }); }); - }); - }); + } + ); } catch (err) { console.log('error in accept request', err); } } connect(options: VideoConnectInputOptions): void { - const { signalData } = options || {}; + const { signalData, peerAddress } = options || {}; try { console.log('connect', 'options', options); // setup error handler - this.peerInstance.on('error', (err: any) => { + this.peerInstances[peerAddress].on('error', (err: any) => { console.log('error in connect', err); - if (this.data.incoming[0].retryCount >= 5) { + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + peerAddress + ); + + if (this.data.incoming[incomingIndex].retryCount >= 5) { console.log('Max retries exceeded, please try again.'); - this.disconnect(); + this.disconnect({ peerAddress }); } // retrying in case of connection error this.request({ senderAddress: this.data.local.address, - recipientAddress: this.data.incoming[0].address, + recipientAddress: this.data.incoming[incomingIndex].address, chatId: this.data.meta.chatId, retry: true, }); }); - this.peerInstance?.signal(signalData); + this.peerInstances[peerAddress]?.signal(signalData); + + // send the addresses the local peer is connected to remote peer + const connectedAddresses = getConnectedAddresses({ + incomingPeers: this.data.incoming, + }); + this.peerInstances[peerAddress].send( + JSON.stringify({ + type: 'connectedAddresses', + value: connectedAddresses, + }) + ); // set videoCallInfo state with status connected for the caller's end this.setData((oldData) => { return produce(oldData, (draft) => { - draft.incoming[0].status = VideoCallStatus.CONNECTED; + const incomingIndex = getIncomingIndexFromAddress( + oldData.incoming, + peerAddress + ); + draft.incoming[incomingIndex].status = VideoCallStatus.CONNECTED; }); }); } catch (err) { @@ -480,13 +733,27 @@ export class Video { } } - disconnect(): void { + disconnect(options: VideoDisconnectOptions): void { + const { peerAddress, details } = options || {}; + try { - console.log('disconnect', 'status', this.data.incoming[0].status); - if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { - this.peerInstance?.send( - JSON.stringify({ type: 'endCall', endCall: true }) + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + peerAddress + ); + + console.log( + 'disconnect', + 'status', + this.data.incoming[incomingIndex].status + ); + if ( + this.data.incoming[incomingIndex].status === VideoCallStatus.CONNECTED + ) { + this.peerInstances[peerAddress]?.send( + JSON.stringify({ type: 'endCall', value: true, details }) ); + this.peerInstances[peerAddress]?.destroy(); } else { // for disconnecting during status INITIALIZED, RECEIVED, RETRY_INITIALIZED, RETRY_RECEIVED // send a notif to the other user signaling status = DISCONNECTED @@ -498,18 +765,20 @@ export class Video { }, { senderAddress: this.data.local.address, - recipientAddress: this.data.incoming[0].address, + recipientAddress: this.data.incoming[incomingIndex].address, status: VideoCallStatus.DISCONNECTED, chatId: this.data.meta.chatId, signalData: null, env: this.env, + callType: this.callType, + callDetails: details, } ); } // destroy the peerInstance - this.peerInstance?.destroy(); - this.peerInstance = null; + this.peerInstances[peerAddress]?.destroy(); + this.peerInstances[peerAddress] = null; // destroy the local stream if (this.data.local.stream) { @@ -526,16 +795,23 @@ export class Video { // functions for enabling/disabling local audio and video enableVideo(options: EnableVideoInputOptions): void { - const { state } = options || {}; + const { state, peerAddress } = options || {}; if (this.data.local.video !== state) { // need to change the video state - if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { - this.peerInstance?.send( + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + peerAddress + ); + + if ( + this.data.incoming[incomingIndex].status === VideoCallStatus.CONNECTED + ) { + this.peerInstances[peerAddress]?.send( JSON.stringify({ type: 'isVideoOn', - isVideoOn: state, + value: state, }) ); } @@ -555,14 +831,21 @@ export class Video { } enableAudio(options: EnableAudioInputOptions): void { - const { state } = options || {}; + const { state, peerAddress } = options || {}; if (this.data.local.audio !== state) { // need to change the audio state - if (this.data.incoming[0].status === VideoCallStatus.CONNECTED) { - this.peerInstance?.send( - JSON.stringify({ type: 'isAudioOn', isAudioOn: state }) + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + peerAddress + ); + + if ( + this.data.incoming[incomingIndex].status === VideoCallStatus.CONNECTED + ) { + this.peerInstances[peerAddress]?.send( + JSON.stringify({ type: 'isAudioOn', value: state }) ); } if (this.data.local.stream) { diff --git a/packages/restapi/src/lib/video/helpers/getConnectToAddresses.ts b/packages/restapi/src/lib/video/helpers/getConnectToAddresses.ts new file mode 100644 index 000000000..6731ef169 --- /dev/null +++ b/packages/restapi/src/lib/video/helpers/getConnectToAddresses.ts @@ -0,0 +1,17 @@ +const getConnectToAddresses = ({ + localAddress, + localConnectedAddresses, + receivedConnectedAddresses, +}: { + localAddress: string; + localConnectedAddresses: string[]; + receivedConnectedAddresses: string[]; +}): string[] => { + return receivedConnectedAddresses.filter( + (receivedConnectedAddress) => + !localConnectedAddresses.includes(receivedConnectedAddress) && + receivedConnectedAddress !== localAddress + ); +}; + +export default getConnectToAddresses; diff --git a/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts b/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts new file mode 100644 index 000000000..7e9d9a149 --- /dev/null +++ b/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts @@ -0,0 +1,17 @@ +import { PeerData, VideoCallStatus } from '../../types'; + +const getConnectedAddresses = ({ + incomingPeers, +}: { + incomingPeers: PeerData[]; +}): string[] => { + const connectedAddresses: string[] = []; + incomingPeers.forEach((incomingPeer) => { + if (incomingPeer.status === VideoCallStatus.CONNECTED) { + connectedAddresses.push(incomingPeer.address); + } + }); + return connectedAddresses; +}; + +export default getConnectedAddresses; diff --git a/packages/restapi/src/lib/video/helpers/getIceServerConfig.ts b/packages/restapi/src/lib/video/helpers/getIceServerConfig.ts index 8e7acdad8..cb0d5ebaa 100644 --- a/packages/restapi/src/lib/video/helpers/getIceServerConfig.ts +++ b/packages/restapi/src/lib/video/helpers/getIceServerConfig.ts @@ -1,10 +1,20 @@ import axios from 'axios'; import { getAPIBaseUrls } from '../../helpers'; import Constants from '../../constants'; +import * as CryptoJS from 'crypto-js'; + +const ENCRYPTION_KEY = 'turnserversecret'; export const getIceServerConfig = async (env = Constants.ENV.PROD) => { const API_BASE_URL = getAPIBaseUrls(env); const apiEndpoint = `${API_BASE_URL}/v1/turnserver/iceconfig`; - const { data } = await axios.get(apiEndpoint); - return data; + const { data: encryptedData } = await axios.get(apiEndpoint); + + const { config: decryptedData } = JSON.parse( + CryptoJS.AES.decrypt(encryptedData, ENCRYPTION_KEY).toString( + CryptoJS.enc.Utf8 + ) + ); + + return decryptedData; }; diff --git a/packages/restapi/src/lib/video/helpers/getIncomingIndexFromAddress.ts b/packages/restapi/src/lib/video/helpers/getIncomingIndexFromAddress.ts new file mode 100644 index 000000000..e4c61cf44 --- /dev/null +++ b/packages/restapi/src/lib/video/helpers/getIncomingIndexFromAddress.ts @@ -0,0 +1,7 @@ +import { PeerData } from "../../types"; + +const getIncomingIndexFromAddress = (incomingPeers: PeerData[], address: string) => { + return incomingPeers.findIndex(incomingPeer => incomingPeer.address === address); +} + +export default getIncomingIndexFromAddress; diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts index 07beed66c..935375d6e 100644 --- a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -1,9 +1,20 @@ import Constants, { ENV } from '../../constants'; import { getCAIPWithChainId } from '../../helpers'; import { sendNotification } from '../../payloads'; -import { ADDITIONAL_META_TYPE } from '../../payloads/constants'; +import { + NOTIFICATION_TYPE, + SPACE_ACCEPT_REQUEST_TYPE, + SPACE_DISCONNECT_TYPE, + SPACE_REQUEST_TYPE, + VIDEO_CALL_TYPE, +} from '../../payloads/constants'; import { SignerType, VideoCallStatus } from '../../types'; +interface CallDetailsType { + type: SPACE_REQUEST_TYPE | SPACE_ACCEPT_REQUEST_TYPE | SPACE_DISCONNECT_TYPE; + data: Record; +}; + interface VideoCallInfoType { recipientAddress: string; senderAddress: string; @@ -11,6 +22,8 @@ interface VideoCallInfoType { signalData: any; status: VideoCallStatus; env?: ENV; + callType?: VIDEO_CALL_TYPE; + callDetails?: CallDetailsType; } interface UserInfoType { @@ -19,12 +32,13 @@ interface UserInfoType { pgpPrivateKey: string; } -interface VideoDataType { +export interface VideoDataType { recipientAddress: string; senderAddress: string; chatId: string; signalData?: any; status: VideoCallStatus; + callDetails?: CallDetailsType; } const sendVideoCallNotification = async ( @@ -33,9 +47,11 @@ const sendVideoCallNotification = async ( recipientAddress, senderAddress, chatId, - signalData = null, status, + signalData = null, env = Constants.ENV.PROD, + callType = VIDEO_CALL_TYPE.PUSH_VIDEO, + callDetails }: VideoCallInfoType ) => { try { @@ -45,6 +61,7 @@ const sendVideoCallNotification = async ( chatId, signalData, status, + callDetails }; console.log('sendVideoCallNotification', 'videoData', videoData); @@ -57,12 +74,14 @@ const sendVideoCallNotification = async ( const notificationText = `Video Call from ${senderAddress}`; + const notificationType = NOTIFICATION_TYPE.TARGETTED; + await sendNotification({ senderType: 1, // for chat notification signer, pgpPrivateKey, chatId, - type: 3, + type: notificationType, identityType: 2, notification: { title: notificationText, @@ -74,9 +93,10 @@ const sendVideoCallNotification = async ( cta: '', img: '', additionalMeta: { - type: `${ADDITIONAL_META_TYPE.PUSH_VIDEO}+1`, + // type: `${callType}+1`, + type: `${VIDEO_CALL_TYPE.PUSH_VIDEO}+1`, data: JSON.stringify(videoData), - } + }, }, recipients: recipientAddressInCaip, channel: senderAddressInCaip, diff --git a/packages/restapi/src/lib/video/index.ts b/packages/restapi/src/lib/video/index.ts index b157270a0..ac0701b1a 100644 --- a/packages/restapi/src/lib/video/index.ts +++ b/packages/restapi/src/lib/video/index.ts @@ -1 +1,2 @@ export * from './Video'; +export { VideoDataType } from './helpers/sendVideoCallNotification'; diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index ebb32538b..5bb63c29d 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -3,1798 +3,1585 @@ "@chainsafe/as-sha256@^0.3.1": - "integrity" "sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg==" - "resolved" "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" - "version" "0.3.1" + version "0.3.1" + resolved "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" + integrity sha512-hldFFYuf49ed7DAakWVXSJODuq3pzJEguD8tQ7h+sGkM18vja+OFoJI9krnGmgzyuZC2ETX0NOIcCTy31v2Mtg== "@chainsafe/persistent-merkle-tree@^0.4.2": - "integrity" "sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ==" - "resolved" "https://registry.npmjs.org/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz" - "version" "0.4.2" + version "0.4.2" + resolved "https://registry.npmjs.org/@chainsafe/persistent-merkle-tree/-/persistent-merkle-tree-0.4.2.tgz" + integrity sha512-lLO3ihKPngXLTus/L7WHKaw9PnNJWizlOF1H9NNzHP6Xvh82vzg9F2bzkXhYIFshMZ2gTCEz8tq6STe7r5NDfQ== dependencies: "@chainsafe/as-sha256" "^0.3.1" "@chainsafe/ssz@0.9.4": - "integrity" "sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ==" - "resolved" "https://registry.npmjs.org/@chainsafe/ssz/-/ssz-0.9.4.tgz" - "version" "0.9.4" + version "0.9.4" + resolved "https://registry.npmjs.org/@chainsafe/ssz/-/ssz-0.9.4.tgz" + integrity sha512-77Qtg2N1ayqs4Bg/wvnWfg5Bta7iy7IRh8XqXh7oNMeP2HBbBwx8m6yTpA8p0EHItWPEBkgZd5S5/LSlp3GXuQ== dependencies: "@chainsafe/as-sha256" "^0.3.1" "@chainsafe/persistent-merkle-tree" "^0.4.2" - "case" "^1.6.3" + case "^1.6.3" "@cspotcode/source-map-support@^0.8.0": - "integrity" "sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw==" - "resolved" "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz" - "version" "0.8.1" + version "0.8.1" + resolved "https://registry.npmjs.org/@cspotcode/source-map-support/-/source-map-support-0.8.1.tgz" + integrity sha512-IchNf6dN4tHoMFIn/7OE8LWZ19Y6q/67Bmf6vnGREv8RSbBVb9LPJxEcnwrcwX6ixSvaiGoomAUvu4YSxXrVgw== dependencies: "@jridgewell/trace-mapping" "0.3.9" "@ethereumjs/rlp@^4.0.1": - "integrity" "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==" - "resolved" "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz" - "version" "4.0.1" + version "4.0.1" + resolved "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz" + integrity sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw== "@ethereumjs/util@^8.0.0": - "integrity" "sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw==" - "resolved" "https://registry.npmjs.org/@ethereumjs/util/-/util-8.0.5.tgz" - "version" "8.0.5" + version "8.0.5" + resolved "https://registry.npmjs.org/@ethereumjs/util/-/util-8.0.5.tgz" + integrity sha512-259rXKK3b3D8HRVdRmlOEi6QFvwxdt304hhrEAmpZhsj7ufXEOTIc9JRZPMnXatKjECokdLNBcDOFBeBSzAIaw== dependencies: "@chainsafe/ssz" "0.9.4" "@ethereumjs/rlp" "^4.0.1" - "ethereum-cryptography" "^1.1.2" - -"@ethersproject/abi@^5.7.0", "@ethersproject/abi@5.7.0": - "integrity" "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==" - "resolved" "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/abstract-provider@^5.7.0", "@ethersproject/abstract-provider@5.7.0": - "integrity" "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==" - "resolved" "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/networks" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/web" "^5.7.0" - -"@ethersproject/abstract-signer@^5.7.0", "@ethersproject/abstract-signer@5.7.0": - "integrity" "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - -"@ethersproject/address@^5.7.0", "@ethersproject/address@5.7.0": - "integrity" "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==" - "resolved" "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/rlp" "^5.7.0" - -"@ethersproject/base64@^5.7.0", "@ethersproject/base64@5.7.0": - "integrity" "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - -"@ethersproject/basex@^5.7.0", "@ethersproject/basex@5.7.0": - "integrity" "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==" - "resolved" "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - -"@ethersproject/bignumber@^5.7.0", "@ethersproject/bignumber@5.7.0": - "integrity" "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==" - "resolved" "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "bn.js" "^5.2.1" - -"@ethersproject/bytes@^5.7.0", "@ethersproject/bytes@5.7.0": - "integrity" "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==" - "resolved" "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/constants@^5.7.0", "@ethersproject/constants@5.7.0": - "integrity" "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==" - "resolved" "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - -"@ethersproject/contracts@5.7.0": - "integrity" "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==" - "resolved" "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abi" "^5.7.0" - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - -"@ethersproject/hash@^5.7.0", "@ethersproject/hash@5.7.0": - "integrity" "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==" - "resolved" "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/base64" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/hdnode@^5.7.0", "@ethersproject/hdnode@5.7.0": - "integrity" "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==" - "resolved" "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/basex" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/pbkdf2" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - "@ethersproject/signing-key" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/wordlists" "^5.7.0" - -"@ethersproject/json-wallets@^5.7.0", "@ethersproject/json-wallets@5.7.0": - "integrity" "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==" - "resolved" "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/hdnode" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/pbkdf2" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/random" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "aes-js" "3.0.0" - "scrypt-js" "3.0.1" - -"@ethersproject/keccak256@^5.7.0", "@ethersproject/keccak256@5.7.0": - "integrity" "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==" - "resolved" "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "js-sha3" "0.8.0" - -"@ethersproject/logger@^5.7.0", "@ethersproject/logger@5.7.0": - "integrity" "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" - "resolved" "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz" - "version" "5.7.0" - -"@ethersproject/networks@^5.7.0", "@ethersproject/networks@5.7.1": - "integrity" "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz" - "version" "5.7.1" - dependencies: - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/pbkdf2@^5.7.0", "@ethersproject/pbkdf2@5.7.0": - "integrity" "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==" - "resolved" "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - -"@ethersproject/properties@^5.7.0", "@ethersproject/properties@5.7.0": - "integrity" "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==" - "resolved" "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/providers@5.7.2": - "integrity" "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==" - "resolved" "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz" - "version" "5.7.2" - dependencies: - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/base64" "^5.7.0" - "@ethersproject/basex" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/networks" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/random" "^5.7.0" - "@ethersproject/rlp" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/web" "^5.7.0" - "bech32" "1.1.4" - "ws" "7.4.6" - -"@ethersproject/random@^5.7.0", "@ethersproject/random@5.7.0": - "integrity" "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/rlp@^5.7.0", "@ethersproject/rlp@5.7.0": - "integrity" "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==" - "resolved" "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/sha2@^5.7.0", "@ethersproject/sha2@5.7.0": - "integrity" "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==" - "resolved" "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "hash.js" "1.1.7" - -"@ethersproject/signing-key@^5.7.0", "@ethersproject/signing-key@5.7.0": - "integrity" "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==" - "resolved" "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "bn.js" "^5.2.1" - "elliptic" "6.5.4" - "hash.js" "1.1.7" - -"@ethersproject/solidity@5.7.0": - "integrity" "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==" - "resolved" "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/sha2" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/strings@^5.7.0", "@ethersproject/strings@5.7.0": - "integrity" "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==" - "resolved" "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/transactions@^5.7.0", "@ethersproject/transactions@5.7.0": - "integrity" "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==" - "resolved" "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/rlp" "^5.7.0" - "@ethersproject/signing-key" "^5.7.0" - -"@ethersproject/units@5.7.0": - "integrity" "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==" - "resolved" "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/constants" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - -"@ethersproject/wallet@5.7.0": - "integrity" "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==" - "resolved" "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/abstract-provider" "^5.7.0" - "@ethersproject/abstract-signer" "^5.7.0" - "@ethersproject/address" "^5.7.0" - "@ethersproject/bignumber" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/hdnode" "^5.7.0" - "@ethersproject/json-wallets" "^5.7.0" - "@ethersproject/keccak256" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/random" "^5.7.0" - "@ethersproject/signing-key" "^5.7.0" - "@ethersproject/transactions" "^5.7.0" - "@ethersproject/wordlists" "^5.7.0" - -"@ethersproject/web@^5.7.0", "@ethersproject/web@5.7.1": - "integrity" "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==" - "resolved" "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz" - "version" "5.7.1" - dependencies: - "@ethersproject/base64" "^5.7.0" - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" - -"@ethersproject/wordlists@^5.7.0", "@ethersproject/wordlists@5.7.0": - "integrity" "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==" - "resolved" "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz" - "version" "5.7.0" - dependencies: - "@ethersproject/bytes" "^5.7.0" - "@ethersproject/hash" "^5.7.0" - "@ethersproject/logger" "^5.7.0" - "@ethersproject/properties" "^5.7.0" - "@ethersproject/strings" "^5.7.0" + ethereum-cryptography "^1.1.2" "@jridgewell/resolve-uri@^3.0.3": - "integrity" "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==" - "resolved" "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz" - "version" "3.1.0" + version "3.1.0" + resolved "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz" + integrity sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w== "@jridgewell/sourcemap-codec@^1.4.10": - "integrity" "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==" - "resolved" "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz" - "version" "1.4.14" + version "1.4.14" + resolved "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz" + integrity sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw== "@jridgewell/trace-mapping@0.3.9": - "integrity" "sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ==" - "resolved" "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz" - "version" "0.3.9" + version "0.3.9" + resolved "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.9.tgz" + integrity sha512-3Belt6tdc8bPgAtbcmdtNJlirVoTmEb5e2gC94PnkwEW9jI6CAHUeoG85tjWP5WquqfavoMtMwiG4P926ZKKuQ== dependencies: "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" +"@livepeer/core@^1.5.8": + version "1.5.8" + resolved "https://registry.yarnpkg.com/@livepeer/core/-/core-1.5.8.tgz#c048bffb216a7d0dc831d2de2956652262b318de" + integrity sha512-h/afwfan0y5DugHz/lZhsTzTeDs2lzVFuuHyJrU3EPZl0SvHHFT0cI47/vRjLY6aV1UfJglQwZAa6auPrVXM9w== + dependencies: + cross-fetch "^3.1.5" + ms "^3.0.0-canary.1" + multiformats "9.9.0" + tus-js-client "^3.0.1" + zustand "^4.3.2" + +"@livepeer/webrtmp-sdk@^0.2.3": + version "0.2.3" + resolved "https://registry.yarnpkg.com/@livepeer/webrtmp-sdk/-/webrtmp-sdk-0.2.3.tgz#10c5baca5517b8f14ec766df15be467d14e7c8d7" + integrity sha512-tJ2gGhUZfbeXmIkZHxY/WNS0C9SYUhJ/6QlYhot1CJlBuXkuoki9gSGhYhS3G7Vu/HchL1HU/DXWKhrQhlogXg== + dependencies: + events "3.3.0" + "@metamask/eth-sig-util@^5.0.2": - "integrity" "sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q==" - "resolved" "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" - "version" "5.0.2" + version "5.0.2" + resolved "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" + integrity sha512-RU6fG/H6/UlBol221uBkq5C7w3TwLK611nEZliO2u+kO0vHKGBXnIPlhI0tzKUigjhUeOd9mhCNbNvhh0LKt9Q== dependencies: "@ethereumjs/util" "^8.0.0" - "bn.js" "^4.11.8" - "ethereum-cryptography" "^1.1.2" - "ethjs-util" "^0.1.6" - "tweetnacl" "^1.0.3" - "tweetnacl-util" "^0.15.1" - -"@noble/hashes@~1.2.0", "@noble/hashes@1.2.0": - "integrity" "sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==" - "resolved" "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz" - "version" "1.2.0" - -"@noble/secp256k1@~1.7.0", "@noble/secp256k1@1.7.1": - "integrity" "sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==" - "resolved" "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" - "version" "1.7.1" + bn.js "^4.11.8" + ethereum-cryptography "^1.1.2" + ethjs-util "^0.1.6" + tweetnacl "^1.0.3" + tweetnacl-util "^0.15.1" + +"@noble/hashes@1.2.0", "@noble/hashes@~1.2.0": + version "1.2.0" + resolved "https://registry.npmjs.org/@noble/hashes/-/hashes-1.2.0.tgz" + integrity sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ== + +"@noble/secp256k1@1.7.1", "@noble/secp256k1@~1.7.0": + version "1.7.1" + resolved "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" + integrity sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw== "@scure/base@~1.1.0": - "integrity" "sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA==" - "resolved" "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" + integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== "@scure/bip32@1.1.5": - "integrity" "sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw==" - "resolved" "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz" - "version" "1.1.5" + version "1.1.5" + resolved "https://registry.npmjs.org/@scure/bip32/-/bip32-1.1.5.tgz" + integrity sha512-XyNh1rB0SkEqd3tXcXMi+Xe1fvg+kUIcoRIEujP1Jgv7DqW2r9lg3Ah0NkFaCs9sTkQAQA8kw7xiRXzENi9Rtw== dependencies: "@noble/hashes" "~1.2.0" "@noble/secp256k1" "~1.7.0" "@scure/base" "~1.1.0" "@scure/bip39@1.1.1": - "integrity" "sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==" - "resolved" "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz" - "version" "1.1.1" + version "1.1.1" + resolved "https://registry.npmjs.org/@scure/bip39/-/bip39-1.1.1.tgz" + integrity sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg== dependencies: "@noble/hashes" "~1.2.0" "@scure/base" "~1.1.0" +"@stitches/core@^1.2.8": + version "1.2.8" + resolved "https://registry.yarnpkg.com/@stitches/core/-/core-1.2.8.tgz#dce3b8fdc764fbc6dbea30c83b73bfb52cf96173" + integrity sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg== + "@tsconfig/node10@^1.0.7": - "integrity" "sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==" - "resolved" "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" - "version" "1.0.9" + version "1.0.9" + resolved "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz" + integrity sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA== "@tsconfig/node12@^1.0.7": - "integrity" "sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==" - "resolved" "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz" - "version" "1.0.11" + version "1.0.11" + resolved "https://registry.npmjs.org/@tsconfig/node12/-/node12-1.0.11.tgz" + integrity sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag== "@tsconfig/node14@^1.0.0": - "integrity" "sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==" - "resolved" "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz" - "version" "1.0.3" + version "1.0.3" + resolved "https://registry.npmjs.org/@tsconfig/node14/-/node14-1.0.3.tgz" + integrity sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow== "@tsconfig/node16@^1.0.2": - "integrity" "sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==" - "resolved" "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz" - "version" "1.0.3" + version "1.0.3" + resolved "https://registry.npmjs.org/@tsconfig/node16/-/node16-1.0.3.tgz" + integrity sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ== "@types/chai-as-promised@^7.1.5": - "integrity" "sha512-jStwss93SITGBwt/niYrkf2C+/1KTeZCZl1LaeezTlqppAKeoQC7jxyqYuP72sxBGKCIbw7oHgbYssIRzT5FCQ==" - "resolved" "https://registry.npmjs.org/@types/chai-as-promised/-/chai-as-promised-7.1.5.tgz" - "version" "7.1.5" + version "7.1.5" + resolved "https://registry.npmjs.org/@types/chai-as-promised/-/chai-as-promised-7.1.5.tgz" + integrity sha512-jStwss93SITGBwt/niYrkf2C+/1KTeZCZl1LaeezTlqppAKeoQC7jxyqYuP72sxBGKCIbw7oHgbYssIRzT5FCQ== dependencies: "@types/chai" "*" "@types/chai@*", "@types/chai@^4.3.4": - "integrity" "sha512-KnRanxnpfpjUTqTCXslZSEdLfXExwgNxYPdiO2WGUj8+HDjFi8R3k5RVKPeSCzLjCcshCAtVO2QBbVuAV4kTnw==" - "resolved" "https://registry.npmjs.org/@types/chai/-/chai-4.3.4.tgz" - "version" "4.3.4" + version "4.3.4" + resolved "https://registry.npmjs.org/@types/chai/-/chai-4.3.4.tgz" + integrity sha512-KnRanxnpfpjUTqTCXslZSEdLfXExwgNxYPdiO2WGUj8+HDjFi8R3k5RVKPeSCzLjCcshCAtVO2QBbVuAV4kTnw== "@types/crypto-js@^4.1.1": - "integrity" "sha512-BG7fQKZ689HIoc5h+6D2Dgq1fABRa0RbBWKBd9SP/MVRVXROflpm5fhwyATX5duFmbStzyzyycPB8qUYKDH3NA==" - "resolved" "https://registry.npmjs.org/@types/crypto-js/-/crypto-js-4.1.1.tgz" - "version" "4.1.1" + version "4.1.1" + resolved "https://registry.npmjs.org/@types/crypto-js/-/crypto-js-4.1.1.tgz" + integrity sha512-BG7fQKZ689HIoc5h+6D2Dgq1fABRa0RbBWKBd9SP/MVRVXROflpm5fhwyATX5duFmbStzyzyycPB8qUYKDH3NA== "@types/mocha@^10.0.1": - "integrity" "sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q==" - "resolved" "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz" - "version" "10.0.1" + version "10.0.1" + resolved "https://registry.npmjs.org/@types/mocha/-/mocha-10.0.1.tgz" + integrity sha512-/fvYntiO1GeICvqbQ3doGDIP97vWmvFt83GKguJ6prmQM2iXZfFcq6YE8KteFyRtX2/h5Hf91BYvPodJKFYv5Q== "@types/mocha@^5.2.0": - "integrity" "sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ==" - "resolved" "https://registry.npmjs.org/@types/mocha/-/mocha-5.2.7.tgz" - "version" "5.2.7" - -"@types/node@*": - "integrity" "sha512-JJulVEQXmiY9Px5axXHeYGLSjhkZEnD+MDPDGbCbIAbMslkKwmygtZFy1X6s/075Yo94sf8GuSlFfPzysQrWZQ==" - "resolved" "https://registry.npmjs.org/@types/node/-/node-20.2.5.tgz" - "version" "20.2.5" - -"acorn-walk@^8.1.1": - "integrity" "sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA==" - "resolved" "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz" - "version" "8.2.0" - -"acorn@^8.4.1": - "integrity" "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==" - "resolved" "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz" - "version" "8.8.2" - -"aes-js@3.0.0": - "integrity" "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" - "resolved" "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz" - "version" "3.0.0" - -"ansi-colors@4.1.1": - "integrity" "sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==" - "resolved" "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz" - "version" "4.1.1" - -"ansi-regex@^2.0.0": - "integrity" "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" - "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz" - "version" "2.1.1" - -"ansi-regex@^3.0.0": - "integrity" "sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==" - "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz" - "version" "3.0.1" - -"ansi-regex@^5.0.1": - "integrity" "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" - "resolved" "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" - "version" "5.0.1" - -"ansi-styles@^3.2.1": - "integrity" "sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==" - "resolved" "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz" - "version" "3.2.1" - dependencies: - "color-convert" "^1.9.0" - -"ansi-styles@^4.0.0", "ansi-styles@^4.1.0": - "integrity" "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==" - "resolved" "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz" - "version" "4.3.0" - dependencies: - "color-convert" "^2.0.1" - -"anymatch@~3.1.2": - "integrity" "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==" - "resolved" "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz" - "version" "3.1.3" - dependencies: - "normalize-path" "^3.0.0" - "picomatch" "^2.0.4" - -"arg@^4.1.0": - "integrity" "sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==" - "resolved" "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz" - "version" "4.1.3" - -"argparse@^2.0.1": - "integrity" "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==" - "resolved" "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" - "version" "2.0.1" - -"asn1.js@^5.0.0": - "integrity" "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==" - "resolved" "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz" - "version" "5.4.1" - dependencies: - "bn.js" "^4.0.0" - "inherits" "^2.0.1" - "minimalistic-assert" "^1.0.0" - "safer-buffer" "^2.1.0" - -"assertion-error@^1.1.0": - "integrity" "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==" - "resolved" "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz" - "version" "1.1.0" - -"balanced-match@^1.0.0": - "integrity" "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" - "resolved" "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" - "version" "1.0.2" - -"base64-js@^1.3.1": - "integrity" "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==" - "resolved" "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" - "version" "1.5.1" - -"bech32@1.1.4": - "integrity" "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" - "resolved" "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz" - "version" "1.1.4" - -"binary-extensions@^2.0.0": - "integrity" "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==" - "resolved" "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz" - "version" "2.2.0" - -"bn.js@^4.0.0", "bn.js@^4.11.8", "bn.js@^4.11.9": - "integrity" "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" - "resolved" "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" - "version" "4.12.0" - -"bn.js@^5.2.1": - "integrity" "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" - "resolved" "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" - "version" "5.2.1" - -"brace-expansion@^1.1.7": - "integrity" "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==" - "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" - "version" "1.1.11" - dependencies: - "balanced-match" "^1.0.0" - "concat-map" "0.0.1" - -"brace-expansion@^2.0.1": - "integrity" "sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==" - "resolved" "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "balanced-match" "^1.0.0" - -"braces@~3.0.2": - "integrity" "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==" - "resolved" "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" - "version" "3.0.2" - dependencies: - "fill-range" "^7.0.1" - -"brorand@^1.1.0": - "integrity" "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" - "resolved" "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" - "version" "1.1.0" - -"browser-stdout@1.3.1": - "integrity" "sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==" - "resolved" "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz" - "version" "1.3.1" - -"buffer@^6.0.3": - "integrity" "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==" - "resolved" "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" - "version" "6.0.3" - dependencies: - "base64-js" "^1.3.1" - "ieee754" "^1.2.1" - -"camelcase@^4.1.0": - "integrity" "sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==" - "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz" - "version" "4.1.0" - -"camelcase@^6.0.0": - "integrity" "sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==" - "resolved" "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz" - "version" "6.3.0" - -"case@^1.6.3": - "integrity" "sha512-mzDSXIPaFwVDvZAHqZ9VlbyF4yyXRuX6IvB06WvPYkqJVO24kX1PPhv9bfpKNFZyxYFmmgo03HUiD8iklmJYRQ==" - "resolved" "https://registry.npmjs.org/case/-/case-1.6.3.tgz" - "version" "1.6.3" - -"chai-as-promised@^7.1.1": - "integrity" "sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA==" - "resolved" "https://registry.npmjs.org/chai-as-promised/-/chai-as-promised-7.1.1.tgz" - "version" "7.1.1" - dependencies: - "check-error" "^1.0.2" - -"chai@^4.3.7", "chai@>= 2.1.2 < 5": - "integrity" "sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A==" - "resolved" "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz" - "version" "4.3.7" - dependencies: - "assertion-error" "^1.1.0" - "check-error" "^1.0.2" - "deep-eql" "^4.1.2" - "get-func-name" "^2.0.0" - "loupe" "^2.3.1" - "pathval" "^1.1.1" - "type-detect" "^4.0.5" - -"chalk@^2.4.1": - "integrity" "sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==" - "resolved" "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" - "version" "2.4.2" - dependencies: - "ansi-styles" "^3.2.1" - "escape-string-regexp" "^1.0.5" - "supports-color" "^5.3.0" - -"chalk@^4.1.0": - "integrity" "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==" - "resolved" "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" - "version" "4.1.2" - dependencies: - "ansi-styles" "^4.1.0" - "supports-color" "^7.1.0" - -"check-error@^1.0.2": - "integrity" "sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==" - "resolved" "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz" - "version" "1.0.2" - -"chokidar@3.5.3": - "integrity" "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==" - "resolved" "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz" - "version" "3.5.3" - dependencies: - "anymatch" "~3.1.2" - "braces" "~3.0.2" - "glob-parent" "~5.1.2" - "is-binary-path" "~2.1.0" - "is-glob" "~4.0.1" - "normalize-path" "~3.0.0" - "readdirp" "~3.6.0" + version "5.2.7" + resolved "https://registry.npmjs.org/@types/mocha/-/mocha-5.2.7.tgz" + integrity sha512-NYrtPht0wGzhwe9+/idPaBB+TqkY9AhTvOLMkThm0IoEfLaiVQZwBwyJ5puCkO3AUCWrmcoePjp2mbFocKy4SQ== + +acorn-walk@^8.1.1: + version "8.2.0" + resolved "https://registry.npmjs.org/acorn-walk/-/acorn-walk-8.2.0.tgz" + integrity sha512-k+iyHEuPgSw6SbuDpGQM+06HQUa04DZ3o+F6CSzXMvvI5KMvnaEqXe+YVe555R9nn6GPt404fos4wcgpw12SDA== + +acorn@^8.4.1: + version "8.8.2" + resolved "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz" + integrity sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw== + +ansi-colors@4.1.1: + version "4.1.1" + resolved "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz" + integrity sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA== + +ansi-regex@^2.0.0: + version "2.1.1" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz" + integrity sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA== + +ansi-regex@^3.0.0: + version "3.0.1" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-3.0.1.tgz" + integrity sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw== + +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" + integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== + +ansi-styles@^3.2.1: + 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== + dependencies: + color-convert "^1.9.0" + +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== + dependencies: + color-convert "^2.0.1" + +anymatch@~3.1.2: + version "3.1.3" + resolved "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz" + integrity sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw== + dependencies: + normalize-path "^3.0.0" + picomatch "^2.0.4" + +arg@^4.1.0: + version "4.1.3" + resolved "https://registry.npmjs.org/arg/-/arg-4.1.3.tgz" + integrity sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA== + +argparse@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" + integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== + +asn1.js@^5.0.0: + version "5.4.1" + resolved "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz" + integrity sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA== + dependencies: + bn.js "^4.0.0" + inherits "^2.0.1" + minimalistic-assert "^1.0.0" + safer-buffer "^2.1.0" + +assertion-error@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz" + integrity sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw== + +balanced-match@^1.0.0: + version "1.0.2" + resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" + integrity sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw== + +base64-js@^1.3.1: + version "1.5.1" + resolved "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" + integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== + +binary-extensions@^2.0.0: + version "2.2.0" + resolved "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz" + integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== + +bn.js@^4.0.0, bn.js@^4.11.8: + version "4.12.0" + resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" + integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== + +brace-expansion@^1.1.7: + version "1.1.11" + resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" + integrity sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA== + dependencies: + balanced-match "^1.0.0" + concat-map "0.0.1" + +brace-expansion@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-2.0.1.tgz" + integrity sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA== + dependencies: + balanced-match "^1.0.0" + +braces@~3.0.2: + version "3.0.2" + resolved "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz" + integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A== + dependencies: + fill-range "^7.0.1" + +browser-stdout@1.3.1: + version "1.3.1" + resolved "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz" + integrity sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw== + +buffer-from@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== + +buffer@^6.0.3: + version "6.0.3" + resolved "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" + integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== + dependencies: + base64-js "^1.3.1" + ieee754 "^1.2.1" + +camelcase@^4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz" + integrity sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw== + +camelcase@^6.0.0: + version "6.3.0" + resolved "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz" + integrity sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA== + +case@^1.6.3: + version "1.6.3" + resolved "https://registry.npmjs.org/case/-/case-1.6.3.tgz" + integrity sha512-mzDSXIPaFwVDvZAHqZ9VlbyF4yyXRuX6IvB06WvPYkqJVO24kX1PPhv9bfpKNFZyxYFmmgo03HUiD8iklmJYRQ== + +chai-as-promised@^7.1.1: + version "7.1.1" + resolved "https://registry.npmjs.org/chai-as-promised/-/chai-as-promised-7.1.1.tgz" + integrity sha512-azL6xMoi+uxu6z4rhWQ1jbdUhOMhis2PvscD/xjLqNMkv3BPPp2JyyuTHOrf9BOosGpNQ11v6BKv/g57RXbiaA== + dependencies: + check-error "^1.0.2" + +chai@^4.3.7: + version "4.3.7" + resolved "https://registry.npmjs.org/chai/-/chai-4.3.7.tgz" + integrity sha512-HLnAzZ2iupm25PlN0xFreAlBA5zaBSv3og0DdeGA4Ar6h6rJ3A0rolRUKJhSF2V10GZKDgWF/VmAEsNWjCRB+A== + dependencies: + assertion-error "^1.1.0" + check-error "^1.0.2" + deep-eql "^4.1.2" + get-func-name "^2.0.0" + loupe "^2.3.1" + pathval "^1.1.1" + type-detect "^4.0.5" + +chalk@^2.4.1: + version "2.4.2" + resolved "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" + integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== + dependencies: + ansi-styles "^3.2.1" + escape-string-regexp "^1.0.5" + supports-color "^5.3.0" + +chalk@^4.1.0: + version "4.1.2" + resolved "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz" + integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +check-error@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/check-error/-/check-error-1.0.2.tgz" + integrity sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA== + +chokidar@3.5.3: + version "3.5.3" + resolved "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz" + integrity sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw== + dependencies: + anymatch "~3.1.2" + braces "~3.0.2" + glob-parent "~5.1.2" + is-binary-path "~2.1.0" + is-glob "~4.0.1" + normalize-path "~3.0.0" + readdirp "~3.6.0" optionalDependencies: - "fsevents" "~2.3.2" - -"cliui@^4.0.0": - "integrity" "sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ==" - "resolved" "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" - "version" "4.1.0" - dependencies: - "string-width" "^2.1.1" - "strip-ansi" "^4.0.0" - "wrap-ansi" "^2.0.0" - -"cliui@^7.0.2": - "integrity" "sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==" - "resolved" "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz" - "version" "7.0.4" - dependencies: - "string-width" "^4.2.0" - "strip-ansi" "^6.0.0" - "wrap-ansi" "^7.0.0" - -"code-point-at@^1.0.0": - "integrity" "sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==" - "resolved" "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" - "version" "1.1.0" - -"color-convert@^1.9.0": - "integrity" "sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==" - "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" - "version" "1.9.3" - dependencies: - "color-name" "1.1.3" - -"color-convert@^2.0.1": - "integrity" "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==" - "resolved" "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" - "version" "2.0.1" - dependencies: - "color-name" "~1.1.4" - -"color-name@~1.1.4": - "integrity" "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" - "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" - "version" "1.1.4" - -"color-name@1.1.3": - "integrity" "sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==" - "resolved" "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" - "version" "1.1.3" - -"concat-map@0.0.1": - "integrity" "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" - "resolved" "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" - "version" "0.0.1" - -"create-require@^1.1.0": - "integrity" "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==" - "resolved" "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz" - "version" "1.1.1" - -"cross-spawn@^6.0.0", "cross-spawn@^6.0.5": - "integrity" "sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==" - "resolved" "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" - "version" "6.0.5" - dependencies: - "nice-try" "^1.0.4" - "path-key" "^2.0.1" - "semver" "^5.5.0" - "shebang-command" "^1.2.0" - "which" "^1.2.9" - -"crypto-js@^4.1.1": - "integrity" "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" - "resolved" "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" - "version" "4.1.1" - -"debug@^4.3.2", "debug@4.3.4": - "integrity" "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==" - "resolved" "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" - "version" "4.3.4" - dependencies: - "ms" "2.1.2" - -"decamelize@^1.1.1": - "integrity" "sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==" - "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" - "version" "1.2.0" - -"decamelize@^4.0.0": - "integrity" "sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==" - "resolved" "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" - "version" "4.0.0" - -"deep-eql@^4.1.2": - "integrity" "sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw==" - "resolved" "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz" - "version" "4.1.3" - dependencies: - "type-detect" "^4.0.0" - -"diff@^4.0.1": - "integrity" "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==" - "resolved" "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz" - "version" "4.0.2" - -"diff@5.0.0": - "integrity" "sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==" - "resolved" "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" - "version" "5.0.0" - -"elliptic@6.5.4": - "integrity" "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==" - "resolved" "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz" - "version" "6.5.4" - dependencies: - "bn.js" "^4.11.9" - "brorand" "^1.1.0" - "hash.js" "^1.0.0" - "hmac-drbg" "^1.0.1" - "inherits" "^2.0.4" - "minimalistic-assert" "^1.0.1" - "minimalistic-crypto-utils" "^1.0.1" - -"emoji-regex@^8.0.0": - "integrity" "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" - "resolved" "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" - "version" "8.0.0" - -"end-of-stream@^1.1.0": - "integrity" "sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==" - "resolved" "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz" - "version" "1.4.4" - dependencies: - "once" "^1.4.0" - -"err-code@^3.0.1": - "integrity" "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" - "resolved" "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz" - "version" "3.0.1" - -"escalade@^3.1.1": - "integrity" "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==" - "resolved" "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" - "version" "3.1.1" - -"escape-string-regexp@^1.0.5": - "integrity" "sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==" - "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" - "version" "1.0.5" - -"escape-string-regexp@4.0.0": - "integrity" "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==" - "resolved" "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" - "version" "4.0.0" - -"ethereum-cryptography@^1.1.2": - "integrity" "sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw==" - "resolved" "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz" - "version" "1.2.0" + fsevents "~2.3.2" + +cliui@^4.0.0: + version "4.1.0" + resolved "https://registry.npmjs.org/cliui/-/cliui-4.1.0.tgz" + integrity sha512-4FG+RSG9DL7uEwRUZXZn3SS34DiDPfzP0VOiEwtUWlE+AR2EIg+hSyvrIgUUfhdgR/UkAeW2QHgeP+hWrXs7jQ== + dependencies: + string-width "^2.1.1" + strip-ansi "^4.0.0" + wrap-ansi "^2.0.0" + +cliui@^7.0.2: + version "7.0.4" + resolved "https://registry.npmjs.org/cliui/-/cliui-7.0.4.tgz" + integrity sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^7.0.0" + +code-point-at@^1.0.0: + version "1.1.0" + resolved "https://registry.npmjs.org/code-point-at/-/code-point-at-1.1.0.tgz" + integrity sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA== + +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.npmjs.org/color-convert/-/color-convert-1.9.3.tgz" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== + dependencies: + color-name "1.1.3" + +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.3.tgz" + integrity sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw== + +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== + +combine-errors@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/combine-errors/-/combine-errors-3.0.3.tgz#f4df6740083e5703a3181110c2b10551f003da86" + integrity sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q== + dependencies: + custom-error-instance "2.1.1" + lodash.uniqby "4.5.0" + +concat-map@0.0.1: + version "0.0.1" + resolved "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz" + integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== + +core-js@^3.27.2: + version "3.31.0" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.31.0.tgz#4471dd33e366c79d8c0977ed2d940821719db344" + integrity sha512-NIp2TQSGfR6ba5aalZD+ZQ1fSxGhDo/s1w0nx3RYzf2pnJxt7YynxFlFScP6eV7+GZsKO95NSjGxyJsU3DZgeQ== + +create-require@^1.1.0: + version "1.1.1" + resolved "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz" + integrity sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ== + +cross-fetch@^3.1.5: + version "3.1.8" + resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-3.1.8.tgz#0327eba65fd68a7d119f8fb2bf9334a1a7956f82" + integrity sha512-cvA+JwZoU0Xq+h6WkMvAUqPEYy92Obet6UdKLfW60qn99ftItKjB5T+BkyWOFWe2pUyfQ+IJHmpOTznqk1M6Kg== + dependencies: + node-fetch "^2.6.12" + +cross-spawn@^6.0.0, cross-spawn@^6.0.5: + version "6.0.5" + resolved "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz" + integrity sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ== + dependencies: + nice-try "^1.0.4" + path-key "^2.0.1" + semver "^5.5.0" + shebang-command "^1.2.0" + which "^1.2.9" + +crypto-js@^4.1.1: + version "4.1.1" + resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" + integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== + +custom-error-instance@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/custom-error-instance/-/custom-error-instance-2.1.1.tgz#3cf6391487a6629a6247eb0ca0ce00081b7e361a" + integrity sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg== + +debug@4.3.4, debug@^4.3.2: + version "4.3.4" + resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" + integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== + dependencies: + ms "2.1.2" + +decamelize@^1.1.1: + version "1.2.0" + resolved "https://registry.npmjs.org/decamelize/-/decamelize-1.2.0.tgz" + integrity sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA== + +decamelize@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/decamelize/-/decamelize-4.0.0.tgz" + integrity sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ== + +deep-eql@^4.1.2: + version "4.1.3" + resolved "https://registry.npmjs.org/deep-eql/-/deep-eql-4.1.3.tgz" + integrity sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw== + dependencies: + type-detect "^4.0.0" + +diff@5.0.0: + version "5.0.0" + resolved "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" + integrity sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w== + +diff@^4.0.1: + version "4.0.2" + resolved "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz" + integrity sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A== + +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + +end-of-stream@^1.1.0: + version "1.4.4" + resolved "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.4.tgz" + integrity sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q== + dependencies: + once "^1.4.0" + +err-code@^3.0.1: + version "3.0.1" + resolved "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz" + integrity sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA== + +escalade@^3.1.1: + version "3.1.1" + resolved "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" + integrity sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw== + +escape-string-regexp@4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" + integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== + +escape-string-regexp@^1.0.5: + version "1.0.5" + resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" + integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== + +ethereum-cryptography@^1.1.2: + version "1.2.0" + resolved "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-1.2.0.tgz" + integrity sha512-6yFQC9b5ug6/17CQpCyE3k9eKBMdhyVjzUy1WkiuY/E4vj/SXDBbCw8QEIaXqf0Mf2SnY6RmpDcwlUmBSS0EJw== dependencies: "@noble/hashes" "1.2.0" "@noble/secp256k1" "1.7.1" "@scure/bip32" "1.1.5" "@scure/bip39" "1.1.1" -"ethers@^5.6.8": - "integrity" "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==" - "resolved" "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz" - "version" "5.7.2" - dependencies: - "@ethersproject/abi" "5.7.0" - "@ethersproject/abstract-provider" "5.7.0" - "@ethersproject/abstract-signer" "5.7.0" - "@ethersproject/address" "5.7.0" - "@ethersproject/base64" "5.7.0" - "@ethersproject/basex" "5.7.0" - "@ethersproject/bignumber" "5.7.0" - "@ethersproject/bytes" "5.7.0" - "@ethersproject/constants" "5.7.0" - "@ethersproject/contracts" "5.7.0" - "@ethersproject/hash" "5.7.0" - "@ethersproject/hdnode" "5.7.0" - "@ethersproject/json-wallets" "5.7.0" - "@ethersproject/keccak256" "5.7.0" - "@ethersproject/logger" "5.7.0" - "@ethersproject/networks" "5.7.1" - "@ethersproject/pbkdf2" "5.7.0" - "@ethersproject/properties" "5.7.0" - "@ethersproject/providers" "5.7.2" - "@ethersproject/random" "5.7.0" - "@ethersproject/rlp" "5.7.0" - "@ethersproject/sha2" "5.7.0" - "@ethersproject/signing-key" "5.7.0" - "@ethersproject/solidity" "5.7.0" - "@ethersproject/strings" "5.7.0" - "@ethersproject/transactions" "5.7.0" - "@ethersproject/units" "5.7.0" - "@ethersproject/wallet" "5.7.0" - "@ethersproject/web" "5.7.1" - "@ethersproject/wordlists" "5.7.0" - -"ethjs-util@^0.1.6": - "integrity" "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==" - "resolved" "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz" - "version" "0.1.6" - dependencies: - "is-hex-prefixed" "1.0.0" - "strip-hex-prefix" "1.0.0" - -"execa@^1.0.0": - "integrity" "sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA==" - "resolved" "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "cross-spawn" "^6.0.0" - "get-stream" "^4.0.0" - "is-stream" "^1.1.0" - "npm-run-path" "^2.0.0" - "p-finally" "^1.0.0" - "signal-exit" "^3.0.0" - "strip-eof" "^1.0.0" - -"fill-range@^7.0.1": - "integrity" "sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==" - "resolved" "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" - "version" "7.0.1" - dependencies: - "to-regex-range" "^5.0.1" - -"find-up@^2.1.0": - "integrity" "sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==" - "resolved" "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz" - "version" "2.1.0" - dependencies: - "locate-path" "^2.0.0" - -"find-up@5.0.0": - "integrity" "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==" - "resolved" "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz" - "version" "5.0.0" - dependencies: - "locate-path" "^6.0.0" - "path-exists" "^4.0.0" - -"flat@^5.0.2": - "integrity" "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==" - "resolved" "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz" - "version" "5.0.2" - -"fs.realpath@^1.0.0": - "integrity" "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" - "resolved" "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" - "version" "1.0.0" - -"fsevents@~2.3.2": - "integrity" "sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==" - "resolved" "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz" - "version" "2.3.2" - -"get-browser-rtc@^1.1.0": - "integrity" "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" - "resolved" "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz" - "version" "1.1.0" - -"get-caller-file@^1.0.1": - "integrity" "sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==" - "resolved" "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz" - "version" "1.0.3" - -"get-caller-file@^2.0.5": - "integrity" "sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==" - "resolved" "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" - "version" "2.0.5" - -"get-func-name@^2.0.0": - "integrity" "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==" - "resolved" "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz" - "version" "2.0.0" - -"get-stream@^4.0.0": - "integrity" "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==" - "resolved" "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" - "version" "4.1.0" - dependencies: - "pump" "^3.0.0" - -"glob-parent@~5.1.2": - "integrity" "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==" - "resolved" "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" - "version" "5.1.2" - dependencies: - "is-glob" "^4.0.1" - -"glob@7.2.0": - "integrity" "sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==" - "resolved" "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz" - "version" "7.2.0" - dependencies: - "fs.realpath" "^1.0.0" - "inflight" "^1.0.4" - "inherits" "2" - "minimatch" "^3.0.4" - "once" "^1.3.0" - "path-is-absolute" "^1.0.0" - -"has-flag@^3.0.0": - "integrity" "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==" - "resolved" "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" - "version" "3.0.0" - -"has-flag@^4.0.0": - "integrity" "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==" - "resolved" "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" - "version" "4.0.0" - -"hash.js@^1.0.0", "hash.js@^1.0.3", "hash.js@1.1.7": - "integrity" "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==" - "resolved" "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" - "version" "1.1.7" - dependencies: - "inherits" "^2.0.3" - "minimalistic-assert" "^1.0.1" - -"he@1.2.0": - "integrity" "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==" - "resolved" "https://registry.npmjs.org/he/-/he-1.2.0.tgz" - "version" "1.2.0" - -"hmac-drbg@^1.0.1": - "integrity" "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==" - "resolved" "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz" - "version" "1.0.1" - dependencies: - "hash.js" "^1.0.3" - "minimalistic-assert" "^1.0.0" - "minimalistic-crypto-utils" "^1.0.1" - -"ieee754@^1.2.1": - "integrity" "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" - "resolved" "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" - "version" "1.2.1" - -"immer@^10.0.2": - "integrity" "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==" - "resolved" "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz" - "version" "10.0.2" - -"inflight@^1.0.4": - "integrity" "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==" - "resolved" "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" - "version" "1.0.6" - dependencies: - "once" "^1.3.0" - "wrappy" "1" - -"inherits@^2.0.1", "inherits@^2.0.3", "inherits@^2.0.4", "inherits@2": - "integrity" "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" - "resolved" "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" - "version" "2.0.4" - -"invert-kv@^2.0.0": - "integrity" "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==" - "resolved" "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" - "version" "2.0.0" - -"is-binary-path@~2.1.0": - "integrity" "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==" - "resolved" "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" - "version" "2.1.0" - dependencies: - "binary-extensions" "^2.0.0" - -"is-extglob@^2.1.1": - "integrity" "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==" - "resolved" "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" - "version" "2.1.1" - -"is-fullwidth-code-point@^1.0.0": - "integrity" "sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==" - "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" - "version" "1.0.0" - dependencies: - "number-is-nan" "^1.0.0" - -"is-fullwidth-code-point@^2.0.0": - "integrity" "sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==" - "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" - "version" "2.0.0" - -"is-fullwidth-code-point@^3.0.0": - "integrity" "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==" - "resolved" "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz" - "version" "3.0.0" - -"is-glob@^4.0.1", "is-glob@~4.0.1": - "integrity" "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==" - "resolved" "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz" - "version" "4.0.3" - dependencies: - "is-extglob" "^2.1.1" - -"is-hex-prefixed@1.0.0": - "integrity" "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==" - "resolved" "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz" - "version" "1.0.0" - -"is-number@^7.0.0": - "integrity" "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==" - "resolved" "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" - "version" "7.0.0" - -"is-plain-obj@^2.1.0": - "integrity" "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==" - "resolved" "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz" - "version" "2.1.0" - -"is-stream@^1.1.0": - "integrity" "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==" - "resolved" "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" - "version" "1.1.0" - -"is-unicode-supported@^0.1.0": - "integrity" "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==" - "resolved" "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz" - "version" "0.1.0" - -"isexe@^2.0.0": - "integrity" "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" - "resolved" "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" - "version" "2.0.0" - -"js-sha3@0.8.0": - "integrity" "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" - "resolved" "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz" - "version" "0.8.0" - -"js-yaml@4.1.0": - "integrity" "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==" - "resolved" "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz" - "version" "4.1.0" - dependencies: - "argparse" "^2.0.1" - -"lcid@^2.0.0": - "integrity" "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==" - "resolved" "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "invert-kv" "^2.0.0" - -"locate-path@^2.0.0": - "integrity" "sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==" - "resolved" "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "p-locate" "^2.0.0" - "path-exists" "^3.0.0" - -"locate-path@^6.0.0": - "integrity" "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==" - "resolved" "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz" - "version" "6.0.0" - dependencies: - "p-locate" "^5.0.0" - -"log-symbols@4.1.0": - "integrity" "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==" - "resolved" "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" - "version" "4.1.0" - dependencies: - "chalk" "^4.1.0" - "is-unicode-supported" "^0.1.0" - -"loupe@^2.3.1": - "integrity" "sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA==" - "resolved" "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz" - "version" "2.3.6" - dependencies: - "get-func-name" "^2.0.0" - -"make-error@^1.1.1": - "integrity" "sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==" - "resolved" "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz" - "version" "1.3.6" - -"map-age-cleaner@^0.1.1": - "integrity" "sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w==" - "resolved" "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" - "version" "0.1.3" - dependencies: - "p-defer" "^1.0.0" - -"mem@^4.0.0": - "integrity" "sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w==" - "resolved" "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz" - "version" "4.3.0" +ethjs-util@^0.1.6: + version "0.1.6" + resolved "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz" + integrity sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w== + dependencies: + is-hex-prefixed "1.0.0" + strip-hex-prefix "1.0.0" + +events@3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" + integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== + +execa@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/execa/-/execa-1.0.0.tgz" + integrity sha512-adbxcyWV46qiHyvSp50TKt05tB4tK3HcmF7/nxfAdhnox83seTDbwnaqKO4sXRy7roHAIFqJP/Rw/AuEbX61LA== + dependencies: + cross-spawn "^6.0.0" + get-stream "^4.0.0" + is-stream "^1.1.0" + npm-run-path "^2.0.0" + p-finally "^1.0.0" + signal-exit "^3.0.0" + strip-eof "^1.0.0" + +fill-range@^7.0.1: + version "7.0.1" + resolved "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" + integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ== + dependencies: + to-regex-range "^5.0.1" + +find-up@5.0.0: + version "5.0.0" + resolved "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz" + integrity sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng== + dependencies: + locate-path "^6.0.0" + path-exists "^4.0.0" + +find-up@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz" + integrity sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ== + dependencies: + locate-path "^2.0.0" + +flat@^5.0.2: + version "5.0.2" + resolved "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz" + integrity sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ== + +fs.realpath@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" + integrity sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw== + +fsevents@~2.3.2: + version "2.3.2" + resolved "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz" + integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== + +get-browser-rtc@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz" + integrity sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ== + +get-caller-file@^1.0.1: + version "1.0.3" + resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-1.0.3.tgz" + integrity sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w== + +get-caller-file@^2.0.5: + version "2.0.5" + resolved "https://registry.npmjs.org/get-caller-file/-/get-caller-file-2.0.5.tgz" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== + +get-func-name@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz" + integrity sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig== + +get-stream@^4.0.0: + version "4.1.0" + resolved "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" + integrity sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w== + dependencies: + pump "^3.0.0" + +glob-parent@~5.1.2: + version "5.1.2" + resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" + integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== + dependencies: + is-glob "^4.0.1" + +glob@7.2.0: + version "7.2.0" + resolved "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz" + integrity sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q== + dependencies: + fs.realpath "^1.0.0" + inflight "^1.0.4" + inherits "2" + minimatch "^3.0.4" + once "^1.3.0" + path-is-absolute "^1.0.0" + +graceful-fs@^4.2.4: + version "4.2.11" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" + integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== + +has-flag@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" + integrity sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw== + +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + +he@1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/he/-/he-1.2.0.tgz" + integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== + +hls.js@^1.4.0: + version "1.4.8" + resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.4.8.tgz#6fedcb5224d7361e4f38046ffd45286d8a645df8" + integrity sha512-wYL7W49M6oKv0+P4RW50YkJaxDzgnHMMrN+YoLpow07hVgaedAdX9HfKkehTb04UEfeJhNSef5ucICYPsHOfqg== + +ieee754@^1.2.1: + version "1.2.1" + resolved "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" + integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== + +immer@^10.0.2: + version "10.0.2" + resolved "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz" + integrity sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA== + +inflight@^1.0.4: + version "1.0.6" + resolved "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz" + integrity sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA== + dependencies: + once "^1.3.0" + wrappy "1" + +inherits@2, inherits@^2.0.1, inherits@^2.0.3: + version "2.0.4" + resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" + integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== + +invert-kv@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" + integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== + +is-binary-path@~2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" + integrity sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw== + dependencies: + binary-extensions "^2.0.0" + +is-extglob@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" + integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== + +is-fullwidth-code-point@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" + integrity sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw== + dependencies: + number-is-nan "^1.0.0" + +is-fullwidth-code-point@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz" + integrity sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w== + +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== + +is-glob@^4.0.1, is-glob@~4.0.1: + version "4.0.3" + resolved "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz" + integrity sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg== + dependencies: + is-extglob "^2.1.1" + +is-hex-prefixed@1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz" + integrity sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA== + +is-number@^7.0.0: + version "7.0.0" + resolved "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" + integrity sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng== + +is-plain-obj@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz" + integrity sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA== + +is-stream@^1.1.0: + version "1.1.0" + resolved "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" + integrity sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ== + +is-stream@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" + integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== + +is-unicode-supported@^0.1.0: + version "0.1.0" + resolved "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz" + integrity sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw== + +isexe@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" + integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== + +js-base64@^3.7.2: + version "3.7.5" + resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.5.tgz#21e24cf6b886f76d6f5f165bfcd69cc55b9e3fca" + integrity sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA== + +js-yaml@4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz" + integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== + dependencies: + argparse "^2.0.1" + +lcid@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/lcid/-/lcid-2.0.0.tgz" + integrity sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA== + dependencies: + invert-kv "^2.0.0" + +livepeer@^2.5.8: + version "2.5.8" + resolved "https://registry.yarnpkg.com/livepeer/-/livepeer-2.5.8.tgz#afce72633bb1036d1fe3c837ad997a5dce957b54" + integrity sha512-V+VZVXjEo47A0hxUAB6HLGSBjEvksBXJyFTatkYqarfU6T8gMk+37RugEOsZn6dDj9up4+6A7xWygKoC1zu+ow== + dependencies: + "@livepeer/core" "^1.5.8" + "@stitches/core" "^1.2.8" + core-js "^3.27.2" + cross-fetch "^3.1.5" + hls.js "^1.4.0" + ms "^3.0.0-canary.1" + multiformats "9.9.0" + tus-js-client "^3.0.1" + zustand "^4.3.2" + +locate-path@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz" + integrity sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA== + dependencies: + p-locate "^2.0.0" + path-exists "^3.0.0" + +locate-path@^6.0.0: + version "6.0.0" + resolved "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz" + integrity sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw== + dependencies: + p-locate "^5.0.0" + +lodash._baseiteratee@~4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz#34a9b5543572727c3db2e78edae3c0e9e66bd102" + integrity sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ== + dependencies: + lodash._stringtopath "~4.8.0" + +lodash._basetostring@~4.12.0: + version "4.12.0" + resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz#9327c9dc5158866b7fa4b9d42f4638e5766dd9df" + integrity sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw== + +lodash._baseuniq@~4.6.0: + version "4.6.0" + resolved "https://registry.yarnpkg.com/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz#0ebb44e456814af7905c6212fa2c9b2d51b841e8" + integrity sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A== + dependencies: + lodash._createset "~4.0.0" + lodash._root "~3.0.0" + +lodash._createset@~4.0.0: + version "4.0.3" + resolved "https://registry.yarnpkg.com/lodash._createset/-/lodash._createset-4.0.3.tgz#0f4659fbb09d75194fa9e2b88a6644d363c9fe26" + integrity sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA== + +lodash._root@~3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" + integrity sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ== + +lodash._stringtopath@~4.8.0: + version "4.8.0" + resolved "https://registry.yarnpkg.com/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz#941bcf0e64266e5fc1d66fed0a6959544c576824" + integrity sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ== + dependencies: + lodash._basetostring "~4.12.0" + +lodash.throttle@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4" + integrity sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ== + +lodash.uniqby@4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz#a3a17bbf62eeb6240f491846e97c1c4e2a5e1e21" + integrity sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ== + dependencies: + lodash._baseiteratee "~4.7.0" + lodash._baseuniq "~4.6.0" + +log-symbols@4.1.0: + version "4.1.0" + resolved "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" + integrity sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg== + dependencies: + chalk "^4.1.0" + is-unicode-supported "^0.1.0" + +loupe@^2.3.1: + version "2.3.6" + resolved "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz" + integrity sha512-RaPMZKiMy8/JruncMU5Bt6na1eftNoo++R4Y+N2FrxkDVTrGvcyzFTsaGif4QTeKESheMGegbhw6iUAq+5A8zA== + dependencies: + get-func-name "^2.0.0" + +make-error@^1.1.1: + version "1.3.6" + resolved "https://registry.npmjs.org/make-error/-/make-error-1.3.6.tgz" + integrity sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw== + +map-age-cleaner@^0.1.1: + version "0.1.3" + resolved "https://registry.npmjs.org/map-age-cleaner/-/map-age-cleaner-0.1.3.tgz" + integrity sha512-bJzx6nMoP6PDLPBFmg7+xRKeFZvFboMrGlxmNj9ClvX53KrmvM5bXFXEWjbz4cz1AFn+jWJ9z/DJSz7hrs0w3w== + dependencies: + p-defer "^1.0.0" + +mem@^4.0.0: + version "4.3.0" + resolved "https://registry.npmjs.org/mem/-/mem-4.3.0.tgz" + integrity sha512-qX2bG48pTqYRVmDB37rn/6PT7LcR8T7oAX3bf99u1Tt1nzxYfxkgqDwUwolPlXweM0XzBOBFzSx4kfp7KP1s/w== dependencies: - "map-age-cleaner" "^0.1.1" - "mimic-fn" "^2.0.0" - "p-is-promise" "^2.0.0" + map-age-cleaner "^0.1.1" + mimic-fn "^2.0.0" + p-is-promise "^2.0.0" -"mimic-fn@^2.0.0": - "integrity" "sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg==" - "resolved" "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" - "version" "2.1.0" +mimic-fn@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" + integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== -"minimalistic-assert@^1.0.0", "minimalistic-assert@^1.0.1": - "integrity" "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" - "resolved" "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" - "version" "1.0.1" +minimalistic-assert@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" + integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== -"minimalistic-crypto-utils@^1.0.1": - "integrity" "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" - "resolved" "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz" - "version" "1.0.1" - -"minimatch@^3.0.4": - "integrity" "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==" - "resolved" "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" - "version" "3.1.2" +minimatch@5.0.1: + version "5.0.1" + resolved "https://registry.npmjs.org/minimatch/-/minimatch-5.0.1.tgz" + integrity sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g== dependencies: - "brace-expansion" "^1.1.7" + brace-expansion "^2.0.1" -"minimatch@5.0.1": - "integrity" "sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g==" - "resolved" "https://registry.npmjs.org/minimatch/-/minimatch-5.0.1.tgz" - "version" "5.0.1" - dependencies: - "brace-expansion" "^2.0.1" +minimatch@^3.0.4: + version "3.1.2" + resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" + integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== + dependencies: + brace-expansion "^1.1.7" -"mocha-typescript@^1.1.17": - "integrity" "sha512-Ge6pCQkZumkkhxVNdAf3JxunskShgaynCb30HYD7TT1Yhog/7NW2+6w5RcRHI+nuQrCMTX6z1+qf2pD8qwCoQA==" - "resolved" "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz" - "version" "1.1.17" +mocha-typescript@^1.1.17: + version "1.1.17" + resolved "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz" + integrity sha512-Ge6pCQkZumkkhxVNdAf3JxunskShgaynCb30HYD7TT1Yhog/7NW2+6w5RcRHI+nuQrCMTX6z1+qf2pD8qwCoQA== dependencies: "@types/mocha" "^5.2.0" - "chalk" "^2.4.1" - "cross-spawn" "^6.0.5" - "yargs" "^11.0.0" - -"mocha@^10.2.0": - "integrity" "sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg==" - "resolved" "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz" - "version" "10.2.0" - dependencies: - "ansi-colors" "4.1.1" - "browser-stdout" "1.3.1" - "chokidar" "3.5.3" - "debug" "4.3.4" - "diff" "5.0.0" - "escape-string-regexp" "4.0.0" - "find-up" "5.0.0" - "glob" "7.2.0" - "he" "1.2.0" - "js-yaml" "4.1.0" - "log-symbols" "4.1.0" - "minimatch" "5.0.1" - "ms" "2.1.3" - "nanoid" "3.3.3" - "serialize-javascript" "6.0.0" - "strip-json-comments" "3.1.1" - "supports-color" "8.1.1" - "workerpool" "6.2.1" - "yargs" "16.2.0" - "yargs-parser" "20.2.4" - "yargs-unparser" "2.0.0" - -"ms@2.1.2": - "integrity" "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" - "resolved" "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" - "version" "2.1.2" - -"ms@2.1.3": - "integrity" "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" - "resolved" "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz" - "version" "2.1.3" - -"nanoid@3.3.3": - "integrity" "sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==" - "resolved" "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz" - "version" "3.3.3" - -"nice-try@^1.0.4": - "integrity" "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==" - "resolved" "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" - "version" "1.0.5" - -"normalize-path@^3.0.0", "normalize-path@~3.0.0": - "integrity" "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==" - "resolved" "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz" - "version" "3.0.0" - -"npm-run-path@^2.0.0": - "integrity" "sha512-lJxZYlT4DW/bRUtFh1MQIWqmLwQfAxnqWG4HhEdjMlkrJYnJn0Jrr2u3mgxqaWsdiBc76TYkTG/mhrnYTuzfHw==" - "resolved" "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz" - "version" "2.0.2" - dependencies: - "path-key" "^2.0.0" - -"number-is-nan@^1.0.0": - "integrity" "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==" - "resolved" "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" - "version" "1.0.1" - -"once@^1.3.0", "once@^1.3.1", "once@^1.4.0": - "integrity" "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==" - "resolved" "https://registry.npmjs.org/once/-/once-1.4.0.tgz" - "version" "1.4.0" - dependencies: - "wrappy" "1" - -"openpgp@^5.5.0": - "integrity" "sha512-SpwcJnxrK9Y0HRM6KxSFqkAEOSWEabCH/c8dII/+y2e5f6KvuDG5ZE7JXaPBaVJNE4VUZZeTphxXDoZD0KOHrw==" - "resolved" "https://registry.npmjs.org/openpgp/-/openpgp-5.5.0.tgz" - "version" "5.5.0" - dependencies: - "asn1.js" "^5.0.0" - -"os-locale@^3.1.0": - "integrity" "sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q==" - "resolved" "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "execa" "^1.0.0" - "lcid" "^2.0.0" - "mem" "^4.0.0" - -"p-defer@^1.0.0": - "integrity" "sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw==" - "resolved" "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz" - "version" "1.0.0" - -"p-finally@^1.0.0": - "integrity" "sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==" - "resolved" "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz" - "version" "1.0.0" - -"p-is-promise@^2.0.0": - "integrity" "sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg==" - "resolved" "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz" - "version" "2.1.0" - -"p-limit@^1.1.0": - "integrity" "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==" - "resolved" "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz" - "version" "1.3.0" - dependencies: - "p-try" "^1.0.0" - -"p-limit@^3.0.2": - "integrity" "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==" - "resolved" "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz" - "version" "3.1.0" - dependencies: - "yocto-queue" "^0.1.0" - -"p-locate@^2.0.0": - "integrity" "sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==" - "resolved" "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "p-limit" "^1.1.0" - -"p-locate@^5.0.0": - "integrity" "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==" - "resolved" "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz" - "version" "5.0.0" - dependencies: - "p-limit" "^3.0.2" - -"p-try@^1.0.0": - "integrity" "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==" - "resolved" "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz" - "version" "1.0.0" - -"path-exists@^3.0.0": - "integrity" "sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==" - "resolved" "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" - "version" "3.0.0" - -"path-exists@^4.0.0": - "integrity" "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==" - "resolved" "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz" - "version" "4.0.0" - -"path-is-absolute@^1.0.0": - "integrity" "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==" - "resolved" "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" - "version" "1.0.1" - -"path-key@^2.0.0", "path-key@^2.0.1": - "integrity" "sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==" - "resolved" "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" - "version" "2.0.1" - -"pathval@^1.1.1": - "integrity" "sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==" - "resolved" "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz" - "version" "1.1.1" - -"picomatch@^2.0.4", "picomatch@^2.2.1": - "integrity" "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==" - "resolved" "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" - "version" "2.3.1" - -"pump@^3.0.0": - "integrity" "sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==" - "resolved" "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz" - "version" "3.0.0" - dependencies: - "end-of-stream" "^1.1.0" - "once" "^1.3.1" - -"queue-microtask@^1.2.3": - "integrity" "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==" - "resolved" "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz" - "version" "1.2.3" - -"randombytes@^2.1.0": - "integrity" "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==" - "resolved" "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz" - "version" "2.1.0" - dependencies: - "safe-buffer" "^5.1.0" - -"readable-stream@^3.6.0": - "integrity" "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==" - "resolved" "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz" - "version" "3.6.2" - dependencies: - "inherits" "^2.0.3" - "string_decoder" "^1.1.1" - "util-deprecate" "^1.0.1" - -"readdirp@~3.6.0": - "integrity" "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==" - "resolved" "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" - "version" "3.6.0" - dependencies: - "picomatch" "^2.2.1" - -"require-directory@^2.1.1": - "integrity" "sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==" - "resolved" "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" - "version" "2.1.1" - -"require-main-filename@^1.0.1": - "integrity" "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==" - "resolved" "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz" - "version" "1.0.1" - -"safe-buffer@^5.1.0", "safe-buffer@~5.2.0": - "integrity" "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" - "resolved" "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" - "version" "5.2.1" - -"safer-buffer@^2.1.0": - "integrity" "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" - "resolved" "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" - "version" "2.1.2" - -"scrypt-js@3.0.1": - "integrity" "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" - "resolved" "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz" - "version" "3.0.1" - -"semver@^5.5.0": - "integrity" "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" - "resolved" "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz" - "version" "5.7.1" - -"serialize-javascript@6.0.0": - "integrity" "sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==" - "resolved" "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz" - "version" "6.0.0" - dependencies: - "randombytes" "^2.1.0" - -"set-blocking@^2.0.0": - "integrity" "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==" - "resolved" "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" - "version" "2.0.0" - -"shebang-command@^1.2.0": - "integrity" "sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==" - "resolved" "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" - "version" "1.2.0" - dependencies: - "shebang-regex" "^1.0.0" - -"shebang-regex@^1.0.0": - "integrity" "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==" - "resolved" "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" - "version" "1.0.0" - -"signal-exit@^3.0.0": - "integrity" "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" - "resolved" "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" - "version" "3.0.7" - -"simple-peer@^9.11.1": - "integrity" "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==" - "resolved" "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz" - "version" "9.11.1" - dependencies: - "buffer" "^6.0.3" - "debug" "^4.3.2" - "err-code" "^3.0.1" - "get-browser-rtc" "^1.1.0" - "queue-microtask" "^1.2.3" - "randombytes" "^2.1.0" - "readable-stream" "^3.6.0" - -"string_decoder@^1.1.1": - "integrity" "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==" - "resolved" "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz" - "version" "1.3.0" - dependencies: - "safe-buffer" "~5.2.0" - -"string-width@^1.0.1": - "integrity" "sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==" - "resolved" "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" - "version" "1.0.2" - dependencies: - "code-point-at" "^1.0.0" - "is-fullwidth-code-point" "^1.0.0" - "strip-ansi" "^3.0.0" - -"string-width@^2.0.0", "string-width@^2.1.1": - "integrity" "sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==" - "resolved" "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz" - "version" "2.1.1" - dependencies: - "is-fullwidth-code-point" "^2.0.0" - "strip-ansi" "^4.0.0" - -"string-width@^4.1.0", "string-width@^4.2.0": - "integrity" "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==" - "resolved" "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" - "version" "4.2.3" - dependencies: - "emoji-regex" "^8.0.0" - "is-fullwidth-code-point" "^3.0.0" - "strip-ansi" "^6.0.1" - -"strip-ansi@^3.0.0", "strip-ansi@^3.0.1": - "integrity" "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==" - "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" - "version" "3.0.1" - dependencies: - "ansi-regex" "^2.0.0" - -"strip-ansi@^4.0.0": - "integrity" "sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==" - "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz" - "version" "4.0.0" - dependencies: - "ansi-regex" "^3.0.0" + chalk "^2.4.1" + cross-spawn "^6.0.5" + yargs "^11.0.0" + +mocha@^10.2.0: + version "10.2.0" + resolved "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz" + integrity sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg== + dependencies: + ansi-colors "4.1.1" + browser-stdout "1.3.1" + chokidar "3.5.3" + debug "4.3.4" + diff "5.0.0" + escape-string-regexp "4.0.0" + find-up "5.0.0" + glob "7.2.0" + he "1.2.0" + js-yaml "4.1.0" + log-symbols "4.1.0" + minimatch "5.0.1" + ms "2.1.3" + nanoid "3.3.3" + serialize-javascript "6.0.0" + strip-json-comments "3.1.1" + supports-color "8.1.1" + workerpool "6.2.1" + yargs "16.2.0" + yargs-parser "20.2.4" + yargs-unparser "2.0.0" + +ms@2.1.2: + version "2.1.2" + resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + +ms@2.1.3: + version "2.1.3" + resolved "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + +ms@^3.0.0-canary.1: + version "3.0.0-canary.1" + resolved "https://registry.yarnpkg.com/ms/-/ms-3.0.0-canary.1.tgz#c7b34fbce381492fd0b345d1cf56e14d67b77b80" + integrity sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g== + +multiformats@9.9.0: + version "9.9.0" + resolved "https://registry.yarnpkg.com/multiformats/-/multiformats-9.9.0.tgz#c68354e7d21037a8f1f8833c8ccd68618e8f1d37" + integrity sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg== + +nanoid@3.3.3: + version "3.3.3" + resolved "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz" + integrity sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w== + +nice-try@^1.0.4: + version "1.0.5" + resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" + integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== + +node-fetch@^2.6.12: + version "2.6.12" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.12.tgz#02eb8e22074018e3d5a83016649d04df0e348fba" + integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== + dependencies: + whatwg-url "^5.0.0" + +normalize-path@^3.0.0, normalize-path@~3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz" + integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== + +npm-run-path@^2.0.0: + version "2.0.2" + resolved "https://registry.npmjs.org/npm-run-path/-/npm-run-path-2.0.2.tgz" + integrity sha512-lJxZYlT4DW/bRUtFh1MQIWqmLwQfAxnqWG4HhEdjMlkrJYnJn0Jrr2u3mgxqaWsdiBc76TYkTG/mhrnYTuzfHw== + dependencies: + path-key "^2.0.0" + +number-is-nan@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" + integrity sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ== + +once@^1.3.0, once@^1.3.1, once@^1.4.0: + version "1.4.0" + resolved "https://registry.npmjs.org/once/-/once-1.4.0.tgz" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== + dependencies: + wrappy "1" + +openpgp@^5.5.0: + version "5.5.0" + resolved "https://registry.npmjs.org/openpgp/-/openpgp-5.5.0.tgz" + integrity sha512-SpwcJnxrK9Y0HRM6KxSFqkAEOSWEabCH/c8dII/+y2e5f6KvuDG5ZE7JXaPBaVJNE4VUZZeTphxXDoZD0KOHrw== + dependencies: + asn1.js "^5.0.0" + +os-locale@^3.1.0: + version "3.1.0" + resolved "https://registry.npmjs.org/os-locale/-/os-locale-3.1.0.tgz" + integrity sha512-Z8l3R4wYWM40/52Z+S265okfFj8Kt2cC2MKY+xNi3kFs+XGI7WXu/I309QQQYbRW4ijiZ+yxs9pqEhJh0DqW3Q== + dependencies: + execa "^1.0.0" + lcid "^2.0.0" + mem "^4.0.0" + +p-defer@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/p-defer/-/p-defer-1.0.0.tgz" + integrity sha512-wB3wfAxZpk2AzOfUMJNL+d36xothRSyj8EXOa4f6GMqYDN9BJaaSISbsk+wS9abmnebVw95C2Kb5t85UmpCxuw== + +p-finally@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz" + integrity sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow== + +p-is-promise@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/p-is-promise/-/p-is-promise-2.1.0.tgz" + integrity sha512-Y3W0wlRPK8ZMRbNq97l4M5otioeA5lm1z7bkNkxCka8HSPjR0xRWmpCmc9utiaLP9Jb1eD8BgeIxTW4AIF45Pg== + +p-limit@^1.1.0: + version "1.3.0" + resolved "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz" + integrity sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q== + dependencies: + p-try "^1.0.0" + +p-limit@^3.0.2: + version "3.1.0" + resolved "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz" + integrity sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ== + dependencies: + yocto-queue "^0.1.0" + +p-locate@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz" + integrity sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg== + dependencies: + p-limit "^1.1.0" + +p-locate@^5.0.0: + 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== + dependencies: + p-limit "^3.0.2" + +p-try@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz" + integrity sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww== + +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" + integrity sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ== + +path-exists@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz" + integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== + +path-is-absolute@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz" + integrity sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg== + +path-key@^2.0.0, path-key@^2.0.1: + version "2.0.1" + resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" + integrity sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw== + +pathval@^1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz" + integrity sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ== + +picomatch@^2.0.4, picomatch@^2.2.1: + version "2.3.1" + resolved "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" + integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== + +proper-lockfile@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/proper-lockfile/-/proper-lockfile-4.1.2.tgz#c8b9de2af6b2f1601067f98e01ac66baa223141f" + integrity sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA== + dependencies: + graceful-fs "^4.2.4" + retry "^0.12.0" + signal-exit "^3.0.2" + +pump@^3.0.0: + version "3.0.0" + resolved "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz" + integrity sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww== + dependencies: + end-of-stream "^1.1.0" + once "^1.3.1" + +querystringify@^2.1.1: + version "2.2.0" + resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== + +queue-microtask@^1.2.3: + version "1.2.3" + resolved "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz" + integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== + +randombytes@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz" + integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== + dependencies: + safe-buffer "^5.1.0" + +readable-stream@^3.6.0: + version "3.6.2" + resolved "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz" + integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + +readdirp@~3.6.0: + version "3.6.0" + resolved "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" + integrity sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA== + dependencies: + picomatch "^2.2.1" + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" + integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== + +require-main-filename@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/require-main-filename/-/require-main-filename-1.0.1.tgz" + integrity sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug== + +requires-port@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== + +retry@^0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" + integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== + +safe-buffer@^5.1.0, safe-buffer@~5.2.0: + version "5.2.1" + resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" + integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== + +safer-buffer@^2.1.0: + version "2.1.2" + resolved "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" + integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== + +semver@^5.5.0: + version "5.7.1" + resolved "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz" + integrity sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ== + +serialize-javascript@6.0.0: + version "6.0.0" + resolved "https://registry.npmjs.org/serialize-javascript/-/serialize-javascript-6.0.0.tgz" + integrity sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag== + dependencies: + randombytes "^2.1.0" + +set-blocking@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" + integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== + +shebang-command@^1.2.0: + version "1.2.0" + resolved "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" + integrity sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg== + dependencies: + shebang-regex "^1.0.0" + +shebang-regex@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" + integrity sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ== + +signal-exit@^3.0.0, signal-exit@^3.0.2: + version "3.0.7" + resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" + integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== + +simple-peer@^9.11.1: + version "9.11.1" + resolved "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz" + integrity sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw== + dependencies: + buffer "^6.0.3" + debug "^4.3.2" + err-code "^3.0.1" + get-browser-rtc "^1.1.0" + queue-microtask "^1.2.3" + randombytes "^2.1.0" + readable-stream "^3.6.0" + +string-width@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" + integrity sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw== + dependencies: + code-point-at "^1.0.0" + is-fullwidth-code-point "^1.0.0" + strip-ansi "^3.0.0" + +string-width@^2.0.0, string-width@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/string-width/-/string-width-2.1.1.tgz" + integrity sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw== + dependencies: + is-fullwidth-code-point "^2.0.0" + strip-ansi "^4.0.0" + +string-width@^4.1.0, string-width@^4.2.0: + version "4.2.3" + resolved "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string_decoder@^1.1.1: + version "1.3.0" + resolved "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz" + integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== + dependencies: + safe-buffer "~5.2.0" + +strip-ansi@^3.0.0, strip-ansi@^3.0.1: + version "3.0.1" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" + integrity sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg== + dependencies: + ansi-regex "^2.0.0" + +strip-ansi@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-4.0.0.tgz" + integrity sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow== + dependencies: + ansi-regex "^3.0.0" -"strip-ansi@^6.0.0", "strip-ansi@^6.0.1": - "integrity" "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==" - "resolved" "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" - "version" "6.0.1" +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== dependencies: - "ansi-regex" "^5.0.1" - -"strip-eof@^1.0.0": - "integrity" "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==" - "resolved" "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz" - "version" "1.0.0" + ansi-regex "^5.0.1" + +strip-eof@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz" + integrity sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q== -"strip-hex-prefix@1.0.0": - "integrity" "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==" - "resolved" "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz" - "version" "1.0.0" +strip-hex-prefix@1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz" + integrity sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A== dependencies: - "is-hex-prefixed" "1.0.0" + is-hex-prefixed "1.0.0" + +strip-json-comments@3.1.1: + 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== -"strip-json-comments@3.1.1": - "integrity" "sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==" - "resolved" "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-3.1.1.tgz" - "version" "3.1.1" - -"supports-color@^5.3.0": - "integrity" "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==" - "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" - "version" "5.5.0" +supports-color@8.1.1: + version "8.1.1" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz" + integrity sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q== dependencies: - "has-flag" "^3.0.0" - -"supports-color@^7.1.0": - "integrity" "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==" - "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz" - "version" "7.2.0" + has-flag "^4.0.0" + +supports-color@^5.3.0: + version "5.5.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" + integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== dependencies: - "has-flag" "^4.0.0" + has-flag "^3.0.0" -"supports-color@8.1.1": - "integrity" "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==" - "resolved" "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz" - "version" "8.1.1" +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== dependencies: - "has-flag" "^4.0.0" + has-flag "^4.0.0" -"to-regex-range@^5.0.1": - "integrity" "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==" - "resolved" "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" - "version" "5.0.1" +to-regex-range@^5.0.1: + 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== dependencies: - "is-number" "^7.0.0" + is-number "^7.0.0" + +tr46@~0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" + integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== -"ts-node@^10.9.1": - "integrity" "sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw==" - "resolved" "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz" - "version" "10.9.1" +ts-node@^10.9.1: + version "10.9.1" + resolved "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz" + integrity sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw== dependencies: "@cspotcode/source-map-support" "^0.8.0" "@tsconfig/node10" "^1.0.7" "@tsconfig/node12" "^1.0.7" "@tsconfig/node14" "^1.0.0" "@tsconfig/node16" "^1.0.2" - "acorn" "^8.4.1" - "acorn-walk" "^8.1.1" - "arg" "^4.1.0" - "create-require" "^1.1.0" - "diff" "^4.0.1" - "make-error" "^1.1.1" - "v8-compile-cache-lib" "^3.0.1" - "yn" "3.1.1" - -"tweetnacl-util@^0.15.1": - "integrity" "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" - "resolved" "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz" - "version" "0.15.1" - -"tweetnacl@^1.0.3": - "integrity" "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" - "resolved" "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz" - "version" "1.0.3" - -"type-detect@^4.0.0", "type-detect@^4.0.5": - "integrity" "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==" - "resolved" "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz" - "version" "4.0.8" - -"typescript@^5.0.2", "typescript@>=2.7": - "integrity" "sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw==" - "resolved" "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz" - "version" "5.0.2" - -"util-deprecate@^1.0.1": - "integrity" "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" - "resolved" "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" - "version" "1.0.2" - -"v8-compile-cache-lib@^3.0.1": - "integrity" "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==" - "resolved" "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz" - "version" "3.0.1" - -"which-module@^2.0.0": - "integrity" "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==" - "resolved" "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" - "version" "2.0.0" - -"which@^1.2.9": - "integrity" "sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==" - "resolved" "https://registry.npmjs.org/which/-/which-1.3.1.tgz" - "version" "1.3.1" - dependencies: - "isexe" "^2.0.0" - -"workerpool@6.2.1": - "integrity" "sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==" - "resolved" "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz" - "version" "6.2.1" - -"wrap-ansi@^2.0.0": - "integrity" "sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw==" - "resolved" "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz" - "version" "2.1.0" - dependencies: - "string-width" "^1.0.1" - "strip-ansi" "^3.0.1" - -"wrap-ansi@^7.0.0": - "integrity" "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==" - "resolved" "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" - "version" "7.0.0" - dependencies: - "ansi-styles" "^4.0.0" - "string-width" "^4.1.0" - "strip-ansi" "^6.0.0" - -"wrappy@1": - "integrity" "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" - "resolved" "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" - "version" "1.0.2" - -"ws@7.4.6": - "integrity" "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==" - "resolved" "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz" - "version" "7.4.6" - -"y18n@^3.2.1": - "integrity" "sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==" - "resolved" "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz" - "version" "3.2.2" - -"y18n@^5.0.5": - "integrity" "sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==" - "resolved" "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz" - "version" "5.0.8" - -"yargs-parser@^20.2.2", "yargs-parser@20.2.4": - "integrity" "sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==" - "resolved" "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.4.tgz" - "version" "20.2.4" - -"yargs-parser@^9.0.2": - "integrity" "sha512-CswCfdOgCr4MMsT1GzbEJ7Z2uYudWyrGX8Bgh/0eyCzj/DXWdKq6a/ADufkzI1WAOIW6jYaXJvRyLhDO0kfqBw==" - "resolved" "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz" - "version" "9.0.2" - dependencies: - "camelcase" "^4.1.0" - -"yargs-unparser@2.0.0": - "integrity" "sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==" - "resolved" "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz" - "version" "2.0.0" - dependencies: - "camelcase" "^6.0.0" - "decamelize" "^4.0.0" - "flat" "^5.0.2" - "is-plain-obj" "^2.1.0" - -"yargs@^11.0.0": - "integrity" "sha512-PRU7gJrJaXv3q3yQZ/+/X6KBswZiaQ+zOmdprZcouPYtQgvNU35i+68M4b1ZHLZtYFT5QObFLV+ZkmJYcwKdiw==" - "resolved" "https://registry.npmjs.org/yargs/-/yargs-11.1.1.tgz" - "version" "11.1.1" - dependencies: - "cliui" "^4.0.0" - "decamelize" "^1.1.1" - "find-up" "^2.1.0" - "get-caller-file" "^1.0.1" - "os-locale" "^3.1.0" - "require-directory" "^2.1.1" - "require-main-filename" "^1.0.1" - "set-blocking" "^2.0.0" - "string-width" "^2.0.0" - "which-module" "^2.0.0" - "y18n" "^3.2.1" - "yargs-parser" "^9.0.2" - -"yargs@16.2.0": - "integrity" "sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==" - "resolved" "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz" - "version" "16.2.0" - dependencies: - "cliui" "^7.0.2" - "escalade" "^3.1.1" - "get-caller-file" "^2.0.5" - "require-directory" "^2.1.1" - "string-width" "^4.2.0" - "y18n" "^5.0.5" - "yargs-parser" "^20.2.2" - -"yn@3.1.1": - "integrity" "sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==" - "resolved" "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz" - "version" "3.1.1" - -"yocto-queue@^0.1.0": - "integrity" "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==" - "resolved" "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz" - "version" "0.1.0" + acorn "^8.4.1" + acorn-walk "^8.1.1" + arg "^4.1.0" + create-require "^1.1.0" + diff "^4.0.1" + make-error "^1.1.1" + v8-compile-cache-lib "^3.0.1" + yn "3.1.1" + +tus-js-client@^3.0.1: + version "3.1.0" + resolved "https://registry.yarnpkg.com/tus-js-client/-/tus-js-client-3.1.0.tgz#20af57d06c23823fbe108ccb3a3dcb7503968cb4" + integrity sha512-Hfpc8ho4C9Lhs/OflPUA/nHUHZJUrKD5upoPBq7dYJJ9DQhWocsjJU2RZYfN16Y5n19j9dFDszwCvVZ5sfcogw== + dependencies: + buffer-from "^1.1.2" + combine-errors "^3.0.3" + is-stream "^2.0.0" + js-base64 "^3.7.2" + lodash.throttle "^4.1.1" + proper-lockfile "^4.1.2" + url-parse "^1.5.7" + +tweetnacl-util@^0.15.1: + version "0.15.1" + resolved "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz" + integrity sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw== + +tweetnacl@^1.0.3: + version "1.0.3" + resolved "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz" + integrity sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw== + +type-detect@^4.0.0, type-detect@^4.0.5: + version "4.0.8" + resolved "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz" + integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== + +typescript@^5.0.2: + version "5.0.2" + resolved "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz" + integrity sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw== + +url-parse@^1.5.7: + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + +use-sync-external-store@1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a" + integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== + +util-deprecate@^1.0.1: + version "1.0.2" + resolved "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" + integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== + +v8-compile-cache-lib@^3.0.1: + version "3.0.1" + resolved "https://registry.npmjs.org/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz" + integrity sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg== + +video-stream-merger@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/video-stream-merger/-/video-stream-merger-4.0.1.tgz#b0061251bd211121d1256ccf9e2be9477e59d5cb" + integrity sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA== + +webidl-conversions@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" + integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== + +whatwg-url@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" + integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== + dependencies: + tr46 "~0.0.3" + webidl-conversions "^3.0.0" + +which-module@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" + integrity sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q== + +which@^1.2.9: + version "1.3.1" + resolved "https://registry.npmjs.org/which/-/which-1.3.1.tgz" + integrity sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ== + dependencies: + isexe "^2.0.0" + +workerpool@6.2.1: + version "6.2.1" + resolved "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz" + integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw== + +wrap-ansi@^2.0.0: + version "2.1.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-2.1.0.tgz" + integrity sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw== + dependencies: + string-width "^1.0.1" + strip-ansi "^3.0.1" + +wrap-ansi@^7.0.0: + version "7.0.0" + resolved "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-7.0.0.tgz" + integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + +wrappy@1: + version "1.0.2" + resolved "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== + +y18n@^3.2.1: + version "3.2.2" + resolved "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz" + integrity sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ== + +y18n@^5.0.5: + version "5.0.8" + resolved "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz" + integrity sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA== + +yargs-parser@20.2.4, yargs-parser@^20.2.2: + version "20.2.4" + resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-20.2.4.tgz" + integrity sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA== + +yargs-parser@^9.0.2: + version "9.0.2" + resolved "https://registry.npmjs.org/yargs-parser/-/yargs-parser-9.0.2.tgz" + integrity sha512-CswCfdOgCr4MMsT1GzbEJ7Z2uYudWyrGX8Bgh/0eyCzj/DXWdKq6a/ADufkzI1WAOIW6jYaXJvRyLhDO0kfqBw== + dependencies: + camelcase "^4.1.0" + +yargs-unparser@2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/yargs-unparser/-/yargs-unparser-2.0.0.tgz" + integrity sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA== + dependencies: + camelcase "^6.0.0" + decamelize "^4.0.0" + flat "^5.0.2" + is-plain-obj "^2.1.0" + +yargs@16.2.0: + version "16.2.0" + resolved "https://registry.npmjs.org/yargs/-/yargs-16.2.0.tgz" + integrity sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw== + dependencies: + cliui "^7.0.2" + escalade "^3.1.1" + get-caller-file "^2.0.5" + require-directory "^2.1.1" + string-width "^4.2.0" + y18n "^5.0.5" + yargs-parser "^20.2.2" + +yargs@^11.0.0: + version "11.1.1" + resolved "https://registry.npmjs.org/yargs/-/yargs-11.1.1.tgz" + integrity sha512-PRU7gJrJaXv3q3yQZ/+/X6KBswZiaQ+zOmdprZcouPYtQgvNU35i+68M4b1ZHLZtYFT5QObFLV+ZkmJYcwKdiw== + dependencies: + cliui "^4.0.0" + decamelize "^1.1.1" + find-up "^2.1.0" + get-caller-file "^1.0.1" + os-locale "^3.1.0" + require-directory "^2.1.1" + require-main-filename "^1.0.1" + set-blocking "^2.0.0" + string-width "^2.0.0" + which-module "^2.0.0" + y18n "^3.2.1" + yargs-parser "^9.0.2" + +yn@3.1.1: + version "3.1.1" + resolved "https://registry.npmjs.org/yn/-/yn-3.1.1.tgz" + integrity sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q== + +yocto-queue@^0.1.0: + version "0.1.0" + resolved "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz" + integrity sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q== + +zustand@^4.3.2: + version "4.3.9" + resolved "https://registry.yarnpkg.com/zustand/-/zustand-4.3.9.tgz#a7d4332bbd75dfd25c6848180b3df1407217f2ad" + integrity sha512-Tat5r8jOMG1Vcsj8uldMyqYKC5IZvQif8zetmLHs9WoZlntTHmIoNM8TpLRY31ExncuUvUOXehd0kvahkuHjDw== + dependencies: + use-sync-external-store "1.2.0" diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index b83e10a1e..8764c656e 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -5,16 +5,16 @@ "registry": "https://registry.npmjs.org/" }, "dependencies": { + "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", "date-fns": "^2.28.0", "emoji-picker-react": "^3.5.1", "html-react-parser": "^1.4.13" }, "peerDependencies": { - "react": ">=16.8.0", - "styled-components": "^5.3.5", "@pushprotocol/restapi": "^1.2.15", - "@pushprotocol/socket": "^0.5.0" + "@pushprotocol/socket": "^0.5.0", + "react": ">=16.8.0", + "styled-components": "^5.3.5" } } - diff --git a/packages/uiweb/src/lib/components/index.ts b/packages/uiweb/src/lib/components/index.ts index 1f6eaf4d3..e80bfb4d7 100644 --- a/packages/uiweb/src/lib/components/index.ts +++ b/packages/uiweb/src/lib/components/index.ts @@ -1,4 +1,5 @@ export * from './notification'; export * from './parsetext'; export * from './subscribemodal'; -export * from './chat'; \ No newline at end of file +export * from './chat'; +export * from './space'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx new file mode 100644 index 000000000..7bc1f19ff --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx @@ -0,0 +1,238 @@ +import React from 'react'; +import styled from 'styled-components'; + +import { SpaceBannerLoadingSkeleton } from './SpaceBannerLoadingSkeleton'; + +import { ISpacesTheme } from '../theme'; +import { ThemeContext } from '../theme/ThemeProvider'; +import { getDateAndTime } from '../helpers/date'; +import { getSpaceStatus } from '../helpers/space'; +import { ParticipantContainer } from '../reusables/ParticipantContainer'; +import { HostPfpContainer } from '../reusables'; + +import live from './../../../icons/live.svg'; +import scheduled from './../../../icons/scheduled.svg'; +import { useGetSpaceInfo } from './../../../hooks'; + +export interface ISpaceBannerProps { + spaceId: string; + orientation?: 'maximized' | 'minimized' | 'pill'; + isInvite?: boolean; + onBannerClick?: (arg: string) => void; + onJoin?: any; +} + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: ISpacesTheme; + orientation?: string; + status?: string; + clickable?: boolean; +} + +export const SpaceBanner: React.FC = ({ + spaceId, + orientation, + isInvite, + onBannerClick, + onJoin, +}) => { + const theme = React.useContext(ThemeContext); + const spaceData = useGetSpaceInfo(spaceId); + + const spaceStatus = getSpaceStatus(spaceData?.status); + + const handleClick = () => { + if (onBannerClick) { + onBannerClick(spaceData?.spaceId || ''); + } + }; + + // Check if the spaceData is not available, show the skeleton loading effect + if (!spaceData) { + return ; + } + + return ( + + {orientation === 'maximized' && ( + + )} + {orientation === 'maximized' ? null : ( + + )} + + {orientation === 'pill' + ? `${spaceData?.spaceName.slice(0, 20)}...` + : spaceData?.spaceName} + + + + + + {isInvite === true && spaceStatus === 'Live' ? ( + Join this space + ) : isInvite === true && + spaceStatus === 'Scheduled' ? ( + Remind Me + ) : null} + + ); +}; + +// Styling +const Container = styled.div` + display: flex; + flex-direction: ${(props) => + props.orientation === 'maximized' ? 'column' : 'row'}; + justify-content: ${(props) => + props.orientation === 'maximized' ? 'space-between' : 'space-between'}; + align-items: ${(props) => + props.orientation === 'maximized' ? 'flex-start' : 'center'}; + padding: ${(props) => + props.orientation === 'maximized' + ? '16px' + : props.orientation === 'minimized' + ? '0 20px' + : '0 11px'}; + gap: ${(props) => (props.orientation === 'maximized' ? '16px' : '8px')}; + width: ${(props) => + props.orientation === 'maximized' + ? 'inherit' + : props.orientation === 'minimized' + ? 'inherit' + : 'fit-content'}; + height: ${(props) => + props.orientation === 'maximized' + ? 'auto' + : props.orientation === 'minimized' + ? '40px' + : '63px'}; + background: ${(props) => + props.status === 'Live' + ? props.theme.titleBg + : props.theme.bgColorSecondary}; + border-radius: ${(props) => + props.orientation === 'maximized' + ? '17px' + : props.orientation === 'minimized' + ? '12px' + : '24px'}; + color: ${(props) => (props.status === 'Live' ? '#f5f5f5' : '#1E1E1E')}; + min-width: 0; + text-overflow: ellipsis; + overflow: hidden; + cursor: ${props => props.clickable && 'pointer'}; +`; + +const Title = styled.div<{ orientation?: string }>` + display: flex; + flex-direction: row; + justify-content: flex-start; + align-items: center; + font-family: Strawford; + font-weight: ${(props) => + props.orientation === 'maximized' ? '700' : '500'}; + font-size: ${(props) => + props.orientation === 'maximized' + ? '20px' + : props.orientation === 'minimized' + ? '16px' + : '12px'}; + line-height: 130%; + width: 90%; + line-clamp: ${(props) => (props.orientation === 'maximized' ? '3' : '2')}; + + @media (max-width: 425px) { + width: 95%; + } +`; + +const Status = styled.div` + display: flex; + flex-direction: row; + width: ${(props) => + props.orientation === 'maximized' ? '100%' : 'fit-content'}; + justify-content: space-between; + align-items: center; +`; + +const Time = styled.div<{ orientation?: string }>` + display: ${(props) => (props.orientation === 'maximized' ? 'flex' : 'none')}; + flex-direction: row; + justify-content: center; + align-items: center; +`; + +const Icon = styled.img` + height: 24px; + width: 24px; + padding: 0 11px 0 0; + align-self: center; +`; + +const TimeText = styled.div<{ status?: string }>` + font-weight: 500; + font-size: 14px; + line-height: 150%; + color: ${(props) => (props.status === 'Live' ? '#fff' : '#71717A')}; +`; + +const InviteButton = styled.button<{ status?: string }>` + display: flex; + justify-content: center; + align-items: center; + height: 36px; + width: 100%; + color: ${(props) => (props.status === 'Live' ? '#FFF' : '#8B5CF6')}; + border-radius: 8px; + border: ${(props) => + props.status === 'Live' ? '1px solid #FFF' : '1px solid #8B5CF6'}; + background: transparent; + cursor: pointer; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx new file mode 100644 index 000000000..013d43705 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx @@ -0,0 +1,137 @@ +import React from 'react'; +import styled from 'styled-components'; + +export const SpaceBannerLoadingSkeleton: React.FC = () => { + return ( + + + + + + + + + + + + + + + + + + + ); +}; + +const SkeletonContainer = styled.div` + display: flex; + flex-direction: column; + gap: 24px; + padding: 16px; + background-color: #f1f1f1; + border-radius: 17px; + border: 1px solid lightgrey; + position: relative; + + &:after { + content: ''; + position: absolute; + top: 0; + left: 0; + right: 0; + bottom: 0; + border-radius: 17px; + background-color: #f1f1f1; + opacity: 0.5; + transition: opacity 0.8s ease-in-out infinite alternate; + } + + &:hover:after { + opacity: 0.3; + } +`; + +const SkeletonContent = styled.div` + display: flex; + align-items: center; + gap: 10px; +`; + +const SkeletonProfilePic = styled.div` + width: 48px; + height: 48px; + border-radius: 50%; + border: 1px solid lightgrey; + background-color: #d9d9d9; + transition: opacity 0.8s ease-in-out infinite alternate; + + &:hover { + opacity: 0.5; + } +`; + +const SkeletonProfileInfo = styled.div` + display: flex; + flex-direction: column; + gap: 5px; + width: 100%; +`; + +const SkeletonText = styled.div` + width: 100%; + height: 18px; + background-color: #d9d9d9; + border-radius: 8px; + border: 1px solid lightgrey; + transition: opacity 0.8s ease-in-out infinite alternate; + + &:hover { + opacity: 0.5; + } +`; + +const SkeletonName = styled(SkeletonText)` + width: 30%; +`; + +const SkeletonHandle = styled(SkeletonText)` + width: 40%; +`; + +const SkeletonSpaceInfo = styled(SkeletonText)` + width: 100%; + height: 30px; +`; + +const SkeletonLine = styled.div` + display: flex; + align-items: center; + width: 100%; +`; + +const SkeletonLeftSquare = styled(SkeletonText)` + width: 10%; + height: 32px; +`; + +const SkeletonOverlap = styled.div` + display: flex; + align-items: flex-start; + justify-content: right; + width: 100%; + margin-top: 8px; +`; + +const SkeletonOverlapProfilePic = styled(SkeletonProfilePic)` + height: 48px; + border: 1px solid lightgrey; + margin-left: -24px; + transition: opacity 0.8s ease-in-out infinite alternate; + &:nth-child(2) { + margin-left: -24px; + } + &:nth-child(3) { + margin-left: -24px; + } +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceBanner/index.ts b/packages/uiweb/src/lib/components/space/SpaceBanner/index.ts new file mode 100644 index 000000000..72fd7241f --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceBanner/index.ts @@ -0,0 +1 @@ +export * from "./SpaceBanner"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx new file mode 100644 index 000000000..ee1244992 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx @@ -0,0 +1,57 @@ +import React, { MouseEventHandler, useContext } from 'react' +import styled from 'styled-components'; + +import { ISpacesTheme } from '../../theme'; +import { ThemeContext } from '../../theme/ThemeProvider'; + +export interface ISCWButtonProps { // Space Creation Widget Button Interface + btnText?: string; + customStyle?: any; + theme?: ISpacesTheme; + onCreate?: MouseEventHandler; +} + +const defaultProps: ISCWButtonProps = { + btnText: 'Create your Space', + customStyle: { + padding: '20px', + borderRadius: '12px', + border: '0px solid transparent', + fontSize: '1rem', + }, +} + +export const SCWButton: React.FC = (props) => { + const { btnText, customStyle, onCreate } = props; + + const theme = useContext(ThemeContext); + + return ( +
+ + {btnText} + +
+ ) +} + +/* styling */ +const CreateButton = styled.button` + padding: ${props => props.customStyle.padding}; + border-radius: ${props => props.customStyle.borderRadius}; + border: ${props => props.customStyle.border}; + font-size: ${props => props.customStyle.fontSize}; + + background-image: ${(props) => props.theme.titleBg}; + color: ${(props) => props.theme.titleTextColor}; + + cursor: pointer; +`; + +SCWButton.defaultProps = defaultProps; + +export default SCWButton; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/index.ts b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/index.ts new file mode 100644 index 000000000..905744434 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/index.ts @@ -0,0 +1 @@ +export * from './SCWButton'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx new file mode 100644 index 000000000..976c5d117 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx @@ -0,0 +1,90 @@ +import React, { MouseEventHandler } from 'react' +import styled from 'styled-components' + +import { Modal } from '../../reusables/Modal' +import { Button } from '../../reusables/Button'; +import { ModalHeader } from '../../reusables/ModalHeader'; +import { TextInputWithCounter } from '../../reusables/TextInput'; + +import { CalendarPurple } from '../../../../icons/CalendarPurple'; + +export interface ISCWCModalProps { // Space Creation Widget Create Modal Interface + isInviteVisible?: any; + closeCreateModal?: MouseEventHandler; + handleNameChange?: any; + handleDescriptionChange?: any; + nameValue?: any; + descriptionValue?: any; + isDescriptionEnabled: boolean; + isScheduleVisible?: any; + onClose: () => void; +} + +export const SCWCreateModal: React.FC = (props) => { + const { + isInviteVisible, closeCreateModal, handleNameChange, + handleDescriptionChange, nameValue, descriptionValue, + isDescriptionEnabled, isScheduleVisible, onClose, + } = props; + + const secBtn = { + background: 'transparent', + borderColor: '#8b5cf6' + } + + return ( + + + + + + { + isDescriptionEnabled ? + + : null + } + + + + +
+ +
+
+
+ ) +} + +/* styling */ +const ButtonContainer = styled.div` + display: flex; + justify-content: space-between; + width: 100%; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/index.ts b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/index.ts new file mode 100644 index 000000000..aae6e3038 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/index.ts @@ -0,0 +1 @@ +export * from './SCWCreateModal' diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx new file mode 100644 index 000000000..7843ac871 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx @@ -0,0 +1,367 @@ +/* eslint-disable no-prototype-builtins */ +import React, { useState, MouseEventHandler, useContext } from 'react' +import styled from 'styled-components' +import * as PushAPI from '@pushprotocol/restapi'; + +import { ModalHeader } from '../../reusables/ModalHeader'; +import { Modal } from '../../reusables/Modal'; +import { Button } from '../../reusables/Button'; +import { SearchInput } from '../../reusables/SearchInput'; +import { ProfileContainer } from '../../reusables/ProfileContainer'; +import { ThemeContext } from '../../theme/ThemeProvider'; +import { Spinner } from '../../reusables/Spinner'; + +import CircularProgressSpinner from '../../../loader/loader'; + +import { useSpaceData } from '../../../../hooks'; +import SettingsIcon from '../../../../icons/settingsBlack.svg'; +import { Image } from '../../../../config'; + +export interface ISCWIModalProps { // Space Creation Widget Create Modal Interface + closeInviteModal?: MouseEventHandler; + makeScheduleVisible?: MouseEventHandler; + createSpace?: MouseEventHandler; + isLoading?: boolean; + invitedMembersList?: any; + setInvitedMembersList?: any; + invitedAddressList?: any; + setInvitedAddressList?: any; + adminsList?: any; + setAdminsList?: any; + adminsAddressList?: any; + setAdminsAddressList?: any; + onClose: () => void; +} + +interface User { + handle: string; + name: string; +} + +export const SCWInviteModal: React.FC = (props) => { + const { + closeInviteModal, makeScheduleVisible, createSpace, isLoading, + invitedMembersList, + setInvitedMembersList, + invitedAddressList, + setInvitedAddressList, + adminsList, + setAdminsList, + adminsAddressList, + setAdminsAddressList, + onClose + } = props; + + const { env } = useSpaceData(); + + const theme = useContext(ThemeContext); + + const [invitedMember, setInvitedMember] = useState('') + const [loadingAccount, setLoadingAccount] = useState(false) + + const [searchedUser, setSearchedUser]= useState({}); + const [errorMsg, setErrorMsg] = useState(''); + + const searchMember = async (event: any) => { + setInvitedMember(event.target.value) + + try { + setLoadingAccount(true); + const response = await PushAPI.user.get({ + account: event.target.value, + env, + }); + + if(response === null) { + const nullUser = { + walletAddress: event.target.value, + name: event.target.value, + image: tempImageUrl, + }; + setSearchedUser(nullUser) + } else { + setSearchedUser(response); + } + setErrorMsg(''); + } catch (e:any) { + console.error(e.message); + setSearchedUser({}); + setErrorMsg(e.message); + } finally { + setLoadingAccount(false); + } + } + + const clearInput = () => { + setInvitedMember(''); + setSearchedUser({}); + setErrorMsg(''); + } + + const handleInviteMember = (user: any) => { + if (user.did) { + setInvitedAddressList([...invitedAddressList, user.did.substring(7)]) + setInvitedMembersList([...invitedMembersList, user]); + } else { + setInvitedAddressList([...invitedAddressList, user.walletAddress]) + setInvitedMembersList([...invitedMembersList, user]); + } + + clearInput(); + } + + const handlePromoteToAdmin = (user: any) => { + if (user.did) { + setAdminsList([...adminsList, user]) + setAdminsAddressList([...adminsAddressList, user.did.substring(7)]); + } else { + setAdminsList([...adminsList, user]) + setAdminsAddressList([...adminsAddressList, user.walletAddress]); + } + + const updatedArray = invitedMembersList.filter((item: any) => item !== user) + setInvitedMembersList(updatedArray); + + if (user.did) { + const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.did.substring(7)) + setInvitedAddressList(updateAddressArray); + } else { + const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.walletAddress) + setInvitedAddressList(updateAddressArray); + } + + clearInput(); + } + + const handleDeleteInvitedUser = (user: any) => { + const updatedArray = invitedMembersList.filter((item: any) => item !== user) + setInvitedMembersList(updatedArray); + }; + + const tempImageUrl = "https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg"; + + return ( +
+ + + + + {errorMsg} + + + {loadingAccount && } + { + Object.keys(searchedUser).length === 0 ? + null + : searchedUser.hasOwnProperty('walletAddress') ? + Add +} + btnCallback={() => handleInviteMember(searchedUser)} + border + /> + : Add +} + btnCallback={() => handleInviteMember(searchedUser)} + border + /> + } + + + { + invitedMembersList.length ? + + Invited Members {invitedMembersList.length} + { + invitedMembersList.map((item: any) => { + if (item.hasOwnProperty('walletAddress')) { + return + Settings icon + + } + // btnCallback={() => handleDeleteInvitedUser(item)} + removeCallback={() => handleDeleteInvitedUser(item)} + promoteCallback={() => handlePromoteToAdmin(item)} + border + /> + } else { + return + Settings icon + + } + // btnCallback={() => handleDeleteInvitedUser(item)} + removeCallback={() => handleDeleteInvitedUser(item)} + promoteCallback={() => handlePromoteToAdmin(item)} + border + /> + } + }) + } + + : null + } + + { + adminsList.length ? + + Speakers {adminsList.length} + { + adminsList.map((item: any) => { + if (item.hasOwnProperty('walletAddress')) { + return + Settings icon + + } + // btnCallback={() => handleDeleteInvitedUser(item)} + removeCallback={() => handleDeleteInvitedUser(item)} + promoteCallback={() => handlePromoteToAdmin(item)} + border + /> + } else { + return + Settings icon + + } + // btnCallback={() => handleDeleteInvitedUser(item)} + removeCallback={() => handleDeleteInvitedUser(item)} + // promoteCallback={() => handlePromoteToAdmin(item)} + border + /> + } + }) + } + + : null + } + + + +
+ ) +} + + +const MembersList = styled.div` + width: 100%; + display: flex; + flex-direction: column; + gap: 8px; +`; + +const InvitedList = styled.div` + width: 100%; + display: flex; + flex-direction: column; + gap: 8px; + + margin-top: 28px; +`; + +const Heading = styled.div` + display: flex; + align-items: center; +`; + +const PendingCount = styled.div` + background: ${(props => props.theme.btnColorPrimary)}; + border-radius: 8px; + padding: 4px 10px; + margin-left: 6px; + font-size: 13px; + color: ${(props => props.theme.titleTextColor)}; +`; + +const SettingsCont = styled.div` + display: flex; + justify-content: center; + align-items: center; + + cursor: pointer; +`; + +const ContBtn = styled.button` + display: flex; + flex-direction: row; + align-items: center; + margin-left: 8px; + line-height: 18px; + width: max-content; + background: transparent; + color: #8B5CF6; + border-radius: 6px; + font-weight: 500; + font-size: 12px; + padding: 4px 8px; + border-radius: 8px; + border: 1px solid #8B5CF6; + cursor: pointer; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/index.ts b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/index.ts new file mode 100644 index 000000000..ce11a56b2 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/index.ts @@ -0,0 +1 @@ +export * from './SCWInviteModal'; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/SCWScheduleModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/SCWScheduleModal.tsx new file mode 100644 index 000000000..063d2222d --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/SCWScheduleModal.tsx @@ -0,0 +1,59 @@ +import React, { MouseEventHandler } from 'react' +import styled from 'styled-components'; + +import DateTimePicker from '../../reusables/DateTimePicker'; + +import { Modal } from '../../reusables/Modal'; +import { ModalHeader } from '../../reusables/ModalHeader'; +import { Button } from '../../reusables/Button'; + +export interface ISCWSModalProps { // Space Creation Widget Schedule Modal Interface + closeScheduleModal?: MouseEventHandler; + makeCreateVisible?: MouseEventHandler; + makeInviteVisible?: MouseEventHandler; + + dateValue?: any; + onDateChange?: any; + timeValue?: any; + onTimeChange?: any; + + onClose: () => void; +} + +export const SCWScheduleModal: React.FC = (props) => { + + const { closeScheduleModal, makeCreateVisible, makeInviteVisible, dateValue, timeValue, onDateChange, onTimeChange, onClose } = props; + + return ( + + + + + + + + + + ) +} + +const ButtonContainer = styled.div` + display: flex; + justify-content: space-between; + width: 100%; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/index.ts b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/index.ts new file mode 100644 index 000000000..9b907490d --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWScheduleModal/index.ts @@ -0,0 +1 @@ +export * from './SCWScheduleModal'; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx new file mode 100644 index 000000000..26baa118c --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx @@ -0,0 +1,174 @@ +import { useState } from 'react' +import styled from 'styled-components'; +import * as PushAPI from '@pushprotocol/restapi'; + +import { SCWCreateModal } from './SCWCreateModal/SCWCreateModal' +import { SCWScheduleModal } from './SCWScheduleModal/SCWScheduleModal'; +import { SCWInviteModal } from './SCWInviteModal/SCWInviteModal'; +import { SCWButton } from './SCWButton'; + +import { useSpaceData } from '../../../hooks'; + +export interface ISpaceCreateWidgetProps { + CustomComponent?: any; +} + +export const SpaceCreationWidget:React.FC = (props) => { + const { CustomComponent } = props; + + const [isCreateModalVisible, setIsCreateModalVisible] = useState(false); + const [isScheduleModalVisible, setIsScheduleModalVisible] = useState(false); + const [isInviteModalVisible, setIsInviteModalVisible] = useState(false); + + const [invitedMembersList, setInvitedMembersList] = useState([]) + const [invitedAddressList, setInvitedAddressList] = useState([]) + console.log("🚀 ~ file: SpaceCreationWidget.tsx:25 ~ invitedAddressList:", invitedAddressList) + const [adminsList, setAdminsList] = useState([]) + const [adminsAddressList, setAdminsAddressList] = useState([]) + console.log("🚀 ~ file: SpaceCreationWidget.tsx:27 ~ adminsAddressList:", adminsAddressList) + + const [isLoading, setLoading] = useState(false); + + const [spaceState, setSpaceState] = useState({ + spaceName: '', + spaceDescription: '', + date: new Date(), + time: new Date(), + }) + + const { signer } = useSpaceData(); + + const handleNameChange = (event: any) => { + setSpaceState((prevState) => ({...prevState, spaceName: event.target.value})) + }; + + const handleDescriptionChange = (event: any) => { + setSpaceState((prevState) => ({...prevState, spaceDescription: event.target.value})) + }; + + const onDateChange = (dateValue: any) => { + setSpaceState((prevState) => ({...prevState, date: dateValue})) + }; + + const onTimeChange = (timeValue: any) => { + setSpaceState((prevState) => ({...prevState, time: timeValue})) + }; + + const showCreateSpace = () => { + setIsCreateModalVisible(!isCreateModalVisible); + setIsScheduleModalVisible(false); + setIsInviteModalVisible(false); + } + + const showScheduleSpace = () => { + setIsScheduleModalVisible(!isScheduleModalVisible); + setIsCreateModalVisible(false); + setIsInviteModalVisible(false); + } + + const showInviteSpace = () => { + setIsInviteModalVisible(!isInviteModalVisible); + setIsScheduleModalVisible(false); + setIsCreateModalVisible(false); + } + + const closeCreateModal = () => { + setIsCreateModalVisible(false); + } + + const closeScheduleModal = () => { + setIsScheduleModalVisible(false); + } + + const closeInviteModal = () => { + setIsInviteModalVisible(false); + } + + const testCreateSpace = async () => { + const spaceCreate = { + spaceName: spaceState.spaceName, + spaceDescription: 'Push Space', + members: invitedAddressList, + spaceImage: 'asd', + admins: adminsAddressList, + isPublic: true, + scheduleAt: new Date(spaceState.time), + signer: signer as PushAPI.SignerType, + } + + try { + setLoading(true); + const response = await PushAPI.space.create(spaceCreate); + + console.log(response); + } catch (e:any) { + console.error(e.message); + } finally { + setLoading(false); + closeInviteModal(); + } + }; + + return ( + + { + CustomComponent + ? + + : + + } + + {isCreateModalVisible && + + } + + {isScheduleModalVisible && + + } + + {isInviteModalVisible && + + } + + ) +} + +const SCWContainer = styled.div` + font-family: 'Strawford'; // update to fontFamily theme +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/index.ts b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/index.ts new file mode 100644 index 000000000..7f6d6d24e --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/index.ts @@ -0,0 +1 @@ +export * from './SpaceCreationWidget'; diff --git a/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx b/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx new file mode 100644 index 000000000..1cb55ff6f --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx @@ -0,0 +1,478 @@ +import React, { useState } from 'react'; +import styled from 'styled-components'; + +import { SpaceIFeeds } from '@pushprotocol/restapi'; + +import { SpaceBanner } from '../SpaceBanner'; + +import { Spinner } from '../reusables/Spinner'; + +import { + useSpaceData, + useFeedScroll, + useMySpaces, + usePopularSpaces, + useSpaceRequests, +} from '../../../hooks'; + +import { ISpacePaginationData } from '../../../context/spacesContext'; +import spacesIcon from '../../../icons/Spaces.svg'; + +enum OrientationEnums { + Horizontal = 'horizontal', + Vertical = 'vertical', +} + +enum Tabs { + ForYou = 'For You', + Popular = 'Popular', + HostedByYou = 'Hosted by you', +} + +enum FilterEnums { + All = 'All', + Live = 'Live', + Scheduled = 'Scheduled', +} +export interface ISpaceFeedProps { + orientation?: 'horizontal' | 'vertical'; + height?: number; + width?: number; + sortingOrder?: string[]; + showTabs?: boolean; + filter?: FilterEnums.All | FilterEnums.Live | FilterEnums.Scheduled; + showFilter?: boolean; + onBannerClickHandler?: (arg: string) => void; +} + +export const SpaceFeed: React.FC = ({ + orientation = 'veritcal', + height, + width, + sortingOrder = [Tabs.Popular, Tabs.ForYou, Tabs.HostedByYou], + showTabs = true, + filter = FilterEnums.All, + showFilter = true, + onBannerClickHandler, +}) => { + const [tab, setTab] = useState(sortingOrder[0]); + const [filterTab, setFilterTab] = useState(filter); + + const { + account, + mySpaces, + setMySpaces, + popularSpaces, + setPopularSpaces, + spaceRequests, + setSpaceRequests, + } = useSpaceData(); + + const listInnerRef = useFeedScroll(mySpaces.apiData?.length); + + const handleTabChange = (tab: string) => { + setTab(tab); + }; + + const handleFilterData = (spacesList: SpaceIFeeds[]) => { + if (filterTab === FilterEnums.All) { + return spacesList; + } else if (filterTab === FilterEnums.Live) { + return spacesList.filter( + (space: SpaceIFeeds) => space.spaceInformation?.status === 'ACTIVE' + ); + } else if (filterTab === FilterEnums.Scheduled) { + return spacesList.filter( + (space: SpaceIFeeds) => space.spaceInformation?.status === 'PENDING' + ); + } else { + return spacesList; + } + }; + + const handleMySpacesFilter = (spacesList: SpaceIFeeds[]) => { + if (tab === Tabs.HostedByYou) { + return spacesList.filter( + (space: SpaceIFeeds) => + space.spaceInformation?.spaceCreator.slice(7).toUpperCase() === + account?.toUpperCase() + ); + } + if (tab === Tabs.ForYou) { + return spacesList.filter( + (space: SpaceIFeeds) => + space.spaceInformation?.spaceCreator.slice(7).toUpperCase() !== + account?.toUpperCase() + ); + } else { + return handleFilterData(spacesList); + } + }; + + const handleClick = (spaceId: string) => { + if (onBannerClickHandler) { + return onBannerClickHandler(spaceId || ''); + } + }; + + const incrementSpacePage = async (spaces: ISpacePaginationData) => { + if ( + loading === false && + spaces.currentPage && + spaces.lastPage && + spaces.currentPage < spaces.lastPage + ) { + if (spaces === mySpaces) + spaces.currentPage && + console.log('spaces.currentPage', spaces.currentPage, Date.now()); + setMySpaces({ + currentPage: spaces.currentPage + 1, + lastPage: spaces.lastPage + 1, + }); + if (spaces === popularSpaces) + spaces.currentPage && + setPopularSpaces({ + currentPage: spaces.currentPage + 1, + lastPage: spaces.lastPage + 1, + }); + if (spaces === spaceRequests) + spaces.currentPage && + setSpaceRequests({ + currentPage: spaces.currentPage + 1, + lastPage: spaces.lastPage + 1, + }); + } else { + return; + } + }; + + const loadMoreData = async () => { + if (tab === Tabs.ForYou) { + incrementSpacePage(mySpaces); + } + if (tab === Tabs.Popular) { + incrementSpacePage(popularSpaces); + } + if (tab === Tabs.HostedByYou) { + incrementSpacePage(spaceRequests); + } + }; + + console.log(account); + + const onScroll = () => { + if (listInnerRef.current) { + const { scrollTop } = listInnerRef.current; + const { offsetHeight } = listInnerRef.current; + const { scrollHeight } = listInnerRef.current; + + if (scrollTop + offsetHeight + 1 >= scrollHeight) { + loadMoreData(); + } + } + }; + + //API calls + + const mySpaceLoading = useMySpaces(account); + const popularSpaceLoading = usePopularSpaces(); + const spaceRequestsLoading = useSpaceRequests(account); + const { loading } = + mySpaceLoading || popularSpaceLoading || spaceRequestsLoading; + + return ( +
+ {orientation === OrientationEnums.Horizontal ? ( + + {orientation === OrientationEnums.Horizontal + ? mySpaces && + mySpaces.apiData?.map((space: SpaceIFeeds) => { + return ( + + ); + }) + : mySpaces && + mySpaces.apiData?.map((space: SpaceIFeeds) => { + return ( + + ); + })} + + ) : ( + <> + + + {sortingOrder.map((tabName: string) => { + return ( + handleTabChange(tabName)} + > + {tabName} + + ); + })} + + + + setFilterTab(FilterEnums.All)} + > + All + + setFilterTab(FilterEnums.Live)} + > + Live + + setFilterTab(FilterEnums.Scheduled)} + > + Scheduled + + + + + {tab === Tabs.ForYou ? ( + + {mySpaces.apiData && + (handleFilterData( + handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) + ).length === 0 ? ( + + + Join a space + + Get started by joining a space + + + ) : ( + handleFilterData( + handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) + ).map((space: SpaceIFeeds) => { + return ( + + ); + }) + ))} + + ) : tab === Tabs.Popular ? ( + + Popular Spaces + {popularSpaces && + handleFilterData( + popularSpaces.apiData as SpaceIFeeds[] + ).map((space: SpaceIFeeds) => { + return ( + + ); + })} + + ) : ( + + {mySpaces.apiData && + (handleFilterData( + handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) + ).length === 0 ? ( + + + Create a space + + Get started by creating a space + + + ) : ( + handleFilterData( + handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) + ).map((space: SpaceIFeeds) => { + return ( + + ); + }) + ))} + + )} + {loading && } + + + + )} +
+ ); +}; + +//Styling +const ScrollContainer = styled.div<{ height?: number; width?: number }>` + width: ${(props) => (props.width ? `${props.width}px` : 'inherit')}; + height: ${(props) => (props.height ? `${props.height}px` : 'auto')}; + overflow-y: auto; +}`; +const Container = styled.div` + display: flex; + flex-direction: column; + align-items: center; + background: #ffffff; + border: 1px solid #dcdcdf; + border-radius: 12px; + padding: 24px 32px; +}`; + +const Navigation = styled.div<{ + showTabs?: boolean; + showFilter?: boolean; + width?: number; +}>` + display: ${(props) => (props.showTabs ? 'flex' : 'none')}; + flex-direction: row; + justify-content: space-between; + align-items: center; + width: ${(props) => (props.width ? `${props.width}px` : 'inherit')}; + border-bottom: 1px solid #DCDCDF; + margin-bottom: ${(props) => (props.showFilter ? '0' : '27px')}; +}`; + +const NavButtonWrapper = styled.div` + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; +}`; + +const NavButton = styled.button<{ active?: boolean }>` + padding: 10px 30px; + font-weight: 450; + font-size: 14px; + border: none; + border-bottom: ${(props) => (props.active ? '2px solid #8B5CF6' : 'none')}; + background: none; + color : ${(props) => (props.active ? '#000000' : '#71717A')}; + + &:hover { + cursor: pointer; + } +}`; + +const Spaces = styled.div<{ orientation?: string }>` + display: flex; + flex-direction: ${(props) => + props.orientation === 'horizontal' ? 'row' : 'column'}; + justify-content: flex-start; + align-items: center; + background: #ffffff; + width: ${(props) => + props.orientation === 'horizontal' ? 'inherit' : '100%'}; + height: auto; + gap: 16px; +}`; + +const PopularSpaces = styled.div` + display: flex; + flex-direction: column; + justify-content: space-between; + align-items: center; + background: #ffffff; + width: 100%; + height: auto; + gap: 16px; +}`; + +const Text = styled.div` + width: 100%; + text-align: left; + font-family: 'Strawford'; + font-weight: 450; + font-size: 18px; +}`; + +const Filter = styled.div<{ showFilter?: boolean }>` + display: ${(props) => (props.showFilter ? 'flex' : 'none')}; + flex-direction: row; + justify-content: flex-start; + align-items: center; + background: #ffffff; + width: 100%; + margin: 22px 0; +}`; + +const FilterButton = styled.button<{ active: boolean }>` + display: inline-flex; + height: 30px; + padding: 0px 16px; + justify-content: center; + align-items: center; + border-radius: 99px; + border: 1px solid #C4B5FD; + background: ${(props) => (props.active ? '#8B5CF6' : '#EDE9FE')}; + color: ${(props) => (!props.active ? '#8B5CF6' : '#FFF')}; + margin-right: 8px; + font-size: 14px; + + &:hover { + cursor: pointer; + } +}`; + +const NoSpaces = styled.div` + display: flex; + flex-direction: column; + justify-content: center; + align-items: center; + margin: 130px 0; +}`; + +const SpacesIcon = styled.img` + width: 36px; + height: 36px; +}`; + +const NoSpacesTextV1 = styled.div` + font-family: 'Strawford'; + font-weight: 450; + font-size: 16px; + color: #000; +}`; + +const NoSpacesTextV2 = styled.div` + font-family: 'Strawford'; + font-weight: 450; + color: #71717A; + font-size: 14px; +}`; diff --git a/packages/uiweb/src/lib/components/space/SpaceFeed/index.ts b/packages/uiweb/src/lib/components/space/SpaceFeed/index.ts new file mode 100644 index 000000000..506cf05f5 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceFeed/index.ts @@ -0,0 +1 @@ +export * from "./SpaceFeed"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx b/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx new file mode 100644 index 000000000..ecc07676e --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx @@ -0,0 +1,144 @@ +import React, { useState } from 'react'; +import styled from 'styled-components'; +import { Modal } from '../reusables/Modal'; +import { Spinner } from '../reusables/Spinner'; +import { ModalHeader } from '../reusables/ModalHeader'; +import { useFeedScroll, useSpaceData, useSpaceRequests } from '../../../hooks'; +import { SpaceBanner } from '../SpaceBanner'; + +export interface ISpaceInvitesProps { + account?: string; + children?: React.ReactNode; +} + +export const SpaceInvites: React.FC = ({ + account = '0x04bE5701AB5b2f2117332b4748020737B29a2e1D', + children, +}: ISpaceInvitesProps) => { + const [modalOpen, setModalOpen] = useState(false); + const { spaceRequests, setSpaceRequests } = useSpaceData(); + + const containerRef = useFeedScroll(spaceRequests.apiData?.length); + + const [playBackUrl, setPlayBackUrl] = useState(''); + const { spacesObjectRef, spaceObjectData, initSpaceObject, setSpaceWidgetId } = useSpaceData(); + + const handleJoinSpace = async (space: any) => { + await initSpaceObject(space?.spaceId as string); + await spacesObjectRef?.current?.join(); + const playBackUrl = spaceObjectData.spaceDescription; + setPlayBackUrl(playBackUrl); + handleCloseModal(); + setSpaceWidgetId(space?.spaceId as string) + console.log('Space Joined'); + }; + + const handleOpenModal = () => { + setModalOpen(true); + }; + + const handleCloseModal = () => { + setModalOpen(false); + }; + + const loadMoreData = () => { + if ( + loading === false && + spaceRequests.currentPage && + spaceRequests.lastPage && + spaceRequests.currentPage < spaceRequests.lastPage + ) { + console.log('Load More Data'); + setSpaceRequests({ + currentPage: spaceRequests.currentPage + 1, + lastPage: spaceRequests.lastPage + 1, + }); + } + }; + + const onScrollContainer = () => { + if (containerRef.current) { + const { scrollTop, scrollHeight, clientHeight } = containerRef.current; + if (scrollTop + clientHeight >= scrollHeight) { + loadMoreData(); + } + } + }; + + const { loading } = useSpaceRequests(account); + return ( + <> + {!children && } + + {children &&
{children}
} + + {modalOpen && ( + + 0 + ? spaceRequests.apiData?.length + : undefined + } + closeCallback={handleCloseModal} + /> + + + {spaceRequests.apiData + ? spaceRequests.apiData.map((space: any) => { + return ( + handleJoinSpace(space)} + /> + ); + }) + : null} + {loading ? : null} + + + + )} + + ); +}; + +const Button = styled.button` + padding: 8px 16px; + background-color: #8b5cf6; + color: #fff; + border: none; + border-radius: 4px; + cursor: pointer; +`; + +const ScrollContainer = styled.div` + max-height: 400px; + width: inherit; + margin-top: 24px; + overflow-y: scroll; + + &::-webkit-scrollbar{ + margin-left: 10px; + width: 8px; + height: 8px; + } + + &::-webkit-scrollbar-thumb{ + -webkit-appearance: none; + width: 4px; + height: auto; + background:#8B5CF6; + border-radius: 99px; + } +`; + +const InviteContainer = styled.div` + display: flex; + flex-direction: column; + gap: 16px; + margin: 0 10px; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceInvites/index.ts b/packages/uiweb/src/lib/components/space/SpaceInvites/index.ts new file mode 100644 index 000000000..43c623f28 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceInvites/index.ts @@ -0,0 +1 @@ +export * from "./SpaceInvites"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx new file mode 100644 index 000000000..c7cf15281 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx @@ -0,0 +1,90 @@ +import { IMediaStream } from '@pushprotocol/restapi'; +import { Image, Item, Text } from '../../../config'; + +import HandIcon from '../../../icons/hand.svg'; +import MicOffIcon from '../../../icons/micoff.svg'; +import { VideoPlayer } from './VideoPlayer'; + +export interface ILiveSpaceProfileContainerProps { + wallet: string; + isHost?: boolean; + isSpeaker?: boolean; + image: string; + requested?: boolean; + mic?: boolean; + stream?: IMediaStream; +} + +export const LiveSpaceProfileContainer = ( + options: ILiveSpaceProfileContainerProps +) => { + const { + wallet, + isHost, + isSpeaker, + image, + requested = false, + mic = true, + stream, + } = options || {}; + + return ( + + Profile pic + + {wallet.slice(7, 12).concat('...')} + {stream && } + + {requested ? ( + + + Requested + + Hand Icon + + ) : ( + + + {isHost ? 'Host' : isSpeaker ? 'Speaker' : 'Listener'} + + {!mic && ( + Mic Off Icon + )} + + )} + + ); +}; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx new file mode 100644 index 000000000..bf630ce96 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx @@ -0,0 +1,174 @@ +import React, { useEffect, useState } from 'react'; +import styled from 'styled-components'; + +import { LiveSpaceProfileContainer } from './LiveSpaceProfileContainer'; +import { SpaceMembersSectionModal } from './SpaceMembersSectionModal'; + +import { Button, Image, Item, Text } from '../../../config'; +import MicOnIcon from '../../../icons/micon.svg'; +import MicEngagedIcon from '../../../icons/MicEngage.svg'; +import MuteIcon from '../../../icons/Muted.svg'; +import ShareIcon from '../../../icons/Share.svg'; +import MembersIcon from '../../../icons/Members.svg'; +import { SpaceDTO } from '@pushprotocol/restapi'; + +import { useSpaceData } from '../../../hooks'; + +import { Player } from '@livepeer/react'; + +interface LiveWidgetContentProps { + spaceData?: SpaceDTO; + // temp props only for testing demo purpose for now + isHost?: boolean; + isJoined?: boolean; + isSpeaker?: boolean; +} +export const LiveWidgetContent: React.FC = ({ + spaceData, + isJoined, + isHost, + isSpeaker, +}) => { + const tempImageUrl = + 'https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg'; + const [showMembersModal, setShowMembersModal] = useState(false); + const [isMicOn, setIsMicOn] = useState(true); + const [playBackUrl, setPlayBackUrl] = useState(''); + const { spacesObjectRef, spaceObjectData, initSpaceObject } = useSpaceData(); + + const handleJoinSpace = async () => { + // await initSpaceObject(spaceData?.spaceId as string); + await spacesObjectRef?.current?.join(); + const playBackUrl = spaceObjectData.spaceDescription; + setPlayBackUrl(playBackUrl); + console.log('Space Joined'); + }; + console.log('spaceObjectData', spaceObjectData); + + return ( + <> + + {spaceObjectData.connectionData.incoming.map( + (profile) => ( + ( + + ) + ) + )} + + + {isJoined ? ( + + + isHost || isSpeaker ? setIsMicOn(!isMicOn) : null + } + > + Mic Icon + + {isHost || isSpeaker + ? isMicOn + ? 'Speaking' + : 'Muted' + : 'Request'} + + + + setShowMembersModal(true)} + alt="Members Icon" + /> + Share Icon + + + + + ) : ( + + )} + {showMembersModal ? ( + setShowMembersModal(false)} + /> + ) : null} + + + ); +}; + +const PeerPlayer = styled(Player)` + width: 0; + height: 0; +}`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx new file mode 100644 index 000000000..29af80161 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx @@ -0,0 +1,215 @@ +import styled from 'styled-components'; + +import { Button, Container, Image, Item, Text } from '../../../config'; +import { formatDate } from '../../../helpers'; + +import SpacesIcon from '../../../icons/Spaces.svg'; +import TwitterIcon from '../../../icons/twitterVector.svg'; +import CopyIcon from '../../../icons/copyVector.svg'; +import AtIcon from '../../../icons/atVector.svg'; +import { SpaceDTO } from '@pushprotocol/restapi'; +import { useSpaceData } from '../../../hooks'; +import { useEffect } from 'react'; + +interface ScheduledWidgetContentProps { + account?: string; + spaceData?: SpaceDTO; + shareUrl?: string; + + // temp props only for testing demo purpose for now + isHost?: boolean; + isTimeToStartSpace?: boolean; + isMember?: boolean; +} +export const ScheduledWidgetContent: React.FC = ({ + account, + spaceData, + shareUrl, + isHost, + isMember, +}: ScheduledWidgetContentProps) => { + const isTimeToStartSpace = true; + const { spacesObjectRef, initSpaceObject, spaceObjectData } = useSpaceData(); + + //Initialize the space object + + const handleStartSpace = async () => { + await initSpaceObject(spaceData?.spaceId as string); + await spacesObjectRef.current.createAudioStream(); + // Start the space by calling the start method on the space object + + console.log('Space Started'); + }; + + const handleShareTweet = () => { + if (!shareUrl) return; + const url = shareUrl; + const tweetText = 'Join this Space:'; // Replace with your desired tweet text + + const tweetUrl = `https://twitter.com/intent/tweet?text=${encodeURIComponent( + tweetText + )}&url=${encodeURIComponent(url)}`; + + window.open(tweetUrl, '_blank'); + }; + + const handleCopyLink = async () => { + try { + if (!shareUrl) return; + const url = shareUrl; + await navigator.clipboard.writeText(url); + // add a success toast here + console.log('URL copied to clipboard:', url); + } catch (error) { + console.error('Failed to copy URL:', error); + } + }; + + useEffect(() => { + async function startSpace() { + if (!spaceObjectData?.connectionData?.local.stream) return; + await spacesObjectRef.current.start({ + livepeerApiKey: '2638ace1-0a3a-4853-b600-016e6125b9bc', + }); + } + startSpace(); + }, [spaceObjectData?.connectionData?.local.stream]); + + return ( + + Spaces Icon + {isHost ? ( + isTimeToStartSpace ? ( + It’s time to start your space + ) : ( + + Your space is scheduled.
Share and let people know when to + join! +
+ ) + ) : ( + + This space will go live on{' '} + {formatDate((spaceData?.scheduleAt as any) || new Date())} + + )} + {isHost && isTimeToStartSpace && ( + + )} + {!isHost && !isMember && ( + + )} + {!isHost && isMember && ( + + )} + {(!isHost || (isHost && !isTimeToStartSpace)) && shareUrl && ( + + + + Twitter Icon + + + Twitter + + + + + Copy Icon + + + Copy Link + + + + + At Icon + + + Email + + + + )} +
+ ); +}; + +const SpaceInfoText = styled.span` + font-size: 18px; + font-weight: 600; + text-align: center; +`; + +const ShareLinkItem = styled.div` + display: flex; + flex-direction: column; + gap: 8px; + align-items: center; +`; + +const ShareLinkButton = styled.button` + background: #e4e4e7; + border-radius: 14px; + padding: 16px; + border: none; + cursor: pointer; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceMembersSectionModal.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceMembersSectionModal.tsx new file mode 100644 index 000000000..a1c43966b --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceMembersSectionModal.tsx @@ -0,0 +1,256 @@ +import React, { ReactNode, useState } from 'react'; +import styled from 'styled-components'; + +import { Modal } from '../reusables/Modal'; +import { ModalHeader } from '../reusables/ModalHeader'; +import { ProfileContainer } from '../reusables/ProfileContainer'; + +import { Button, Container, Image, Text } from '../../../config'; +import SettingsIcon from '../../../icons/settingsBlack.svg'; + +const tempImageUrl = "https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg"; +const Requests: React.FC = () => { + return ( + + + + + ) +} + +const Speakers: React.FC = () => { + return ( + + + + + Settings icon + + + + + + Settings icon + + + + ) +} + +const CoHosts: React.FC = () => { + return ( + + + + + Settings icon + + + + + + Settings icon + + + + ) +} + +const Listeners: React.FC = () => { + return ( + + + + + Settings icon + + + + + + Settings icon + + + + ) +} + +interface ISpaceMembersModalProps { + onClose: () => void; +} +enum MemberTabsEnum { + CoHost = 'Co-Host', + Speakers = 'Speakers', + Requests = 'Requests', + Listeners = 'Listeners', +} + +export const SpaceMembersSectionModal: React.FC = ({ onClose }: ISpaceMembersModalProps) => { + + const [activeTab, setActiveTab] = useState(MemberTabsEnum.CoHost); + + const handleTabClick = (index: MemberTabsEnum) => { + setActiveTab(index); + }; + + const renderTabs = (): ReactNode => { + return Object.values(MemberTabsEnum).map((tab) => ( + handleTabClick(tab)} + > + {tab} + + )); + }; + + return ( + + + + + + + + {renderTabs()} + + + {activeTab === MemberTabsEnum.CoHost && } + {activeTab === MemberTabsEnum.Speakers && } + {activeTab === MemberTabsEnum.Requests && } + {activeTab === MemberTabsEnum.Listeners && } + + + + + + ) +} + +/* styling */ +// const ButtonContainer = styled.div` +// display: flex; +// justify-content: space-between; +// width: 100%; +// `; +const SpacesMembersContainer = styled.div` + color: black; + display: flex; + flex-direction: column; + margin-top: 28px; + gap: 16px; + width: 100%; +`; + +const ProfileWithSettingsContainer = styled.div` + display: flex; + justify-content: space-between; +`; + +const SettingsIconContainer = styled.div` + display: flex; + margin: 0px 16px; + align-items: center; + cursor: pointer; +` + +const TabContainer = styled.div` + display: flex; + padding: 0px 10px; +`; + +const Tab = styled.div<{active: boolean}>` + flex: 1; + padding: 10px; + text-align: center; + border-bottom: ${(props) => + props.active ? '1px solid #8B5CF6' : '1px solid #82828A26'}; + cursor: pointer; + color: ${(props) => (props.active ? '#8B5CF6' : '#82828A')}; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx new file mode 100644 index 000000000..67e1e1487 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx @@ -0,0 +1,142 @@ +import React, { MouseEventHandler, useEffect, useState } from 'react'; +import styled from 'styled-components'; +import { SpaceDTO } from '@pushprotocol/restapi'; +import * as PushAPI from '@pushprotocol/restapi'; + +import { WidgetContent } from './WidgetContent'; +import { WidgetHeader } from './WidgetHeader'; + +import { ISpaceWidgetProps } from '../exportedTypes'; +import { isLiveSpace, isHostOfSpace, isMemberOfSpace } from './helpers/utils'; + +import { useSpaceData } from '../../../hooks'; + +const DEFAULT_OFFSET = 16; +const DEFAULT_MAXWIDTH = 415; + +export const SpaceWidget: React.FC = ( + options: ISpaceWidgetProps +) => { + const { + bottomOffset = DEFAULT_OFFSET, + rightOffset = DEFAULT_OFFSET, + width, + zIndex = 1000, + spaceId, + shareUrl, + onClose = (() => { + /** */ + }) as MouseEventHandler, + isJoined, + isTimeToStartSpace, + } = options || {}; + const [widgetHidden, setWidgetHidden] = useState(!spaceId); + const { account, spaceObjectData, initSpaceObject, env } = useSpaceData(); + + const [isMinimized, setIsMinimized] = useState(false); + const { getSpaceInfo, setSpaceInfo } = useSpaceData(); + const [spaceData, setSpaceData] = useState(); + + useEffect(() => { + if (!spaceId) { + return; + } + setWidgetHidden(!spaceId); + const fetchData = async () => { + try { + if (getSpaceInfo(spaceId)) { + setSpaceData(getSpaceInfo(spaceId)); + return; + } + const response = await PushAPI.space.get({ spaceId, env }); + setSpaceInfo(spaceId, response); + setSpaceData(response); + } catch (error) { + console.error(error); + } + }; + + fetchData(); + }, [spaceId]); + + useEffect(() => { + (async () => { + if (!spaceData) { + return; + } + if (isLiveSpace(spaceData as SpaceDTO)) { + await initSpaceObject(spaceData?.spaceId as string); + } + })(); + }, [spaceData]); + + const isLive = isLiveSpace(spaceData as SpaceDTO); + const isHost = isHostOfSpace(account, spaceData as SpaceDTO); + const isMember = isMemberOfSpace(account, spaceData as SpaceDTO); + + const toggleWidgetVisibility = () => { + setWidgetHidden(!widgetHidden); + }; + + // Implement the SpaceWidget component + return ( + + ); +}; + +interface WidgetContainerProps { + bottomOffset: number; + rightOffset: number; + width?: number; + zIndex?: number; + hidden: boolean; +} + +const Container = styled.div` + font-family: 'Strawford'; // update to fontFamily theme + border-radius: 12px; // update acc to theme + border: 1px solid #dcdcdf; // update acc to theme + display: flex; + flex-direction: column; + width: ${(props) => (props.width ? `${props.width}px` : 'auto')}; + max-width: ${(props) => + props.width ? `${props.width}px` : `${DEFAULT_MAXWIDTH}px`}; + min-width: 320px; + background: white; + justify-content: flex-start; + position: fixed; + bottom: ${(props) => props.bottomOffset}px; + right: ${(props) => props.rightOffset}px; + visibility: ${(props) => (props.hidden ? 'hidden' : 'visible')}; + opacity: ${(props) => (props.hidden ? 0 : 1)}; + transition: opacity 0.3s ease; + z-index: ${(props) => props.zIndex ?? '1000'}; + overflow: hidden; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx new file mode 100644 index 000000000..15a363597 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx @@ -0,0 +1,124 @@ +import React, { useContext, MouseEventHandler } from 'react' +import styled from 'styled-components'; + +import { Modal } from '../reusables/Modal' +import { ModalHeader } from '../reusables/ModalHeader' +import { IThemeProviderProps, ThemeContext } from '../theme/ThemeProvider'; +import { Button } from '../reusables/Button'; +import { ProfileContainer } from '../reusables/ProfileContainer'; +import Accordion from '../reusables/Accordion'; + +export interface ISpacesInfoProps { + closeSpacesInfo: MouseEventHandler; +} + +interface IThemeProps { + theme: IThemeProviderProps; +} + +export const SpacesInfo: React.FC = (props) => { + const tempImageUrl = "https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg"; + + const theme = useContext(ThemeContext); + + const customStyle = { + color: theme.textColorPrimary, + background: theme.bgColorPrimary, + borderColor: theme.borderColor, + fontWeight: '500', + padding: '14px', + } + + const TEMP_MEMBERS = [ + { + handle: 's4m4', + name: 'Samarendra' + }, + { + handle: 'aamsa', + name: 'Aam Saltman' + }, + { + handle: 's4m4', + name: 'Samarendra' + }, + { + handle: 'aamsa', + name: 'Aam Saltman' + }, + ] + + return ( + + + + + + + + larryscruff's space + Ac orci quam cras in placerat. Sollicitudin tristique sed nisi proin duis. + + + + + + { + TEMP_MEMBERS.map((item) => { + return + }) + } + + + + + + + ) +} + + +/** styling */ +const SpacesInfoContainer = styled.div` + color: black; +`; + +const SpacesDetailsContainer = styled.div` + padding: 0 16px; + margin: 24px 0; +`; + +const Title = styled.div` + font-weight: 500; +`; + +const Description = styled.div` + color: ${(props => props.theme.textColorSecondary)}; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx new file mode 100644 index 000000000..3156b2065 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx @@ -0,0 +1,25 @@ +import { IMediaStream } from '@pushprotocol/restapi'; +import React, { useEffect, useRef } from 'react'; +import styled from 'styled-components'; + +export interface IVideoPlayerProps { + videoCallData: IMediaStream; +} + +export const VideoPlayer: React.FC = ({ videoCallData }) => { + const incomingVideoRef = useRef(null); + + useEffect(() => { + if (!incomingVideoRef.current) return; + const video = incomingVideoRef.current; + video.srcObject = videoCallData; + video.play(); + }, [incomingVideoRef, videoCallData]); + + return ; +}; + +const Video = styled.video` + height:0; + width:0; +}`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx new file mode 100644 index 000000000..50e9d5ce7 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx @@ -0,0 +1,75 @@ +import React from 'react'; +import styled from 'styled-components'; + +import { LiveWidgetContent } from './LiveWidgetContent'; +import { ScheduledWidgetContent } from './ScheduledWidgetContent'; +import { SpaceDTO } from '@pushprotocol/restapi'; + +const LIVE_WIDGET_CONTENT_FIXED_HEIGHT = '485px'; +const SCHEDULED_WIDGET_CONTENT_FIXED_HEIGHT = '350px'; + +interface WidgetContentProps { + account?: string; //Temp Prop to Test Host functionality + spaceData?: SpaceDTO; + shareUrl?: string; + isMinimized: boolean; + + // temp props only for testing demo purpose for now + isHost?: boolean; + isLive?: boolean; + isJoined?: boolean; + isTimeToStartSpace?: boolean; + isMember?: boolean; +} +export const WidgetContent: React.FC = ({ + account, + spaceData, + shareUrl, + isLive, + isHost, + isJoined, + isTimeToStartSpace, + isMember, + isMinimized, +}: WidgetContentProps) => { + return ( + + {isLive ? ( + + ) : ( + + )} + + ); +}; + +//styles +const Container = styled.div<{ height: string; isMinimized: boolean }>` + display: flex; + flex-direction: column; + border-bottom: ${(props) => props.theme.border}; + + height: ${(props) => (props.isMinimized ? '0' : props.height)}; + transition: height 200ms ease-out; + overflow: hidden; + + align-items: center; + justify-content: space-between; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx new file mode 100644 index 000000000..49a50b71e --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx @@ -0,0 +1,211 @@ +import React, { useState, MouseEventHandler, useContext } from 'react'; +import styled from 'styled-components'; + +import { Item, Text } from '../../../config'; +import { formatDate } from '../../../helpers'; + +import SettingsIcon from '../../../icons/settings.svg'; +import CaretDownIcon from '../../../icons/CaretDown.svg'; +import CaretUpIcon from '../../../icons/CaretUp.svg'; +import CalendarIcon from '../../../icons/calendar.svg'; +import LiveIcon from '../../../icons/live.svg'; +import { CloseSvg } from '../../../icons/CloseSvg'; +import { HostPfpContainer, ParticipantContainer } from '../reusables'; +import { SpacesInfo } from './SpacesInfo'; +import { ThemeContext } from '../theme/ThemeProvider'; + +export interface IWidgetHeaderProps { + onClose: MouseEventHandler; + spaceData?: any; + isMinimized: boolean; + setIsMinimized: React.Dispatch>; + toggleWidgetVisibility: () => void; + + // temp props + isLive?: boolean; + isHost?: boolean; +} + +export const WidgetHeader: React.FC = ({ + onClose, + isMinimized, + isHost, + isLive, + setIsMinimized, + toggleWidgetVisibility, + spaceData, +}: IWidgetHeaderProps) => { + const theme = useContext(ThemeContext); + + const tempImageUrl = + 'https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg'; + + const [isSpacesInfoVisible, setIsSpacesInfoVisible] = useState(false); + const handleCloseWidget: React.MouseEventHandler = ( + event + ) => { + // Call for hiding the widget + toggleWidgetVisibility(); + + // Call for running onClose handler from prop + onClose(event); + }; + + const showSpacesInfo = () => { + setIsSpacesInfoVisible(!isSpacesInfoVisible); + console.log(isSpacesInfoVisible); + }; + + const closeSpacesInfo = () => { + setIsSpacesInfoVisible(false); + }; + + return ( + + {!isLive && ( +
+ + + + + {isHost && } + + Settings icon + + + setIsMinimized(!isMinimized)} + src={isMinimized ? CaretUpIcon : CaretDownIcon} + alt="Maximize/Minimize icon" + /> + + + + + +
+ )} +
+ + {spaceData?.spaceName || 'Test Space'} + + {isLive && ( + + + Settings icon + + + setIsMinimized(!isMinimized)} + src={isMinimized ? CaretUpIcon : CaretDownIcon} + alt="Maximize/Minimize icon" + /> + + + + + + )} +
+ {!isLive && ( + + Calendar Icon + + {formatDate(spaceData?.scheduleAt || new Date())} + + + )} + {isLive && ( +
+ + Calendar Icon + + Live + + + + + + + {/* + +190 Listeners + */} + +
+ )} + {isSpacesInfoVisible ? ( + + ) : null} +
+ ); +}; + +//styles +const Container = styled.div` + display: flex; + flex-direction: column; + color: ${(props) => props.theme.titleTextColor}; + padding: 16px 24px; + background: ${(props) => props.theme.titleBg}; +`; + +const Image = styled.img` + display: flex; + max-height: initial; + vertical-align: middle; + overflow: initial; + cursor: pointer; + height: ${(props: any): string => props.height || '24px'}; + width: ${(props: any): string => props.width || '20px'}; + align-self: center; +`; + +const Section = styled.div<{ marginTop?: string }>` + display: flex; + justify-content: space-between; + margin-top: ${(props) => props.marginTop}; +`; + +const Button = styled.button<{ + padding?: string; + color?: string; +}>` + padding: ${(props) => props.padding ?? '0px'}; + color: ${(props) => props.color ?? 'inherit'}; + margin-left: 10px; + background: rgba(255, 255, 255, 0.2); + border-radius: 6px; + border: none; + cursor: pointer; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts b/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts new file mode 100644 index 000000000..bc518b603 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts @@ -0,0 +1,31 @@ +import { SpaceDTO } from '@pushprotocol/restapi'; +import { getSpaceStatus } from '../../helpers/space'; + +export const isHostOfSpace = (account: string, spaceData: SpaceDTO) => { + return ( + account.toUpperCase() === spaceData?.spaceCreator.slice(7).toUpperCase() + ); +}; + +export const isMemberOfSpace = (account: string, spaceData: SpaceDTO) => { + const isMemberArr = spaceData?.members.filter( + (member) => member.wallet.slice(7).toUpperCase() === account.toUpperCase() + ); + return isMemberArr?.length > 0; +}; + +export const isLiveSpace = (spaceData: SpaceDTO) => { + return getSpaceStatus(spaceData?.status) === 'Live'; +}; + +export const isTimeToStart = (spaceData: SpaceDTO, now: Date) => { + const isScheduled = spaceData?.status === 'PENDING'; + const scheduledTime = spaceData?.scheduleAt as Date; + + //true 15 min before scheduledTime + if (scheduledTime && isScheduled) { + return now.getTime() >= new Date(scheduledTime).getTime() - 15 * 60 * 1000; + } else { + return false; + } +}; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/index.ts b/packages/uiweb/src/lib/components/space/SpaceWidget/index.ts new file mode 100644 index 000000000..06fa7de30 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/index.ts @@ -0,0 +1 @@ +export * from "./SpaceWidget"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpacesUI.tsx b/packages/uiweb/src/lib/components/space/SpacesUI.tsx new file mode 100644 index 000000000..0db6e0989 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpacesUI.tsx @@ -0,0 +1,78 @@ +import React, { useEffect, useState } from 'react'; + +import { ISpaceBannerProps, SpaceBanner } from './SpaceBanner'; +import { SpaceWidget } from './SpaceWidget'; +import { ISpaceFeedProps, SpaceFeed } from './SpaceFeed'; +import { ISpaceInvitesProps, SpaceInvites } from './SpaceInvites'; +import { SpaceCreationWidget } from './SpaceCreationWidget'; + +import { SignerType } from '../../types'; +import { ENV } from '../../config'; +import { useSpaceData } from '../../hooks'; +import { ISpacesUIProps, ISpaceWidgetProps } from './exportedTypes'; + +export class SpacesUI { + public account: string; + public signer: SignerType; + public pgpPrivateKey: string; + public env: ENV; + + constructor(props: ISpacesUIProps) { + this.account = props.account; + this.signer = props.signer; + this.pgpPrivateKey = props.pgpPrivateKey; + this.env = props.env; + } + + SpaceBanner: React.FC = (options: ISpaceBannerProps) => { + const { spaceInfo, setSpaceInfo } = useSpaceData(); + + // Use spaceBannerData and setSpaceBannerData in your component + + return ; + }; + + SpaceWidget: React.FC = (options: ISpaceWidgetProps) => { + const { spaceId } = options; + const { spaceWidgetId } = useSpaceData(); + const [SpaceId, setSpaceId] = useState(spaceId); + + useEffect(() => { + setSpaceId(spaceId); + }, [spaceId, setSpaceId]); + + useEffect(() => { + setSpaceId(spaceWidgetId); + }, [spaceWidgetId, setSpaceId]); + + return ; + } + + SpaceFeed: React.FC = (options: ISpaceFeedProps) => { + return ; + }; + + SpaceInvites: React.FC = (options: ISpaceInvitesProps) => { + return ; + }; + + SpaceCreationButtonWidget = () => { + return + } + + connectToSockets = () => { + // Connect to sockets and listen for events + // Update spaceBannerData or trendingListData based on events + const { setSpaceInfo, setTrendingListData } = useSpaceData(); + + // Example of updating spaceBannerData + //setSpaceBannerData(); + }; + + init = () => { + // Initialization logic + + // Call connectToSockets or any other initialization tasks + this.connectToSockets(); + }; +} diff --git a/packages/uiweb/src/lib/components/space/exportedTypes.ts b/packages/uiweb/src/lib/components/space/exportedTypes.ts new file mode 100644 index 000000000..9c4aaf140 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/exportedTypes.ts @@ -0,0 +1,30 @@ +import { MouseEventHandler } from "react"; + +import { ENV } from "../../config"; +import { SignerType } from "../../types"; + +export interface ISpacesUIProps { + account: string; + signer: SignerType; + pgpPrivateKey: string; + env: ENV; +} + +export interface ISpaceWidgetProps { + // Add props specific to the SpaceWidget class method + account?: string; + bottomOffset?: number; + rightOffset?: number; + zIndex?: number; + spaceId?: string; + width?: number; + shareUrl?: string; + onClose?: MouseEventHandler; + + // props only for testing demo purpose for now + isHost?: boolean; + isLive?: boolean; + isJoined?: boolean; + isTimeToStartSpace? :boolean; + isMember?: boolean; +} diff --git a/packages/uiweb/src/lib/components/space/helpers/date.ts b/packages/uiweb/src/lib/components/space/helpers/date.ts new file mode 100644 index 000000000..fc9bcd62a --- /dev/null +++ b/packages/uiweb/src/lib/components/space/helpers/date.ts @@ -0,0 +1,48 @@ +/** + * Get Date and Time in Day. + * @param {string | Date} datestring - The JavaScript Date String or Date Object. + * @returns {string} - The Date and Time in Day, DD Month at HH:MM AM format. + */ + +export function getDateAndTime(datestring: string | Date) { + const date = new Date(datestring); + + //Day of Week + const dayOfWeek = date.getDay(); + const weekdays = [ + 'Sunday', + 'Monday', + 'Tuesday', + 'Wednesday', + 'Thursday', + 'Friday', + 'Saturday', + ]; + const weekday = weekdays[dayOfWeek]; + + //Date + const day = date.getDate(); + const monthIndex = date.getMonth(); + const months = [ + 'January', + 'February', + 'March', + 'April', + 'May', + 'June', + 'July', + 'August', + 'September', + 'October', + 'November', + 'December', + ]; + const month = months[monthIndex]; + + //Time + const amOrPm = date.getHours() >= 12 ? 'PM' : 'AM'; + const hour = amOrPm === 'PM' ? date.getHours() % 12 : date.getHours(); + const minute = date.getMinutes(); + + return `${weekday}, ${day} ${month} at ${hour}:${minute} ${amOrPm}`; + } diff --git a/packages/uiweb/src/lib/components/space/helpers/space.ts b/packages/uiweb/src/lib/components/space/helpers/space.ts new file mode 100644 index 000000000..57eb76703 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/helpers/space.ts @@ -0,0 +1,12 @@ +/** + * Get Status of the Space. + * @param {string | Date} datestring - The JavaScript Date String or Date Object. + * @returns {string} - The Status of the Space. + */ + +export type ISpaceStatus = 'Live' | 'Scheduled' | 'Ended'; +export function getSpaceStatus(status: any): ISpaceStatus { + if (status === 'ACTIVE') return 'Live'; + if (status === 'PENDING') return 'Scheduled'; + return 'Ended'; +} diff --git a/packages/uiweb/src/lib/components/space/index.ts b/packages/uiweb/src/lib/components/space/index.ts new file mode 100644 index 000000000..6d9bc714a --- /dev/null +++ b/packages/uiweb/src/lib/components/space/index.ts @@ -0,0 +1,15 @@ +import { ISpaceBannerProps } from "./SpaceBanner"; +import { ISpaceFeedProps } from "./SpaceFeed"; +import { SpacesUI } from "./SpacesUI"; +import { ISpaceInvitesProps } from "./SpaceInvites"; +import { ISpaceCreateWidgetProps } from "./SpaceCreationWidget"; + +export { + SpacesUI, + ISpaceBannerProps, + ISpaceFeedProps, + ISpaceInvitesProps, + ISpaceCreateWidgetProps +} + +export * from './exportedTypes'; diff --git a/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx b/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx new file mode 100644 index 000000000..d962d5fdd --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx @@ -0,0 +1,89 @@ +import React, { useState, useContext } from 'react'; +import styled from 'styled-components'; + +import CaretDownIcon from '../../../icons/CaretDownGrey.svg'; +import CaretUpIcon from '../../../icons/CaretUpGrey.svg'; +import { ThemeContext } from '../theme/ThemeProvider'; + +interface IAccordionProps { + title: string; + items?: number; + children: React.ReactNode; +} + +const Accordion: React.FC = ({ title, items, children }) => { + const theme = useContext(ThemeContext) + + const [isOpen, setIsOpen] = useState(true); + + const toggleAccordion = () => { + setIsOpen((prevIsOpen) => !prevIsOpen); + }; + + return ( + + + + <div>{title}</div> + { items ? <PendingCount theme={theme}>{items}</PendingCount> : null } + + Maximize/Minimize icon + + {children} + + ); +}; + +export default Accordion; + +/* styling */ +const AccordionParent = styled.div` + border: 1px solid #E4E4E7; + border-radius: 8px; + padding: 6.5px 0; + margin: 16px 0; +`; + +const AccordionBody = styled.div<{ isOpen: boolean }>` + overflow-y: scroll; + max-height: ${({ isOpen }) => (isOpen ? '200px' : '0')}; + transition: max-height 200ms ease-out; +`; + +const AccordionTitle = styled.div` + display: flex; + justify-content: space-between; + align-items: center; + + padding: 8px 16px; + + cursor: pointer; +`; + +const Title = styled.div` + display: flex; + align-items: center; +`; + +const PendingCount = styled.div` + background: ${(props => props.theme.btnColorPrimary)}; + border-radius: 8px; + padding: 4px 10px; + margin-left: 6px; + font-size: 13px; + color: ${(props => props.theme.titleTextColor)}; +`; + +const Image = styled.img` + display: flex; + max-height: initial; + vertical-align: middle; + overflow: initial; + cursor: pointer; + height: ${(props: any): string => props.height || '24px'}; + width: ${(props: any): string => props.width || '20px'}; + align-self: center; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/reusables/Button.tsx b/packages/uiweb/src/lib/components/space/reusables/Button.tsx new file mode 100644 index 000000000..8ae710ad7 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/Button.tsx @@ -0,0 +1,82 @@ +/** + * @file Button + * generic button component for spaces + * Represents the props for the Button component. + * @interface IButtonProps + * @property {string} [width] - The width of the button. Optional. + * @property {React.ReactNode} children - The content of the button. + * @property {React.MouseEventHandler} [onClick] - The click event handler for the button. Optional. + * @property {ISpacesTheme} [theme] - The theme for the button. Optional. + * @property {any} [customStyle] - Custom styles for the button. Optional. + */ + +import { MouseEventHandler, useContext } from 'react' +import styled from 'styled-components'; + +import { ISpacesTheme } from '../theme'; +import { ThemeContext } from '../theme/ThemeProvider'; + +export interface IButtonProps { + width?: string; + height?: string; + children: any; + onClick?: MouseEventHandler; + theme?: ISpacesTheme; + customStyle?: any; +} + +/** + * A button component. + * @function Button + * @param {IButtonProps} props - The props for the Button component. + * @returns {JSX.Element} The rendered Button component. + */ +export const Button: React.FC = (props) => { + const theme = useContext(ThemeContext); + + const { onClick, width, height, customStyle } = props; + + return ( + + { props.children } + + ) +} + +/* styling */ +const SpacesButton = styled.button` + display: flex; + flex-direction: row; + justify-content: center; + align-items: center; + padding: ${(props => props.customStyle ? props.customStyle.padding : '10px 16px')}; + margin-top: 12px; + + background: ${(props => props.customStyle ? props.customStyle.background : props.theme.btnColorPrimary)}; + border: 2px solid ${(props => props.customStyle ? props.customStyle.borderColor : props.theme.btnOutline)}; + color: ${(props => props.customStyle ? props.customStyle.color : props.theme.titleTextColor)}; + border-radius: 8px; + font-size: 14px; + font-weight: ${(props => props.customStyle ? props.customStyle.fontWeight : '700')}; + font-family: 'Strawford'; // update to fontFamily theme + + /* Inside auto layout */ + flex: none; + order: 0; + flex-grow: 0; + + transition: 150ms ease-in-out; + + &:hover { + cursor: pointer; + } + + width: ${(props => props.width ? props.width : '100%')}; + height: ${(props => props.height ? props.height : '100%')}; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/reusables/Checkbox.tsx b/packages/uiweb/src/lib/components/space/reusables/Checkbox.tsx new file mode 100644 index 000000000..6bfb07c13 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/Checkbox.tsx @@ -0,0 +1,18 @@ +export const Checkbox = (props: { + id: string; + label: string; + value?: boolean; + onChange: () => void; +}) => { + return ( +
+ + +
+ ); +}; diff --git a/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx b/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx new file mode 100644 index 000000000..4160b807b --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx @@ -0,0 +1,148 @@ +/* eslint-disable prefer-const */ +import React, { useContext, useState, useEffect } from 'react'; +import styled from 'styled-components'; + +import { ThemeContext } from '../theme/ThemeProvider'; + +interface DateTimePickerProps { + propsDate: Date; + propsTime: string; + onDateChange?: any; + onTimeChange?: any; +} + +const DateTimePicker: React.FC = (props) => { + const { + propsDate, onDateChange, onTimeChange, + } = props; + const theme = useContext(ThemeContext); + + const [selectedHours, setSelectedHours] = useState('1'); + const [selectedMinutes, setSelectedMinutes] = useState('0'); + const [selectedAMPM, setSelectedAMPM] = useState('AM'); + const [timeHumanReadable, setTimeHumanReadable] = useState(0); + + const handleDateChange = (event: React.ChangeEvent) => { + const date = new Date(event.target.value); + onDateChange(date); + }; + + const getTime = (hours: number, minutes: number, ampm: string, propsDate: Date) => { + let totalMinutes = hours * 60 + minutes; + + if (ampm === 'PM' && hours !== 12) { + totalMinutes += 12 * 60; + } else if (ampm === 'AM' && hours === 12) { + totalMinutes -= 12 * 60; + } + + const date = new Date(propsDate); + date.setHours(0, 0, 0, 0); + date.setMinutes(totalMinutes); + + return date.getTime(); + }; + + useEffect(() => { + const hours = parseInt(selectedHours, 10); + const minutes = parseInt(selectedMinutes, 10); + const ampm = selectedAMPM; + + const newTimeEpoch = getTime(hours, minutes, ampm, propsDate); + setTimeHumanReadable(newTimeEpoch); + + onTimeChange(newTimeEpoch) + }, [selectedHours, selectedMinutes, selectedAMPM, propsDate]); + + return ( + +
Select date and time
+ + + + + + +
+ ); +}; + +const DateTimeCont = styled.div` + display: flex; + flex-direction: column; + + margin-top: 24px; +`; + +const Input = styled.input` + padding: 16px; + margin-top: 12px; + + width: 330px; + + background: #FFFFFF; + border: 1px solid ${(props => props.theme.btnOutline)}; + box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border-radius: 12px; + + font-size: 16px; + font-family: 'Strawford'; +`; + +const TimeContainer = styled.div` + display: flex; + width: 100%; + gap: 12px; +`; + +const Select = styled.select<{ width?: string }>` + padding: 16px; + margin-top: 12px; + + background: #FFFFFF; + border: 1px solid ${(props => props.theme.btnOutline)}; + box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border-radius: 12px; + + font-size: 16px; + font-family: 'Strawford'; + width: ${(props => props.width ? props.width : '100%')}; +`; + +export default DateTimePicker; diff --git a/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx b/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx new file mode 100644 index 000000000..3c410a760 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx @@ -0,0 +1,111 @@ +import React from 'react'; +import styled from 'styled-components'; + +export interface IHostPfpContainerProps { + name?: string; + handle?: string; + imageUrl?: string; + statusTheme: "Live" | "Scheduled" | "Ended"; + imageHeight?: string; +} + +export const HostPfpContainer: React.FC = ({ + name = "Host Name", + handle = "Host Handle", + imageUrl = "", + statusTheme, + imageHeight, +}: IHostPfpContainerProps) => { + return ( + + + + + + + {name} + Host + + {handle && + + {/* Fetch the handle from Lenster */}@{handle} + + } + + + ); +}; + +const ProfileContainer = styled.div` + display: flex; + flex-direction: row; + justify-content: space-between; + width: 100%; + align-items: center; +`; + +const PfpContainer = styled.div` + display: flex; +`; + +const Pfp = styled.img<{ imageHeight?: string }>` + height: ${(props) => (props.imageHeight ?? '32px')}; + width: ${(props) => (props.imageHeight ?? '32px')};; + border-radius: 50%; +`; + +const HostContainer = styled.div` + display: flex; + flex-direction: column; + justify-content: center; + align-items: flex-start; + padding-left: 8px; + width: 100%; + overflow: hidden; + text-overflow: ellipsis; +`; + +const HostName = styled.div` + display: flex; + flex-direction: row; + font-weight: 600; + font-size: 15px; + width: 100%; +`; + +const Name = styled.span` + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; +`; + +const Host = styled.div<{ statusTheme?: string }>` + display: flex; + flex-direction: row; + align-items: center; + padding: 2px 8px; + margin-left: 8px; + line-height: 18px; + width: max-content; + height: 19px; + background: ${(props) => + props.statusTheme === 'Live' + ? 'rgba(255, 255, 255, 0.2);' + : 'rgba(139, 92, 246, 0.2)'}; + color: ${(props) => (props.statusTheme === 'Live' ? 'inherit' : '#8B5CF6')}; + border-radius: 6px; + font-weight: 500; + font-size: 10px; +`; + +const HostHandle = styled.div<{ statusTheme?: string }>` + color: ${(props) => (props.statusTheme === 'Live' ? '#F5F5F5E5' : '#71717A')}; + padding: 0; + font-weight: 450; + font-size: 14px; + line-height: 130%; + width: 100%; + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; +`; diff --git a/packages/uiweb/src/lib/components/space/reusables/Modal.tsx b/packages/uiweb/src/lib/components/space/reusables/Modal.tsx new file mode 100644 index 000000000..b45a54949 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/Modal.tsx @@ -0,0 +1,83 @@ +/** + * @file Modal + * generic modal component for spaces UI + * does not handle any business logic, acts only as a container + */ +import { useRef, useContext } from 'react'; +import styled from 'styled-components' + +import { ThemeContext } from '../theme/ThemeProvider'; + +import { useClickAway } from '../../../hooks'; + +interface IModalProps { + width?: string; + clickawayClose?: () => void; + children: any; +} + +const ClickawayCloseModal = ({ children, clickawayClose, width }: IModalProps) => { + const modalRef = useRef(null); + const theme = useContext(ThemeContext) + + useClickAway(modalRef, () => { + if (clickawayClose) { + clickawayClose(); + } + }); + + return ( + + {children} + + ); +}; + +export const Modal = ({ clickawayClose, children, width }: IModalProps) => { + const theme = useContext(ThemeContext) + return ( + + {clickawayClose ? ( + {children} + ) : ( + + { children } + + )} + + ); +}; + +/* styling */ + +const ModalOverlay = styled.div` + position: fixed; + top: 0; + left: 0; + width: 100%; + height: 100%; + background-color: rgba(0, 0, 0, 0.4); /* Black with 40% opacity */ + display: flex; + justify-content: center; + align-items: center; +`; + +const ModalParent = styled.div` + position: absolute; + top: 50%; + left: 50%; + transform: translate(-50%, -50%); + + display: flex; + flex-direction: column; + align-items: center; + padding: 24px 20px; + + background: ${(props => props.theme.bgColorPrimary)}; + border-radius: 12px; + + width: ${(props => props.width ? props.width : 'auto')}; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx b/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx new file mode 100644 index 000000000..e6df966a6 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx @@ -0,0 +1,101 @@ +import { MouseEventHandler } from 'react'; +import styled from 'styled-components'; + +import { CloseSvg } from '../../../icons/CloseSvg'; +import { ArrowLeft } from '../../../icons/ArrowLeft'; + +export interface IModalHeaderProps { + heading: string; + headingBadgeNumber?: number; + backCallback?: MouseEventHandler; + closeCallback?: MouseEventHandler; +} + +export const ModalHeader = (props: IModalHeaderProps) => { + return ( +
+
+ {props.backCallback ? ( + + + + ) : null} + + + {props.heading} + {props.headingBadgeNumber && {props.headingBadgeNumber}} + + + {props.closeCallback ? ( + + + + ) : null} +
+
+ ); +}; + +/* styling */ +const Header = styled.div` + display: flex; + align-items: center; + width: 100%; + + margin-bottom: 24px; +`; + +const BackBtn = styled.button` + position: absolute; + top: 0; + left: 0; + margin: 1.5rem; + + border: none; + background: transparent; + + &:hover { + cursor: pointer; + } +`; + +const CloseBtn = styled.button` + position: absolute; + top: 0; + right: 0; + margin: 1.5rem; + + border: none; + background: transparent; + + &:hover { + cursor: pointer; + } +`; + +const CenterText = styled.div` + position: absolute; + top: 0; + left: 50%; + transform: translateX(-50%); + margin: 1.5rem 0; + + display: flex; + flex-direction: row; + align-items: center; + + font-weight: 500; +`; + +const NumberBadge = styled.div` + display: flex; + justify-content: center; + align-items: center; + background:#8B5CF6; + color: #fff; + border-radius: 8px; + margin-left: 8px; + padding: 4px 8px; + font-size: 13px; + font-weight: 500; +}`; diff --git a/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx b/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx new file mode 100644 index 000000000..789f016ce --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx @@ -0,0 +1,98 @@ +import React from 'react'; +import styled from 'styled-components'; + +export interface IParticipantContainerProps { + participants: any[]; + orientation?: 'maximized' | 'minimized' | 'pill'; + imageHeight?: any; +} + +export const ParticipantContainer: React.FC = ({ + participants, + orientation, + imageHeight, +}) => { + return ( + + + {orientation === 'pill' + ? participants && + participants.map( + (person, index) => + index < 2 && ( + + ) + ) + : participants && + participants.map( + (person, index) => + index < 3 && ( + + ) + )} + + + {orientation === 'pill' + ? participants && (participants.length as number) - 3 > 0 + ? `+${(participants.length as number) - 3}` + : null + : participants && (participants.length as number) - 3 > 0 + ? `+${(participants.length as number) - 3}` + : null} + + + ); +}; + +const Participants = styled.div` + display: flex; + flex-direction: row; + align-items: center; + justify-content: space-between; +}`; + +const ParticipantsIconContainer = styled.div<{ orientation?: string }>` + display: grid; + grid-template-columns: repeat(5, 1fr); + width: ${(props) => (props.orientation === 'pill' ? '46.5px' : '62px')}; + padding: 0 4px; +}`; + +const ParticipantsIcon = styled.img<{ imageHeight?: any }>` + height: ${(props) => (props.imageHeight ? props.imageHeight : '31px')}; + border-radius: 50%; + + &.index0 { + position: relative; + top: 0; + left: 0; + z-index: 3; + } + &.index1 { + position: relative; + top: 0; + left: -50%; + z-index: 2; + } + &.index2 { + position: relative; + top: 0; + left: -100%; + z-index: 1; + } +}`; + +const ParticipantsText = styled.div` + display: flex; + justify-content: center; + align-items: center; + width: auto; +}`; diff --git a/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx b/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx new file mode 100644 index 000000000..3a0efab98 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx @@ -0,0 +1,194 @@ +import React, { useContext, useState } from 'react'; +import styled from 'styled-components'; +import { ThemeContext } from '../theme/ThemeProvider'; + +export interface IProfileContainerProps { + name?: string; + handle?: string; + imageUrl?: string; + tag?: string; + imageHeight?: string; + border?: boolean; + contBtn?: any; + btnCallback?: any; + removeCallback?: any; + promoteCallback?: any; +} + +export const ProfileContainer: React.FC = ({ + name = "Host Name", + handle = "Host Handle", + imageUrl = "", + tag, + imageHeight, + border = false, + contBtn, + btnCallback, + removeCallback, + promoteCallback, +}: IProfileContainerProps) => { + const theme = useContext(ThemeContext); + + const [isDDOpen, setIsDDOpen] = useState(false) + + const handleDDState = () => { + setIsDDOpen(!isDDOpen) + } + + return ( + + + + + + + + {name} + + {handle && + + {/* Fetch the handle from Lenster */}@{handle} + + } + + { tag ? {tag} : null } + { contBtn ?
{contBtn}
: null } +
+ + { + isDDOpen ? + + + Remove + + + + Make Admin + + + + Close
This Dropdown +
+
+ : null + } +
+ ); +}; + +const ParentContainer = styled.div<{ border?: boolean }>` + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; + + position: relative; + + padding: 8px 16px; + + border: ${(props => props.border ? '1px solid #E4E4E7' : 'none')}; + border-radius: 16px; +`; + +const PfpContainer = styled.div` + display: flex; +`; + +const Pfp = styled.img<{ imageHeight?: string }>` + height: ${(props) => (props.imageHeight ?? '32px')}; + width: ${(props) => (props.imageHeight ?? '32px')};; + border-radius: 50%; +`; + +const HostContainer = styled.div` + display: flex; + flex-direction: row; + justify-content: space-between; + align-items: center; + padding-left: 8px; + width: 100%; + overflow: hidden; + text-overflow: ellipsis; +`; + +const ProfileDetails = styled.div` + display: flex; + flex-direction: column; + + flex-grow: 1; + white-space: nowrap; + text-overflow: ellipsis; + overflow: hidden; + + width: 200px; +`; + +const HostName = styled.div` + display: flex; + flex-direction: row; + font-weight: 600; + font-size: 15px; + width: 100%; +`; + +const Name = styled.span` + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; +`; + +const Host = styled.div` + display: flex; + flex-direction: row; + align-items: center; + margin-left: 8px; + line-height: 18px; + width: max-content; + background: rgba(139, 92, 246, 0.2); + color: #8B5CF6; + border-radius: 6px; + font-weight: 500; + font-size: 12px; + padding: 6px 10px; + border-radius: 8px; +`; + +const HostHandle = styled.div<{ theme?: any }>` + background: ${(props => props.theme.textGradient)}; + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; + padding: 0; + font-weight: 450; + font-size: 14px; + line-height: 130%; + width: 100%; + text-overflow: ellipsis; + white-space: nowrap; + overflow: hidden; +`; + +const DropDown = styled.div<{ theme?: any }>` + position: absolute; + top: 0px; + right: 0px; + + display: flex; + flex-direction: column; + gap: 12px; + + justify-content: center; + align-items: start; + + padding: 16px; + background: ${(props => props.theme.bgColorPrimary)}; + color: ${(props => props.theme.textColorPrimary)}; + border-radius: 16px; + + border: 1px solid ${(props => props.theme.borderColor)}; +`; + +const DDItem = styled.div` + cursor: pointer; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx b/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx new file mode 100644 index 000000000..5f44c25e2 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx @@ -0,0 +1,76 @@ +import { ChangeEvent, useContext } from 'react'; +import styled from 'styled-components'; + +import { ISpacesTheme } from '../theme'; +import { ThemeContext } from '../theme/ThemeProvider'; + +import { CloseSvg } from '../../../icons/CloseSvg'; + +export interface ISearchInputProps { + labelName?: string; + inputValue?: string; + onInputChange?: any; + clearInput?: any; +} + +export const SearchInput = (props: ISearchInputProps) => { + const theme = useContext(ThemeContext); + + const handleChange = (event: ChangeEvent) => { + props.onInputChange(event); + }; + + return ( + + + + + + + + + + + + ); +}; + +/* styling */ +const InputContainer = styled.div` + display: flex; + flex-direction: column; + + margin: 16px 0; + + font-family: 'Strawford'; // update to fontFamily theme +`; + +const LabelContainer = styled.div` + display: flex; + justify-content: space-between; + + font-weight: 500; +`; + +const Input = styled.input` + padding: 16px; + margin-top: 12px; + + width: 330px; + + background: #FFFFFF; + border: 1px solid ${(props => props.theme.btnOutline)}; + box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border-radius: 12px; +`; + +const InputWrapper = styled.div` + position: relative; +`; + +const CloseBtn = styled.div` + position: absolute; + right: 0; + top: 0; + padding: 1.75rem 0.75rem; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx b/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx new file mode 100644 index 000000000..d635de040 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx @@ -0,0 +1,35 @@ +import React, { useContext } from 'react'; +import styled, { keyframes } from 'styled-components'; +import { SpinnerSvg } from '../../../icons/SpinnerSvg'; + +type SpinnerPropType = { + size?: string; +}; + +type SpinLoaderPropType = { + width?: string; +}; + +export const Spinner: React.FC = ({ size = 42 }) => { + return ( + + + + ); +}; + +//styles +const spinAnimation = keyframes` + from { transform:rotate(0deg); } + to { transform:rotate(360deg); } +`; +const SpinLoader = styled.div` + display: flex; + flex: initial; + align-self: center; + width: ${(props) => props.width}; + animation-name: ${spinAnimation}; + animation-duration: 2500ms; + animation-iteration-count: infinite; + animation-timing-function: linear; +`; diff --git a/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx b/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx new file mode 100644 index 000000000..d87d90a2d --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx @@ -0,0 +1,71 @@ +import React, { ChangeEvent, useContext } from 'react'; +import styled from 'styled-components'; + +import { ISpacesTheme } from '../theme'; +import { ThemeContext } from '../theme/ThemeProvider'; + +export interface ITextInputProps { + charCount: number; + labelName?: string; + inputValue: string; + onInputChange: any; +} + +export const TextInputWithCounter = (props: ITextInputProps) => { + const theme = useContext(ThemeContext); + + const handleChange = (event: ChangeEvent) => { + const newText = event.target.value; + const count = newText.length; + + if (count <= props.charCount) { + props.onInputChange(event); + } + }; + + return ( + + + + {props.inputValue.length} / {props.charCount} + + + + ); +}; + +/* styling */ +const InputContainer = styled.div` + display: flex; + flex-direction: column; + + margin: 16px 0; + + font-family: 'Strawford'; // update to fontFamily theme +`; + +const LabelContainer = styled.div` + display: flex; + justify-content: space-between; + + font-weight: 500; +`; + +const Input = styled.input` + padding: 16px; + margin-top: 12px; + + width: 330px; + + background: #FFFFFF; + border: 1px solid ${(props => props.theme.btnOutline)}; + box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border-radius: 12px; + + font-family: 'Strawford'; // update to fontFamily theme + font-size: 14px; +`; + +const CharCounter = styled.div` + color: ${(props => props.theme.textColorSecondary)}; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/reusables/index.ts b/packages/uiweb/src/lib/components/space/reusables/index.ts new file mode 100644 index 000000000..b9a75a085 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/reusables/index.ts @@ -0,0 +1,2 @@ +export * from './HostPfpContainer'; +export * from './ParticipantContainer'; diff --git a/packages/uiweb/src/lib/components/space/theme/ThemeProvider.tsx b/packages/uiweb/src/lib/components/space/theme/ThemeProvider.tsx new file mode 100644 index 000000000..999c6e8d1 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/theme/ThemeProvider.tsx @@ -0,0 +1,19 @@ +/** + * @file ThemeProvider.tsx: This acts as the custom theme provider for the entire app. + */ +import { createContext } from 'react'; + +import { ISpacesTheme, lightTheme } from './index'; + +/** + * @param theme optional: light or dark theme. defaults to light + * @param customTheme optional: custom colors/theme + * @param children children to be wrapped with ThemeProvider + */ +export interface IThemeProviderProps { + theme?: 'light' | 'dark'; + customTheme?: Partial; + children: any; +} + +export const ThemeContext = createContext(lightTheme); diff --git a/packages/uiweb/src/lib/components/space/theme/index.ts b/packages/uiweb/src/lib/components/space/theme/index.ts new file mode 100644 index 000000000..99c70253e --- /dev/null +++ b/packages/uiweb/src/lib/components/space/theme/index.ts @@ -0,0 +1,58 @@ +/** + * @file theme file: all the predefined themes are defined here + */ + +export interface ISpacesTheme { + titleBg?: string; + titleTextColor?: string; + bgColorPrimary?: string; + bgColorSecondary?: string; + textColorPrimary?: string; + textColorSecondary?: string; + textGradient?: string; + btnColorPrimary?: string; + btnOutline?: string; + borderColor?: string; + borderRadius?: string; + containerBorderRadius?: string; + statusColorError?: string; + statusColorSuccess?: string; + iconColorPrimary?: string; + fontFamily?: string; +} + +export const lightTheme: ISpacesTheme = { + titleBg: 'linear-gradient(87.17deg, #EA4EE4 0%, #D23CDF 0.01%, #8B5CF6 100%)', + titleTextColor: '#fff', + bgColorPrimary: '#fff', + bgColorSecondary: '#EDE9FE', + textColorPrimary: '#000', + textColorSecondary: '#71717A', + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', + btnColorPrimary: '#8B5CF6', + btnOutline: '#8B5CF6', + borderColor: '#DCDCDF', + borderRadius: '17px', + containerBorderRadius: '12px', + statusColorError: '#E93636', + statusColorSuccess: '#30CC8B', + iconColorPrimary: '#82828A' +}; + +export const darkTheme: ISpacesTheme = { + titleBg: 'linear-gradient(87.17deg, #EA4EE4 0%, #D23CDF 0.01%, #8B5CF6 100%)', + titleTextColor: '#fff', + bgColorPrimary: '#000', + bgColorSecondary: '#292344', + textColorPrimary: '#fff', + textColorSecondary: '#71717A', + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', + btnColorPrimary: '#8B5CF6', + btnOutline: '#8B5CF6', + borderColor: '#3F3F46', + borderRadius: '17px', + containerBorderRadius: '12px', + statusColorError: '#E93636', + statusColorSuccess: '#30CC8B', + iconColorPrimary: '#71717A' +}; diff --git a/packages/uiweb/src/lib/config/index.ts b/packages/uiweb/src/lib/config/index.ts index c53ff8b53..6068abaca 100644 --- a/packages/uiweb/src/lib/config/index.ts +++ b/packages/uiweb/src/lib/config/index.ts @@ -1,2 +1,3 @@ export * from './constants'; -export * from './themisation'; \ No newline at end of file +export * from './themisation'; +export * from './styles'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/config/styles.tsx b/packages/uiweb/src/lib/config/styles.tsx new file mode 100644 index 000000000..7bbce9aa6 --- /dev/null +++ b/packages/uiweb/src/lib/config/styles.tsx @@ -0,0 +1,75 @@ +import React from 'react'; +import styled, { css } from 'styled-components'; + +interface CommonStyles extends React.CSSProperties { + // Add any additional custom style properties here + customProperty?: string; // random for now +} + +const commonStyle = css` + display: ${(props) => props.display}; + position: ${(props) => props.position}; + background: ${(props) => props.background}; + color: ${(props) => props.color}; + cursor: ${(props) => props.cursor}; + flex: ${(props) => props.flex}; + flex-direction: ${(props) => props.flexDirection}; + flex-wrap: ${(props) => props.flexWrap}; + gap: ${(props) => props.gap}; + align-self: ${(props) => props.alignSelf}; + align-items: ${(props) => props.alignItems}; + align-content: ${(props) => props.alignContent}; + justify-content: ${(props) => props.justifyContent}; + padding: ${(props) => props.padding}; + margin: ${(props) => props.margin}; + margin-top: ${(props) => props.marginTop}; + margin-left: ${(props) => props.marginLeft}; + margin-right: ${(props) => props.marginRight}; + margin-bottom: ${(props) => props.marginBottom}; + min-width: ${(props) => props.minWidth}; + max-width: ${(props) => props.maxWidth}; + overflow-y: ${(props) => props.overflowY}; + font-size: ${(props) => props.fontSize}; + font-weight: ${(props) => props.fontWeight}; + text-align: ${(props) => props.textAlign}; + filter: ${(props) => props.filter}; + box-shadow: ${(props) => props.boxShadow}; + top: ${(props) => props.top}; + bottom: ${(props) => props.bottom}; + left: ${(props) => props.left}; + right: ${(props) => props.right}; + width: ${(props) => props.width}; + height: ${(props) => props.height}; + border: ${(props) => props.border}; + border-radius: ${(props) => props.borderRadius}; + overflow: ${(props) => props.overflow}; + z-index: ${(props) => props.zIndex}; +`; + +export const Item = styled.div` + ${commonStyle} +`; + +export const Anchor = styled.a` + ${commonStyle} +`; + +export const Container = styled.div` + ${commonStyle} +`; + +export const Image = styled.img` + ${commonStyle} +`; + +export const Heading = styled.h1` + ${commonStyle} +`; + +export const Button = styled.button` + ${commonStyle} +`; + +export const Text = styled.span` + ${commonStyle} +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/context/index.ts b/packages/uiweb/src/lib/context/index.ts index 5b023c5a2..38bc1f881 100644 --- a/packages/uiweb/src/lib/context/index.ts +++ b/packages/uiweb/src/lib/context/index.ts @@ -1,7 +1,9 @@ import ChatPropsContext from "./chatPropsContext"; import ChatMainStateContext from "./chatMainStateContext"; +import { SpaceDataContext } from "./spacesContext"; export { ChatPropsContext, - ChatMainStateContext + ChatMainStateContext, + SpaceDataContext }; \ No newline at end of file diff --git a/packages/uiweb/src/lib/context/spacesContext.ts b/packages/uiweb/src/lib/context/spacesContext.ts new file mode 100644 index 000000000..285fdfb2a --- /dev/null +++ b/packages/uiweb/src/lib/context/spacesContext.ts @@ -0,0 +1,113 @@ +import React, { createContext } from 'react'; +import * as PushAPI from '@pushprotocol/restapi'; +import { SpaceDTO, SpaceIFeeds } from '@pushprotocol/restapi'; +import { SignerType } from '../types'; +import { ENV } from '../config'; + +export interface ISpaceInfo { + [key: string]: SpaceDTO; +} + +export interface ISpacePaginationData { + apiData?: SpaceIFeeds[]; + currentPage?: number; + lastPage?: number; +} + +export interface ISpaceDataContextValues { + account: string; + setAccount: React.Dispatch>; + signer: SignerType | undefined; + setSigner: React.Dispatch>; + pgpPrivateKey: string; + setPgpPrivateKey: React.Dispatch>; + env: ENV; + setEnv: React.Dispatch>; + trendingListData: any; + setTrendingListData: React.Dispatch>; + spaceInfo: ISpaceInfo; + setSpaceInfo: (key: string, value: SpaceDTO) => void; + getSpaceInfo: (key: string) => SpaceDTO | undefined; + spaceWidgetId: string; + setSpaceWidgetId: React.Dispatch>; + mySpaces: ISpacePaginationData; + setMySpaces: (paginationData: ISpacePaginationData) => void; + popularSpaces: ISpacePaginationData; + setPopularSpaces: (paginationData: ISpacePaginationData) => void; + spaceRequests: ISpacePaginationData; + setSpaceRequests: (paginationData: ISpacePaginationData) => void; + spaceObjectData: PushAPI.SpaceData; + setSpaceObjectData: (data: any) => void; + initSpaceObject: (data: any) => Promise; + spacesObjectRef: React.MutableRefObject; +} + +export const initialSpaceDataContextValues: ISpaceDataContextValues = { + account: '', + setAccount: () => { + /**/ + }, + signer: undefined, + setSigner: () => { + /**/ + }, + pgpPrivateKey: '', + setPgpPrivateKey: () => { + /**/ + }, + env: ENV.DEV, + setEnv: () => { + /**/ + }, + trendingListData: null, + setTrendingListData: () => { + /**/ + }, + spaceInfo: {} as ISpaceInfo, + setSpaceInfo: () => { + /**/ + }, + getSpaceInfo: () => undefined, + spaceWidgetId: '', + setSpaceWidgetId: () => { + /**/ + }, + mySpaces: { + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData, + setMySpaces: () => { + /**/ + }, + popularSpaces: { + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData, + setPopularSpaces: () => { + /**/ + }, + spaceRequests: { + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData, + setSpaceRequests: () => { + /**/ + }, + spaceObjectData: {} as PushAPI.SpaceData, + setSpaceObjectData: () => { + /**/ + }, + initSpaceObject: async () => { + /**/ + }, + spacesObjectRef: { + current: null, + } as React.MutableRefObject, +}; + +export const SpaceDataContext = createContext( + initialSpaceDataContextValues +); diff --git a/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx new file mode 100644 index 000000000..4ea53ea27 --- /dev/null +++ b/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx @@ -0,0 +1,222 @@ +import { useEffect, useRef, useState } from 'react'; +import { SignerType, SpaceDTO, SpaceIFeeds } from '@pushprotocol/restapi'; + +import { SpacesUI } from '../components'; +import { ThemeContext } from '../components/space/theme/ThemeProvider'; +import { ISpacesTheme, lightTheme } from '../components/space/theme'; +import { + ISpaceDataContextValues, + ISpaceInfo, + ISpacePaginationData, + SpaceDataContext, +} from '../context/spacesContext'; +import { ENV } from '../config'; + +import * as PushAPI from '@pushprotocol/restapi'; +import { useSpaceNotificationSocket } from '../hooks'; + +export interface ISpacesUIProviderProps { + spaceUI: SpacesUI; + theme: ISpacesTheme; + children: React.ReactNode; +} + +export const SpacesUIProvider = ({ + spaceUI, + theme, + children, +}: ISpacesUIProviderProps) => { + const spacesObjectRef = useRef({} as PushAPI.space.Space); + const [account, setAccount] = useState(spaceUI.account); + const [signer, setSigner] = useState(spaceUI.signer); + const [pgpPrivateKey, setPgpPrivateKey] = useState( + spaceUI.pgpPrivateKey + ); + const [env, setEnv] = useState(spaceUI.env); + const [spaceWidgetId, setSpaceWidgetId] = useState(''); + + const [trendingListData, setTrendingListData] = useState(null); + const [spaceInfo, setSpaceInfo] = useState({} as ISpaceInfo); + const [spaceObjectData, setSpaceObjectData] = useState( + PushAPI.space.initSpaceData + ); + + const [mySpaces, setMySpaces] = useState({ + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData); + + const [popularSpaces, setPopularSpaces] = useState({ + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData); + + const [spaceRequests, setSpaceRequests] = useState({ + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData); + + const setSpaceInfoItem = (key: string, value: SpaceDTO): void => { + setSpaceInfo((prevState) => ({ + ...prevState, + [key]: value, + })); + }; + + const initSpaceObject = async (spaceId: string) => { + spacesObjectRef.current = new PushAPI.space.Space({ + signer, + pgpPrivateKey, + address: account, + chainId: 5, // TODO: Make this dynamic + env, + setSpaceData: setSpaceObjectData, + }); + await spacesObjectRef.current.initialize({ spaceId }); + }; + + const getSpaceInfo = (spaceId: string): SpaceDTO | undefined => { + return spaceInfo[spaceId]; + }; + + const setMySpacePaginationInfo = ( + paginationInfo: ISpacePaginationData + ): void => { + const { apiData, currentPage, lastPage } = paginationInfo; + setMySpaces((prevState) => { + if (apiData) { + const existingIds = new Set( + prevState.apiData?.map((space: SpaceIFeeds) => space.spaceId) + ); + console.log('Existing ID', existingIds); + const uniqueSpaces = apiData?.filter( + (space) => !existingIds.has(space.spaceId) + ); + console.log('Unique Spaces', uniqueSpaces); + return { + ...prevState, + ...(uniqueSpaces && + prevState.apiData && { + apiData: [...prevState.apiData, ...uniqueSpaces], + }), + }; + } + return { + ...prevState, + ...(currentPage && { currentPage }), + ...(lastPage && { lastPage }), + }; + }); + }; + + const setPopularSpacePaginationInfo = ( + paginationInfo: ISpacePaginationData + ): void => { + const { apiData, currentPage, lastPage } = paginationInfo; + setPopularSpaces((prevState) => { + if (apiData) { + const existingIds = new Set( + prevState.apiData?.map((space: SpaceIFeeds) => space.spaceId) + ); + console.log('Existing ID', existingIds); + const uniqueSpaces = apiData?.filter( + (space) => !existingIds.has(space.spaceId) + ); + console.log('Unique Spaces', uniqueSpaces); + return { + ...prevState, + ...(uniqueSpaces && + prevState.apiData && { + apiData: [...prevState.apiData, ...uniqueSpaces], + }), + }; + } + return { + ...prevState, + ...(currentPage && { currentPage }), + ...(lastPage && { lastPage }), + }; + }); + }; + + const setSpacesRequestPaginationInfo = ( + paginationInfo: ISpacePaginationData + ): void => { + const { apiData, currentPage, lastPage } = paginationInfo; + setSpaceRequests((prevState) => { + if (apiData) { + const existingIds = new Set( + prevState.apiData?.map((space: SpaceIFeeds) => space.spaceId) + ); + console.log('Existing ID', existingIds); + const uniqueSpaces = apiData?.filter( + (space) => !existingIds.has(space.spaceId) + ); + console.log('Unique Spaces', uniqueSpaces); + return { + ...prevState, + ...(uniqueSpaces && + prevState.apiData && { + apiData: [...prevState.apiData, ...uniqueSpaces], + }), + }; + } + return { + ...prevState, + ...(currentPage && { currentPage }), + ...(lastPage && { lastPage }), + }; + }); + }; + + const value: ISpaceDataContextValues = { + account, + setAccount, + signer, + setSigner, + pgpPrivateKey, + setPgpPrivateKey, + env, + setEnv, + trendingListData, + setTrendingListData, + spaceInfo, + setSpaceInfo: setSpaceInfoItem, + getSpaceInfo, + spaceWidgetId, + setSpaceWidgetId, + mySpaces, + setMySpaces: setMySpacePaginationInfo, + popularSpaces, + setPopularSpaces: setPopularSpacePaginationInfo, + spaceRequests, + setSpaceRequests: setSpacesRequestPaginationInfo, + spaceObjectData, + setSpaceObjectData, + initSpaceObject, + spacesObjectRef, + }; + + useEffect(() => { + setAccount(spaceUI.account); + setSigner(spaceUI.signer); + setEnv(spaceUI.env); + setPgpPrivateKey(spaceUI.pgpPrivateKey); + }, [spaceUI]); + + const PROVIDER_THEME = Object.assign({}, lightTheme, theme); + + spaceUI.init(); + useSpaceNotificationSocket({ account, env }); + + return ( + + + {children} + + + ); +}; diff --git a/packages/uiweb/src/lib/dataProviders/index.ts b/packages/uiweb/src/lib/dataProviders/index.ts new file mode 100644 index 000000000..bf7f090a8 --- /dev/null +++ b/packages/uiweb/src/lib/dataProviders/index.ts @@ -0,0 +1 @@ +export * from "./SpaceDataProvider"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/helpers/apiHelper.ts b/packages/uiweb/src/lib/helpers/apiHelper.ts new file mode 100644 index 000000000..c33e9d6d5 --- /dev/null +++ b/packages/uiweb/src/lib/helpers/apiHelper.ts @@ -0,0 +1,9 @@ +export const pollAPI = async (fetchData: () => Promise, interval: number): Promise => { + try { + await fetchData(); + setTimeout(() => pollAPI(fetchData, interval), interval); + } catch (error) { + console.error('Error polling API:', error); + // Handle error if needed + } +}; diff --git a/packages/uiweb/src/lib/helpers/date.ts b/packages/uiweb/src/lib/helpers/date.ts new file mode 100644 index 000000000..c1a7357e5 --- /dev/null +++ b/packages/uiweb/src/lib/helpers/date.ts @@ -0,0 +1,6 @@ +import moment from 'moment'; + +export const formatDate = (date: number): string => { + const formattedDate = moment(date).format('Do MMM [at] h:mm A'); + return formattedDate; +} \ No newline at end of file diff --git a/packages/uiweb/src/lib/helpers/index.ts b/packages/uiweb/src/lib/helpers/index.ts index be1114040..c5872881b 100644 --- a/packages/uiweb/src/lib/helpers/index.ts +++ b/packages/uiweb/src/lib/helpers/index.ts @@ -1,2 +1,4 @@ export * from "./chat"; -export * from "./address"; \ No newline at end of file +export * from "./address"; +export * from "./apiHelper"; +export * from "./date"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/index.ts b/packages/uiweb/src/lib/hooks/index.ts index d83772c74..52d121727 100644 --- a/packages/uiweb/src/lib/hooks/index.ts +++ b/packages/uiweb/src/lib/hooks/index.ts @@ -1,2 +1,3 @@ export * from './useClickAway'; -export * from './useChatScroll'; \ No newline at end of file +export * from './useChatScroll'; +export * from "./space"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/space/index.ts b/packages/uiweb/src/lib/hooks/space/index.ts new file mode 100644 index 000000000..dc53136ff --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/index.ts @@ -0,0 +1,7 @@ +export * from './useSpaceData'; +export * from './useGetSpaceInfo'; +export * from './usePopularSpaces'; +export * from './useMySpaces'; +export * from './useSpaceRequests'; +export * from './useFeedScroll'; +export * from './useSpaceNotificationSocket'; diff --git a/packages/uiweb/src/lib/hooks/space/useFeedScroll.ts b/packages/uiweb/src/lib/hooks/space/useFeedScroll.ts new file mode 100644 index 000000000..b589f37c5 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/useFeedScroll.ts @@ -0,0 +1,13 @@ +import React from 'react'; + +export const useFeedScroll = ( + dep: T, +): React.MutableRefObject => { + const ref = React.useRef(null); + React.useEffect(() => { + if (ref.current) { + ref.current.scrollTop = 0; + } + }, []); + return ref; +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts b/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts new file mode 100644 index 000000000..1e50445c6 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts @@ -0,0 +1,37 @@ +import { useContext, useEffect, useState } from 'react'; +import * as PushAPI from '@pushprotocol/restapi'; +import { + ISpaceDataContextValues, + SpaceDataContext, +} from '../../context/spacesContext'; +import { SpaceDTO } from '@pushprotocol/restapi'; +import { ENV } from '../../config'; + +export const useGetSpaceInfo = (spaceId: string): SpaceDTO | undefined => { + const { getSpaceInfo, setSpaceInfo, env }: ISpaceDataContextValues = + useContext(SpaceDataContext); + const [spaceData, setSpaceDataState] = useState( + getSpaceInfo(spaceId) + ); + + useEffect(() => { + if (!spaceId) { + return; + } + const fetchData = async () => { + if (!spaceData) { + try { + const response = await PushAPI.space.get({ spaceId, env }); + setSpaceInfo(spaceId, response); + setSpaceDataState(response); + } catch (error) { + console.error(error); + } + } + }; + + fetchData(); + }, [spaceId, spaceData, getSpaceInfo, setSpaceInfo]); + + return spaceData; +}; diff --git a/packages/uiweb/src/lib/hooks/space/useMySpaces.ts b/packages/uiweb/src/lib/hooks/space/useMySpaces.ts new file mode 100644 index 000000000..d78de24ff --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/useMySpaces.ts @@ -0,0 +1,44 @@ +import { useSpaceData } from './useSpaceData'; +import { useEffect, useState } from 'react'; + +import * as PushAPI from '@pushprotocol/restapi'; + +export const useMySpaces = (account?: string) => { + const LIMIT = 10; + + const { mySpaces, setMySpaces, env } = useSpaceData(); + const [loading, setLoading] = useState(false); + + const fetchMySpaces = async () => { + if (!account) return; + setLoading(true); + try { + const res = await PushAPI.space.spaces({ + account: account, + page: mySpaces.currentPage, + limit: LIMIT, + env, + }); + + const newMySpaces = res; + + if (newMySpaces.length === 0) { + setMySpaces({ lastPage: -1 }); + setLoading(false); + return; + } + if (newMySpaces.length > 0) { + setMySpaces({ apiData: newMySpaces }); + } + } catch (error) { + console.error('Error while fetching Spaces For You:', error); + } + setLoading(false); + }; + + useEffect(() => { + fetchMySpaces(); + }, [mySpaces.currentPage]); + + return { loading }; +}; diff --git a/packages/uiweb/src/lib/hooks/space/usePopularSpaces.ts b/packages/uiweb/src/lib/hooks/space/usePopularSpaces.ts new file mode 100644 index 000000000..2f6fcb7b1 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/usePopularSpaces.ts @@ -0,0 +1,41 @@ +import { useSpaceData } from './useSpaceData'; +import { useEffect, useState } from 'react'; + +import * as PushAPI from '@pushprotocol/restapi'; + +export const usePopularSpaces = () => { + const LIMIT = 10; + const { popularSpaces, setPopularSpaces, env } = useSpaceData(); + const [loading, setLoading] = useState(false); + + const fetchPopularSpaces = async () => { + setLoading(true); + try { + const res = await PushAPI.space.trending({ + page: popularSpaces.currentPage, + limit: LIMIT, + env + }); + + const newPopularSpaces = res; + + if (newPopularSpaces.length === 0) { + setPopularSpaces({ lastPage: -1 }); + setLoading(false); + return; + } + if (newPopularSpaces.length > 0) { + setPopularSpaces({ apiData: newPopularSpaces }); + } + } catch (error) { + console.error('Error while fetching popular spaces:', error); + } + setLoading(false); + }; + + useEffect(() => { + fetchPopularSpaces(); + }, [popularSpaces.currentPage]); + + return { loading }; +}; diff --git a/packages/uiweb/src/lib/hooks/space/useSpaceData.ts b/packages/uiweb/src/lib/hooks/space/useSpaceData.ts new file mode 100644 index 000000000..e1e00a93e --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/useSpaceData.ts @@ -0,0 +1,11 @@ +import { useContext } from "react"; +import { ISpaceDataContextValues } from "../../context/spacesContext"; +import { SpaceDataContext } from "../../context"; + +export const useSpaceData = (): ISpaceDataContextValues => { + const context = useContext(SpaceDataContext); + if (!context) { + throw new Error('useSpaceData must be used within a SpaceDataProvider'); + } + return context; +} \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts b/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts new file mode 100644 index 000000000..95ebe1cb1 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts @@ -0,0 +1,141 @@ +import { useCallback, useEffect, useState } from 'react'; +import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; +import * as PushAPI from '@pushprotocol/restapi'; +import { useSpaceData } from './useSpaceData'; +import { ENV } from '../../config'; + +const NOTIFICATION_SOCKET_TYPE = 'notification'; + +export type SDKSocketHookOptions = { + account?: string | null; + env?: ENV; +}; + +export const useSpaceNotificationSocket = ({ + account, + env = ENV.PROD, +}: SDKSocketHookOptions) => { + const { spacesObjectRef } = useSpaceData(); + + const [notificationSocket, setNotificationSocket] = useState(null); + const [isNotificationSocketConnected, setIsNotificationSocketConnected] = + useState(false); + + const addSocketEvents = useCallback(() => { + notificationSocket?.on(EVENTS.CONNECT, () => { + setIsNotificationSocketConnected(true); + }); + + notificationSocket?.on(EVENTS.DISCONNECT, () => { + setIsNotificationSocketConnected(false); + }); + + notificationSocket?.on(EVENTS.USER_FEEDS, (feedItem: any) => { + const { payload } = feedItem; + + if ( + payload?.data?.additionalMeta?.type === + `${PushAPI.payloads.ADDITIONAL_META_TYPE.PUSH_VIDEO}+1` + ) { + const { + status, + callDetails, + senderAddress, + recipientAddress, + signalData, + chatId: spaceId, + }: PushAPI.video.VideoDataType = JSON.parse( + payload.data.additionalMeta.data + ); + + if (status === PushAPI.VideoCallStatus.INITIALIZED) { + if ( + callDetails?.type === + PushAPI.payloads.SPACE_REQUEST_TYPE.JOIN_SPEAKER + ) { + // @Nilesh + // host has started the space and is asking speakers to join in (real-time) + // we need to store the receivedSpaceData.signalData, chatId -> spaceId + // so that we can use then when the speaker wants to join the space from space invites + } + if ( + callDetails?.type === + PushAPI.payloads.SPACE_REQUEST_TYPE.ESTABLISH_MESH + ) { + spacesObjectRef.current?.acceptRequest({ + signalData, + senderAddress: recipientAddress, + recipientAddress: senderAddress, + chatId: spaceId, + }); + } + } + if (status === PushAPI.VideoCallStatus.RECEIVED) { + spacesObjectRef.current?.connect({ + signalData, + peerAddress: senderAddress, + }); + } + if (status === PushAPI.VideoCallStatus.DISCONNECTED) { + if(callDetails?.type === PushAPI.payloads.SPACE_DISCONNECT_TYPE.LEAVE){ + // later -> the 'senderAddress' has left the space + } + if(callDetails?.type === PushAPI.payloads.SPACE_DISCONNECT_TYPE.STOP){ + // later -> space has been ended by the host + } + } + } + }); + }, [notificationSocket]); + + const removeSocketEvents = useCallback(() => { + notificationSocket?.off(EVENTS.CONNECT); + notificationSocket?.off(EVENTS.DISCONNECT); + notificationSocket?.off(EVENTS.USER_FEEDS); + }, [notificationSocket]); + + useEffect(() => { + if (notificationSocket) { + addSocketEvents(); + } + + return () => { + if (notificationSocket) { + removeSocketEvents(); + } + }; + }, [addSocketEvents, notificationSocket, removeSocketEvents]); + + /** + * Whenever the requisite params to create a connection object change + * - disconnect the old connection + * - create a new connection object + */ + useEffect(() => { + if (account) { + if (notificationSocket) { + // console.log('=================>>> disconnection in the hook'); + notificationSocket?.disconnect(); + } + const main = async () => { + const connectionObject = createSocketConnection({ + user: account, + env, + socketType: NOTIFICATION_SOCKET_TYPE, + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + }); + console.warn('new connection object: ', connectionObject); + + setNotificationSocket(connectionObject); + }; + main().catch((err) => console.error(err)); + } + + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [account, env]); + + return { + notificationSocket, + isNotificationSocketConnected, + }; +}; diff --git a/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts b/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts new file mode 100644 index 000000000..b9c67c0a7 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts @@ -0,0 +1,45 @@ +import { useSpaceData } from './useSpaceData'; +import { useEffect, useState } from 'react'; + +import * as PushAPI from '@pushprotocol/restapi'; + +export const useSpaceRequests = (account?: string) => { + const LIMIT = 2; + + const { spaceRequests, setSpaceRequests, env } = useSpaceData(); + const [loading, setLoading] = useState(false); + + const fetchSpaceRequests = async () => { + if (!account) return; + setLoading(true); + try { + const res = await PushAPI.space.requests({ + account: account, + page: spaceRequests.currentPage, + limit: LIMIT, + env, + + }); + + const newSpaceRequests = res; + + if (newSpaceRequests.length === 0) { + setSpaceRequests({ lastPage: -1 }); + setLoading(false); + return; + } + if (newSpaceRequests.length > 0) { + setSpaceRequests({ apiData: newSpaceRequests }); + } + } catch (error) { + console.error('Error while fetching spaces requests:', error); + } + setLoading(false); + }; + + useEffect(() => { + fetchSpaceRequests(); + }, [spaceRequests.currentPage]); + + return { loading }; +}; diff --git a/packages/uiweb/src/lib/hooks/useChatScroll.ts b/packages/uiweb/src/lib/hooks/useChatScroll.ts index d7f7a90ad..f02209c2c 100644 --- a/packages/uiweb/src/lib/hooks/useChatScroll.ts +++ b/packages/uiweb/src/lib/hooks/useChatScroll.ts @@ -6,7 +6,7 @@ export const useChatScroll = ( const ref = React.useRef(null); React.useEffect(() => { if (ref.current) { - ref.current.scrollTop = ref.current.scrollHeight; + ref.current.scrollTop = 0; } }, [dep]); return ref; diff --git a/packages/uiweb/src/lib/icons/ArrowLeft.svg b/packages/uiweb/src/lib/icons/ArrowLeft.svg new file mode 100644 index 000000000..de2987515 --- /dev/null +++ b/packages/uiweb/src/lib/icons/ArrowLeft.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/ArrowLeft.tsx b/packages/uiweb/src/lib/icons/ArrowLeft.tsx new file mode 100644 index 000000000..54b4153aa --- /dev/null +++ b/packages/uiweb/src/lib/icons/ArrowLeft.tsx @@ -0,0 +1,9 @@ +export const ArrowLeft = () => { + return ( + + + + + ); + }; + \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/CalendarPurple.tsx b/packages/uiweb/src/lib/icons/CalendarPurple.tsx new file mode 100644 index 000000000..a3e4f8524 --- /dev/null +++ b/packages/uiweb/src/lib/icons/CalendarPurple.tsx @@ -0,0 +1,28 @@ +import React from 'react'; + +export const CalendarPurple = ({ height, width }: { height?: string, width?: string }) => { + return ( + < svg + width={width || "15"} + height={height || "14"} + viewBox = "0 0 15 14" + fill = "none" + xmlns = "http://www.w3.org/2000/svg" + > + + + + ); +}; diff --git a/packages/uiweb/src/lib/icons/CaretDown.svg b/packages/uiweb/src/lib/icons/CaretDown.svg new file mode 100644 index 000000000..6b3c3561b --- /dev/null +++ b/packages/uiweb/src/lib/icons/CaretDown.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/CaretDownGrey.svg b/packages/uiweb/src/lib/icons/CaretDownGrey.svg new file mode 100644 index 000000000..a450775da --- /dev/null +++ b/packages/uiweb/src/lib/icons/CaretDownGrey.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/CaretUp.svg b/packages/uiweb/src/lib/icons/CaretUp.svg new file mode 100644 index 000000000..852d9acae --- /dev/null +++ b/packages/uiweb/src/lib/icons/CaretUp.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/CaretUpGrey.svg b/packages/uiweb/src/lib/icons/CaretUpGrey.svg new file mode 100644 index 000000000..43b353b05 --- /dev/null +++ b/packages/uiweb/src/lib/icons/CaretUpGrey.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/CloseSvg.tsx b/packages/uiweb/src/lib/icons/CloseSvg.tsx index 2bf81b330..cf42abfe7 100644 --- a/packages/uiweb/src/lib/icons/CloseSvg.tsx +++ b/packages/uiweb/src/lib/icons/CloseSvg.tsx @@ -1,25 +1,25 @@ import React from 'react'; -export const CloseSvg = () => { +export const CloseSvg = ({ stroke, height, width }: { stroke?: string, height?: string, width?: string }) => { return ( + + + + + diff --git a/packages/uiweb/src/lib/icons/MicEngage.svg b/packages/uiweb/src/lib/icons/MicEngage.svg new file mode 100644 index 000000000..2118ce9d3 --- /dev/null +++ b/packages/uiweb/src/lib/icons/MicEngage.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/Minimize.tsx b/packages/uiweb/src/lib/icons/Minimize.tsx new file mode 100644 index 000000000..cf42abfe7 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Minimize.tsx @@ -0,0 +1,29 @@ +import React from 'react'; + +export const CloseSvg = ({ stroke, height, width }: { stroke?: string, height?: string, width?: string }) => { + return ( + + + + + ); +}; diff --git a/packages/uiweb/src/lib/icons/Muted.svg b/packages/uiweb/src/lib/icons/Muted.svg new file mode 100644 index 000000000..a68158636 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Muted.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/Share.svg b/packages/uiweb/src/lib/icons/Share.svg new file mode 100644 index 000000000..dd69beae1 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Share.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/Spaces.svg b/packages/uiweb/src/lib/icons/Spaces.svg new file mode 100644 index 000000000..529ef17e0 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Spaces.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/atVector.svg b/packages/uiweb/src/lib/icons/atVector.svg new file mode 100644 index 000000000..b4aa5c9bf --- /dev/null +++ b/packages/uiweb/src/lib/icons/atVector.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/calendar.svg b/packages/uiweb/src/lib/icons/calendar.svg new file mode 100644 index 000000000..769c7e11c --- /dev/null +++ b/packages/uiweb/src/lib/icons/calendar.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/packages/uiweb/src/lib/icons/calendarPurple.svg b/packages/uiweb/src/lib/icons/calendarPurple.svg new file mode 100644 index 000000000..fde94df20 --- /dev/null +++ b/packages/uiweb/src/lib/icons/calendarPurple.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/checkIcon.svg b/packages/uiweb/src/lib/icons/checkIcon.svg new file mode 100644 index 000000000..f8d7fc7cb --- /dev/null +++ b/packages/uiweb/src/lib/icons/checkIcon.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/copyVector.svg b/packages/uiweb/src/lib/icons/copyVector.svg new file mode 100644 index 000000000..6f780bb22 --- /dev/null +++ b/packages/uiweb/src/lib/icons/copyVector.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/filter.svg b/packages/uiweb/src/lib/icons/filter.svg new file mode 100644 index 000000000..2ac3e870f --- /dev/null +++ b/packages/uiweb/src/lib/icons/filter.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/hand.svg b/packages/uiweb/src/lib/icons/hand.svg new file mode 100644 index 000000000..422d49f54 --- /dev/null +++ b/packages/uiweb/src/lib/icons/hand.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/live.svg b/packages/uiweb/src/lib/icons/live.svg new file mode 100644 index 000000000..5cf6ae8c8 --- /dev/null +++ b/packages/uiweb/src/lib/icons/live.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/micoff.svg b/packages/uiweb/src/lib/icons/micoff.svg new file mode 100644 index 000000000..ad6e4f143 --- /dev/null +++ b/packages/uiweb/src/lib/icons/micoff.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/micon.svg b/packages/uiweb/src/lib/icons/micon.svg new file mode 100644 index 000000000..80cd7a2a1 --- /dev/null +++ b/packages/uiweb/src/lib/icons/micon.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/scheduled.svg b/packages/uiweb/src/lib/icons/scheduled.svg new file mode 100644 index 000000000..63b3495d0 --- /dev/null +++ b/packages/uiweb/src/lib/icons/scheduled.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/packages/uiweb/src/lib/icons/settings.svg b/packages/uiweb/src/lib/icons/settings.svg new file mode 100644 index 000000000..9510b8a01 --- /dev/null +++ b/packages/uiweb/src/lib/icons/settings.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/settingsBlack.svg b/packages/uiweb/src/lib/icons/settingsBlack.svg new file mode 100644 index 000000000..0ffa8bc28 --- /dev/null +++ b/packages/uiweb/src/lib/icons/settingsBlack.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/twitterVector.svg b/packages/uiweb/src/lib/icons/twitterVector.svg new file mode 100644 index 000000000..4be66ead6 --- /dev/null +++ b/packages/uiweb/src/lib/icons/twitterVector.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/index.ts b/packages/uiweb/src/lib/index.ts index 816c837a9..85d2f4cb9 100644 --- a/packages/uiweb/src/lib/index.ts +++ b/packages/uiweb/src/lib/index.ts @@ -1,3 +1,4 @@ export * from './components' export * from './config'; +export * from './dataProviders'; export * from './types'; \ No newline at end of file diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index ee4c9abcb..cc99d5ead 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -2,11 +2,459 @@ # yarn lockfile v1 +"@babel/runtime@^7.13.10": + version "7.22.6" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.6.tgz#57d64b9ae3cff1d67eb067ae117dac087f5bd438" + integrity sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ== + dependencies: + regenerator-runtime "^0.13.11" + +"@floating-ui/core@^1.3.1": + version "1.3.1" + resolved "https://registry.yarnpkg.com/@floating-ui/core/-/core-1.3.1.tgz#4d795b649cc3b1cbb760d191c80dcb4353c9a366" + integrity sha512-Bu+AMaXNjrpjh41znzHqaz3r2Nr8hHuHZT6V2LBKMhyMl0FgKA62PNYbqnfgmzOhoWZj70Zecisbo4H1rotP5g== + +"@floating-ui/dom@^1.3.0": + version "1.4.4" + resolved "https://registry.yarnpkg.com/@floating-ui/dom/-/dom-1.4.4.tgz#cf859dde33995a4e7b6ded16c98cb73b2ebfffd0" + integrity sha512-21hhDEPOiWkGp0Ys4Wi6Neriah7HweToKra626CIK712B5m9qkdz54OP9gVldUg+URnBTpv/j/bi/skmGdstXQ== + dependencies: + "@floating-ui/core" "^1.3.1" + +"@floating-ui/react-dom@^2.0.0": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@floating-ui/react-dom/-/react-dom-2.0.1.tgz#7972a4fc488a8c746cded3cfe603b6057c308a91" + integrity sha512-rZtAmSht4Lry6gdhAJDrCp/6rKN7++JnL1/Anbr/DdeyYXQPxvg/ivrbYvJulbRf4vL8b212suwMM2lxbv+RQA== + dependencies: + "@floating-ui/dom" "^1.3.0" + +"@livepeer/core-react@^1.6.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@livepeer/core-react/-/core-react-1.6.0.tgz#2a29789bd8acb551d81496cdc85376f165652971" + integrity sha512-6lsrWJ/iJSF9bL3y8O+gkvRJ17tT6g9z3l1/E7pf30tIlELjwFb4KklK/k3SFtuYYskkx8v5DvU2LaOd2yhQYA== + dependencies: + "@livepeer/core" "^1.6.0" + "@tanstack/query-async-storage-persister" "4.22.4" + "@tanstack/query-core" "4.22.4" + "@tanstack/react-query" "4.22.4" + "@tanstack/react-query-persist-client" "4.22.4" + use-sync-external-store "^1.2.0" + zustand "^4.3.2" + +"@livepeer/core@^1.6.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@livepeer/core/-/core-1.6.0.tgz#1be05fc92b21f0cdebf28dd7243de6d8d0b8753c" + integrity sha512-MhyrtsXFrndnWn16GViavVG9UNjGroavw1FttgfstQ1IPWxrP2HEEvX52zATXF0JX/xfH5MCsfLNcVC9MF399g== + dependencies: + cross-fetch "^3.1.5" + ms "^3.0.0-canary.1" + multiformats "9.9.0" + tus-js-client "^3.0.1" + zustand "^4.3.2" + +"@livepeer/react@^2.6.0": + version "2.6.0" + resolved "https://registry.yarnpkg.com/@livepeer/react/-/react-2.6.0.tgz#6ddff6d1c9e8f4dccff76c95ece238bc77642e5b" + integrity sha512-CH5hpONn4eiL6Qqf3neVzduvMbEkYa9DP1wliEGTpq/rAb8kfdrKGVOeEKkx7GoIIdHNPf0GIwFIggiqu/l8yw== + dependencies: + "@livepeer/core-react" "^1.6.0" + "@radix-ui/react-dialog" "^1.0.4" + "@radix-ui/react-popover" "^1.0.6" + "@radix-ui/react-select" "^1.2.2" + "@stitches/react" "^1.2.8" + core-js "^3.27.2" + livepeer "2.6.0" + zustand "^4.3.2" + +"@pushprotocol/socket@^0.5.0": + version "0.5.1" + resolved "https://registry.yarnpkg.com/@pushprotocol/socket/-/socket-0.5.1.tgz#3ba128e6f58d62fabca0287efe049d6a52defcaa" + integrity sha512-nkF3tpSZc8a6IC2ypXfja8S8oF78aJG3oCEXUSmee3otN5bYZb+pBV2Ggiay/6NBx/wL1L7dngspe/7BhoLNcg== + dependencies: + socket.io-client "^4.5.2" + tslib "^2.3.0" + +"@radix-ui/number@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/number/-/number-1.0.1.tgz#644161a3557f46ed38a042acf4a770e826021674" + integrity sha512-T5gIdVO2mmPW3NNhjNgEP3cqMXjXL9UbO0BzWcXfvdBs+BohbQxvd/K5hSVKmn9/lbTdsQVKbUcP5WLCwvUbBg== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/primitive@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/primitive/-/primitive-1.0.1.tgz#e46f9958b35d10e9f6dc71c497305c22e3e55dbd" + integrity sha512-yQ8oGX2GVsEYMWGxcovu1uGWPCxV5BFfeeYxqPmuAzUyLT9qmaMXSAhXpb0WrspIeqYzdJpkh2vHModJPgRIaw== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-arrow@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-arrow/-/react-arrow-1.0.3.tgz#c24f7968996ed934d57fe6cde5d6ec7266e1d25d" + integrity sha512-wSP+pHsB/jQRaL6voubsQ/ZlrGBHHrOjmBnr19hxYgtS0WvAFwZhK2WP/YY5yF9uKECCEEDGxuLxq1NBK51wFA== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-primitive" "1.0.3" + +"@radix-ui/react-collection@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-collection/-/react-collection-1.0.3.tgz#9595a66e09026187524a36c6e7e9c7d286469159" + integrity sha512-3SzW+0PW7yBBoQlT8wNcGtaxaD0XSu0uLUFgrtHY08Acx05TaHaOmVLR73c0j/cqpDy53KBMO7s0dx2wmOIDIA== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-context" "1.0.1" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-slot" "1.0.2" + +"@radix-ui/react-compose-refs@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.1.tgz#7ed868b66946aa6030e580b1ffca386dd4d21989" + integrity sha512-fDSBgd44FKHa1FRMU59qBMPFcl2PZE+2nmqunj+BWFyYYjnhIDWL2ItDs3rrbJDQOtzt5nIebLCQc4QRfz6LJw== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-context@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-context/-/react-context-1.0.1.tgz#fe46e67c96b240de59187dcb7a1a50ce3e2ec00c" + integrity sha512-ebbrdFoYTcuZ0v4wG5tedGnp9tzcV8awzsxYph7gXUyvnNLuTIcCk1q17JEbnVhXAKG9oX3KtchwiMIAYp9NLg== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-dialog@^1.0.4": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@radix-ui/react-dialog/-/react-dialog-1.0.4.tgz#06bce6c16bb93eb36d7a8589e665a20f4c1c52c1" + integrity sha512-hJtRy/jPULGQZceSAP2Re6/4NpKo8im6V8P2hUqZsdFiSL8l35kYsw3qbRI6Ay5mQd2+wlLqje770eq+RJ3yZg== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/primitive" "1.0.1" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-context" "1.0.1" + "@radix-ui/react-dismissable-layer" "1.0.4" + "@radix-ui/react-focus-guards" "1.0.1" + "@radix-ui/react-focus-scope" "1.0.3" + "@radix-ui/react-id" "1.0.1" + "@radix-ui/react-portal" "1.0.3" + "@radix-ui/react-presence" "1.0.1" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-slot" "1.0.2" + "@radix-ui/react-use-controllable-state" "1.0.1" + aria-hidden "^1.1.1" + react-remove-scroll "2.5.5" + +"@radix-ui/react-direction@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-direction/-/react-direction-1.0.1.tgz#9cb61bf2ccf568f3421422d182637b7f47596c9b" + integrity sha512-RXcvnXgyvYvBEOhCBuddKecVkoMiI10Jcm5cTI7abJRAHYfFxeu+FBQs/DvdxSYucxR5mna0dNsL6QFlds5TMA== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-dismissable-layer@1.0.4": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.0.4.tgz#883a48f5f938fa679427aa17fcba70c5494c6978" + integrity sha512-7UpBa/RKMoHJYjie1gkF1DlK8l1fdU/VKDpoS3rCCo8YBJR294GwcEHyxHw72yvphJ7ld0AXEcSLAzY2F/WyCg== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/primitive" "1.0.1" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-use-callback-ref" "1.0.1" + "@radix-ui/react-use-escape-keydown" "1.0.3" + +"@radix-ui/react-focus-guards@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-focus-guards/-/react-focus-guards-1.0.1.tgz#1ea7e32092216b946397866199d892f71f7f98ad" + integrity sha512-Rect2dWbQ8waGzhMavsIbmSVCgYxkXLxxR3ZvCX79JOglzdEy4JXMb98lq4hPxUbLr77nP0UOGf4rcMU+s1pUA== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-focus-scope@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-focus-scope/-/react-focus-scope-1.0.3.tgz#9c2e8d4ed1189a1d419ee61edd5c1828726472f9" + integrity sha512-upXdPfqI4islj2CslyfUBNlaJCPybbqRHAi1KER7Isel9Q2AtSJ0zRBZv8mWQiFXD2nyAJ4BhC3yXgZ6kMBSrQ== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-use-callback-ref" "1.0.1" + +"@radix-ui/react-id@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-id/-/react-id-1.0.1.tgz#73cdc181f650e4df24f0b6a5b7aa426b912c88c0" + integrity sha512-tI7sT/kqYp8p96yGWY1OAnLHrqDgzHefRBKQ2YAkBS5ja7QLcZ9Z/uY7bEjPUatf8RomoXM8/1sMj1IJaE5UzQ== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-use-layout-effect" "1.0.1" + +"@radix-ui/react-popover@^1.0.6": + version "1.0.6" + resolved "https://registry.yarnpkg.com/@radix-ui/react-popover/-/react-popover-1.0.6.tgz#19bb81e7450482c625b8cd05bf4dcd1d2cd91a8b" + integrity sha512-cZ4defGpkZ0qTRtlIBzJLSzL6ht7ofhhW4i1+pkemjV1IKXm0wgCRnee154qlV6r9Ttunmh2TNZhMfV2bavUyA== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/primitive" "1.0.1" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-context" "1.0.1" + "@radix-ui/react-dismissable-layer" "1.0.4" + "@radix-ui/react-focus-guards" "1.0.1" + "@radix-ui/react-focus-scope" "1.0.3" + "@radix-ui/react-id" "1.0.1" + "@radix-ui/react-popper" "1.1.2" + "@radix-ui/react-portal" "1.0.3" + "@radix-ui/react-presence" "1.0.1" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-slot" "1.0.2" + "@radix-ui/react-use-controllable-state" "1.0.1" + aria-hidden "^1.1.1" + react-remove-scroll "2.5.5" + +"@radix-ui/react-popper@1.1.2": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@radix-ui/react-popper/-/react-popper-1.1.2.tgz#4c0b96fcd188dc1f334e02dba2d538973ad842e9" + integrity sha512-1CnGGfFi/bbqtJZZ0P/NQY20xdG3E0LALJaLUEoKwPLwl6PPPfbeiCqMVQnhoFRAxjJj4RpBRJzDmUgsex2tSg== + dependencies: + "@babel/runtime" "^7.13.10" + "@floating-ui/react-dom" "^2.0.0" + "@radix-ui/react-arrow" "1.0.3" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-context" "1.0.1" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-use-callback-ref" "1.0.1" + "@radix-ui/react-use-layout-effect" "1.0.1" + "@radix-ui/react-use-rect" "1.0.1" + "@radix-ui/react-use-size" "1.0.1" + "@radix-ui/rect" "1.0.1" + +"@radix-ui/react-portal@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-portal/-/react-portal-1.0.3.tgz#ffb961244c8ed1b46f039e6c215a6c4d9989bda1" + integrity sha512-xLYZeHrWoPmA5mEKEfZZevoVRK/Q43GfzRXkWV6qawIWWK8t6ifIiLQdd7rmQ4Vk1bmI21XhqF9BN3jWf+phpA== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-primitive" "1.0.3" + +"@radix-ui/react-presence@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-presence/-/react-presence-1.0.1.tgz#491990ba913b8e2a5db1b06b203cb24b5cdef9ba" + integrity sha512-UXLW4UAbIY5ZjcvzjfRFo5gxva8QirC9hF7wRE4U5gz+TP0DbRk+//qyuAQ1McDxBt1xNMBTaciFGvEmJvAZCg== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-use-layout-effect" "1.0.1" + +"@radix-ui/react-primitive@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-primitive/-/react-primitive-1.0.3.tgz#d49ea0f3f0b2fe3ab1cb5667eb03e8b843b914d0" + integrity sha512-yi58uVyoAcK/Nq1inRY56ZSjKypBNKTa/1mcL8qdl6oJeEaDbOldlzrGn7P6Q3Id5d+SYNGc5AJgc4vGhjs5+g== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-slot" "1.0.2" + +"@radix-ui/react-select@^1.2.2": + version "1.2.2" + resolved "https://registry.yarnpkg.com/@radix-ui/react-select/-/react-select-1.2.2.tgz#caa981fa0d672cf3c1b2a5240135524e69b32181" + integrity sha512-zI7McXr8fNaSrUY9mZe4x/HC0jTLY9fWNhO1oLWYMQGDXuV4UCivIGTxwioSzO0ZCYX9iSLyWmAh/1TOmX3Cnw== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/number" "1.0.1" + "@radix-ui/primitive" "1.0.1" + "@radix-ui/react-collection" "1.0.3" + "@radix-ui/react-compose-refs" "1.0.1" + "@radix-ui/react-context" "1.0.1" + "@radix-ui/react-direction" "1.0.1" + "@radix-ui/react-dismissable-layer" "1.0.4" + "@radix-ui/react-focus-guards" "1.0.1" + "@radix-ui/react-focus-scope" "1.0.3" + "@radix-ui/react-id" "1.0.1" + "@radix-ui/react-popper" "1.1.2" + "@radix-ui/react-portal" "1.0.3" + "@radix-ui/react-primitive" "1.0.3" + "@radix-ui/react-slot" "1.0.2" + "@radix-ui/react-use-callback-ref" "1.0.1" + "@radix-ui/react-use-controllable-state" "1.0.1" + "@radix-ui/react-use-layout-effect" "1.0.1" + "@radix-ui/react-use-previous" "1.0.1" + "@radix-ui/react-visually-hidden" "1.0.3" + aria-hidden "^1.1.1" + react-remove-scroll "2.5.5" + +"@radix-ui/react-slot@1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@radix-ui/react-slot/-/react-slot-1.0.2.tgz#a9ff4423eade67f501ffb32ec22064bc9d3099ab" + integrity sha512-YeTpuq4deV+6DusvVUW4ivBgnkHwECUu0BiN43L5UCDFgdhsRUWAghhTF5MbvNTPzmiFOx90asDSUjWuCNapwg== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-compose-refs" "1.0.1" + +"@radix-ui/react-use-callback-ref@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.1.tgz#f4bb1f27f2023c984e6534317ebc411fc181107a" + integrity sha512-D94LjX4Sp0xJFVaoQOd3OO9k7tpBYNOXdVhkltUbGv2Qb9OXdrg/CpsjlZv7ia14Sylv398LswWBVVu5nqKzAQ== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-use-controllable-state@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.0.1.tgz#ecd2ced34e6330caf89a82854aa2f77e07440286" + integrity sha512-Svl5GY5FQeN758fWKrjM6Qb7asvXeiZltlT4U2gVfl8Gx5UAv2sMR0LWo8yhsIZh2oQ0eFdZ59aoOOMV7b47VA== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-use-callback-ref" "1.0.1" + +"@radix-ui/react-use-escape-keydown@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.0.3.tgz#217b840c250541609c66f67ed7bab2b733620755" + integrity sha512-vyL82j40hcFicA+M4Ex7hVkB9vHgSse1ZWomAqV2Je3RleKGO5iM8KMOEtfoSB0PnIelMd2lATjTGMYqN5ylTg== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-use-callback-ref" "1.0.1" + +"@radix-ui/react-use-layout-effect@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.0.1.tgz#be8c7bc809b0c8934acf6657b577daf948a75399" + integrity sha512-v/5RegiJWYdoCvMnITBkNNx6bCj20fiaJnWtRkU18yITptraXjffz5Qbn05uOiQnOvi+dbkznkoaMltz1GnszQ== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-use-previous@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-previous/-/react-use-previous-1.0.1.tgz#b595c087b07317a4f143696c6a01de43b0d0ec66" + integrity sha512-cV5La9DPwiQ7S0gf/0qiD6YgNqM5Fk97Kdrlc5yBcrF3jyEZQwm7vYFqMo4IfeHgJXsRaMvLABFtd0OVEmZhDw== + dependencies: + "@babel/runtime" "^7.13.10" + +"@radix-ui/react-use-rect@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-rect/-/react-use-rect-1.0.1.tgz#fde50b3bb9fd08f4a1cd204572e5943c244fcec2" + integrity sha512-Cq5DLuSiuYVKNU8orzJMbl15TXilTnJKUCltMVQg53BQOF1/C5toAaGrowkgksdBQ9H+SRL23g0HDmg9tvmxXw== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/rect" "1.0.1" + +"@radix-ui/react-use-size@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/react-use-size/-/react-use-size-1.0.1.tgz#1c5f5fea940a7d7ade77694bb98116fb49f870b2" + integrity sha512-ibay+VqrgcaI6veAojjofPATwledXiSmX+C0KrBk/xgpX9rBzPV3OsfwlhQdUOFbh+LKQorLYT+xTXW9V8yd0g== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-use-layout-effect" "1.0.1" + +"@radix-ui/react-visually-hidden@1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.0.3.tgz#51aed9dd0fe5abcad7dee2a234ad36106a6984ac" + integrity sha512-D4w41yN5YRKtu464TLnByKzMDG/JlMPHtfZgQAu9v6mNakUqGUI9vUrfQKz8NK41VMm/xbZbh76NUTVtIYqOMA== + dependencies: + "@babel/runtime" "^7.13.10" + "@radix-ui/react-primitive" "1.0.3" + +"@radix-ui/rect@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@radix-ui/rect/-/rect-1.0.1.tgz#bf8e7d947671996da2e30f4904ece343bc4a883f" + integrity sha512-fyrgCaedtvMg9NK3en0pnOYJdtfwxUcNolezkNPUsoX57X8oQk+NkqcvzHXD2uKNij6GXmWU9NDru2IWjrO4BQ== + dependencies: + "@babel/runtime" "^7.13.10" + +"@socket.io/component-emitter@~3.1.0": + version "3.1.0" + resolved "https://registry.yarnpkg.com/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz#96116f2a912e0c02817345b3c10751069920d553" + integrity sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg== + +"@stitches/core@^1.2.8": + version "1.2.8" + resolved "https://registry.yarnpkg.com/@stitches/core/-/core-1.2.8.tgz#dce3b8fdc764fbc6dbea30c83b73bfb52cf96173" + integrity sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg== + +"@stitches/react@^1.2.8": + version "1.2.8" + resolved "https://registry.yarnpkg.com/@stitches/react/-/react-1.2.8.tgz#954f8008be8d9c65c4e58efa0937f32388ce3a38" + integrity sha512-9g9dWI4gsSVe8bNLlb+lMkBYsnIKCZTmvqvDG+Avnn69XfmHZKiaMrx7cgTaddq7aTPPmXiTsbFcUy0xgI4+wA== + +"@tanstack/query-async-storage-persister@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@tanstack/query-async-storage-persister/-/query-async-storage-persister-4.22.4.tgz#60f846dbb2b0bad6911b29ff77ba6272e610283c" + integrity sha512-8DWEt+bmxyjp12aqGnYhpgroOZgvgzvs+mMqBIyZVET4eWQNKAuQSFXTlkztmq9/sxbvTnp+xu7KRZExyurZPA== + dependencies: + "@tanstack/query-persist-client-core" "4.22.4" + +"@tanstack/query-core@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-4.22.4.tgz#aca622d2f8800a147ece5520d956a076ab92f0ea" + integrity sha512-t79CMwlbBnj+yL82tEcmRN93bL4U3pae2ota4t5NN2z3cIeWw74pzdWrKRwOfTvLcd+b30tC+ciDlfYOKFPGUw== + +"@tanstack/query-persist-client-core@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@tanstack/query-persist-client-core/-/query-persist-client-core-4.22.4.tgz#a8ed136a8234b9cbd12ae3df857425330c6200db" + integrity sha512-F5rCLczSw8RjFlwWASD3oRR7D4oyG90QbBFaOqBCjGbvE3bcD+m/E4GGCp1qfACoLuH4KtxhdwdOFfE+e0TRZQ== + +"@tanstack/react-query-persist-client@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@tanstack/react-query-persist-client/-/react-query-persist-client-4.22.4.tgz#8e4fad6f70ca922ef9e7be58c5bd14b010cff780" + integrity sha512-vnRD28T0BLsbDRlantC6W34eLCbjSoZEkYL4t2QYRyuEcmUya2Ddbn+DN+RfZHqxoMiSJNfMdmRXsMPpNHZ1QA== + dependencies: + "@tanstack/query-persist-client-core" "4.22.4" + +"@tanstack/react-query@4.22.4": + version "4.22.4" + resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-4.22.4.tgz#851581c645f1c9cfcd394448fedd980a39bbc3fe" + integrity sha512-e5j5Z88XUQGeEPMyz5XF1V0mMf6Da+6URXiTpZfUb9nuHs2nlNoA+EoIvnhccE5b9YT6Yg7kARhn2L7u94M/4A== + dependencies: + "@tanstack/query-core" "4.22.4" + use-sync-external-store "^1.2.0" + +aria-hidden@^1.1.1: + version "1.2.3" + resolved "https://registry.yarnpkg.com/aria-hidden/-/aria-hidden-1.2.3.tgz#14aeb7fb692bbb72d69bebfa47279c1fd725e954" + integrity sha512-xcLxITLe2HYa1cnYnwCjkOO1PqUHQpozB8x9AR0OgWN2woOBi5kSDVxKfd0b7sb1hw5qFeJhXm9H1nu3xSfLeQ== + dependencies: + tslib "^2.0.0" + +buffer-from@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== + +combine-errors@^3.0.3: + version "3.0.3" + resolved "https://registry.yarnpkg.com/combine-errors/-/combine-errors-3.0.3.tgz#f4df6740083e5703a3181110c2b10551f003da86" + integrity sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q== + dependencies: + custom-error-instance "2.1.1" + lodash.uniqby "4.5.0" + +core-js@^3.27.2: + version "3.31.1" + resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.31.1.tgz#f2b0eea9be9da0def2c5fece71064a7e5d687653" + integrity sha512-2sKLtfq1eFST7l7v62zaqXacPc7uG8ZAya8ogijLhTtaKNcpzpB4TMoTw2Si+8GYKRwFPMMtUT0263QFWFfqyQ== + +cross-fetch@^3.1.5: + version "3.1.8" + resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-3.1.8.tgz#0327eba65fd68a7d119f8fb2bf9334a1a7956f82" + integrity sha512-cvA+JwZoU0Xq+h6WkMvAUqPEYy92Obet6UdKLfW60qn99ftItKjB5T+BkyWOFWe2pUyfQ+IJHmpOTznqk1M6Kg== + dependencies: + node-fetch "^2.6.12" + +custom-error-instance@2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/custom-error-instance/-/custom-error-instance-2.1.1.tgz#3cf6391487a6629a6247eb0ca0ce00081b7e361a" + integrity sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg== + date-fns@^2.28.0: version "2.29.3" resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.29.3.tgz#27402d2fc67eb442b511b70bbdf98e6411cd68a8" integrity sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA== +debug@~4.3.1, debug@~4.3.2: + version "4.3.4" + resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" + integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== + dependencies: + ms "2.1.2" + +detect-node-es@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/detect-node-es/-/detect-node-es-1.1.0.tgz#163acdf643330caa0b4cd7c21e7ee7755d6fa493" + integrity sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ== + dom-serializer@^1.0.1: version "1.4.1" resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-1.4.1.tgz#de5d41b1aea290215dc45a6dae8adcf1d32e2d30" @@ -42,6 +490,22 @@ emoji-picker-react@^3.5.1: resolved "https://registry.yarnpkg.com/emoji-picker-react/-/emoji-picker-react-3.6.5.tgz#423fef704b64138b872f8087738c634a3589c6ac" integrity sha512-pfu3XkHSeqXjygyoKtRsmJdsNkRxhkE7hlnWrYBoPnm8V03aJ8Y9H5oRUQ+fF4WRZpjfJFsw5V7ewRVhuj/8cA== +engine.io-client@~6.5.0: + version "6.5.0" + resolved "https://registry.yarnpkg.com/engine.io-client/-/engine.io-client-6.5.0.tgz#c77f14c0e996d3746a1fa681b3b093003dc1743d" + integrity sha512-C7eN3OKggSfd5g8IDgUA9guC8TNS6CEganKT7dL6Fp3q+FobcQ/WBn2Qq2XTL1vNTiFZfDzXohvqLuR9dWejdg== + dependencies: + "@socket.io/component-emitter" "~3.1.0" + debug "~4.3.1" + engine.io-parser "~5.1.0" + ws "~8.11.0" + xmlhttprequest-ssl "~2.0.0" + +engine.io-parser@~5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/engine.io-parser/-/engine.io-parser-5.1.0.tgz#d593d6372d7f79212df48f807b8cace1ea1cb1b8" + integrity sha512-enySgNiK5tyZFynt3z7iqBR+Bto9EVVVvDFuTT0ioHCGbzirZVGDGiQjZzEp8hWl6hd5FSVytJGuScX1C1C35w== + entities@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/entities/-/entities-2.2.0.tgz#098dc90ebb83d8dffa089d55256b351d34c4da55" @@ -52,6 +516,21 @@ entities@^3.0.1: resolved "https://registry.yarnpkg.com/entities/-/entities-3.0.1.tgz#2b887ca62585e96db3903482d336c1006c3001d4" integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== +get-nonce@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/get-nonce/-/get-nonce-1.0.1.tgz#fdf3f0278073820d2ce9426c18f07481b1e0cdf3" + integrity sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q== + +graceful-fs@^4.2.4: + version "4.2.11" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" + integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== + +hls.js@^1.4.0: + version "1.4.8" + resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.4.8.tgz#6fedcb5224d7361e4f38046ffd45286d8a645df8" + integrity sha512-wYL7W49M6oKv0+P4RW50YkJaxDzgnHMMrN+YoLpow07hVgaedAdX9HfKkehTb04UEfeJhNSef5ucICYPsHOfqg== + html-dom-parser@1.2.0: version "1.2.0" resolved "https://registry.yarnpkg.com/html-dom-parser/-/html-dom-parser-1.2.0.tgz#8f689b835982ffbf245eda99730e92b8462c111e" @@ -85,11 +564,207 @@ inline-style-parser@0.1.1: resolved "https://registry.yarnpkg.com/inline-style-parser/-/inline-style-parser-0.1.1.tgz#ec8a3b429274e9c0a1f1c4ffa9453a7fef72cea1" integrity sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q== +invariant@^2.2.4: + version "2.2.4" + resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" + integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA== + dependencies: + loose-envify "^1.0.0" + +is-stream@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" + integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== + +js-base64@^3.7.2: + version "3.7.5" + resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.5.tgz#21e24cf6b886f76d6f5f165bfcd69cc55b9e3fca" + integrity sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA== + +"js-tokens@^3.0.0 || ^4.0.0": + version "4.0.0" + resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== + +livepeer@2.6.0: + version "2.6.0" + resolved "https://registry.yarnpkg.com/livepeer/-/livepeer-2.6.0.tgz#b2c1011436ec801390e8b77d1322087c83171c6b" + integrity sha512-tURkBvJQi0nyS5WlFHhKyRGx0qKqGt/DbKSzhUwJ9fAzT3GAlipujgKVOc3wnNWIj76LQrCp7onUmsrrkFRGkQ== + dependencies: + "@livepeer/core" "^1.6.0" + "@stitches/core" "^1.2.8" + core-js "^3.27.2" + cross-fetch "^3.1.5" + hls.js "^1.4.0" + ms "^3.0.0-canary.1" + multiformats "9.9.0" + tus-js-client "^3.0.1" + zustand "^4.3.2" + +lodash._baseiteratee@~4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz#34a9b5543572727c3db2e78edae3c0e9e66bd102" + integrity sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ== + dependencies: + lodash._stringtopath "~4.8.0" + +lodash._basetostring@~4.12.0: + version "4.12.0" + resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz#9327c9dc5158866b7fa4b9d42f4638e5766dd9df" + integrity sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw== + +lodash._baseuniq@~4.6.0: + version "4.6.0" + resolved "https://registry.yarnpkg.com/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz#0ebb44e456814af7905c6212fa2c9b2d51b841e8" + integrity sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A== + dependencies: + lodash._createset "~4.0.0" + lodash._root "~3.0.0" + +lodash._createset@~4.0.0: + version "4.0.3" + resolved "https://registry.yarnpkg.com/lodash._createset/-/lodash._createset-4.0.3.tgz#0f4659fbb09d75194fa9e2b88a6644d363c9fe26" + integrity sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA== + +lodash._root@~3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" + integrity sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ== + +lodash._stringtopath@~4.8.0: + version "4.8.0" + resolved "https://registry.yarnpkg.com/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz#941bcf0e64266e5fc1d66fed0a6959544c576824" + integrity sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ== + dependencies: + lodash._basetostring "~4.12.0" + +lodash.throttle@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4" + integrity sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ== + +lodash.uniqby@4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz#a3a17bbf62eeb6240f491846e97c1c4e2a5e1e21" + integrity sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ== + dependencies: + lodash._baseiteratee "~4.7.0" + lodash._baseuniq "~4.6.0" + +loose-envify@^1.0.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf" + integrity sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q== + dependencies: + js-tokens "^3.0.0 || ^4.0.0" + +ms@2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== + +ms@^3.0.0-canary.1: + version "3.0.0-canary.1" + resolved "https://registry.yarnpkg.com/ms/-/ms-3.0.0-canary.1.tgz#c7b34fbce381492fd0b345d1cf56e14d67b77b80" + integrity sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g== + +multiformats@9.9.0: + version "9.9.0" + resolved "https://registry.yarnpkg.com/multiformats/-/multiformats-9.9.0.tgz#c68354e7d21037a8f1f8833c8ccd68618e8f1d37" + integrity sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg== + +node-fetch@^2.6.12: + version "2.6.12" + resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.12.tgz#02eb8e22074018e3d5a83016649d04df0e348fba" + integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== + dependencies: + whatwg-url "^5.0.0" + +proper-lockfile@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/proper-lockfile/-/proper-lockfile-4.1.2.tgz#c8b9de2af6b2f1601067f98e01ac66baa223141f" + integrity sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA== + dependencies: + graceful-fs "^4.2.4" + retry "^0.12.0" + signal-exit "^3.0.2" + +querystringify@^2.1.1: + version "2.2.0" + resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== + react-property@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/react-property/-/react-property-2.0.0.tgz#2156ba9d85fa4741faf1918b38efc1eae3c6a136" integrity sha512-kzmNjIgU32mO4mmH5+iUyrqlpFQhF8K2k7eZ4fdLSOPFrD1XgEuSBv9LDEgxRXTMBqMd8ppT0x6TIzqE5pdGdw== +react-remove-scroll-bar@^2.3.3: + version "2.3.4" + resolved "https://registry.yarnpkg.com/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz#53e272d7a5cb8242990c7f144c44d8bd8ab5afd9" + integrity sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A== + dependencies: + react-style-singleton "^2.2.1" + tslib "^2.0.0" + +react-remove-scroll@2.5.5: + version "2.5.5" + resolved "https://registry.yarnpkg.com/react-remove-scroll/-/react-remove-scroll-2.5.5.tgz#1e31a1260df08887a8a0e46d09271b52b3a37e77" + integrity sha512-ImKhrzJJsyXJfBZ4bzu8Bwpka14c/fQt0k+cyFp/PBhTfyDnU5hjOtM4AG/0AMyy8oKzOTR0lDgJIM7pYXI0kw== + dependencies: + react-remove-scroll-bar "^2.3.3" + react-style-singleton "^2.2.1" + tslib "^2.1.0" + use-callback-ref "^1.3.0" + use-sidecar "^1.1.2" + +react-style-singleton@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/react-style-singleton/-/react-style-singleton-2.2.1.tgz#f99e420492b2d8f34d38308ff660b60d0b1205b4" + integrity sha512-ZWj0fHEMyWkHzKYUr2Bs/4zU6XLmq9HsgBURm7g5pAVfyn49DgUiNgY2d4lXRlYSiCif9YBGpQleewkcqddc7g== + dependencies: + get-nonce "^1.0.0" + invariant "^2.2.4" + tslib "^2.0.0" + +regenerator-runtime@^0.13.11: + version "0.13.11" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz#f6dca3e7ceec20590d07ada785636a90cdca17f9" + integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== + +requires-port@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== + +retry@^0.12.0: + version "0.12.0" + resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" + integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== + +signal-exit@^3.0.2: + version "3.0.7" + resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" + integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== + +socket.io-client@^4.5.2: + version "4.7.0" + resolved "https://registry.yarnpkg.com/socket.io-client/-/socket.io-client-4.7.0.tgz#f869a41a2593bc36f058f3b46175024491d997b5" + integrity sha512-7Q8CeDrhuZzg4QLXl3tXlk5yb086oxYzehAVZRLiGCzCmtDneiHz1qHyyWcxhTgxXiokVpWQXoG/u60HoXSQew== + dependencies: + "@socket.io/component-emitter" "~3.1.0" + debug "~4.3.2" + engine.io-client "~6.5.0" + socket.io-parser "~4.2.4" + +socket.io-parser@~4.2.4: + version "4.2.4" + resolved "https://registry.yarnpkg.com/socket.io-parser/-/socket.io-parser-4.2.4.tgz#c806966cf7270601e47469ddeec30fbdfda44c83" + integrity sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew== + dependencies: + "@socket.io/component-emitter" "~3.1.0" + debug "~4.3.1" + style-to-js@1.1.1: version "1.1.1" resolved "https://registry.yarnpkg.com/style-to-js/-/style-to-js-1.1.1.tgz#417786986cda61d4525c80aed9d1123a6a7af9b8" @@ -103,3 +778,89 @@ style-to-object@0.3.0: integrity sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA== dependencies: inline-style-parser "0.1.1" + +tr46@~0.0.3: + version "0.0.3" + resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" + integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== + +tslib@^2.0.0, tslib@^2.1.0: + version "2.6.0" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.0.tgz#b295854684dbda164e181d259a22cd779dcd7bc3" + integrity sha512-7At1WUettjcSRHXCyYtTselblcHl9PJFFVKiCAy/bY97+BPZXSQ2wbq0P9s8tK2G7dFQfNnlJnPAiArVBVBsfA== + +tslib@^2.3.0: + version "2.5.3" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.5.3.tgz#24944ba2d990940e6e982c4bea147aba80209913" + integrity sha512-mSxlJJwl3BMEQCUNnxXBU9jP4JBktcEGhURcPR6VQVlnP0FdDEsIaz0C35dXNGLyRfrATNofF0F5p2KPxQgB+w== + +tus-js-client@^3.0.1: + version "3.1.0" + resolved "https://registry.yarnpkg.com/tus-js-client/-/tus-js-client-3.1.0.tgz#20af57d06c23823fbe108ccb3a3dcb7503968cb4" + integrity sha512-Hfpc8ho4C9Lhs/OflPUA/nHUHZJUrKD5upoPBq7dYJJ9DQhWocsjJU2RZYfN16Y5n19j9dFDszwCvVZ5sfcogw== + dependencies: + buffer-from "^1.1.2" + combine-errors "^3.0.3" + is-stream "^2.0.0" + js-base64 "^3.7.2" + lodash.throttle "^4.1.1" + proper-lockfile "^4.1.2" + url-parse "^1.5.7" + +url-parse@^1.5.7: + version "1.5.10" + resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== + dependencies: + querystringify "^2.1.1" + requires-port "^1.0.0" + +use-callback-ref@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/use-callback-ref/-/use-callback-ref-1.3.0.tgz#772199899b9c9a50526fedc4993fc7fa1f7e32d5" + integrity sha512-3FT9PRuRdbB9HfXhEq35u4oZkvpJ5kuYbpqhCfmiZyReuRgpnhDlbr2ZEnnuS0RrJAPn6l23xjFg9kpDM+Ms7w== + dependencies: + tslib "^2.0.0" + +use-sidecar@^1.1.2: + version "1.1.2" + resolved "https://registry.yarnpkg.com/use-sidecar/-/use-sidecar-1.1.2.tgz#2f43126ba2d7d7e117aa5855e5d8f0276dfe73c2" + integrity sha512-epTbsLuzZ7lPClpz2TyryBfztm7m+28DlEv2ZCQ3MDr5ssiwyOwGH/e5F9CkfWjJ1t4clvI58yF822/GUkjjhw== + dependencies: + detect-node-es "^1.1.0" + tslib "^2.0.0" + +use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a" + integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== + +webidl-conversions@^3.0.0: + version "3.0.1" + resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" + integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== + +whatwg-url@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" + integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== + dependencies: + tr46 "~0.0.3" + webidl-conversions "^3.0.0" + +ws@~8.11.0: + version "8.11.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.11.0.tgz#6a0d36b8edfd9f96d8b25683db2f8d7de6e8e143" + integrity sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg== + +xmlhttprequest-ssl@~2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz#91360c86b914e67f44dce769180027c0da618c67" + integrity sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A== + +zustand@^4.3.2: + version "4.3.9" + resolved "https://registry.yarnpkg.com/zustand/-/zustand-4.3.9.tgz#a7d4332bbd75dfd25c6848180b3df1407217f2ad" + integrity sha512-Tat5r8jOMG1Vcsj8uldMyqYKC5IZvQif8zetmLHs9WoZlntTHmIoNM8TpLRY31ExncuUvUOXehd0kvahkuHjDw== + dependencies: + use-sync-external-store "1.2.0" From 15cb912031b7d0a1ad754eedd6e7ae36e71eceab Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 11 Jul 2023 16:16:17 +0530 Subject: [PATCH 140/298] Spaces backend examples (#522) * fix: spaces documentation * Update README.md * fix: formatting issues * fix: uncommented code --- .../examples/sdk-backend-node/src/main.ts | 3 + .../sdk-backend-node/src/spaces/index.ts | 615 ++++++++ packages/restapi/README.md | 1303 +++++++++++++++++ 3 files changed, 1921 insertions(+) create mode 100644 packages/examples/sdk-backend-node/src/spaces/index.ts diff --git a/packages/examples/sdk-backend-node/src/main.ts b/packages/examples/sdk-backend-node/src/main.ts index 18d9d37a6..a82eb72f4 100644 --- a/packages/examples/sdk-backend-node/src/main.ts +++ b/packages/examples/sdk-backend-node/src/main.ts @@ -1,6 +1,8 @@ import { runNotificaitonsUseCases } from './notification'; import { runChatUseCases, runNFTChatUseCases } from './chat'; import { runVideoUseCases } from './video'; +import { runSpacesUseCases } from './spaces'; + import { config } from './config'; import { ENV } from './types'; @@ -16,6 +18,7 @@ const start = async (): Promise => { await runChatUseCases(); await runNFTChatUseCases(); await runVideoUseCases(); + await runSpacesUseCases(); }; start(); diff --git a/packages/examples/sdk-backend-node/src/spaces/index.ts b/packages/examples/sdk-backend-node/src/spaces/index.ts new file mode 100644 index 000000000..e3fda1b7f --- /dev/null +++ b/packages/examples/sdk-backend-node/src/spaces/index.ts @@ -0,0 +1,615 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import * as dotenv from 'dotenv'; +import { + ethers +} from 'ethers'; +import { + adjectives, + animals, + colors, + uniqueNamesGenerator, +} from 'unique-names-generator'; +dotenv.config(); + +enum ENV { + PROD = 'prod', + STAGING = 'staging', + DEV = 'dev', + /** + * **This is for local development only** + */ + LOCAL = 'local', +} + +// CONFIGS +const env = process.env.PUSH_NODE_NETWORK; // choose ENV.STAGING or ENV.PROD +const showAPIResponse = process.env.SHOW_API_RESPONSE === 'true' ? true : false; // choose to show or hide API responses + +// Addresses that will be used to +const signer = ethers.Wallet.createRandom(); +const signerSecondAccount = ethers.Wallet.createRandom(); + +// generate some dummy wallets as well +const randomWallet1 = ethers.Wallet.createRandom().address; +const randomWallet2 = ethers.Wallet.createRandom().address; +const randomWallet3 = ethers.Wallet.createRandom().address; + + +const spaceName = uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], +}); + +const spaceDescription = uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], +}); + +const spaceImage = + 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg=='; + + +export const runSpacesUseCases = async (): Promise < void > => { + console.log(` + ███████╗██████╗ █████╗ ██████╗███████╗███████╗ + ██╔════╝██╔══██╗██╔══██╗██╔════╝██╔════╝██╔════╝ + ███████╗██████╔╝███████║██║ █████╗ ███████╗ + ╚════██║██╔═══╝ ██╔══██║██║ ██╔══╝ ╚════██║ + ███████║██║ ██║ ██║╚██████╗███████╗███████║ + ╚══════╝╚═╝ ╚═╝ ╚═╝ ╚═════╝╚══════╝╚══════╝ + + `) + + console.log('PushAPI.user.create'); + await PushAPI_user_create(); + + console.log('PushAPI.space.create'); + const spaceId = await PushAPI_space_create(); + + console.log('PushAPI.space.update'); + await PushAPI_space_update(spaceId); + + console.log('PushAPI.space.get'); + await PushAPI_space_get(spaceId); + + console.log('PushAPI.space.start'); + console.log('PushAPI.space.stop'); + await PushAPI_space_start_and_stop(); + + console.log('PushAPI.space.approve'); + await PushAPI_space_approve(); + + console.log('PushAPI.space.addListeners'); + await PushAPI_space_add_listeners(spaceId); + + console.log('PushAPI.space.removeListeners'); + await PushAPI_space_remove_listeners(spaceId); + + console.log('PushAPI.space.addSpeakers'); + await PushAPI_space_add_speakers(spaceId); + + console.log('PushAPI.space.removeSpeakers'); + await PushAPI_space_remove_speakers(spaceId); + + console.log('PushAPI.space.spaces'); + await PushAPI_space_spaces(); + + console.log('PushAPI.space.requests'); + await PushAPI_space_requests(); + + console.log('PushAPI.space.trending'); + await PushAPI_space_trending(); +} + +// Push Chat - PushAPI.user.create +async function PushAPI_user_create(silent = !showAPIResponse) { + const user = await PushAPI.user.create({ + signer: signer, + env: env as ENV, + }); + + const user_2 = await PushAPI.user.create({ + signer: signerSecondAccount, + env: env as ENV, + }); + + console.log('PushAPI_user_create | Response - 200 OK'); + if (!silent) { + console.log(user); + console.log(user_2); + } + + return user; +} + +// Push Space - PushAPI.space.create +async function PushAPI_space_create( + silent = !showAPIResponse +): Promise < string > { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + }); + + const response = await PushAPI.space.create({ + spaceName, + spaceDescription, + members: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], + spaceImage, + admins: [], + isPublic: true, + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + scheduleAt: new Date("2023-07-15T14:48:00.000Z"), + scheduleEnd: new Date("2023-07-15T15:48:00.000Z") + }); + console.log('PushAPI_chat_createSpace | Response - 200 OK'); + if (!silent) { + console.log(response); + } + return response.spaceId; +} + +// Push Space - PushAPI.space.update +async function PushAPI_space_update( + spaceId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + + signer: signer, + }); + + // Actual API + // Convert image to base 64 and pass + // This is an idempotent operation, meaning it requires all space info to be passed no matter if only few things change + // Why so? To ensure that verificationProof always is able to replicate the current space info (trustless since signature is stored with the info) + const response = await PushAPI.space.update({ + spaceId, + spaceName, + spaceDescription, + members: [ + `eip155:${randomWallet1}`, + `eip155:${randomWallet2}`, + `eip155:${randomWallet3}`, + `eip155:${signer.address}`, + ], + spaceImage, + admins: [`eip155:${signer.address}`], // takes signer as admin automatically, add more if you want to + scheduleAt: new Date("2023-07-15T14:48:00.000Z"), + scheduleEnd: new Date("2023-07-15T15:48:00.000Z"), + status: PushAPI.ChatStatus.PENDING, + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_update | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} + +// Push Space - PushAPI.space.get +async function PushAPI_space_get( + spaceId: string, + silent = !showAPIResponse +) { + const response = await PushAPI.space.get({ + spaceId: spaceId, + env: env as ENV, + }); + + console.log('PushAPI_space_get | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} + +// Push Space - PushAPI.space.start +// Push Space - PushAPI.space.stop +async function PushAPI_space_start_and_stop( + silent = !showAPIResponse +): Promise < string > { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + }); + + const now = new Date(); + const start = new Date(now.getTime() + 10 * 60000) + const end = new Date(now.getTime() + 60 * 60000); + + const response = await PushAPI.space.create({ + spaceName: uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], + }), + spaceDescription, + members: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], + spaceImage, + admins: [], + isPublic: true, + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + scheduleAt: start, // Sets scheduleAt to the current time + 10 min + scheduleEnd: end, // Sets scheduleEnd to 60 minutes from now + }); + console.log('PushAPI_chat_createSpace | Response - 200 OK'); + if (!silent) { + console.log(response); + } + + const spaceId = response.spaceId + + // This is causing bug - Aman to check + /*const response2 = await PushAPI.space.start({ + spaceId: spaceId, + env: env as ENV, + signer: signer, + }); + + console.log('PushAPI_space_start | Response - 200 OK'); + if (!silent) { + console.log(response2); + }*/ + + // This is causing bug - Aman to check + /*response = await PushAPI.space.stop({ + spaceId: spaceId, + env: env as ENV, + signer: signer, + });*/ + + console.log('PushAPI_space_stop | Response - 200 OK'); + if (!silent) { + console.log(response); + } + return spaceId; +} + +// Push Space - PushAPI.space.approve +async function PushAPI_space_approve( + silent = !showAPIResponse +): Promise < string > { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + }); + + const now = new Date(); + const start = new Date(now.getTime() + 10 * 60000) + const end = new Date(now.getTime() + 60 * 60000); + + const response = await PushAPI.space.create({ + spaceName: uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], + }), + spaceDescription, + members: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], + spaceImage, + admins: [], + isPublic: true, + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + scheduleAt: start, // Sets scheduleAt to the current time + 10 min + scheduleEnd: end, // Sets scheduleEnd to 60 minutes from now + }); + console.log('PushAPI_chat_createSpace | Response - 200 OK'); + if (!silent) { + console.log(response); + } + + const spaceId = response.spaceId + + const secondUser = await PushAPI.user.get({ + account: `eip155:${signerSecondAccount.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKeyUser2 = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: secondUser.encryptedPrivateKey, + signer: signerSecondAccount, + }); + + // Actual api + const approveResponse = await PushAPI.chat.approve({ + status: 'Approved', + senderAddress: spaceId, // receiver's address or spaceId of a group + signer: signerSecondAccount, + pgpPrivateKey: pgpDecrpyptedPvtKeyUser2, + env: env as ENV, + }); + + console.log('PushAPI_space_approve | Response - 200 OK'); + if (!silent) { + console.log(approveResponse); + } + return spaceId; +} + +// Push Space - PushAPI.space.addListeners +async function PushAPI_space_add_listeners( + spaceId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + + signer: signer, + }); + + const response = await PushAPI.space.addListeners({ + spaceId, + listeners: [ + `eip155:${ethers.Wallet.createRandom().address}`, + `eip155:${ethers.Wallet.createRandom().address}`, + `eip155:${ethers.Wallet.createRandom().address}`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_addListeners | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} + +// Push Space - PushAPI.space.removeListeners +async function PushAPI_space_remove_listeners( + spaceId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + }); + + const a1 = ethers.Wallet.createRandom().address; + const a2 = ethers.Wallet.createRandom().address; + const a3 = ethers.Wallet.createRandom().address; + + const response = await PushAPI.space.addListeners({ + spaceId, + listeners: [ + `eip155:${a1}`, + `eip155:${a2}`, + `eip155:${a3}`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_addListeners | Response - 200 OK'); + if (!silent) { + console.log(response); + } + + const response2 = await PushAPI.space.removeListeners({ + spaceId, + listeners: [ + `eip155:${a1}`, + `eip155:${a2}`, + `eip155:${a3}`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_removeListeners | Response - 200 OK'); + if (!silent) { + console.log(response2); + } +} + +// Push Space - PushAPI.space.addSpeakers +async function PushAPI_space_add_speakers( + spaceId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + + signer: signer, + }); + + const response = await PushAPI.space.addSpeakers({ + spaceId, + speakers: [ + `eip155:${ethers.Wallet.createRandom().address}`, + `eip155:${ethers.Wallet.createRandom().address}`, + `eip155:${ethers.Wallet.createRandom().address}`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_addSpeakers | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} + +// Push Space - PushAPI.space.removeSpeakers +async function PushAPI_space_remove_speakers( + spaceId: string, + silent = !showAPIResponse +) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + + signer: signer, + }); + + const a1 = ethers.Wallet.createRandom().address; + const a2 = ethers.Wallet.createRandom().address; + const a3 = ethers.Wallet.createRandom().address; + + const response = await PushAPI.space.addSpeakers({ + spaceId, + speakers: [ + `eip155:${a1}`, + `eip155:${a2}`, + `eip155:${a3}`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_addSpeakers | Response - 200 OK'); + if (!silent) { + console.log(response); + } + + const response2 = await PushAPI.space.removeSpeakers({ + spaceId, + speakers: [ + `eip155:${a1}`, + `eip155:${a2}`, + `eip155:${a3}`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_removeSpeakers | Response - 200 OK'); + if (!silent) { + console.log(response2); + } +} + +// Push Space - PushAPI.space.spaces +async function PushAPI_space_spaces(silent = !showAPIResponse) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + + signer: signer, + }); + + // Actual api + const response = await PushAPI.space.spaces({ + account: `eip155:${signer.address}`, + toDecrypt: true, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_spaces | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} + +// Push Chat - PushAPI.spaces.requests +async function PushAPI_space_requests(silent = !showAPIResponse) { + // Fetch user + const user = await PushAPI.user.get({ + account: `eip155:${signer.address}`, + env: env as ENV, + }); + + // Decrypt PGP Key + const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + }); + + // Actual api + const response = await PushAPI.space.requests({ + account: `eip155:${signer.address}`, + toDecrypt: true, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + + console.log('PushAPI_space_requests | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} + +// Push Chat - PushAPI.spaces.trending +async function PushAPI_space_trending(silent = !showAPIResponse) { + + // Actual api + const response = await PushAPI.space.trending({ + env: env as ENV, + }); + + console.log('PushAPI_space_trending | Response - 200 OK'); + if (!silent) { + console.log(response); + } +} \ No newline at end of file diff --git a/packages/restapi/README.md b/packages/restapi/README.md index b65e7e2a2..6ca39436b 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -83,6 +83,22 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [enableVideo](#enablevideo) - [enableAudio](#enableaudio) - [isInitiator](#isinitiator) + - [For Spaces](#for-spaces) + - [To create a space](#to-create-a-space) + - [To create a token gated space](#to-create-a-token-gated-space) + - [To update space details](#to-update-space-details) + - [To update token gated space details](#to-update-token-gated-space-details) + - [To get space details by spaceId](#to-get-space-details-by-spaceId) + - [To start a space](#to-start-a-space) + - [To stop a space](#to-stop-a-space) + - [To approve a space request](#to-approve-a-space-request) + - [To add listeners to space](#to-add-listeners-to-space) + - [To remove listeners from space](#to-remove-listeners-from-space) + - [To add speakers to space](#to-add-speakers-to-space) + - [To remove speakers from space](#to-remove-speakers-from-space) + - [Fetching list of user spaces](#fetching-list-of-user-spaces) + - [Fetching list of user space requests](#fetching-list-of-user-space-requests) + - [Fetching list of trending spaces](#fetching-list-of-trending-spaces) # How to use in your app? @@ -4163,3 +4179,1290 @@ Allowed Options (params with \* are mandatory) ```typescript isInitiator(): boolean ``` + +--- + +## For Spaces + +### **To create a space** + +```typescript +// pre-requisite API calls that should be made before +// need to get user and through that encryptedPvtKey of the user +const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); + +// need to decrypt the encryptedPvtKey to pass in the api using helper function +const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); + +// actual api +const response = await PushAPI.space.create({ + spaceName:'wasteful_indigo_warbler', + spaceDescription: 'boring_emerald_gamefowl', + members: ['0x9e60c47edF21fa5e5Af33347680B3971F2FfD464','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + spaceImage: <space image link> , + admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + isPublic: true, + account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', + env: 'staging', + pgpPrivateKey: pgpDecryptedPvtKey, //decrypted private key + scheduleAt: new Date("2024-07-15T14:48:00.000Z"), + scheduleEnd: new Date("2024-07-15T15:48:00.000Z") +}); +``` + +### **To create a token gated space** + +```typescript +// pre-requisite API calls that should be made before +// need to get user and through that encryptedPvtKey of the user +const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); + +// need to decrypt the encryptedPvtKey to pass in the api using helper function +const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); + +// actual api +const response = await PushAPI.space.create({ + spaceName:'wasteful_indigo_warbler', + spaceDescription: 'boring_emerald_gamefowl', + members: ['0x9e60c47edF21fa5e5Af33347680B3971F2FfD464','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + spaceImage: <space image link> , + admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", + numberOfERC20: 20, + contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", + numberOfNFTTokens: 2, + isPublic: true, + account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', + env: 'staging', + pgpPrivateKey: pgpDecryptedPvtKey, //decrypted private key + scheduleAt: new Date("2024-07-15T14:48:00.000Z"), + scheduleEnd: new Date("2024-07-15T15:48:00.000Z") +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| account_ | string | - | user address | +| spaceName* | string | - | group name | +| spaceDescription* | string | - | group description | +| spaceImage* | string | - | group image link | +| members* | Array | - | wallet addresses of all members except admins and spaceCreator | +| admins* | Array | - | wallet addresses of all admins except members and spaceCreator | +| isPublic* | boolean | - | true for public space, false for private space | +| scheduleAt\* | Date | - | Date time when the space is scheduled to start | +| scheduleEnd | Date | - | Date time when the space is scheduled to end | +| contractAddressERC20 | string | null | ERC20 Contract Address | +| numberOfERC20 | int | 0 | Minimum number of tokens required to join the space | +| contractAddressNFT | string | null | NFT Contract Address | +| numberOfNFTTokens | int | 0 | Minimum number of nfts required to join the space | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+
Expected response (create space) + +```typescript +// PushAPI.space.create | Response - 200 OK +{ + members: [{ + wallet: 'eip155:0x727C819feB2c7F99c66d71B8411521bca2010023', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSrssEBCACg3ZjrZB40Xqr5IKIEtFldaeQyJPNwDACMekY77yApav0B\n' + + 'RwiqhFJDFJKcprSHg/vYdqalAIGRQ+J98VMBtHweurIubD/ODB6WknOms7ZY\n' + + '3ummaEzyFRombuq/C75o/0ImCi2v0PJBI3kdpwzOjiTt8S44yoAVOcTf9jyg\n' + + 'vTEVCOM81yqCf0mDB4t0jqRYewlQuJegORXDKHKTfZcnQybBkDYUGgmxOcyF\n' + + 'BaPMhSiWqAAqqb4gcFO2QKq69JoiE9dzSuF/7dvAq2QZRogC/GQW2Q9yQbq3\n' + + 'CvMNO4H2KUZzegaq2s2nMPGMXPNf4GZcZVJE1phWgAnApxTf5kUFfKr1ABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKuywQQLCQcICZDwrCS5ulOLwQMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBFKpO7zcSRed+QmbIfCsJLm6U4vBAABZMwf+OIbBcFQ7x++1\n' + + 'NINOYbP9v0PyJvpllDcUORbk3uiPMpvDuQYAe2Fd4dY2Y91l3VdpIm/w6HQy\n' + + 'y81Y694w4E7PRVhDwHivv5D10VE9MF3h6qOHrLLpvdhpMaB5Ur8ts5rU2zOu\n' + + '64HR04/BVO9N0nrE9iywIgVMOy6IrS+OgK3r75PPX35bam/kbbmZHeygFaE9\n' + + '+mgQVdhwgF5borekIiz1Rc8CPA/P1yZy8QQl4KGmJEs+hOc5rPnUWwarvaAH\n' + + 'mPb6H0/mG81eXBOjpJlSFu6d/uqKLpoAw5fkvFoIsNwovYpyQkSbhzwe4T2N\n' + + 'jGqGd0+La03QdB5FbaiwcnJ96lU6oM7ATQRkq7LBAQgAxu9uK1+p62+/RvcF\n' + + 'Mz7g3A8SJiN76NYxk29sjQ9gW74B/IdPv5TlUVhG6PGr2c3SucASlEHieagY\n' + + 'CXM2+fpdu4rQ6EKRAe+30GFopfzhX1d0zv9d5BE6q1ML5mkrpDECH5iuqah7\n' + + 'smmbRdWE7zRSGaHyEfVqAG3wfMzzN0BcchxxR4vMCNKYLs9v2Q09ecO7DgaY\n' + + '5CZqxaFlTo+auuDhE0XU7WRbNL77izocV1Sm+McRyo28PrFTcrRRznD1nP0V\n' + + 'eZ4+aoulqyYA+gBBaIUdSA5kQXJiy67crB50yX3V6zLIfptD2ThHPjTY/inW\n' + + 'wVHVug4jIWUQ1QQw/q9qvGxAzQARAQABwsB2BBgBCAAqBYJkq7LBCZDwrCS5\n' + + 'ulOLwQKbDBYhBFKpO7zcSRed+QmbIfCsJLm6U4vBAADu6wf+NJDX/3NAxQKN\n' + + 'Iigj0GkBm/y69iFmQvWJxxtiYCNu8VBhm8MkcghUJ8G2tWP9ueUOM8sMTEa+\n' + + 'G+l+wSNwh/1yisF3FutDpy6l+fiy6kPPD4vl08jY3GrqSuWWfMxTJhMZ5D6v\n' + + 'OW2EfdyET+oP5eOnCd6p0EXP2ic48rVHDdU2iWeg0RkGvZP3t2LljWFdLbvw\n' + + 'h7+wSD1i4LY4slUIdbLdDSLN1gWFN1HXzX10mpX0grV2sBdfkNyHhF0WcIat\n' + + 'sD9HpAx2M62yP2D9D9UZVrW7WfmOoyL1NrnXSJsI8CRFDzujvpIrr7875zSi\n' + + 'VnxDVyt7twc7cYqRDHsNYuxAuE815A==\n' + + '=2jvb\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA4klEQVR4AcXBoW3FMBRA0dsn75E9skAU6BkMSk1CA0xNsoBnMLSyQPbIDgVlLX0OcPX1Vb1zPj6/v35QWg5o61bQok+MHHVHazmgrVtBE4wJxgRjjofzmuj4xCuiT2iRCe2gJxgTjAnGXMuBTi2MRJ8YOerOSMsBTTAmGBOMuXUraNEntKPuaEfdeUX0iU4taIIxwZhgzPGH6BP/STAmGBOMOR6W+UY7r4l3LPONttITjAnGBGMu+kSnFrQlB96xbgUt+oQmGBOMCcYcDy0HRs5rYmSZb7SWA1pkQhOMCcYEY78uSjTZAXCkaQAAAABJRU5ErkJggg==' + }], + pendingMembers: [{ + wallet: 'eip155:0x5f4e9e7Fcc17a943178c0b0881b09E8Ef9D34437', + publicKey: null, + isSpeaker: false, + image: null + }, + { + wallet: 'eip155:0xFedfA2b276676C5c6ce753ddb4B05d00104E9236', + publicKey: null, + isSpeaker: false, + image: null + } + ], + contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", + numberOfERC20: 20, + contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", + numberOfNFTTokens: 2, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkq7LBCZDwrCS5ulOLwRYhBFKpO7zcSRed+QmbIfCsJLm6\n' + + 'U4vBAAAAHwf+K4f0gxaP56X4Cv2zlPWB9iUPi/1FOnx8ZF7oEf9xJSv/xA7v\n' + + '9LHBTZ2Y9AQlJpy0WLB7KGF7mVV1MdUKHjn2SFQ+1h+8d+FIHXfmB7Ie4alP\n' + + 'nnar6XjtMVKYyqXRzMzCq2F7Fjea1sUOXBxAeyJstAGG6nvsU51imaAtGQlQ\n' + + 'u7ih8D9UkiOe719v5GyI1vtiS+hHGlYo0+A7WVImH6SuVyPZ3UyPvLxXpeKs\n' + + '1SeEfuvfmKHbswm1DDGOknyo7fJ/QgKqOfkwsBIrYRNGwPGEKt8pHdwNxsNn\n' + + 'hNQtlFqtmtvieaxbhJQKXHbVgNv206xNsUBrK/U2nCakx7EMmxikFg==\n' + + '=tz9T\n' + + '-----END PGP SIGNATURE-----\n', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'wasteful_indigo_warbler', + isPublic: true, + spaceDescription: 'boring_emerald_gamefowl', + spaceCreator: 'eip155:0x727C819feB2c7F99c66d71B8411521bca2010023', + spaceId: 'spaces:e0553610da88dacac70b406d1222a6881c0bde2c5129e58b526b5ae729d82116', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} + + +``` + + + +--- + +### **To update space details** + +Note - updateSpace is an idompotent call + +```typescript +// pre-requisite API calls that should be made before +// need to get user and through that encryptedPvtKey of the user +const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); + +// need to decrypt the encryptedPvtKey to pass in the api using helper function +const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); + +// actual api +const response = await PushAPI.space.update({ + spaceId: 'spaces:e0553610da88dacac70b406d1222a6881c0bde2c5129e58b526b5ae729d82116', + spaceName: 'Push Space 3', + spaceDescription: 'This is the oficial space for Push Protocol', + members: ['0x2e60c47edF21fa5e5A333347680B3971F1FfD456','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + spaceImage: <group image link> , + admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: PushAPI.ChatStatus.PENDING, + account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', + env: 'staging', + pgpPrivateKey: pgpDecryptedPvtKey, //decrypted private key +}); +``` + +### **To update token gated space details** + +Note - updateSpace is an idompotent call + +```typescript +// pre-requisite API calls that should be made before +// need to get user and through that encryptedPvtKey of the user +const user = await PushAPI.user.get(account: 'eip155:0xFe6C8E9e25f7bcF374412c5C81B2578aC473C0F7', env: 'staging'); + +// need to decrypt the encryptedPvtKey to pass in the api using helper function +const pgpDecryptedPvtKey = await PushAPI.chat.decryptPGPKey(encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: _signer); + +// actual api +const response = await PushAPI.space.update({ + spaceId: 'spaces:e0553610da88dacac70b406d1222a6881c0bde2c5129e58b526b5ae729d82116', + spaceName: 'Push Space 3', + spaceDescription: 'This is the oficial space for Push Protocol', + members: ['0x2e60c47edF21fa5e5A333347680B3971F1FfD456','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + spaceImage: <group image link> , + admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: PushAPI.ChatStatus.PENDING, + contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", + numberOfERC20: 20, + contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", + numberOfNFTTokens: 2, + account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', + env: 'staging', + pgpPrivateKey: pgpDecryptedPvtKey, //decrypted private key +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | Id of the space | +| account* | string | - | user address | +| spaceName* | string | - | space name | +| spaceDescription* | string | - | space description | +| spaceImage* | string | - | space image | +| status* | string | - | space status - 'ACTIVE', 'PENDING', 'ENDED' | +| members* | Array | - | wallet addresses of all members except admins and spaceCreator | +| admins* | Array | - | wallet addresses of all admins except members and spaceCreator | +| scheduleAt* | Date | - | Date time when the space is scheduled to start | +| scheduleEnd | Date | - | Date time when the space is scheduled to end | +| contractAddressERC20 | string | null | ERC20 Contract Address | +| numberOfERC20 | int | 0 | Minimum number of tokens required to join the group | +| contractAddressNFT | string | null | NFT Contract Address | +| numberOfNFTTokens | int | 0 | Minimum number of nfts required to join the group | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (update space) + +```typescript +// PushAPI.space.update | Response - 200 OK +{ + members: [ + { + wallet: 'eip155:0x367c6555b2CAD9C2d2656066EC3996Ba12cD058d', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSr17UBCADhEXWz/lsg0sDA+QRygzl+4t84/YYa459nzFRNB36jkbU8\n' + + 'FxRsE6oZTu0Leanup7aul4trJJ4qyA6xFfDjprDzrm1Gtp/gos46Lxk+br64\n' + + 'lzgqTfSKpBs9UWqOcr4Vnoq9WeOiFZax0DhN//7ibIQDWIJ0E6iOc8uiSoGZ\n' + + 's4AHTx7GtUvHxIUAk/hQY8UjjDNyhgCSrmdPeWt/SVbmFCHchdH/KhSK8JVq\n' + + 'qs8/nKx2Tm/nmAdWFZDqIJxd5tVuXXMxTZYZADZfmBltR2F/8GkF7hfX/aOo\n' + + 'gGQ/u2FPbCKRjtedfJi3WsPUKtyFg6QdwBnOQmYn0fGXlPGR7UVSsmIVABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKvXtQQLCQcICZD2NRrvru2XMgMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBM1nsbalDm3PtLAK2/Y1Gu+u7ZcyAADzuwgAmTBbnBQZ2w06\n' + + 'RbLmcZf8cYTof1X3mpYBa1lprMltib2jZQdu8DxhZBapYIE1O0UzV2Dy8IXj\n' + + 'zavtNFZiLR8FTwkrXQ3DGrZylnqjLkQ6m2jZsGIypb2OpTlBIBnjW98Dh99F\n' + + 'egI/5wse59IfGhYXVcKluKDAW2ezUJx8BhacZCwf/S8iG9YKrZctS5cVZxQw\n' + + 'SymXv88msoQrWhxmu2AT0rNsZ656ANMr/MuUjKMxQsoNCNIkp5kE0UTGfMwc\n' + + 'c69Gabs9uOPOqAGeSBGVfw+uJig/RJ4MWDCbj6QIDsV5FFRvTmJmmSNLNH5y\n' + + '83pHxE+923z6NiPWRonbns3pFNvhnc7ATQRkq9e1AQgAxjGMkGhs2OTW8fW/\n' + + '4tloJOID0UIDrz/24uX4JU+qjTqMzFyNGaNagT8n0xDH2E63YFmketip4QA2\n' + + '6kUBICKR2Y5kNNzkJXK4NYfa5OXEIS+lw+X7oMXd9YJ/D1fig1XD4Bf0ofsZ\n' + + 'QIxHOn6w3T/wQHOBpu+cqE3d0pW+6s6hZ4mkuPk6OXrkBSEtynk4ADQS+a3b\n' + + 'PrCGU9rJy2OnbP+lMr3onv/6BR/DFE4qCIfQt0cLu4nhAuYVYrOupi3p9eBQ\n' + + 'z/oWHCSNQVQSW2/vHp0YwMj2r3jSGdoZ3pcfy4iXOa7xEyeauOn/pHK+syOX\n' + + 'Pv64DHncql4AJFj9tw4rZ2/kkQARAQABwsB2BBgBCAAqBYJkq9e1CZD2NRrv\n' + + 'ru2XMgKbDBYhBM1nsbalDm3PtLAK2/Y1Gu+u7ZcyAADapwf/XF6I2NifyL/h\n' + + '2aVsr2lL2At732336je3WM6QnA/q1x9lmxX646c9eETUQvLLhT5RZmx1X8Fa\n' + + 'X/qGMKJe+BWLFPy5k6LnOezvvOxHGV+dzRndlWbnC9d3AZhThciw/Rd8V9W6\n' + + 'd6luo7+Apdd3rS17hG4gElhNX1drq5TuWR89yxA5oXcIqA+u3jBdpz0qo/ME\n' + + '+63r0AubixdM7rgV0skugaIXvqMKtfMC/V2A8mCL5AmRXCyfMBIsEA0L5YA1\n' + + 'wsKlHIQAy3jiPdY/2q5KUWJsR9o/IFirjnTd5vywtYsscOq/KnfLKdc2cVOr\n' + + 'e/vSkTOrD+dVTlxGhADoud4kvcOPtg==\n' + + '=6H2/\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAy0lEQVR4AcXBMU5DMRBF0cvI63FJETn7oXY3K3CBNHX2g/WFKKdnLdCOUnyEgnjnPH2+v35RXPagOsbmEZc9qI6xqQwxQ8wQa9w5xuYvHWNzxhAzxAyxxg8ynKrPxZkMp+pzccYQM8QMsZbhVH0uzmQ4j8hwKkPMEDPEWp+LKsOp+lxUGc6ZPhdVhlP1uagMMUPMEGsZzn/KcCpDzBAzxBp3+lxUGU718vzGmVtcqfpcVBlOZYgZYoZY63PxG7ePK4/oc1EZYoaYIfYN05Y0ReqpB6sAAAAASUVORK5CYII=' + } + ], + pendingMembers: [ + { + wallet: 'eip155:0xB026B0A8BB1fea997a73c5a84fe7aF8cAab1AcF2', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA4ElEQVR4AcXBsU0EMRCG0Y+RC3ETzpwheqAFOnBmOZtSNqGC02abOaUAdwLp3AU+IYT+916+Pj6/CXLp/Kc1B5EhZogZYokn1hxEuXR21hxEuXR2DDFDzBBLuXSiNQdRaxeR+2CntYvIfRDl0okMMUPMEEs8cZw37pQbO8fJnUVlxxAzxAyxxINcOtGag7/IpbNjiBlihlh6f30jcq9EuXSiNQc7uXSiNQdRaxeRIWaIGWLJvRK1dhEdJ3dy6fxGaxeReyUyxAwxQyzxwL0SLSpRLp2dNQeRT7YMMUPMEPsB1yM4zt7CMugAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x9b70FD7164ec0Ed3E1B3E318836522340dd2e125', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA0UlEQVR4AcXBMWoDMRRF0ZtnkWYKgddgGKbSVrSILFBbUWUMLrICgwqXQ9L+NDKDIe+cj8+v7x+CPhpRyZV39NGISq5EwkyYCbN0f9z4a2Omj8ZMyZVo2Tei++NGJMyEmTBLz9OVqOTKTMmVIy7nlaiPRiTMhJkwS8u+8Z+WfSMSZsJMmKXLeWWmj0a07Bszz9OVqORKdDmvRMJMmAmzxAslV45ZOUKYCTNhlvpozJRcifpozJRcifpozAgzYSbMEi/00YhKrsz00ThCmAkzYfYLlLsvpsHyBx0AAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x1A050099a08D7faf3b5923669a0FAe42A0872D72', + publicKey: null, + isSpeaker: false, + image: null + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkq9e1CZD2NRrvru2XMhYhBM1nsbalDm3PtLAK2/Y1Gu+u\n' + + '7ZcyAAA0igf/Tgo/WU4C5g4UtHPCwU/jThQwjElzCa96bZU8bCXsgnoO1NMI\n' + + 'fwI7FxIw8FmFrktHIWT10T/9vq2ItyUvpbWRhnD5zt5aRhJ1KA1z06iwkoUt\n' + + 'DLiPfveoSDyIhUIjx5PUMN0r/tXmLhj3CrkHx1hiPBxEkhi9brfFcOvX57HS\n' + + 'VOKOeeUa4G1cmk6dtzLHWT4p7ekrFhZPHXDtZUMZEU2wbMkB6bRqlZ7UYLbN\n' + + '7+0AvCu7uaCYG0zfbl3oZc6DkIm9jnBknsII6Hqv7Dc9NLAUBWo8tPrW2/KN\n' + + '8Bv/gk5HPb16tOihIUjs8v45wO3oTPAQYbJGdF6ta+HyiKO8JWipbw==\n' + + '=wkHz\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'mobile_aquamarine_constrictor', + isPublic: true, + spaceDescription: 'conventional_crimson_dove', + spaceCreator: 'eip155:0x367c6555b2CAD9C2d2656066EC3996Ba12cD058d', + spaceId: 'spaces:108f766a5053e2b985d0843e806f741da5ad754d128aff0710e526eebc127afc', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} +``` + +
+ +--- + +### **To get space details by spaceId** + +```typescript +const response = await PushAPI.space.get({ + spaceId: + 'spaces:108f766a5053e2b985d0843e806f741da5ad754d128aff0710e526eebc127afc', + env: 'staging', +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (get space by space id) + +```typescript +// PushAPI_space_get | Response - 200 OK +{ + members: [ + { + wallet: 'eip155:0xd1ab5Af3Be78bB1492099CE568761F0e706352a0', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSr528BCADI8kQcWkaw9PKmSrwCtPBDWj+wzPhmok9jAzxzb2+qAjSV\n' + + 'rYdIrnx6PAp1rMU6qoVg4cdDbCYPV+kCj8l3lUzH/a/SfPsDWpspA/ICWMeS\n' + + 'dMdGYxHLk2gsu0wRz69qoddXMY1h5eMZEyRnr2fsX/cy15mxO2IEHYnC2/rp\n' + + '06iFpx1T8k5HWgFDpyleWyMSQ7Bnn7GutrlHYEVtIGVfXDSkea8IDLLkzBEV\n' + + '3jlBUFhpsrlcvDwDYcMYOrqSBEtg1a+GMK+2Ye/hF37KUYTAPleKXeN0cYIs\n' + + 'Va8oleZK960XYfuy5SYCJav2kaAggNWQBie5G9C4H3h7FuFwWk8LH3DhABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKvnbwQLCQcICZBm9Bz6DvB6DwMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBPkdSvwnOBuAJaOWAGb0HPoO8HoPAAAkiQgAukm3owebckwr\n' + + 'xAR42r/+CBx1uoqM2ZeEAUeYtBF7sdLEsdxFrxl8wHKAbglZwtgWcfG95v2R\n' + + 'zLcBco3v9p0IuS6DZduIfhngZ49gpYwqFGyiCOvo+k14tuMbrbOZTTKp0uc6\n' + + 'icpTyP8/1U0nZrQmmSXyfh6Hgmx1OnW3zTM7oUN1ZVvj3V6rOl+ktUPjAaYo\n' + + 'CWJjth92xhDWEPZnC/4Gz2eRoTVtmx8u+/2vNPffQVgzzHznUxB+G5XeZmPk\n' + + 'z8oxxSxII8PNiAs5LizqPjyq2gEv25GlCsMXTYz60n/t/4G7Yc94yu8xD8u3\n' + + 'BpWluHC2eW0pYFcDfiNLfv0uJCrUcM7ATQRkq+dvAQgA7v7Zz4CZdPsd4jvB\n' + + 'uDwjop/Gvoz+rbvAdS3Xrsi+OTyrWAqidnXChhwExlUNelZ9v52lGxe1twwr\n' + + 'vxeQ4M0pv4oqSlZxhkqBCyj+E7ECR2WXG7ccLlzYOz3b5BXT+fEkmVsbVTjA\n' + + 'Kttjosm7FtY4igY2Hu4UlZZW8M1tYL1R/UegFeMYGY7aO7dcKeiP0NsDwm3c\n' + + '0SiU6/JlOXAIi/ZSKDJ4b5BPK6GFj5pNWr92/V7LejlZfoHAVDbb91tiPGdP\n' + + 'y3+r9T3IYsgUDLgOpPQn6o82Nctm6CnIZqAN12nJ1DEJP2JyLDedg9b5H+aa\n' + + 'FDZFc7yQ3In/QPtjHImydLt9NwARAQABwsB2BBgBCAAqBYJkq+dvCZBm9Bz6\n' + + 'DvB6DwKbDBYhBPkdSvwnOBuAJaOWAGb0HPoO8HoPAABRUQf+KoF4UXuseLBO\n' + + 'd0PD0+hEcnsYbaPWmPZtJPWusxPl6kt421luymPiThDXwaMVzRrmxkz0dNZ3\n' + + 'bUFYtS24t2BhlXZ6cGFNRjXrA9OV0kLg/kNm1vboQ1GL8qRV9CIjPVEpksQp\n' + + 'tOiYN+X+/2XdPJkaQpITHIFV067qWQSAKIonvOI8OJYOovGRQTInz0VE71Yn\n' + + 'SeiOilKBK+p2RN38jGr0PGWt740KJ6560FzfUwTAQzz9vrkYa+vEhWe+bzOd\n' + + 'YBpxj/BRTGR19DrKlGcFPdTYz5ADxCjBuCxXgoRCbBiWwh+iIstk5qkT8uHK\n' + + 'NQjzDvo3RO1cROQp0zsikladmzGZHQ==\n' + + '=q/e/\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA10lEQVR4AcXBsWnFMBSG0c8/brOD9kgfogHUGQIuAppInSsVAQ2gdbSD64fTXl4hMI/HPWf5fXxf3DDaxkxIlTuEM+FMOFt5MtqG1XvBipGpsp9YMWaskCqWcCacCWfL4+fzwogx8069FyzhTDgTzpavv3oxEVLlFaNtzAhnwplwtvIkpIpV9hMrxsxM7wUrHxVrtA1LOBPOhLM1pIo12oaVj4rV98JMPj6wRtuwQqpYwplwJpyt3BRjZiZQuUM4E86Es7XsJ1aMTIVUeUXZTyzhTDgTzv4BnGY033BWusUAAAAASUVORK5CYII=' + } + ], + pendingMembers: [ + { + wallet: 'eip155:0xaC6C69c657cF6022fa787B14BDdaA22936B56D65', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA2UlEQVR4AcXBQWoEIRBA0Z+ikOwNDHirbARPKDiLvkzOIATaC4iQbGt6ITSzqPc+np8/fxhpVazzcfCOr99vrK4FS3AmOBOcKRddCy9GwQoxszNHw+rKluBMcCY407QqO10L1hyNO9Kq7AjOBGeCMz0fB9YcjZ20KjtdC1bXghVixhKcCc4EZzpH446uhXfM0bAEZ4IzwZmGmLHmaOyEmNmZo7ETYsYSnAnOBGfKRVoVq2vBmqNxR1oV6+SV4ExwJjhTLroWdkLM7MzRsLoWrMCBJTgTnAnO/gGd1jrTKk/8EAAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xEf532414907E8c631307c0d501cDe6D1694bAF5e', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA00lEQVR4AcXBobHDMBBF0ZsdjftIDeGuIkzIaGsQC1MNQkZirsLcnaQCk3yqBOzMH4N3zu11f38I+GPiinacRAwxQ8wQS/zo1flSGqNenUgujVGvziiXxsgQM8QMscSPXBqjXp1RLo1Ir84ol0bEEDPEDLHkj4lI51uvzn/4YyJiiBlihlhqx0lkZ2U0Pxci+7YyasdJxBAzxAyx1KsT8W3lil6diCFmiBlit9f9/SHQq3NFLo2IIWaIGWKpVyeybyuj+bkQ2beV0VwXIoaYIWaI/QH8GTSs76EUEQAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x2F5f27B523C8888eA79b7FA80a9CbA6b6980784c', + publicKey: null, + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA0klEQVR4AcXBsW3DQAxA0W9CExjIDhogfboDCw9gICvcHmldcIAMoYLgJJ5CKzgto4KA4ILvXT5+Pl8kwydZqJHt60bl+ryRDZ9koUYmNBOaCc0u31+/L04INSrDJ2cIzYRmQrMl1Dhj+KQSapwhNBOaCc0WDvZ1o+ROZV83KtfnjUxoJjQTmi0c3B/OO+4PpxLKP0IzoZnQbBk+yUKNyvBJJdSoDJ9kQjOhmdBsCTWy4ZNKqFEZPqmEGpnQTGgmNFs4CDWy4ZN3hBoVoZnQTGj2BxvbMvuaMCXUAAAAAElFTkSuQmCC' + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkq+dvCZBm9Bz6DvB6DxYhBPkdSvwnOBuAJaOWAGb0HPoO\n' + + '8HoPAAD5ywf/cvaGM0DzcB22Q2FMzUZG4/ZmkN4OknvSj0d4hB/sPUIb9176\n' + + 'z+niFMjWZNFpIj8s36f16oMEZZ+Eleu9t6sECBxRDvO8pEwyByCXSmz8e/SH\n' + + 'Y659cvg5/A3bSe0FqR0VTI1o+Uz2BpnXG/P38C6D46btaIaJcr4cIh88wQ9J\n' + + 'lr05hOE7w/7Uo5OwyXala0NfB+8S4LIfpC2OlPOhyHQEJd2+WoFKb/6dO28D\n' + + 'TLuvgYJXJfc4R3ElcgFfm1N9ylG0Pt1F3c0C/k9bNokR2PVXgX2XSTQsx1rD\n' + + 'MCY/ePr93INyNZuTPcPlK87X6OTa2/gEW161vup2Xn2Did9HtL76Qw==\n' + + '=EkOP\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'intellectual_green_bat', + isPublic: true, + spaceDescription: 'sad_purple_pinniped', + spaceCreator: 'eip155:0xd1ab5Af3Be78bB1492099CE568761F0e706352a0', + spaceId: 'spaces:9dab226c7920fe06154d76f78dfe1187bdc4fda712cdd9a8b37cc6a99741a63b', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} +``` + +
+ +--- + +### **To start a space** + +```typescript +const response = await PushAPI.space.start({ + spaceId: + 'spaces:108f766a5053e2b985d0843e806f741da5ad754d128aff0710e526eebc127afc', + env: 'staging', +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (start space by space id) + +```typescript +// PushAPI_space_start | Response - 200 OK +{ + members: [ + { + wallet: 'eip155:0xd1ab5Af3Be78bB1492099CE568761F0e706352a0', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSr528BCADI8kQcWkaw9PKmSrwCtPBDWj+wzPhmok9jAzxzb2+qAjSV\n' + + 'rYdIrnx6PAp1rMU6qoVg4cdDbCYPV+kCj8l3lUzH/a/SfPsDWpspA/ICWMeS\n' + + 'dMdGYxHLk2gsu0wRz69qoddXMY1h5eMZEyRnr2fsX/cy15mxO2IEHYnC2/rp\n' + + '06iFpx1T8k5HWgFDpyleWyMSQ7Bnn7GutrlHYEVtIGVfXDSkea8IDLLkzBEV\n' + + '3jlBUFhpsrlcvDwDYcMYOrqSBEtg1a+GMK+2Ye/hF37KUYTAPleKXeN0cYIs\n' + + 'Va8oleZK960XYfuy5SYCJav2kaAggNWQBie5G9C4H3h7FuFwWk8LH3DhABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKvnbwQLCQcICZBm9Bz6DvB6DwMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBPkdSvwnOBuAJaOWAGb0HPoO8HoPAAAkiQgAukm3owebckwr\n' + + 'xAR42r/+CBx1uoqM2ZeEAUeYtBF7sdLEsdxFrxl8wHKAbglZwtgWcfG95v2R\n' + + 'zLcBco3v9p0IuS6DZduIfhngZ49gpYwqFGyiCOvo+k14tuMbrbOZTTKp0uc6\n' + + 'icpTyP8/1U0nZrQmmSXyfh6Hgmx1OnW3zTM7oUN1ZVvj3V6rOl+ktUPjAaYo\n' + + 'CWJjth92xhDWEPZnC/4Gz2eRoTVtmx8u+/2vNPffQVgzzHznUxB+G5XeZmPk\n' + + 'z8oxxSxII8PNiAs5LizqPjyq2gEv25GlCsMXTYz60n/t/4G7Yc94yu8xD8u3\n' + + 'BpWluHC2eW0pYFcDfiNLfv0uJCrUcM7ATQRkq+dvAQgA7v7Zz4CZdPsd4jvB\n' + + 'uDwjop/Gvoz+rbvAdS3Xrsi+OTyrWAqidnXChhwExlUNelZ9v52lGxe1twwr\n' + + 'vxeQ4M0pv4oqSlZxhkqBCyj+E7ECR2WXG7ccLlzYOz3b5BXT+fEkmVsbVTjA\n' + + 'Kttjosm7FtY4igY2Hu4UlZZW8M1tYL1R/UegFeMYGY7aO7dcKeiP0NsDwm3c\n' + + '0SiU6/JlOXAIi/ZSKDJ4b5BPK6GFj5pNWr92/V7LejlZfoHAVDbb91tiPGdP\n' + + 'y3+r9T3IYsgUDLgOpPQn6o82Nctm6CnIZqAN12nJ1DEJP2JyLDedg9b5H+aa\n' + + 'FDZFc7yQ3In/QPtjHImydLt9NwARAQABwsB2BBgBCAAqBYJkq+dvCZBm9Bz6\n' + + 'DvB6DwKbDBYhBPkdSvwnOBuAJaOWAGb0HPoO8HoPAABRUQf+KoF4UXuseLBO\n' + + 'd0PD0+hEcnsYbaPWmPZtJPWusxPl6kt421luymPiThDXwaMVzRrmxkz0dNZ3\n' + + 'bUFYtS24t2BhlXZ6cGFNRjXrA9OV0kLg/kNm1vboQ1GL8qRV9CIjPVEpksQp\n' + + 'tOiYN+X+/2XdPJkaQpITHIFV067qWQSAKIonvOI8OJYOovGRQTInz0VE71Yn\n' + + 'SeiOilKBK+p2RN38jGr0PGWt740KJ6560FzfUwTAQzz9vrkYa+vEhWe+bzOd\n' + + 'YBpxj/BRTGR19DrKlGcFPdTYz5ADxCjBuCxXgoRCbBiWwh+iIstk5qkT8uHK\n' + + 'NQjzDvo3RO1cROQp0zsikladmzGZHQ==\n' + + '=q/e/\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA10lEQVR4AcXBsWnFMBSG0c8/brOD9kgfogHUGQIuAppInSsVAQ2gdbSD64fTXl4hMI/HPWf5fXxf3DDaxkxIlTuEM+FMOFt5MtqG1XvBipGpsp9YMWaskCqWcCacCWfL4+fzwogx8069FyzhTDgTzpavv3oxEVLlFaNtzAhnwplwtvIkpIpV9hMrxsxM7wUrHxVrtA1LOBPOhLM1pIo12oaVj4rV98JMPj6wRtuwQqpYwplwJpyt3BRjZiZQuUM4E86Es7XsJ1aMTIVUeUXZTyzhTDgTzv4BnGY033BWusUAAAAASUVORK5CYII=' + } + ], + pendingMembers: [ + { + wallet: 'eip155:0xaC6C69c657cF6022fa787B14BDdaA22936B56D65', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA2UlEQVR4AcXBQWoEIRBA0Z+ikOwNDHirbARPKDiLvkzOIATaC4iQbGt6ITSzqPc+np8/fxhpVazzcfCOr99vrK4FS3AmOBOcKRddCy9GwQoxszNHw+rKluBMcCY407QqO10L1hyNO9Kq7AjOBGeCMz0fB9YcjZ20KjtdC1bXghVixhKcCc4EZzpH446uhXfM0bAEZ4IzwZmGmLHmaOyEmNmZo7ETYsYSnAnOBGfKRVoVq2vBmqNxR1oV6+SV4ExwJjhTLroWdkLM7MzRsLoWrMCBJTgTnAnO/gGd1jrTKk/8EAAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xEf532414907E8c631307c0d501cDe6D1694bAF5e', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA00lEQVR4AcXBobHDMBBF0ZsdjftIDeGuIkzIaGsQC1MNQkZirsLcnaQCk3yqBOzMH4N3zu11f38I+GPiinacRAwxQ8wQS/zo1flSGqNenUgujVGvziiXxsgQM8QMscSPXBqjXp1RLo1Ir84ol0bEEDPEDLHkj4lI51uvzn/4YyJiiBlihlhqx0lkZ2U0Pxci+7YyasdJxBAzxAyx1KsT8W3lil6diCFmiBlit9f9/SHQq3NFLo2IIWaIGWKpVyeybyuj+bkQ2beV0VwXIoaYIWaI/QH8GTSs76EUEQAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x2F5f27B523C8888eA79b7FA80a9CbA6b6980784c', + publicKey: null, + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA0klEQVR4AcXBsW3DQAxA0W9CExjIDhogfboDCw9gICvcHmldcIAMoYLgJJ5CKzgto4KA4ILvXT5+Pl8kwydZqJHt60bl+ryRDZ9koUYmNBOaCc0u31+/L04INSrDJ2cIzYRmQrMl1Dhj+KQSapwhNBOaCc0WDvZ1o+ROZV83KtfnjUxoJjQTmi0c3B/OO+4PpxLKP0IzoZnQbBk+yUKNyvBJJdSoDJ9kQjOhmdBsCTWy4ZNKqFEZPqmEGpnQTGgmNFs4CDWy4ZN3hBoVoZnQTGj2BxvbMvuaMCXUAAAAAElFTkSuQmCC' + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkq+dvCZBm9Bz6DvB6DxYhBPkdSvwnOBuAJaOWAGb0HPoO\n' + + '8HoPAAD5ywf/cvaGM0DzcB22Q2FMzUZG4/ZmkN4OknvSj0d4hB/sPUIb9176\n' + + 'z+niFMjWZNFpIj8s36f16oMEZZ+Eleu9t6sECBxRDvO8pEwyByCXSmz8e/SH\n' + + 'Y659cvg5/A3bSe0FqR0VTI1o+Uz2BpnXG/P38C6D46btaIaJcr4cIh88wQ9J\n' + + 'lr05hOE7w/7Uo5OwyXala0NfB+8S4LIfpC2OlPOhyHQEJd2+WoFKb/6dO28D\n' + + 'TLuvgYJXJfc4R3ElcgFfm1N9ylG0Pt1F3c0C/k9bNokR2PVXgX2XSTQsx1rD\n' + + 'MCY/ePr93INyNZuTPcPlK87X6OTa2/gEW161vup2Xn2Did9HtL76Qw==\n' + + '=EkOP\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'intellectual_green_bat', + isPublic: true, + spaceDescription: 'sad_purple_pinniped', + spaceCreator: 'eip155:0xd1ab5Af3Be78bB1492099CE568761F0e706352a0', + spaceId: 'spaces:9dab226c7920fe06154d76f78dfe1187bdc4fda712cdd9a8b37cc6a99741a63b', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'ACTIVE' +} +``` + +
+ +--- + +### **To stop a space** + +```typescript +const response = await PushAPI.space.stop({ + spaceId: + 'spaces:108f766a5053e2b985d0843e806f741da5ad754d128aff0710e526eebc127afc', + env: 'staging', +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (stop space by space id) + +```typescript +// PushAPI_space_stop | Response - 200 OK +{ + members: [ + { + wallet: 'eip155:0xd1ab5Af3Be78bB1492099CE568761F0e706352a0', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSr528BCADI8kQcWkaw9PKmSrwCtPBDWj+wzPhmok9jAzxzb2+qAjSV\n' + + 'rYdIrnx6PAp1rMU6qoVg4cdDbCYPV+kCj8l3lUzH/a/SfPsDWpspA/ICWMeS\n' + + 'dMdGYxHLk2gsu0wRz69qoddXMY1h5eMZEyRnr2fsX/cy15mxO2IEHYnC2/rp\n' + + '06iFpx1T8k5HWgFDpyleWyMSQ7Bnn7GutrlHYEVtIGVfXDSkea8IDLLkzBEV\n' + + '3jlBUFhpsrlcvDwDYcMYOrqSBEtg1a+GMK+2Ye/hF37KUYTAPleKXeN0cYIs\n' + + 'Va8oleZK960XYfuy5SYCJav2kaAggNWQBie5G9C4H3h7FuFwWk8LH3DhABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKvnbwQLCQcICZBm9Bz6DvB6DwMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBPkdSvwnOBuAJaOWAGb0HPoO8HoPAAAkiQgAukm3owebckwr\n' + + 'xAR42r/+CBx1uoqM2ZeEAUeYtBF7sdLEsdxFrxl8wHKAbglZwtgWcfG95v2R\n' + + 'zLcBco3v9p0IuS6DZduIfhngZ49gpYwqFGyiCOvo+k14tuMbrbOZTTKp0uc6\n' + + 'icpTyP8/1U0nZrQmmSXyfh6Hgmx1OnW3zTM7oUN1ZVvj3V6rOl+ktUPjAaYo\n' + + 'CWJjth92xhDWEPZnC/4Gz2eRoTVtmx8u+/2vNPffQVgzzHznUxB+G5XeZmPk\n' + + 'z8oxxSxII8PNiAs5LizqPjyq2gEv25GlCsMXTYz60n/t/4G7Yc94yu8xD8u3\n' + + 'BpWluHC2eW0pYFcDfiNLfv0uJCrUcM7ATQRkq+dvAQgA7v7Zz4CZdPsd4jvB\n' + + 'uDwjop/Gvoz+rbvAdS3Xrsi+OTyrWAqidnXChhwExlUNelZ9v52lGxe1twwr\n' + + 'vxeQ4M0pv4oqSlZxhkqBCyj+E7ECR2WXG7ccLlzYOz3b5BXT+fEkmVsbVTjA\n' + + 'Kttjosm7FtY4igY2Hu4UlZZW8M1tYL1R/UegFeMYGY7aO7dcKeiP0NsDwm3c\n' + + '0SiU6/JlOXAIi/ZSKDJ4b5BPK6GFj5pNWr92/V7LejlZfoHAVDbb91tiPGdP\n' + + 'y3+r9T3IYsgUDLgOpPQn6o82Nctm6CnIZqAN12nJ1DEJP2JyLDedg9b5H+aa\n' + + 'FDZFc7yQ3In/QPtjHImydLt9NwARAQABwsB2BBgBCAAqBYJkq+dvCZBm9Bz6\n' + + 'DvB6DwKbDBYhBPkdSvwnOBuAJaOWAGb0HPoO8HoPAABRUQf+KoF4UXuseLBO\n' + + 'd0PD0+hEcnsYbaPWmPZtJPWusxPl6kt421luymPiThDXwaMVzRrmxkz0dNZ3\n' + + 'bUFYtS24t2BhlXZ6cGFNRjXrA9OV0kLg/kNm1vboQ1GL8qRV9CIjPVEpksQp\n' + + 'tOiYN+X+/2XdPJkaQpITHIFV067qWQSAKIonvOI8OJYOovGRQTInz0VE71Yn\n' + + 'SeiOilKBK+p2RN38jGr0PGWt740KJ6560FzfUwTAQzz9vrkYa+vEhWe+bzOd\n' + + 'YBpxj/BRTGR19DrKlGcFPdTYz5ADxCjBuCxXgoRCbBiWwh+iIstk5qkT8uHK\n' + + 'NQjzDvo3RO1cROQp0zsikladmzGZHQ==\n' + + '=q/e/\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA10lEQVR4AcXBsWnFMBSG0c8/brOD9kgfogHUGQIuAppInSsVAQ2gdbSD64fTXl4hMI/HPWf5fXxf3DDaxkxIlTuEM+FMOFt5MtqG1XvBipGpsp9YMWaskCqWcCacCWfL4+fzwogx8069FyzhTDgTzpavv3oxEVLlFaNtzAhnwplwtvIkpIpV9hMrxsxM7wUrHxVrtA1LOBPOhLM1pIo12oaVj4rV98JMPj6wRtuwQqpYwplwJpyt3BRjZiZQuUM4E86Es7XsJ1aMTIVUeUXZTyzhTDgTzv4BnGY033BWusUAAAAASUVORK5CYII=' + } + ], + pendingMembers: [ + { + wallet: 'eip155:0xaC6C69c657cF6022fa787B14BDdaA22936B56D65', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA2UlEQVR4AcXBQWoEIRBA0Z+ikOwNDHirbARPKDiLvkzOIATaC4iQbGt6ITSzqPc+np8/fxhpVazzcfCOr99vrK4FS3AmOBOcKRddCy9GwQoxszNHw+rKluBMcCY407QqO10L1hyNO9Kq7AjOBGeCMz0fB9YcjZ20KjtdC1bXghVixhKcCc4EZzpH446uhXfM0bAEZ4IzwZmGmLHmaOyEmNmZo7ETYsYSnAnOBGfKRVoVq2vBmqNxR1oV6+SV4ExwJjhTLroWdkLM7MzRsLoWrMCBJTgTnAnO/gGd1jrTKk/8EAAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xEf532414907E8c631307c0d501cDe6D1694bAF5e', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA00lEQVR4AcXBobHDMBBF0ZsdjftIDeGuIkzIaGsQC1MNQkZirsLcnaQCk3yqBOzMH4N3zu11f38I+GPiinacRAwxQ8wQS/zo1flSGqNenUgujVGvziiXxsgQM8QMscSPXBqjXp1RLo1Ir84ol0bEEDPEDLHkj4lI51uvzn/4YyJiiBlihlhqx0lkZ2U0Pxci+7YyasdJxBAzxAyx1KsT8W3lil6diCFmiBlit9f9/SHQq3NFLo2IIWaIGWKpVyeybyuj+bkQ2beV0VwXIoaYIWaI/QH8GTSs76EUEQAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x2F5f27B523C8888eA79b7FA80a9CbA6b6980784c', + publicKey: null, + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA0klEQVR4AcXBsW3DQAxA0W9CExjIDhogfboDCw9gICvcHmldcIAMoYLgJJ5CKzgto4KA4ILvXT5+Pl8kwydZqJHt60bl+ryRDZ9koUYmNBOaCc0u31+/L04INSrDJ2cIzYRmQrMl1Dhj+KQSapwhNBOaCc0WDvZ1o+ROZV83KtfnjUxoJjQTmi0c3B/OO+4PpxLKP0IzoZnQbBk+yUKNyvBJJdSoDJ9kQjOhmdBsCTWy4ZNKqFEZPqmEGpnQTGgmNFs4CDWy4ZN3hBoVoZnQTGj2BxvbMvuaMCXUAAAAAElFTkSuQmCC' + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkq+dvCZBm9Bz6DvB6DxYhBPkdSvwnOBuAJaOWAGb0HPoO\n' + + '8HoPAAD5ywf/cvaGM0DzcB22Q2FMzUZG4/ZmkN4OknvSj0d4hB/sPUIb9176\n' + + 'z+niFMjWZNFpIj8s36f16oMEZZ+Eleu9t6sECBxRDvO8pEwyByCXSmz8e/SH\n' + + 'Y659cvg5/A3bSe0FqR0VTI1o+Uz2BpnXG/P38C6D46btaIaJcr4cIh88wQ9J\n' + + 'lr05hOE7w/7Uo5OwyXala0NfB+8S4LIfpC2OlPOhyHQEJd2+WoFKb/6dO28D\n' + + 'TLuvgYJXJfc4R3ElcgFfm1N9ylG0Pt1F3c0C/k9bNokR2PVXgX2XSTQsx1rD\n' + + 'MCY/ePr93INyNZuTPcPlK87X6OTa2/gEW161vup2Xn2Did9HtL76Qw==\n' + + '=EkOP\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'intellectual_green_bat', + isPublic: true, + spaceDescription: 'sad_purple_pinniped', + spaceCreator: 'eip155:0xd1ab5Af3Be78bB1492099CE568761F0e706352a0', + spaceId: 'spaces:9dab226c7920fe06154d76f78dfe1187bdc4fda712cdd9a8b37cc6a99741a63b', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'ENDED' +} +``` + +
+ +--- + +### **To approve a space request** + +```typescript +const response = await PushAPI.space.approve({ + status: 'Approved', + account: '0x18C0Ab0809589c423Ac9eb42897258757b6b3d3d', + senderAddress: '0x873a538254f8162377296326BB3eDDbA7d00F8E9', // spaceId + env: 'staging', +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| status | 'Approved' | 'Approved' | flag for approving and rejecting space request, supports only approving for now| +| senderAddress_ | string | - | space request sender's address or spaceId of a space | +| signer\* | - | - | signer object | +| pgpPrivateKey | string | null | mandatory for users having pgp keys| +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (approve space request for a spaceId) + +```typescript +// PushAPI_space_approve | Response - 204 OK +``` + +
+ +--- + + +### **To add listeners to space** + +```typescript +const response = await PushAPI.space.addListeners({ + spaceId, + listeners: [ + `eip155:0x65585D8D2475194A26C0B187e6bED494E5D68d5F`, + `eip155:0xE99F29C1b2A658a478E7766D5A2bB28322326C45`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| listeners | Array | - | new listeners that needs to be added to the space. Don't add listeners which are already part of space | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (add Listeners to space) + +```typescript +// PushAPI_space_add_listeners | Response - 200 OK +{ + members: [{ + wallet: 'eip155:0x4Be8cFD08B330853A530DEBB72a2DAf4d4F3D2Ba', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSs51IBCAC+y8oXbU2YvfI7Z4xnSRfcPecRR+nO/XVLDbt30mbn1NU8\n' + + 'wHSXcuHLJTuU9yJy1t9AMB2SY8n/YWMFbeNICF0OQVINkvFS+8Ec/F42IIlb\n' + + 'StUY8rLS9pxTQoI3k1LnQKNL1krGiEuDl2ZT3l304aPGkF1sowu5w6xnzl/o\n' + + 'nb6cgc48jVqIgqoVUCnEoxc3GKdSORm35nl0RBDasFdFPJctnpg2n7hLofU1\n' + + 'RGOIzf/cITY7AE3nta0cqaFgNsO4rO0fXRwgDBAu66CtBG4Px2X8hT7IYMum\n' + + 'XJtCis3KvrmQAOhWrbAwmWjHbkSDSYigd39rmlht21GKf0/kfoILBgRfABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKznUgQLCQcICZDTsTetOyJa2gMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBHGBWhlF6JChmgQO7tOxN607IlraAADq/Af/XWeAagX5+JCX\n' + + 'ChzadMaUtI6m2F7nT8sJcJep/a0Ldyz6kPmP9k6kmWO+QXJwl4FrP3e7HPer\n' + + 'SjTeIWm0FJ2a+pRtF+lWk7xjIWJuZxbx79nOk98arde75fT+bebne1V0raUM\n' + + 'gXPQIc60++okAPif6vJVLAaSMNbCkv8+Lsy0mJqsjY3b9iMVKWHKb8XVvTuN\n' + + 'pobxVV4dLq53lrdNDIiwAWTlbxyuKLSEF4f+hIPJX3PAhquORinOubclUwTM\n' + + '+kEmE6VI3pW4VL1VRi10cDI6ruEVwqOwQyYcp9gSDKXFR6ZXz7t0hjUUhl+3\n' + + 'z6T7yqAjExW1O4tETVSbt3jg6DjaAM7ATQRkrOdSAQgArRRrLZees3xCYyBO\n' + + '9WDzy7XCM2FxmaIJs/ibWwTtD1ZVoc9NKeOx07FYwGiYjigY6FxxJHdr20IQ\n' + + '3xieIyBLZM2XAIXrsxq4M9GLG8R6nhd35BenjcvSGiZH1Rq0aXtFt9Fd7gc6\n' + + 'E8XpMcHPH8KEnf66sPz18vrVCdstVU4Qj2ZjH25ilfeGdMj2HHfDxVN8sRhl\n' + + 'AXAcwblQ+IVXGjuKw19T4zN874bcAaOmXfzxu3+2PtxVSR5uV03x1ln3ji+b\n' + + '+GF8atJMMHCqE0FC/dEciS+BWSQtv0D93XWjzExJeyhd7Z+I3BG8JPuJT5Yj\n' + + '4PxktEgwUxQc83JFFwED9knzyQARAQABwsB2BBgBCAAqBYJkrOdSCZDTsTet\n' + + 'OyJa2gKbDBYhBHGBWhlF6JChmgQO7tOxN607IlraAABLdggAhe1KLjtHTsUI\n' + + 'SR0K25EJ+9gXC7wmebve9wNZL22/Ud9hnyS77/VUmMNBgdPyhm/9ITMhVtTt\n' + + 'rRNo1AzsVKDn3/dW1kc+nSribOufxzMoBM7Bm918Zt/0/7wCegz0bp3EAoQ8\n' + + 'KEa2KPY9lSh2WtEDoA87D8JB1xwIfcR98vg5/AZ7VdtE88foSqXAm+6F85hz\n' + + 'nAASNBO9CCDvUofR28b4exT/aWX0qZxLAukgH7fnYC3KPVv+9ug6mdyJPsOZ\n' + + 'LFjF327UKLrBuQ6VRlfKF+XULJbtNPxckgwO1V/oxycq/M67acGoXgc2MgP/\n' + + '2qOkbiQC0ZxcA+Ze5TNNhuGWKv6d9g==\n' + + '=S9Ba\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA1UlEQVR4AcXBQU1FUQxF0f2bZ6gaIOkAC4yxUCRQHyRoqIo6wcJnesLgEgJJ17p9vDzeEe9vd046nZOo4eT59YYylhnLjGW3p8+HOwedzl9EDSfGMmOZsezim05HRQ2q0zmJGlSno6IGZSwzlhnLrk5HRQ2q01FRw0mno6IG1ekoY5mxzFh2RQ2q01FRw29EDarTUVGDMpYZy4xlV6ejogbV6aio4aTTUVGD6nSUscxYZiy7+KbT+U+dzomxzFhmLLv4QdSgnl9vHNWgOp0TY5mxzFj2BfKPPQUA5ipXAAAAAElFTkSuQmCC' + }], + pendingMembers: [{ + wallet: 'eip155:0x4d2eFB18383a48aCe19a198ae5228BB4bf854cec', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA9UlEQVR4AcXBoZHDMBCG0S87ZqEmooaiLmJJsNtwIyFuwzhERZgKmoqkhxz9HaCbmwP73u159w8iN0fVVFC5OT01FVRujqqpoIxgRjAj2JCbo6b1QE3LiDrpeywjF+vBRXOUEcwIZgQb+MW5zaiaCl3NUdN60GMEM4IZwYaaChfNUdN6cNGcnmk9UOc2o2oqKCOYEcwINuTmqJoKF835i3ObUTUVVG6OMoIZwYxgt+fdP4jHMqJe+xuVm9NTU0E9lhH12t8oI5gRzAg28OXcZlTeuKip0JObo06+7AVlBDOCGcFuz7t/6MjN+Y+aCj1GMCOYEewHE5pCbf3G8WQAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x8E50Bfb57f803814c242c5a25890f5F0c13304fF', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA20lEQVR4AcXBsWkDQRCG0W+Gy53pkgVVsiXYFVx2rsANiCtEmQoxbCHmYBNd6gLW6aBgjDDmf89eXr8GiW6VqIxGplslKqORccQcMUdsWued6Ho/k+lW+Yt13okcMUfMEZt4sM470YUb0XYsZC6nG9HKTsYRc8Qcsel6P5PpVnnGdixEZTQyjpgj5ohNPOhWyZTRyHSrRN0qURmNyBFzxBwx+34rg0QZjahbJVNGI+pWyThijpgjNvGLbpWojEamW+UZjpgj5ojZx/vnINiOhf90Od2IHDFHzBH7AWIQNGL6hyehAAAAAElFTkSuQmCC' + }, + { + wallet: 'eip155:0xaA6E4434D881D2bDEea891AE127313AE5515a06B', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAyklEQVR4AcXBsZGDMABE0c8OqQPGZShzCdCCVNZVIhVAYrpQ6g48lMClkgMlBPve9HjtF0bCTJgJszmXykiKgTtyqYwIM2EmzOYUAyO5VO5IMTAizISZMJu/70rrOOmkGLgjl0prXegIM2EmzKbHa79o5FIZSTEwkktlJMVAS5gJM2E282Nd6Dy3QCuXykiKgdb3XRkRZsJMmE375++isS50jpNOioGRXCqtdaFznHSEmTATZjM/nluglUvljucWaOVSaQkzYSbM/gGGCDCC/3c1nwAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xf6106dd699B6e40f1E822c38DDA459F533470b11', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAwUlEQVR4AcXBsU2DMRSF0S9XHoIFIipmIEW2sPQ6pmGEdJa8BYXXsOgYxKF9afzrr+45l++39uSEUGenrcoZwkyYCbPCgVAna6uyE+pkbVV2hJkwE2Yl1MnaqmT364Ps5/eLnfv1QRZzkIU6mTATZsKscCDm4IXYijk4Q5gJM2FWONDeb7yYbLX3G1nMwY4wE2bCrHAg5iALdbYmpwgzYSbMLh+ff0+MhJkwE2Yl5iALdXbaquyEOjttVTJhJsyE2T84uix63kKmNgAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xAF3d4989652a6ED5554b6191c555525977424Cc9', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA3UlEQVR4AcXBsW3DMBCG0c8/tEMmUClkBDVaQAWHIKAZWHAGAxyChZDejbOCkcrDOO3ZxQlGENx7p4/t64Gj58JfpFbxiGAimAg2cOB6uWHNy4TnernxDhFMBBPBBl70XHg2YaVW8fRcsOalYKVWsUQwEUwEGziQWsXqueBJrWL1XPCIYCKYCHb6/vl8YKRW+U89FywRTAQTwQZebOOK53zf8Wzjim/CEsFEMBFs4MD5vmP1XPCktmNt44pHBBPBRLAhtYrVc+HZipXajmcbV6x5mbBSq1gimAgmgv0CTksv6eJNDqkAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x2ccBeEf6e30dF46D0A7Ee79Bc66FBF3beA7EeA5A', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA00lEQVR4AcXBIW6AMBiG4XdfmnAYboLlCE3NFBLX4JB40hMsWM4x08OgNvsXUbMs//N8fH59/2DksfCfthqxhDPhTDgLvGw1Yq3nhLWnm571nLD2dNMjnAlnwlnIY8HaasQajplGpWs4ZhqVRh4LlnAmnAln4VkuGinSs54TXcdMz7NcWMKZcCachT3dWHksWM9yYQ3HTM+zXFj5oLGlG0s4E86Es8DLViONFLEyhZ493TQqXcKZcCacCWfCmXAmnAVe8lj4izwWerYasYQz4Uw4+wXktDHpzVVJlwAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x65585D8D2475194A26C0B187e6bED494E5D68d5F', + publicKey: null, + isSpeaker: false, + image: null + }, + { + wallet: 'eip155:0xE99F29C1b2A658a478E7766D5A2bB28322326C45', + publicKey: null, + isSpeaker: false, + image: null + }, + { + wallet: 'eip155:0xa145b34443e28C8f718Cd0691Dc41A81E0d0A857', + publicKey: null, + isSpeaker: false, + image: null + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkrOdUCZDTsTetOyJa2hYhBHGBWhlF6JChmgQO7tOxN607\n' + + 'IlraAAAqUQf9FvAtNouG7+2YSyyx7eiHRJZroDPFohH/F2xyc+oJkgh40p2y\n' + + 'hyKw+DSp0FA+IiT95/y8RbGDUrNFz+/kdMfZWCEYFim3Cy+c5k1/YNc8qxx6\n' + + 'VLwef+2YZepC1pSS9K0zbu04uVPWrNmDa5lHXqzTx/mOxWlxLD0NfpI60csE\n' + + 'iQx57duy2gMeW9MwOKSFjOSnWHKy7AySm/vBwZ9Rj4gnOhsvwbAfLprQQf4G\n' + + 'cUaxG/HOb0c/8Ugews0Z1uDJFmGKjT5R5CR63vPo5qDGQwWkm+LYpshCIV+K\n' + + 'ofLepDqQRuEFa7VyUlDOvMcF15LtlvAhwhkIVHvTGjXZC91e8/IUsQ==\n' + + '=UpR2\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'weird_moccasin_alligator', + isPublic: true, + spaceDescription: 'equivalent_blue_armadillo', + spaceCreator: 'eip155:0x4Be8cFD08B330853A530DEBB72a2DAf4d4F3D2Ba', + spaceId: 'spaces:d37c4e303a2ff194e546d3af94353ec829324a578ebffbeadebd1ba91ab88548', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} +``` + +
+ +--- + +### **To remove listeners from space** + +```typescript +const response = await PushAPI.space.removeListeners({ + spaceId, + listeners: [ + `eip155:0xB12869BD3a0F9109222D67ba71e8b109B46908f9`, + `eip155:0x2E3af36E1aC6EEEA2C0d59E43Be1926aBB9eE0BD`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| listeners | Array | - | existing listeners that needs to be removed from the space. Don't add listeners which are not part of space | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (remove Listeners from space) + +```typescript +// PushAPI_space_from_speakers | Response - 200 OK +{ + members: [{ + wallet: 'eip155:0x5908D89B1390ec5833001b86302B868A808D506D', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSs6YABCADC4ldJKGpZ0Z+JJwA1t/1JWp5+dnR98nr7RHPX8eEGxIhL\n' + + 'gtx5TZmek2BcGzNcg66+GEyC4np9USaCZ4/YC9ZMLw8BQKzhOcd3ZILyGtGV\n' + + 'BijBNwjPIbQcy5/cXVtfKCvf303BDYddPYuJ1xFAh7kpvhcR4a72CSpeyEjM\n' + + 'UndteAVTIxqwdpnXIdqpwu6HrSJ089GpHV+XeaDo4Uhg+iHJsCRJy2VJ5m61\n' + + 'CwGx55f3ror6rAXQd+hEx+keLxYINNJLLvfvE9IGsIbKRFZx+emjXQZusbJp\n' + + 'zXYhJnEeHPLVDjWhzo8Q3/4gvOz8m6a+A9sl49sqodLdxVlXQ7d4CuylABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKzpgAQLCQcICZCaDezdj8j4SwMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBGZpOFBNtTj1Oqt695oN7N2PyPhLAACCLgf/dB412nDRcOxR\n' + + 'dNSj2AYknJ+NKeX38KuksyR6wypnaJWpapmIeZCfFjeoBjuBCPd6unvN/IlZ\n' + + 'zPwl66lO5GKJxDaDd1/infxM/dbtFQSESLXlweRLQ/v1+plsntrBUyvbY4uH\n' + + 'Mh9PImYsLY+zo8P5mpBV5AGAMA6R9qmu3axH/MnKVdB0Ky6C/jP+7lPs/QVT\n' + + 'qsISyyI1E9E6Oivzxmao1axfXLdEvICHb6uD0R4p5SUVqHJX41OwM8BFevhK\n' + + '07Hi+c7NhUWp0sxXEOs6dneJZwerCD3EahutpP1Oyt5T8MZitysn2yJ+s5ks\n' + + 'SZza+x8OmCMcMZfZnIsJNnIUvPboP87ATQRkrOmAAQgAteDgsJJ0ftPD+P15\n' + + 'rKgkLuSCD2iwQgm2k8/ZDaXJBsdm4sJYTt2y0ckx7MRpXgLuIyidOGctqVL6\n' + + '/Rl2Hfl30JQPok5cYmYLENVuFz94MEvgDOo8jacyfPdLGPMWZMLRojyM/Yvs\n' + + 'nhDZ8if3zEstP4h3HcpdT+PWSmsJWjrq57la4vKbfILtKfTBaf8sibm5UuZA\n' + + '5Y/SIPxfVC+ybCPAjo4tpDYP901V+wxXDJ8BlZ4AaVvk20MYMzuAjBna+iwD\n' + + 'f0j4CccEabd2EVtAQQcMCg2yTjOT22Dt0jfpDuohDNaXDhX2ZQlJIdlSLCEI\n' + + 'a3c7g+uU9bnNqt7LHPgMzLYKnwARAQABwsB2BBgBCAAqBYJkrOmACZCaDezd\n' + + 'j8j4SwKbDBYhBGZpOFBNtTj1Oqt695oN7N2PyPhLAAD2vQgAu9+sd4AT5b6c\n' + + 'mWOaQBXz2XVfJXYQFNlBdOF23reycF9r7vDAKSRpeyMSyOfRAi0qdLynQ1dN\n' + + 'MXV/gfO0G9dzFu513P/Y1sZxQi0uLRKL9hMcgEQ8FLo8/PGfVcoLfQASryGj\n' + + 'Z8ybCFqiXocGpt2VkkK4wwgv+ZwZ8M1ubz0Boby6A1/kTYs/6ll+QekpB4ao\n' + + 'kJKw3DWvVNR/xODFfMQcClvzAtqwfxhTZXBMbZ4vAG5m1ExGmA15cGXrAfwV\n' + + 'nR2vOhPYDeZGbBKktM3xfDts75N2NF/TBpvazV2DTKpkLqvVitFHWvSMMpVd\n' + + 'dwk9tEOmBlj2AoYATvQ9kKHRTD27Wg==\n' + + '=IXzf\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA1klEQVR4AcXBoXHEMBRF0Zs3oqpHNYgJecZdGKYMd5GZRWaCwaohZbiAhP5d8HeC3jkfnz/fvwSTRua+DjJ1nGQ6i0iYCTNhVnjRWUSTRlTHyX90FhlhJsyEWeHFpJG5r4NMHSfRpBF1FpEwE2bCrPDGfR1E29jJPK6DqI6TjDATZsKsTBqZOk6iSa6ORmbSiISZMBNmpbOIHtcXUR0nUWeRmTSi+zqItrETCTNhJswKL7ax82wRTRqZzuLJ2MkIM2EmzApvTBpRZ5GZNKLOIiPMhJkw+wPV2i2sD43hKwAAAABJRU5ErkJggg==' + }], + pendingMembers: [{ + wallet: 'eip155:0xC1469cB7b59d16dC887D4C11faB3E3C0abBeA12C', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA30lEQVR4AcXBsWnFMBSG0e9dBAGDPUs6LeAFNIEb1x5GtRtDei3gBQzZIFtYYEj10t73CkFw8Z/z+Pj+euJs14iXlsodJfd4U7fjGWKGmCEWzjnilUzTsB60nHOk5ZwjniFmiBligTdTt+MlIt52jbRVvKnb8RIRzxAzxAyxx+/nzxMhQ8wQM8RCyT0taancUXJPiyFmiBligTdTt+NNKy/OOdIyrAct2zXiGWKGmCEW0lJ5kUe8tFT+45wjXsk9XloqniFmiBliYVgPvHOOeCX33JGWijesB54hZogZYn8uFTTKoy9pgwAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xccF7a3131E0E73F83Bc457C27494411a57f23248', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA9ElEQVR4AcXBIWoEMRSA4X8fw6qayBW9zULVEBFygLqcqMwdhlBCbKjqXSLjY7b2UZEVpbzvu3x8vT5QShhoqUa0Yz9ZSTWiHfuJ5rNDE4wJxgRjl8/v9wdKn43/dLve0QRjgjHB2NZnQ7td72h9NrQSBis+O7Tb9Y7WZ0MTjAnGBGMbv/TZ0EoYaD47VkoYaD43VgRjgjHB2MYTqUa0Yz9ZSTWi9dlYEYwJxgRjlzf38kDx2aGVMNBSjawc+4nms0MrYaAJxgRjgrGNJ1KNaH02VlKNaH02VgRjgjHB2OazQythoKXKn5Qw0Hx2aIIxwZhg7Ae2cUcV4Bl8pAAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x052aD82D3a7b4DAb5b9BcFED771D28703a6faadf', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAy0lEQVR4AcXBoXFDQQxF0RtlkZsQNjHICKYYV7DFCAW6II2BycfbhklCNR/sTNA75+Pn+/MXIUPMEDPEBifhSVdr0oUnO7UmXXjS1Zp0hpghZogZYoaYIWaIDU5qTbrwpHtfnuyEJ12tyY4hZogZYiM86WpNdl7Hg53wL3bCk84QM8QMscFJeNLVmnS3652dOiZdeLJjiBlihtioNenCky486eqY7IQnO7UmnSFmiBliIzzpak262/XOf7wvT7rX8aALTzpDzBAzxP4AMOQyARcWaToAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x956f73E5a3BF0D19299BF74bD6dc819D7f775eC7', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA20lEQVR4AcXBsYnDMBiG4dc/nsHgHeJWS1x7G6QzqNQUKlUHLn12ONdqNYTBS/ja/xqBCeF7nmFbbydODoVPSjXiGWKGmCE2Pu8vvPT45pOe9xeeIWaIGWLj0Xa8HAo9qUZ6cih0tR3PEDPEDLFhW28nTg4FL9XIO3IoeKlGPEPMEDPEhq+f3xNnWmZ6jrbTMy0zPUfb8QwxQ8wQG6dlxjvajpdq5JLKPzkUvGmZ8QwxQ8wQG4+246Ua8XIovCPViJcpeIaYIWaIDdt6O7kgh0JPqpErDDFDzBD7AzabOPmHFg/aAAAAAElFTkSuQmCC' + }, + { + wallet: 'eip155:0x19da526eD1a57E07D48aa25aDa6cbA7E41FF3129', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAyUlEQVR4AcXBsY1CQQxF0cvTFEHuNn4jxB6JJggpw5Mh/UZogmByumBTi2DQahf5nMN2vr1IjvtG1ufgL8Kc7Hm6k4liopgo1i7XB1nsG990uT7IRDFRTBRrfBDmZH0OVsKc3xDFRDFRrPFBn4MszFnpc5CFOSuimCgmih228+1Fctw3vul5upOJYqKYKNaO+0bW5yALc7I+BythTtbnIAtzMlFMFBPFGm/CnP8U5qyIYqKYKNZ40+dgJcxZ6XOwEuZkopgoJor9AIckL2mEiBQrAAAAAElFTkSuQmCC' + }, + { + wallet: 'eip155:0x77059B40Ec974883b98a23eef519b4076D1Cf9F1', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAw0lEQVR4AcXBsY0CMRRF0cuTQ6rYaQFiAvdBYMkFkFEAwWYTryxZ2kIcEE8N1MKmH4JJRuw7Z/d7uD0JRu1EuRW2GLUT5VaIhJkwE2a788/XEyNhJsyEWcqtEI3a+aTcCpEwE2bCLI3aia77E9EyT2xxvDyIvmsnEmbCTJgl3izzRDRqJ8qtsGbUzou58KLeiYSZMBNmKbfCf8qtEAkzYSbM0qidTxq1s0aYCTNhlq77E9EyT2yRW2HN8fIgEmbCTJj9AUPBKWCCQlIAAAAAAElFTkSuQmCC' + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkrOmCCZCaDezdj8j4SxYhBGZpOFBNtTj1Oqt695oN7N2P\n' + + 'yPhLAAD+iwf/dvaRCTwXKGH6iUe49NpyTHMaD6ZwaLerk+K4Ojehbdoo0mDf\n' + + 'aOu/MR8wfqk49h2436rcMmyeM5avcMgmtGUmIdy/6hCZ6zxR/3E5t/vq5UfO\n' + + '3YFO1VLghR5cTYqR9bMLFkvvCB4P29rnaok2QVKTBZLfyAM4wu1h2DDBESoz\n' + + 'SS+ZtQLPz6/y7gOQobO0zbwBPmy8MpVVu1wxht+sneOMvZX+5al679nQbwNL\n' + + 'oCcU3UKrlqMhuFgMTCKx99VLcc4JbhBf2M+IHf78NtQ9mcQC/X+gxRfp6f+p\n' + + '2RePQzkmUH5vqXjzcUsNBWJPOyjl09/IZWWwaeiUjsPazjxqDtYNHg==\n' + + '=H4X4\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'sheer_ivory_ox', + isPublic: true, + spaceDescription: 'specific_green_alpaca', + spaceCreator: 'eip155:0x5908D89B1390ec5833001b86302B868A808D506D', + spaceId: 'spaces:bc96011f182e2c86ad68aaf4c95c4a916c808088370cb0ba294f9168e2ff6328', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} +``` + +
+ +--- + + +### **To add speakers to space** + +```typescript +const response = await PushAPI.space.addSpeakers({ + spaceId, + listeners: [ + `eip155:0x65585D8D2475194A26C0B187e6bED494E5D68d5F`, + `eip155:0xE99F29C1b2A658a478E7766D5A2bB28322326C45`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| speakers | Array | - | new speakers that needs to be added to the space. Don't add speakers which are already part of space | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (add Speakers to space) + +```typescript +// PushAPI_space_add_speakers | Response - 200 OK +{ + members: [{ + wallet: 'eip155:0x4Be8cFD08B330853A530DEBB72a2DAf4d4F3D2Ba', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSs51IBCAC+y8oXbU2YvfI7Z4xnSRfcPecRR+nO/XVLDbt30mbn1NU8\n' + + 'wHSXcuHLJTuU9yJy1t9AMB2SY8n/YWMFbeNICF0OQVINkvFS+8Ec/F42IIlb\n' + + 'StUY8rLS9pxTQoI3k1LnQKNL1krGiEuDl2ZT3l304aPGkF1sowu5w6xnzl/o\n' + + 'nb6cgc48jVqIgqoVUCnEoxc3GKdSORm35nl0RBDasFdFPJctnpg2n7hLofU1\n' + + 'RGOIzf/cITY7AE3nta0cqaFgNsO4rO0fXRwgDBAu66CtBG4Px2X8hT7IYMum\n' + + 'XJtCis3KvrmQAOhWrbAwmWjHbkSDSYigd39rmlht21GKf0/kfoILBgRfABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKznUgQLCQcICZDTsTetOyJa2gMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBHGBWhlF6JChmgQO7tOxN607IlraAADq/Af/XWeAagX5+JCX\n' + + 'ChzadMaUtI6m2F7nT8sJcJep/a0Ldyz6kPmP9k6kmWO+QXJwl4FrP3e7HPer\n' + + 'SjTeIWm0FJ2a+pRtF+lWk7xjIWJuZxbx79nOk98arde75fT+bebne1V0raUM\n' + + 'gXPQIc60++okAPif6vJVLAaSMNbCkv8+Lsy0mJqsjY3b9iMVKWHKb8XVvTuN\n' + + 'pobxVV4dLq53lrdNDIiwAWTlbxyuKLSEF4f+hIPJX3PAhquORinOubclUwTM\n' + + '+kEmE6VI3pW4VL1VRi10cDI6ruEVwqOwQyYcp9gSDKXFR6ZXz7t0hjUUhl+3\n' + + 'z6T7yqAjExW1O4tETVSbt3jg6DjaAM7ATQRkrOdSAQgArRRrLZees3xCYyBO\n' + + '9WDzy7XCM2FxmaIJs/ibWwTtD1ZVoc9NKeOx07FYwGiYjigY6FxxJHdr20IQ\n' + + '3xieIyBLZM2XAIXrsxq4M9GLG8R6nhd35BenjcvSGiZH1Rq0aXtFt9Fd7gc6\n' + + 'E8XpMcHPH8KEnf66sPz18vrVCdstVU4Qj2ZjH25ilfeGdMj2HHfDxVN8sRhl\n' + + 'AXAcwblQ+IVXGjuKw19T4zN874bcAaOmXfzxu3+2PtxVSR5uV03x1ln3ji+b\n' + + '+GF8atJMMHCqE0FC/dEciS+BWSQtv0D93XWjzExJeyhd7Z+I3BG8JPuJT5Yj\n' + + '4PxktEgwUxQc83JFFwED9knzyQARAQABwsB2BBgBCAAqBYJkrOdSCZDTsTet\n' + + 'OyJa2gKbDBYhBHGBWhlF6JChmgQO7tOxN607IlraAABLdggAhe1KLjtHTsUI\n' + + 'SR0K25EJ+9gXC7wmebve9wNZL22/Ud9hnyS77/VUmMNBgdPyhm/9ITMhVtTt\n' + + 'rRNo1AzsVKDn3/dW1kc+nSribOufxzMoBM7Bm918Zt/0/7wCegz0bp3EAoQ8\n' + + 'KEa2KPY9lSh2WtEDoA87D8JB1xwIfcR98vg5/AZ7VdtE88foSqXAm+6F85hz\n' + + 'nAASNBO9CCDvUofR28b4exT/aWX0qZxLAukgH7fnYC3KPVv+9ug6mdyJPsOZ\n' + + 'LFjF327UKLrBuQ6VRlfKF+XULJbtNPxckgwO1V/oxycq/M67acGoXgc2MgP/\n' + + '2qOkbiQC0ZxcA+Ze5TNNhuGWKv6d9g==\n' + + '=S9Ba\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA1UlEQVR4AcXBQU1FUQxF0f2bZ6gaIOkAC4yxUCRQHyRoqIo6wcJnesLgEgJJ17p9vDzeEe9vd046nZOo4eT59YYylhnLjGW3p8+HOwedzl9EDSfGMmOZsezim05HRQ2q0zmJGlSno6IGZSwzlhnLrk5HRQ2q01FRw0mno6IG1ekoY5mxzFh2RQ2q01FRw29EDarTUVGDMpYZy4xlV6ejogbV6aio4aTTUVGD6nSUscxYZiy7+KbT+U+dzomxzFhmLLv4QdSgnl9vHNWgOp0TY5mxzFj2BfKPPQUA5ipXAAAAAElFTkSuQmCC' + }], + pendingMembers: [{ + wallet: 'eip155:0x4d2eFB18383a48aCe19a198ae5228BB4bf854cec', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA9UlEQVR4AcXBoZHDMBCG0S87ZqEmooaiLmJJsNtwIyFuwzhERZgKmoqkhxz9HaCbmwP73u159w8iN0fVVFC5OT01FVRujqqpoIxgRjAj2JCbo6b1QE3LiDrpeywjF+vBRXOUEcwIZgQb+MW5zaiaCl3NUdN60GMEM4IZwYaaChfNUdN6cNGcnmk9UOc2o2oqKCOYEcwINuTmqJoKF835i3ObUTUVVG6OMoIZwYxgt+fdP4jHMqJe+xuVm9NTU0E9lhH12t8oI5gRzAg28OXcZlTeuKip0JObo06+7AVlBDOCGcFuz7t/6MjN+Y+aCj1GMCOYEewHE5pCbf3G8WQAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x8E50Bfb57f803814c242c5a25890f5F0c13304fF', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA20lEQVR4AcXBsWkDQRCG0W+Gy53pkgVVsiXYFVx2rsANiCtEmQoxbCHmYBNd6gLW6aBgjDDmf89eXr8GiW6VqIxGplslKqORccQcMUdsWued6Ho/k+lW+Yt13okcMUfMEZt4sM470YUb0XYsZC6nG9HKTsYRc8Qcsel6P5PpVnnGdixEZTQyjpgj5ohNPOhWyZTRyHSrRN0qURmNyBFzxBwx+34rg0QZjahbJVNGI+pWyThijpgjNvGLbpWojEamW+UZjpgj5ojZx/vnINiOhf90Od2IHDFHzBH7AWIQNGL6hyehAAAAAElFTkSuQmCC' + }, + { + wallet: 'eip155:0xaA6E4434D881D2bDEea891AE127313AE5515a06B', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAyklEQVR4AcXBsZGDMABE0c8OqQPGZShzCdCCVNZVIhVAYrpQ6g48lMClkgMlBPve9HjtF0bCTJgJszmXykiKgTtyqYwIM2EmzOYUAyO5VO5IMTAizISZMJu/70rrOOmkGLgjl0prXegIM2EmzKbHa79o5FIZSTEwkktlJMVAS5gJM2E282Nd6Dy3QCuXykiKgdb3XRkRZsJMmE375++isS50jpNOioGRXCqtdaFznHSEmTATZjM/nluglUvljucWaOVSaQkzYSbM/gGGCDCC/3c1nwAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xf6106dd699B6e40f1E822c38DDA459F533470b11', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAwUlEQVR4AcXBsU2DMRSF0S9XHoIFIipmIEW2sPQ6pmGEdJa8BYXXsOgYxKF9afzrr+45l++39uSEUGenrcoZwkyYCbPCgVAna6uyE+pkbVV2hJkwE2Yl1MnaqmT364Ps5/eLnfv1QRZzkIU6mTATZsKscCDm4IXYijk4Q5gJM2FWONDeb7yYbLX3G1nMwY4wE2bCrHAg5iALdbYmpwgzYSbMLh+ff0+MhJkwE2Yl5iALdXbaquyEOjttVTJhJsyE2T84uix63kKmNgAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xAF3d4989652a6ED5554b6191c555525977424Cc9', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA3UlEQVR4AcXBsW3DMBCG0c8/tEMmUClkBDVaQAWHIKAZWHAGAxyChZDejbOCkcrDOO3ZxQlGENx7p4/t64Gj58JfpFbxiGAimAg2cOB6uWHNy4TnernxDhFMBBPBBl70XHg2YaVW8fRcsOalYKVWsUQwEUwEGziQWsXqueBJrWL1XPCIYCKYCHb6/vl8YKRW+U89FywRTAQTwQZebOOK53zf8Wzjim/CEsFEMBFs4MD5vmP1XPCktmNt44pHBBPBRLAhtYrVc+HZipXajmcbV6x5mbBSq1gimAgmgv0CTksv6eJNDqkAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x2ccBeEf6e30dF46D0A7Ee79Bc66FBF3beA7EeA5A', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA00lEQVR4AcXBIW6AMBiG4XdfmnAYboLlCE3NFBLX4JB40hMsWM4x08OgNvsXUbMs//N8fH59/2DksfCfthqxhDPhTDgLvGw1Yq3nhLWnm571nLD2dNMjnAlnwlnIY8HaasQajplGpWs4ZhqVRh4LlnAmnAln4VkuGinSs54TXcdMz7NcWMKZcCachT3dWHksWM9yYQ3HTM+zXFj5oLGlG0s4E86Es8DLViONFLEyhZ493TQqXcKZcCacCWfCmXAmnAVe8lj4izwWerYasYQz4Uw4+wXktDHpzVVJlwAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x65585D8D2475194A26C0B187e6bED494E5D68d5F', + publicKey: null, + isSpeaker: true, + image: null + }, + { + wallet: 'eip155:0xE99F29C1b2A658a478E7766D5A2bB28322326C45', + publicKey: null, + isSpeaker: true, + image: null + }, + { + wallet: 'eip155:0xa145b34443e28C8f718Cd0691Dc41A81E0d0A857', + publicKey: null, + isSpeaker: false, + image: null + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkrOdUCZDTsTetOyJa2hYhBHGBWhlF6JChmgQO7tOxN607\n' + + 'IlraAAAqUQf9FvAtNouG7+2YSyyx7eiHRJZroDPFohH/F2xyc+oJkgh40p2y\n' + + 'hyKw+DSp0FA+IiT95/y8RbGDUrNFz+/kdMfZWCEYFim3Cy+c5k1/YNc8qxx6\n' + + 'VLwef+2YZepC1pSS9K0zbu04uVPWrNmDa5lHXqzTx/mOxWlxLD0NfpI60csE\n' + + 'iQx57duy2gMeW9MwOKSFjOSnWHKy7AySm/vBwZ9Rj4gnOhsvwbAfLprQQf4G\n' + + 'cUaxG/HOb0c/8Ugews0Z1uDJFmGKjT5R5CR63vPo5qDGQwWkm+LYpshCIV+K\n' + + 'ofLepDqQRuEFa7VyUlDOvMcF15LtlvAhwhkIVHvTGjXZC91e8/IUsQ==\n' + + '=UpR2\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'weird_moccasin_alligator', + isPublic: true, + spaceDescription: 'equivalent_blue_armadillo', + spaceCreator: 'eip155:0x4Be8cFD08B330853A530DEBB72a2DAf4d4F3D2Ba', + spaceId: 'spaces:d37c4e303a2ff194e546d3af94353ec829324a578ebffbeadebd1ba91ab88548', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} +``` + +
+ +--- + + +### **To remove speakers from space** + +```typescript +const response = await PushAPI.space.removeSpeakers({ + spaceId, + speakers: [ + `eip155:0xB12869BD3a0F9109222D67ba71e8b109B46908f9`, + `eip155:0x2E3af36E1aC6EEEA2C0d59E43Be1926aBB9eE0BD`, + ], + signer: signer, + pgpPrivateKey: pgpDecrpyptedPvtKey, + env: env as ENV, + }); + +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| spaceId_ | string | - | space id | +| speakers | Array | - | existing speakers that needs to be removed from the space. Don't add speakers which are not part of space | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +
+ Expected response (remove Speakers to space) + +```typescript +// PushAPI_space_remove_speakers | Response - 200 OK +{ + members: [{ + wallet: 'eip155:0x5908D89B1390ec5833001b86302B868A808D506D', + publicKey: '-----BEGIN PGP PUBLIC KEY BLOCK-----\n' + + '\n' + + 'xsBNBGSs6YABCADC4ldJKGpZ0Z+JJwA1t/1JWp5+dnR98nr7RHPX8eEGxIhL\n' + + 'gtx5TZmek2BcGzNcg66+GEyC4np9USaCZ4/YC9ZMLw8BQKzhOcd3ZILyGtGV\n' + + 'BijBNwjPIbQcy5/cXVtfKCvf303BDYddPYuJ1xFAh7kpvhcR4a72CSpeyEjM\n' + + 'UndteAVTIxqwdpnXIdqpwu6HrSJ089GpHV+XeaDo4Uhg+iHJsCRJy2VJ5m61\n' + + 'CwGx55f3ror6rAXQd+hEx+keLxYINNJLLvfvE9IGsIbKRFZx+emjXQZusbJp\n' + + 'zXYhJnEeHPLVDjWhzo8Q3/4gvOz8m6a+A9sl49sqodLdxVlXQ7d4CuylABEB\n' + + 'AAHNAMLAigQQAQgAPgWCZKzpgAQLCQcICZCaDezdj8j4SwMVCAoEFgACAQIZ\n' + + 'AQKbAwIeARYhBGZpOFBNtTj1Oqt695oN7N2PyPhLAACCLgf/dB412nDRcOxR\n' + + 'dNSj2AYknJ+NKeX38KuksyR6wypnaJWpapmIeZCfFjeoBjuBCPd6unvN/IlZ\n' + + 'zPwl66lO5GKJxDaDd1/infxM/dbtFQSESLXlweRLQ/v1+plsntrBUyvbY4uH\n' + + 'Mh9PImYsLY+zo8P5mpBV5AGAMA6R9qmu3axH/MnKVdB0Ky6C/jP+7lPs/QVT\n' + + 'qsISyyI1E9E6Oivzxmao1axfXLdEvICHb6uD0R4p5SUVqHJX41OwM8BFevhK\n' + + '07Hi+c7NhUWp0sxXEOs6dneJZwerCD3EahutpP1Oyt5T8MZitysn2yJ+s5ks\n' + + 'SZza+x8OmCMcMZfZnIsJNnIUvPboP87ATQRkrOmAAQgAteDgsJJ0ftPD+P15\n' + + 'rKgkLuSCD2iwQgm2k8/ZDaXJBsdm4sJYTt2y0ckx7MRpXgLuIyidOGctqVL6\n' + + '/Rl2Hfl30JQPok5cYmYLENVuFz94MEvgDOo8jacyfPdLGPMWZMLRojyM/Yvs\n' + + 'nhDZ8if3zEstP4h3HcpdT+PWSmsJWjrq57la4vKbfILtKfTBaf8sibm5UuZA\n' + + '5Y/SIPxfVC+ybCPAjo4tpDYP901V+wxXDJ8BlZ4AaVvk20MYMzuAjBna+iwD\n' + + 'f0j4CccEabd2EVtAQQcMCg2yTjOT22Dt0jfpDuohDNaXDhX2ZQlJIdlSLCEI\n' + + 'a3c7g+uU9bnNqt7LHPgMzLYKnwARAQABwsB2BBgBCAAqBYJkrOmACZCaDezd\n' + + 'j8j4SwKbDBYhBGZpOFBNtTj1Oqt695oN7N2PyPhLAAD2vQgAu9+sd4AT5b6c\n' + + 'mWOaQBXz2XVfJXYQFNlBdOF23reycF9r7vDAKSRpeyMSyOfRAi0qdLynQ1dN\n' + + 'MXV/gfO0G9dzFu513P/Y1sZxQi0uLRKL9hMcgEQ8FLo8/PGfVcoLfQASryGj\n' + + 'Z8ybCFqiXocGpt2VkkK4wwgv+ZwZ8M1ubz0Boby6A1/kTYs/6ll+QekpB4ao\n' + + 'kJKw3DWvVNR/xODFfMQcClvzAtqwfxhTZXBMbZ4vAG5m1ExGmA15cGXrAfwV\n' + + 'nR2vOhPYDeZGbBKktM3xfDts75N2NF/TBpvazV2DTKpkLqvVitFHWvSMMpVd\n' + + 'dwk9tEOmBlj2AoYATvQ9kKHRTD27Wg==\n' + + '=IXzf\n' + + '-----END PGP PUBLIC KEY BLOCK-----\n', + isSpeaker: true, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA1klEQVR4AcXBoXHEMBRF0Zs3oqpHNYgJecZdGKYMd5GZRWaCwaohZbiAhP5d8HeC3jkfnz/fvwSTRua+DjJ1nGQ6i0iYCTNhVnjRWUSTRlTHyX90FhlhJsyEWeHFpJG5r4NMHSfRpBF1FpEwE2bCrPDGfR1E29jJPK6DqI6TjDATZsKsTBqZOk6iSa6ORmbSiISZMBNmpbOIHtcXUR0nUWeRmTSi+zqItrETCTNhJswKL7ax82wRTRqZzuLJ2MkIM2EmzApvTBpRZ5GZNKLOIiPMhJkw+wPV2i2sD43hKwAAAABJRU5ErkJggg==' + }], + pendingMembers: [{ + wallet: 'eip155:0xC1469cB7b59d16dC887D4C11faB3E3C0abBeA12C', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA30lEQVR4AcXBsWnFMBSG0e9dBAGDPUs6LeAFNIEb1x5GtRtDei3gBQzZIFtYYEj10t73CkFw8Z/z+Pj+euJs14iXlsodJfd4U7fjGWKGmCEWzjnilUzTsB60nHOk5ZwjniFmiBligTdTt+MlIt52jbRVvKnb8RIRzxAzxAyxx+/nzxMhQ8wQM8RCyT0taancUXJPiyFmiBligTdTt+NNKy/OOdIyrAct2zXiGWKGmCEW0lJ5kUe8tFT+45wjXsk9XloqniFmiBliYVgPvHOOeCX33JGWijesB54hZogZYn8uFTTKoy9pgwAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0xccF7a3131E0E73F83Bc457C27494411a57f23248', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA9ElEQVR4AcXBIWoEMRSA4X8fw6qayBW9zULVEBFygLqcqMwdhlBCbKjqXSLjY7b2UZEVpbzvu3x8vT5QShhoqUa0Yz9ZSTWiHfuJ5rNDE4wJxgRjl8/v9wdKn43/dLve0QRjgjHB2NZnQ7td72h9NrQSBis+O7Tb9Y7WZ0MTjAnGBGMbv/TZ0EoYaD47VkoYaD43VgRjgjHB2MYTqUa0Yz9ZSTWi9dlYEYwJxgRjlzf38kDx2aGVMNBSjawc+4nms0MrYaAJxgRjgrGNJ1KNaH02VlKNaH02VgRjgjHB2OazQythoKXKn5Qw0Hx2aIIxwZhg7Ae2cUcV4Bl8pAAAAABJRU5ErkJggg==' + }, + { + wallet: 'eip155:0x052aD82D3a7b4DAb5b9BcFED771D28703a6faadf', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAy0lEQVR4AcXBoXFDQQxF0RtlkZsQNjHICKYYV7DFCAW6II2BycfbhklCNR/sTNA75+Pn+/MXIUPMEDPEBifhSVdr0oUnO7UmXXjS1Zp0hpghZogZYoaYIWaIDU5qTbrwpHtfnuyEJ12tyY4hZogZYiM86WpNdl7Hg53wL3bCk84QM8QMscFJeNLVmnS3652dOiZdeLJjiBlihtioNenCky486eqY7IQnO7UmnSFmiBliIzzpak262/XOf7wvT7rX8aALTzpDzBAzxP4AMOQyARcWaToAAAAASUVORK5CYII=' + }, + { + wallet: 'eip155:0x956f73E5a3BF0D19299BF74bD6dc819D7f775eC7', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAA20lEQVR4AcXBsYnDMBiG4dc/nsHgHeJWS1x7G6QzqNQUKlUHLn12ONdqNYTBS/ja/xqBCeF7nmFbbydODoVPSjXiGWKGmCE2Pu8vvPT45pOe9xeeIWaIGWLj0Xa8HAo9qUZ6cih0tR3PEDPEDLFhW28nTg4FL9XIO3IoeKlGPEPMEDPEhq+f3xNnWmZ6jrbTMy0zPUfb8QwxQ8wQG6dlxjvajpdq5JLKPzkUvGmZ8QwxQ8wQG4+246Ua8XIovCPViJcpeIaYIWaIDdt6O7kgh0JPqpErDDFDzBD7AzabOPmHFg/aAAAAAElFTkSuQmCC' + }, + { + wallet: 'eip155:0x19da526eD1a57E07D48aa25aDa6cbA7E41FF3129', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAyUlEQVR4AcXBsY1CQQxF0cvTFEHuNn4jxB6JJggpw5Mh/UZogmByumBTi2DQahf5nMN2vr1IjvtG1ufgL8Kc7Hm6k4liopgo1i7XB1nsG990uT7IRDFRTBRrfBDmZH0OVsKc3xDFRDFRrPFBn4MszFnpc5CFOSuimCgmih228+1Fctw3vul5upOJYqKYKNaO+0bW5yALc7I+BythTtbnIAtzMlFMFBPFGm/CnP8U5qyIYqKYKNZ40+dgJcxZ6XOwEuZkopgoJor9AIckL2mEiBQrAAAAAElFTkSuQmCC' + }, + { + wallet: 'eip155:0x77059B40Ec974883b98a23eef519b4076D1Cf9F1', + publicKey: '', + isSpeaker: false, + image: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAw0lEQVR4AcXBsY0CMRRF0cuTQ6rYaQFiAvdBYMkFkFEAwWYTryxZ2kIcEE8N1MKmH4JJRuw7Z/d7uD0JRu1EuRW2GLUT5VaIhJkwE2a788/XEyNhJsyEWcqtEI3a+aTcCpEwE2bCLI3aia77E9EyT2xxvDyIvmsnEmbCTJgl3izzRDRqJ8qtsGbUzou58KLeiYSZMBNmKbfCf8qtEAkzYSbM0qidTxq1s0aYCTNhlq77E9EyT2yRW2HN8fIgEmbCTJj9AUPBKWCCQlIAAAAAAElFTkSuQmCC' + } + ], + contractAddressERC20: null, + numberOfERC20: 0, + contractAddressNFT: null, + numberOfNFTTokens: 0, + verificationProof: 'pgp:-----BEGIN PGP SIGNATURE-----\n' + + '\n' + + 'wsBzBAEBCAAnBYJkrOmCCZCaDezdj8j4SxYhBGZpOFBNtTj1Oqt695oN7N2P\n' + + 'yPhLAAD+iwf/dvaRCTwXKGH6iUe49NpyTHMaD6ZwaLerk+K4Ojehbdoo0mDf\n' + + 'aOu/MR8wfqk49h2436rcMmyeM5avcMgmtGUmIdy/6hCZ6zxR/3E5t/vq5UfO\n' + + '3YFO1VLghR5cTYqR9bMLFkvvCB4P29rnaok2QVKTBZLfyAM4wu1h2DDBESoz\n' + + 'SS+ZtQLPz6/y7gOQobO0zbwBPmy8MpVVu1wxht+sneOMvZX+5al679nQbwNL\n' + + 'oCcU3UKrlqMhuFgMTCKx99VLcc4JbhBf2M+IHf78NtQ9mcQC/X+gxRfp6f+p\n' + + '2RePQzkmUH5vqXjzcUsNBWJPOyjl09/IZWWwaeiUjsPazjxqDtYNHg==\n' + + '=H4X4\n' + + '-----END PGP SIGNATURE-----\n' + + ':null', + spaceImage: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==', + spaceName: 'sheer_ivory_ox', + isPublic: true, + spaceDescription: 'specific_green_alpaca', + spaceCreator: 'eip155:0x5908D89B1390ec5833001b86302B868A808D506D', + spaceId: 'spaces:bc96011f182e2c86ad68aaf4c95c4a916c808088370cb0ba294f9168e2ff6328', + scheduleAt: '2023-07-15T14:48:00.000Z', + scheduleEnd: '2023-07-15T15:48:00.000Z', + status: 'PENDING' +} +``` + +
+ +--- From e7f2d3073390806e83fabd88876b67079cae560b Mon Sep 17 00:00:00 2001 From: Madhur Gupta Date: Tue, 11 Jul 2023 16:17:32 +0530 Subject: [PATCH 141/298] Spaces SDK alpha publish (#520) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * refactor: added initial SpacesUI class architecture * Update packages/uiweb/src/lib/components/space/SpacesUI.tsx Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> * Update packages/uiweb/src/lib/components/space/SpacesUI.tsx Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> * fix: refine code structure * refactor: change structure and added a test sample * feat: added themeprovider for spaces ui components (#436) * feat: feat: add themeprovider for spaces * fix: resolved conflicts * refactor: cleaned up provider * refactor: resolved comments * feat: added colors and themeing in demoreactapp * refactor: cleaned code * refactor: resolved comments * refactor: added a basic style structure for ease of use (#453) * feat: SpaceBanner Component (#438) * feat: SpaceBanner * refactor: removed-optionals * feat: space-banner functionality * fix: reverted app.tsx * fix: reverted app.tsx * fix: removed test svg file * refactor: change structure and added a test sample * feat: space-banner functionality * refactor: api-implementation * fix: removed-svg * refactor: mobile version * Revert "fix: removed test svg file" This reverts commit 7af756badaeb8435db60712c42ca57ef9ce9f74c. * Revert "refactor: change structure and added a test sample" This reverts commit b1e8745948a9ce5e0485ad51a8cffd07010a5186. * fix: revert * refactor: lastest-pull * feat: added-spaceBanner-test * refactor: cache-to-context * refactor: custom hook added for data * refactor: spaceDTO * fix: SpaceDTO implementation * refactor: participant-container * refactor: cleanups * fix: ui-fixes * fix: EOF newlines * fix: overflow-fixed * refactor: tweaked context structure a bit --------- Co-authored-by: Samarendra Gouda Co-authored-by: Nilesh Gupta * refactor: updated theme object along with light and dark theme * feat: Create Space Component (#454) * refactor: resolved merge conflicts * feat: added modals and modal behaviour logic * feat: modal inputs * feat: change modal logic + integr8 API * feat: added CSS for modals and inputs * fix: resolved PR comments * refactor: improve css * refactor: rft create modal * feat: added search input component * Refactor/space widget component (#458) * refactor: added basic design * refactor: added full widget with style * refactor: reduced fixed height of scheduled widget content * refactor: changes requested * refactor: resolved review comments * feat: add spaces info component (#474) * Feat/added members modal (#477) * refactor: added modal * refactor: added members modal * refactor: review comments * refactor: resolve review comments * fix: review comments * 424 spaces functions webrtc logic (#482) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class --------- Co-authored-by: Shoaib Mohammed Co-authored-by: Madhur Gupta * refactor: spaces UI Components refactor (#478) > replaced hardcoded styles with context theme >added smoother animations on collapsoble components >added profile cards to invite modal * refactor: added spaceUI class variables into context as well (#488) * refactor: added spaceUI class variables into context as well * refactor: resolve review comments * refactor: added a clickHandler in spaceBanner component for extra flexibility (#489) * fix(spaces): fix console errs and refactor create, update methods (#492) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class * fix: Merge branch 'alpha' into 424-spaces-functions-webrtc-logic * fix(spaces): fix console errors and move out create, update functions from Space class --------- Co-authored-by: Shoaib Mohammed * refactor: modified init class method * refactor/added-space-feed-component(#481) * feat: space-feed * refactor: space-feed * Deployment (#440) * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.1 * ci(restapi): 🎉 cut release to restapi-v1.0.1 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * fix: success progressHook * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.1.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.2.0 * ci(restapi): 🎉 cut release to restapi-v1.0.0 * fix(component): dummy * fix(component): dummy * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.2 * fix(component): dummy * ci(restapi): 🎉 cut release to restapi-v1.0.3 * ci(restapi): 🎉 cut release to restapi-v1.0.4 * ci(restapi): 🎉 cut release to restapi-v1.2.1 * fix: local for local development (#295) Co-Authored-By: aman035 * fix: version update * ci(restapi): 🎉 cut release to restapi-v1.2.2 * ci(restapi): 🎉 cut release to restapi-v1.2.3 * ci(restapi): 🎉 cut release to restapi-v1.2.4 * ci(restapi): 🎉 cut release to restapi-v1.2.5 * ci(restapi): 🎉 cut release to restapi-v1.2.6 * ci(restapi): 🎉 cut release to restapi-v1.2.7 * ci(socket): 🎉 cut release to socket-v0.5.0 * fix: test commit * ci(restapi): 🎉 cut release to restapi-v1.2.8 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.0 * ci(uiweb): 🎉 cut release to uiweb-v1.0.1 * fix: added ci-version-beta * fix: added ci-version-beta * ci(restapi): 🎉 cut beta release to restapi-v1.2.9 * fix: added releaseType * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.0 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut release to restapi-v1.2.10 * ci(restapi): 🎉 cut beta release to restapi-v0.0.1-beta.1 * ci(restapi): 🎉 cut release to restapi-v1.2.11 * fix: linkedListHash test cases removed & CI version corrected * fix: update name to beta * ci(restapi): 🎉 cut release to restapi-v1.2.12 * ci(restapi): 🎉 cut release to restapi-v1.2.12 * ci(restapi): 🎉 cut release to restapi-v1.2.13 * ci(restapi): 🎉 cut release to restapi-v1.2.14 * ci(restapi): 🎉 cut release to restapi-v1.2.15 * fix: update package json * fix: updated socket version * ci(uiweb): 🎉 cut release to uiweb-v1.0.2 * fix: socket lib update * ci(uiweb): 🎉 cut release to uiweb-v1.0.2 * ci(restapi): 🎉 cut release to restapi-v1.2.16 * ci(restapi): 🎉 cut release to restapi-v1.3.0 * ci(restapi): 🎉 cut release to restapi-v1.3.1 * ci(socket): 🎉 cut release to socket-v0.5.1 * ci(restapi): 🎉 cut release to restapi-v1.3.2 * ci(restapi): 🎉 cut release to restapi-v1.3.3 * ci(restapi): 🎉 cut release to restapi-v1.3.4 --------- Co-authored-by: aman035 * feat: space-feed * refactor: space-feed * fix: api-call-custom-hooks * fix: api-call * refactor: enums/changes * fix: scrollable * fix: scrolling-issue * feat: filter-changes * fix: added types * fix: loader-issue * fix: tab-button-color * feat: new-filter and prop * fix: ended-logic && participant-number logic * refactor: add onBannerClick * fix: conflicts * revert: messed-up spaceBanner * fix: onClick issue * fix: onClick and cleanups * refactor: new pagination interface * fix: scroll-logic * fix: scroll-final * fix: .. * fix: removed any * fix: onClick-issue * fix: loading-context-to-state * refactor: add-NoSpaceIcons * refactor: new-ui-layout * refactor: new-ui-layout --------- Co-authored-by: Mohammed S Co-authored-by: aman035 Co-authored-by: Nilesh Gupta * refactor: added structure for spaces invites modal component * refactor: invite-component * fix: minor-bug * feat: Create Space API Integration (#494) * feat: create spaces integration * feat: added datetime picker * feat: completed create space API integration * feat: changed flow and time component * feat(spaces): initiate livepeer playback in start method (#499) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class * fix: Merge branch 'alpha' into 424-spaces-functions-webrtc-logic * fix(spaces): fix console errors and move out create, update functions from Space class * feat(spaces): initiate livepeer playback in start method * feat(spaces): store livepeer playback id in space description --------- Co-authored-by: Shoaib Mohammed * Add initialize method (#505) * fix: add spaces for functions * fix: Separate page for space in the demo react APP * fix: start/stop spaces functions * fix: fix image and description types * fix: added functions to add and remove members from group * fix: spaces functions * fix: spaces functions refactoring * fix: few more changes * fix: spaces function testing * fix: spaces functions * fix: SDK bug fixes * fix: SDK bug fixes * fix: minor fixes * fix: minor fix * fix: minor fix * feat(video): add create mesh connection logic in Video class * feat(spaces): make video mesh compatible & add spaces class * feat(spaces): add backend methods in Space class * fix: Merge branch 'alpha' into 424-spaces-functions-webrtc-logic * fix(spaces): fix console errors and move out create, update functions from Space class * feat(spaces): initiate livepeer playback in start method * feat(spaces): store livepeer playback id in space description * feat(spaces): add intitialize method --------- Co-authored-by: Shoaib Mohammed * refactor: resolved css in space banner * refactor: added a skeleton loading effect on space Banner component * feat: add invite functionality to create space (#506) * feat: added invite functionality * fix: add logic for time selector * fix: css fixes * refactor: info-on-widget (#504) * refactor: info-on-widget * refactor: add Space class to context * fix: padding, added new mic icons * fix: added-ref to context * feat: start added * fix: remove optional spaceId * fix: inf-bug * fix: effectAdded * fix(spaces): add is supported check in start * refactor: added-join-functionalities (#507) * refactor: added-join-functionalities * fix: screens * fix(spaces): fix livepeer stream creation in start --------- Co-authored-by: Madhur Gupta * Fix join and pgpPrivateKey in demoreact (#508) * refactor: info-on-widget * refactor: add Space class to context * fix: padding, added new mic icons * fix: added-ref to context * feat: start added * fix: remove optional spaceId * fix: inf-bug * fix: effectAdded * fix(spaces): add is supported check in start * refactor: added-join-functionalities * fix: screens * refactor: added-join-functionalities (#507) * refactor: added-join-functionalities * fix: screens * fix(spaces): fix livepeer stream creation in start * fix: join function --------- Co-authored-by: samarendra-push Co-authored-by: Samarendra Gouda <134079446+samarendra-push@users.noreply.github.com> * refactor: added feature of triggering widget from sdk * fix(spaces): fix join as speaker and listner * fix: resolved updating env and other class variables * Spaces/UI migration (#510) * fix: ui-migration * fix: migration fixes * refactor: added notification socket for space in uiweb * feat: add remove and admin func to invite modal (#509) * feat: add remove and admin func to invite modal * fix: fix null * fix(spaces): fix start * feat: add join functionality to invited spaces (#512) * feat: add join functionality to invited spaces * fix: open space widget after joining * refactor: add audio playback from space speakers (#511) * refactor: added a hidden Video container * fix: migrated initSpaceObject to parent component * feat(spaces): add user feeds socket handler logic * fix: fix create invite UI edge cases (#515) * fix: fix create invite UI edge cases * fix: fix env * fix: fix state behaviour * fix: add wallet as name if name string empty add wallet as name if name string empty * refactor: added join function and socket code (#517) * refactor: added join function and socket code * refactor(spaces): fix mesh creation logic * refactor(spaces): remove unused imports from context * refactor(spaces): remove unused code and improve positioning of code blocks --------- Co-authored-by: Madhur Gupta * Fix isJoined, add hidden video tag (#514) * refactor: added a hidden Video container * fix: migrated initSpaceObject to parent component * fix: WIP isJoined * fix: join as a listener --------- Co-authored-by: Madhur Gupta * fix(spaces): add create audio call before join for speakers (#518) * Widget/videoplayer (#519) * refactor: added a hidden Video container * fix: migrated initSpaceObject to parent component * fix: WIP isJoined * fix: revert husky * fix: nx.json revert * fix: join as a listener * fix: start ui-logic refactor * fix: merge-conflicts * fix: isListener * fix(spaces): fix isSpeaker and isListner logic * feat: added blockies (#523) --------- Co-authored-by: Nilesh Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Samarendra Gouda <134079446+samarendra-push@users.noreply.github.com> Co-authored-by: Samarendra Gouda Co-authored-by: Shoaib Mohammed Co-authored-by: aman035 Co-authored-by: samarendra-push --- .../sdk-frontend/pages/spaces/index.tsx | 2 + packages/restapi/src/lib/space/join.ts | 37 ++---- packages/restapi/src/lib/space/start.ts | 21 ---- .../SCWCreateModal/SCWCreateModal.tsx | 2 +- .../SCWInviteModal/SCWInviteModal.tsx | 74 +++++++++-- .../SpaceCreationWidget.tsx | 30 ++++- .../space/SpaceInvites/SpaceInvites.tsx | 56 +++++++-- .../space/SpaceWidget/LiveWidgetContent.tsx | 105 ++++++++++++---- .../SpaceWidget/ScheduledWidgetContent.tsx | 32 +++-- .../space/SpaceWidget/SpaceWidget.tsx | 29 +++-- .../space/SpaceWidget/WidgetContent.tsx | 31 +++-- .../space/SpaceWidget/WidgetHeader.tsx | 4 +- .../lib/components/space/helpers/blockies.ts | 119 ++++++++++++++++++ .../space/reusables/DateTimePicker.tsx | 5 +- .../space/reusables/ProfileContainer.tsx | 61 +++++++-- .../uiweb/src/lib/context/spacesContext.ts | 18 +++ .../lib/dataProviders/SpaceDataProvider.tsx | 90 ++++++++++++- packages/uiweb/src/lib/hooks/space/index.ts | 1 + .../lib/hooks/space/usePushSpaceSocket.tsx | 112 +++++++++++++++++ .../hooks/space/useSpaceNotificationSocket.ts | 25 ++-- 20 files changed, 692 insertions(+), 162 deletions(-) create mode 100644 packages/uiweb/src/lib/components/space/helpers/blockies.ts create mode 100644 packages/uiweb/src/lib/hooks/space/usePushSpaceSocket.tsx diff --git a/packages/examples/sdk-frontend/pages/spaces/index.tsx b/packages/examples/sdk-frontend/pages/spaces/index.tsx index 2441d1181..651988b8d 100644 --- a/packages/examples/sdk-frontend/pages/spaces/index.tsx +++ b/packages/examples/sdk-frontend/pages/spaces/index.tsx @@ -28,6 +28,7 @@ export const SpacesComponentProvider = ({ }; const Spaces: NextPage = () => { + const { SpaceWidgetComponent } = useSpaceComponents(); return ( @@ -49,6 +50,7 @@ const Spaces: NextPage = () => { Spaces Invites
+ ); diff --git a/packages/restapi/src/lib/space/join.ts b/packages/restapi/src/lib/space/join.ts index d1b640595..151239450 100644 --- a/packages/restapi/src/lib/space/join.ts +++ b/packages/restapi/src/lib/space/join.ts @@ -1,22 +1,19 @@ -import { SPACE_ACCEPT_REQUEST_TYPE } from '../payloads/constants'; +import { + SPACE_ACCEPT_REQUEST_TYPE, + SPACE_REQUEST_TYPE, +} from '../payloads/constants'; import { ChatStatus } from '../types'; import { VideoDataType } from '../video/helpers/sendVideoCallNotification'; import { approve } from './approve'; import { get } from './get'; import type Space from './Space'; -export interface JoinSpaceType { - recievedVideoData?: VideoDataType; // only required when joining as a speaker -} - /** * * @param options * recievedVideoData: only required when joining as a speaker */ -export async function join(this: Space, options: JoinSpaceType) { - const { recievedVideoData = null } = options || {}; - +export async function join(this: Space) { try { const space = await get({ spaceId: this.spaceSpecificData.spaceId, @@ -57,27 +54,19 @@ export async function join(this: Space, options: JoinSpaceType) { signer: this.signer, pgpPrivateKey: this.pgpPrivateKey, senderAddress: this.spaceSpecificData.spaceId, - env: this.env + env: this.env, }); } if (isSpeaker || isSpeakerPending) { - if (!recievedVideoData) - throw new Error('Joining as a speaker failed due to bad video data'); - - if (recievedVideoData.chatId !== this.spaceSpecificData.spaceId) - throw new Error( - 'Joining as a speaker failed due to mismatch in space id' - ); - - // call acceptRequest to initiate connection - await this.acceptRequest({ - senderAddress: recievedVideoData.recipientAddress, - recipientAddress: recievedVideoData.senderAddress, - signalData: recievedVideoData.signalData, - chatId: recievedVideoData.chatId, + // Call the host and join the mesh connection + const hostAddress = space.spaceCreator.replace('eip155:', ''); + await this.request({ + senderAddress: this.data.local.address, + recipientAddress: hostAddress, + chatId: this.spaceSpecificData.spaceId, details: { - type: SPACE_ACCEPT_REQUEST_TYPE.ACCEPT_JOIN_SPEAKER, + type: SPACE_REQUEST_TYPE.JOIN_SPEAKER, data: {}, }, }); diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts index 5d5d3c2db..fd518678b 100644 --- a/packages/restapi/src/lib/space/start.ts +++ b/packages/restapi/src/lib/space/start.ts @@ -85,25 +85,6 @@ export async function start(this: Space, options: StartType): Promise { }); }); - /* - - Try calling all the speakers (admins) - - Create a mesh based webRTC connection with all those who pick up - */ - this.request({ - senderAddress: this.data.local.address, - recipientAddress: convertedAdmins.map((convertedAdmin) => { - if (convertedAdmin.startsWith('eip155:')) { - return convertedAdmin.split('eip155:')[1]; - } - return convertedAdmin; - }), - chatId: this.spaceSpecificData.spaceId, - details: { - type: SPACE_REQUEST_TYPE.JOIN_SPEAKER, - data: {}, - }, - }); - // start the livepeer playback and store the playback URL group meta // send a notification/meta message to all the added listeners (members) telling the space has started @@ -135,8 +116,6 @@ export async function start(this: Space, options: StartType): Promise { console.log('webrtmp-sdk is not currently supported on this browser'); } - console.log('stream key', streamKey); - // cast to the stream const client = new Client(); const session = client.cast(mergeStreamObject.result!, streamKey); diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx index 976c5d117..5054e6235 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx @@ -45,7 +45,7 @@ export const SCWCreateModal: React.FC = (props) => { labelName='Name' inputValue={nameValue} onInputChange={handleNameChange} - charCount={70} + charCount={50} /> { diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx index 7843ac871..94c8ac684 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx @@ -1,5 +1,5 @@ /* eslint-disable no-prototype-builtins */ -import React, { useState, MouseEventHandler, useContext } from 'react' +import React, { useState, MouseEventHandler, useContext, useEffect } from 'react' import styled from 'styled-components' import * as PushAPI from '@pushprotocol/restapi'; @@ -17,6 +17,8 @@ import { useSpaceData } from '../../../../hooks'; import SettingsIcon from '../../../../icons/settingsBlack.svg'; import { Image } from '../../../../config'; +import { createIcon } from '../../helpers/blockies'; + export interface ISCWIModalProps { // Space Creation Widget Create Modal Interface closeInviteModal?: MouseEventHandler; makeScheduleVisible?: MouseEventHandler; @@ -51,11 +53,10 @@ export const SCWInviteModal: React.FC = (props) => { setAdminsAddressList, onClose } = props; - - const { env } = useSpaceData(); - const theme = useContext(ThemeContext); + const { env, account } = useSpaceData(); + const [invitedMember, setInvitedMember] = useState('') const [loadingAccount, setLoadingAccount] = useState(false) @@ -65,6 +66,11 @@ export const SCWInviteModal: React.FC = (props) => { const searchMember = async (event: any) => { setInvitedMember(event.target.value) + if (event.target.value === account) { + handleError('Cannot add Host to members'); + return; + } + try { setLoadingAccount(true); const response = await PushAPI.user.get({ @@ -73,11 +79,18 @@ export const SCWInviteModal: React.FC = (props) => { }); if(response === null) { + const icon = createIcon({ + seed: event.target.value, + size: 10, + scale: 3, + }); + const nullUser = { walletAddress: event.target.value, name: event.target.value, - image: tempImageUrl, + image: icon.toDataURL(), }; + setSearchedUser(nullUser) } else { setSearchedUser(response); @@ -98,7 +111,22 @@ export const SCWInviteModal: React.FC = (props) => { setErrorMsg(''); } + const handleError = (errMsg: string) => { + setErrorMsg(errMsg); + setTimeout(() => { + setErrorMsg('') + }, 2000); + } + const handleInviteMember = (user: any) => { + if( + (invitedAddressList.length !== 0 && adminsAddressList.length !== 0) + && (invitedAddressList.includes(user.did.substring(7)) || adminsAddressList.includes(user.did.substring(7))) + ) { + handleError('Already Invited'); + return; + } + if (user.did) { setInvitedAddressList([...invitedAddressList, user.did.substring(7)]) setInvitedMembersList([...invitedMembersList, user]); @@ -136,6 +164,27 @@ export const SCWInviteModal: React.FC = (props) => { const handleDeleteInvitedUser = (user: any) => { const updatedArray = invitedMembersList.filter((item: any) => item !== user) setInvitedMembersList(updatedArray); + + if (user.did) { + const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.did.substring(7)) + setInvitedAddressList(updateAddressArray); + } else { + const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.walletAddress) + setInvitedAddressList(updateAddressArray); + } + }; + + const handleDeleteInvitedAdmin = (user: any) => { + const updatedArray = adminsList.filter((item: any) => item !== user) + setAdminsList(updatedArray); + + if (user.did) { + const updateAdminAddressArray = adminsAddressList.filter((item: string) => item !== user.did.substring(7)) + setAdminsAddressList(updateAdminAddressArray); + } else { + const updateAddressArray = adminsAddressList.filter((item: string) => item !== user.walletAddress) + setAdminsAddressList(updateAddressArray); + } }; const tempImageUrl = "https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg"; @@ -157,7 +206,8 @@ export const SCWInviteModal: React.FC = (props) => { onInputChange={searchMember} clearInput={clearInput} /> - {errorMsg} + + {errorMsg} {loadingAccount && } @@ -263,8 +313,8 @@ export const SCWInviteModal: React.FC = (props) => { } // btnCallback={() => handleDeleteInvitedUser(item)} - removeCallback={() => handleDeleteInvitedUser(item)} - promoteCallback={() => handlePromoteToAdmin(item)} + removeCallback={() => handleDeleteInvitedAdmin(item)} + // promoteCallback={() => handlePromoteToAdmin(item)} border /> } else { @@ -283,7 +333,7 @@ export const SCWInviteModal: React.FC = (props) => { } // btnCallback={() => handleDeleteInvitedUser(item)} - removeCallback={() => handleDeleteInvitedUser(item)} + removeCallback={() => handleDeleteInvitedAdmin(item)} // promoteCallback={() => handlePromoteToAdmin(item)} border /> @@ -364,4 +414,10 @@ const ContBtn = styled.button` border-radius: 8px; border: 1px solid #8B5CF6; cursor: pointer; +`; + +const ErrorMessage = styled.div` + color: #E93636; + font-size: 14px; + margin-bottom: 8px; `; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx index 26baa118c..6b37ac307 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx @@ -22,10 +22,9 @@ export const SpaceCreationWidget:React.FC = (props) => const [invitedMembersList, setInvitedMembersList] = useState([]) const [invitedAddressList, setInvitedAddressList] = useState([]) - console.log("🚀 ~ file: SpaceCreationWidget.tsx:25 ~ invitedAddressList:", invitedAddressList) + const [adminsList, setAdminsList] = useState([]) const [adminsAddressList, setAdminsAddressList] = useState([]) - console.log("🚀 ~ file: SpaceCreationWidget.tsx:27 ~ adminsAddressList:", adminsAddressList) const [isLoading, setLoading] = useState(false); @@ -33,10 +32,10 @@ export const SpaceCreationWidget:React.FC = (props) => spaceName: '', spaceDescription: '', date: new Date(), - time: new Date(), + time: Date.now(), }) - const { signer } = useSpaceData(); + const { signer, env, account } = useSpaceData(); const handleNameChange = (event: any) => { setSpaceState((prevState) => ({...prevState, spaceName: event.target.value})) @@ -83,17 +82,35 @@ export const SpaceCreationWidget:React.FC = (props) => const closeInviteModal = () => { setIsInviteModalVisible(false); } + + const clearAllState = () => { + setIsCreateModalVisible(false) + setIsScheduleModalVisible(false) + setIsInviteModalVisible(false) + setInvitedMembersList([]) + setInvitedAddressList([]) + setAdminsList([]) + setAdminsAddressList([]) + setLoading(false) + setSpaceState({ + spaceName: '', + spaceDescription: '', + date: new Date(), + time: Date.now(), + }) + } const testCreateSpace = async () => { const spaceCreate = { - spaceName: spaceState.spaceName, + spaceName: spaceState.spaceName.length === 0 ? `${account}'s Space` : spaceState.spaceName, spaceDescription: 'Push Space', members: invitedAddressList, spaceImage: 'asd', admins: adminsAddressList, isPublic: true, - scheduleAt: new Date(spaceState.time), + scheduleAt: spaceState.time > Date.now() ? new Date(spaceState.time) : new Date(Date.now() + 120000), signer: signer as PushAPI.SignerType, + env } try { @@ -106,6 +123,7 @@ export const SpaceCreationWidget:React.FC = (props) => } finally { setLoading(false); closeInviteModal(); + clearAllState(); } }; diff --git a/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx b/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx index ecc07676e..6e808f5fa 100644 --- a/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx @@ -1,4 +1,4 @@ -import React, { useState } from 'react'; +import React, { useEffect, useState } from 'react'; import styled from 'styled-components'; import { Modal } from '../reusables/Modal'; import { Spinner } from '../reusables/Spinner'; @@ -7,12 +7,13 @@ import { useFeedScroll, useSpaceData, useSpaceRequests } from '../../../hooks'; import { SpaceBanner } from '../SpaceBanner'; export interface ISpaceInvitesProps { - account?: string; children?: React.ReactNode; } +// temp +let spaceId = ""; + export const SpaceInvites: React.FC = ({ - account = '0x04bE5701AB5b2f2117332b4748020737B29a2e1D', children, }: ISpaceInvitesProps) => { const [modalOpen, setModalOpen] = useState(false); @@ -21,18 +22,47 @@ export const SpaceInvites: React.FC = ({ const containerRef = useFeedScroll(spaceRequests.apiData?.length); const [playBackUrl, setPlayBackUrl] = useState(''); - const { spacesObjectRef, spaceObjectData, initSpaceObject, setSpaceWidgetId } = useSpaceData(); + const { + spacesObjectRef, + spaceObjectData, + initSpaceObject, + setSpaceWidgetId, + isSpeaker, + isListener, + account, + } = useSpaceData(); const handleJoinSpace = async (space: any) => { await initSpaceObject(space?.spaceId as string); - await spacesObjectRef?.current?.join(); - const playBackUrl = spaceObjectData.spaceDescription; - setPlayBackUrl(playBackUrl); - handleCloseModal(); - setSpaceWidgetId(space?.spaceId as string) - console.log('Space Joined'); + + if (isSpeaker) { + // create audio stream + await spacesObjectRef.current.createAudioStream(); + spaceId = space?.spaceId; // temp + } + if (isListener) { + await spacesObjectRef?.current?.join(); + const playBackUrl = spaceObjectData.spaceDescription; + setPlayBackUrl(playBackUrl); + handleCloseModal(); + setSpaceWidgetId(space?.spaceId as string); + console.log('space joined'); + } }; + useEffect(() => { + if (!spaceObjectData?.connectionData?.local.stream || !isSpeaker) return; + const joinSpaceAsSpeaker = async () => { + console.log('joining as a speaker'); + await spacesObjectRef?.current?.join(); + setSpaceWidgetId(spaceId); + console.log('space joined'); + handleCloseModal(); + }; + joinSpaceAsSpeaker(); + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [spaceObjectData?.connectionData?.local.stream]); + const handleOpenModal = () => { setModalOpen(true); }; @@ -121,17 +151,17 @@ const ScrollContainer = styled.div` margin-top: 24px; overflow-y: scroll; - &::-webkit-scrollbar{ + &::-webkit-scrollbar { margin-left: 10px; width: 8px; height: 8px; } - &::-webkit-scrollbar-thumb{ + &::-webkit-scrollbar-thumb { -webkit-appearance: none; width: 4px; height: auto; - background:#8B5CF6; + background: #8b5cf6; border-radius: 99px; } `; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx index bf630ce96..93c056e70 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx @@ -13,37 +13,80 @@ import MembersIcon from '../../../icons/Members.svg'; import { SpaceDTO } from '@pushprotocol/restapi'; import { useSpaceData } from '../../../hooks'; - import { Player } from '@livepeer/react'; interface LiveWidgetContentProps { spaceData?: SpaceDTO; // temp props only for testing demo purpose for now isHost?: boolean; - isJoined?: boolean; - isSpeaker?: boolean; } export const LiveWidgetContent: React.FC = ({ spaceData, - isJoined, isHost, - isSpeaker, }) => { const tempImageUrl = 'https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg'; const [showMembersModal, setShowMembersModal] = useState(false); const [isMicOn, setIsMicOn] = useState(true); const [playBackUrl, setPlayBackUrl] = useState(''); - const { spacesObjectRef, spaceObjectData, initSpaceObject } = useSpaceData(); + const { + spacesObjectRef, + spaceObjectData, + isSpeaker, + isListener, + setSpaceWidgetId, + isJoined, + initSpaceObject, + } = useSpaceData(); const handleJoinSpace = async () => { - // await initSpaceObject(spaceData?.spaceId as string); - await spacesObjectRef?.current?.join(); + if (!spaceData) { + return; + } + + await initSpaceObject(spaceData?.spaceId as string); + + if (isListener) { + console.log('joining as a listner'); + await spacesObjectRef?.current?.join(); + setSpaceWidgetId(spaceData?.spaceId as string); + console.log('space joined'); + } + }; + + useEffect(()=>{ + const createAudioStream = async () => { + console.log("isSpeaker", isSpeaker); + if (isSpeaker) { + // create audio stream as we'll need it to start the mesh connection + console.log('creating audio stream'); + await spacesObjectRef.current.createAudioStream(); + } + } + createAudioStream(); + }, [isSpeaker]) + + useEffect(() => { + if (!spaceObjectData?.connectionData?.local.stream || !isSpeaker) return; + const joinSpaceAsSpeaker = async () => { + console.log('joining as a speaker'); + await spacesObjectRef?.current?.join(); + setSpaceWidgetId(spaceData?.spaceId as string); + console.log('space joined'); + }; + joinSpaceAsSpeaker(); + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [spaceObjectData?.connectionData?.local.stream]); + + useEffect(() => { + if (!spaceObjectData.spaceDescription) return; const playBackUrl = spaceObjectData.spaceDescription; setPlayBackUrl(playBackUrl); - console.log('Space Joined'); - }; - console.log('spaceObjectData', spaceObjectData); + }, [spaceObjectData.spaceDescription]); + + // console.log('spaceObjectData', spaceObjectData); + // console.log('playBackUrl', playBackUrl); + // console.log('isListener', isListener); return ( <> @@ -57,19 +100,25 @@ export const LiveWidgetContent: React.FC = ({ overflowY={'auto'} alignContent={'flex-start'} > - {spaceObjectData.connectionData.incoming.map( - (profile) => ( - ( - - ) - ) - )} + {isSpeaker && + spaceObjectData.connectionData.incoming.map((profile) => ( + + ))} + {isListener && + spaceObjectData.members.map((profile) => ( + + ))} {isJoined ? ( @@ -139,7 +188,13 @@ export const LiveWidgetContent: React.FC = ({ {!isHost ? 'Leave' : 'End space'} - + {isListener && playBackUrl.length > 0 && ( + + )} ) : (
- { - const { spaceUI } = useSpaceComponents(); const customtheme = { - statusColorError: 'red', - } + titleBg: 'linear-gradient(45deg, #E165EC 0.01%, #A483ED 100%)', //not changed + titleTextColor: '#FFFFFF', + bgColorPrimary: '#fff', + bgColorSecondary: '#F7F1FB', + textColorPrimary: '#000', + textColorSecondary: '#657795', + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', //not changed + btnColorPrimary: '#D53A94', + btnOutline: '#D53A94', + borderColor: '#FFFF', + borderRadius: '17px', + containerBorderRadius: '12px', + statusColorError: '#E93636', + statusColorSuccess: '#30CC8B', + iconColorPrimary: '#82828A', + }; + + const customDarkTheme = { + titleBg: + 'linear-gradient(87.17deg, #EA4EE4 0%, #D23CDF 0.01%, #8B5CF6 100%)', + titleTextColor: '#fff', + bgColorPrimary: '#000', + bgColorSecondary: '#292344', + textColorPrimary: '#fff', + textColorSecondary: '#71717A', + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', + btnColorPrimary: '#8B5CF6', + btnOutline: '#8B5CF6', + borderColor: '#3F3F46', + borderRadius: '17px', + containerBorderRadius: '12px', + statusColorError: '#E93636', + statusColorSuccess: '#30CC8B', + iconColorPrimary: '#71717A', + }; return ( - - {children} - + // + // {children} + // + <> ); }; diff --git a/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx b/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx index 5c0ee9ffc..0452683ea 100644 --- a/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx +++ b/packages/demoreact/src/app/SpaceUITest/useSpaceComponents.tsx @@ -6,12 +6,10 @@ import { SpacesUI, ISpaceInvitesProps, } from '@pushprotocol/uiweb'; -import React, { useContext, useEffect, useState } from 'react'; -import { EnvContext, Web3Context } from '../context'; -import * as PushAPI from '@pushprotocol/restapi'; +import React, { useContext } from 'react'; +import { AccountContext, EnvContext, Web3Context } from '../context'; export interface IUseSpaceReturnValues { - spaceUI: SpacesUI; SpaceInvitesComponent: React.FC; SpaceWidgetComponent: React.FC; SpaceFeedComponent: React.FC; @@ -22,39 +20,17 @@ export interface IUseSpaceReturnValues { export const useSpaceComponents = (): IUseSpaceReturnValues => { const { account, library } = useContext(Web3Context); const { env } = useContext(EnvContext); + const { pgpPrivateKey } = useContext(AccountContext); const librarySigner = library?.getSigner(); - const [pgpPrivateKey, setPgpPrivateKey] = useState(''); - const spaceUI = new SpacesUI({ - account: account, + account: account as string, signer: librarySigner, pgpPrivateKey: pgpPrivateKey, env: env, }); - useEffect(() => { - (async () => { - if (!account || !env || !library) return; - - const user = await PushAPI.user.get({ account, env }); - let pgpPrivateKey; - const librarySigner = await library.getSigner(account); - if (user?.encryptedPrivateKey) { - pgpPrivateKey = await PushAPI.chat.decryptPGPKey({ - encryptedPGPPrivateKey: user.encryptedPrivateKey, - account, - signer: librarySigner, - env, - }); - } - - setPgpPrivateKey(pgpPrivateKey); - })(); - }, [account, env, library]); - return { - spaceUI, SpaceInvitesComponent: spaceUI.SpaceInvites, SpaceWidgetComponent: spaceUI.SpaceWidget, SpaceBannerComponent: spaceUI.SpaceBanner, diff --git a/packages/demoreact/src/app/app.tsx b/packages/demoreact/src/app/app.tsx index e5a51911f..279a49e41 100644 --- a/packages/demoreact/src/app/app.tsx +++ b/packages/demoreact/src/app/app.tsx @@ -1,11 +1,11 @@ -import { useState } from 'react'; +import { useEffect, useMemo, useState } from 'react'; import styled from 'styled-components'; import { Route, Routes, Link } from 'react-router-dom'; import { useWeb3React } from '@web3-react/core'; import ConnectButton from './components/Connect'; import { Checkbox } from './components/Checkbox'; import Dropdown from './components/Dropdown'; -import { Web3Context, EnvContext, SocketContext } from './context'; +import { Web3Context, EnvContext, SocketContext, AccountContext } from './context'; import { useSDKSocket } from './hooks'; import { ReactComponent as PushLogo } from '../assets/pushLogo.svg'; import NotificationsTest from './NotificationsTest'; @@ -55,7 +55,6 @@ import GetSpacesRequestsTest from './SpaceTest/GetSpacesRequestsTest'; import GetSpacesTrendingTest from './SpaceTest/GetSpacesTrendingTest'; import SpaceUITest from './SpaceUITest/SpaceUITest'; import { - SpacesComponentProvider, SpaceWidget, SpaceBanner, SpaceFeed, @@ -63,7 +62,9 @@ import { SpaceInvitesComponent } from './SpaceUITest'; import { useSpaceComponents } from './SpaceUITest/useSpaceComponents'; +import * as PushAPI from "@pushprotocol/restapi"; import { ChatWidgetTest } from './ChatWidgetTest'; +import { SpacesUI, SpacesUIProvider } from '@pushprotocol/uiweb'; window.Buffer = window.Buffer || Buffer; @@ -147,6 +148,43 @@ const NavMenu = styled.div` } `; +const customtheme = { + titleBg: 'linear-gradient(45deg, #E165EC 0.01%, #A483ED 100%)', //not changed + titleTextColor: '#FFFFFF', + bgColorPrimary: '#fff', + bgColorSecondary: '#F7F1FB', + textColorPrimary: '#000', + textColorSecondary: '#657795', + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', //not changed + btnColorPrimary: '#D53A94', + btnOutline: '#D53A94', + borderColor: '#FFFF', + borderRadius: '17px', + containerBorderRadius: '12px', + statusColorError: '#E93636', + statusColorSuccess: '#30CC8B', + iconColorPrimary: '#82828A', +}; + +const customDarkTheme = { + titleBg: + 'linear-gradient(87.17deg, #EA4EE4 0%, #D23CDF 0.01%, #8B5CF6 100%)', + titleTextColor: '#fff', + bgColorPrimary: '#000', + bgColorSecondary: '#292344', + textColorPrimary: '#fff', + textColorSecondary: '#71717A', + textGradient: 'linear-gradient(45deg, #B6A0F5, #F46EF6, #FFDED3, #FFCFC5)', + btnColorPrimary: '#8B5CF6', + btnOutline: '#8B5CF6', + borderColor: '#3F3F46', + borderRadius: '17px', + containerBorderRadius: '12px', + statusColorError: '#E93636', + statusColorSuccess: '#30CC8B', + iconColorPrimary: '#71717A', +}; + const checkForWeb3Data = ({ library, active, @@ -157,17 +195,18 @@ const checkForWeb3Data = ({ }; export function App() { - const web3Data: Web3ReactState = useWeb3React(); + const {account, library, active, chainId} = useWeb3React(); - const [env, setEnv] = useState(ENV.PROD); + const [env, setEnv] = useState(ENV.DEV); const [isCAIP, setIsCAIP] = useState(false); const { SpaceWidgetComponent } = useSpaceComponents(); const [spaceId, setSpaceId] = useState(''); + const [pgpPrivateKey, setPgpPrivateKey] = useState(''); const socketData = useSDKSocket({ - account: web3Data.account, - chainId: web3Data.chainId, + account: account, + chainId: chainId, env, isCAIP, }); @@ -180,6 +219,33 @@ export function App() { setIsCAIP(!isCAIP); }; + useEffect(() => { + (async () => { + if (!account || !env || !library) return; + + const user = await PushAPI.user.get({ account: account, env }); + let pgpPrivateKey; + const librarySigner = await library.getSigner(account); + if (user?.encryptedPrivateKey) { + pgpPrivateKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account: account, + signer: librarySigner, + env, + }); + } + + setPgpPrivateKey(pgpPrivateKey); + })(); + }, [account, env, library]); + + const spaceUI = useMemo(() => new SpacesUI({ + account: account as string, + signer: library?.getSigner(), + pgpPrivateKey: pgpPrivateKey, + env: env, + }), [account, library, pgpPrivateKey, env]); + return ( @@ -211,10 +277,13 @@ export function App() {
- {checkForWeb3Data(web3Data) ? ( - + {checkForWeb3Data({ + active, account, library, chainId + }) ? ( + - + + */} - + + ) : null} diff --git a/packages/demoreact/src/app/context/accountContext.ts b/packages/demoreact/src/app/context/accountContext.ts new file mode 100644 index 000000000..45750805a --- /dev/null +++ b/packages/demoreact/src/app/context/accountContext.ts @@ -0,0 +1,5 @@ +import { createContext } from 'react' + +const AccountContext = createContext({}); + +export default AccountContext; \ No newline at end of file diff --git a/packages/demoreact/src/app/context/index.ts b/packages/demoreact/src/app/context/index.ts index cccf3958c..80db31f5d 100644 --- a/packages/demoreact/src/app/context/index.ts +++ b/packages/demoreact/src/app/context/index.ts @@ -1,9 +1,11 @@ import Web3Context from "./web3context"; import EnvContext from "./envContext"; import SocketContext from "./socketContext"; +import AccountContext from "./accountContext"; export { Web3Context, EnvContext, - SocketContext + SocketContext, + AccountContext }; \ No newline at end of file diff --git a/packages/examples/sdk-backend-node/src/spaces/index.ts b/packages/examples/sdk-backend-node/src/spaces/index.ts index f320f7659..9689045d5 100644 --- a/packages/examples/sdk-backend-node/src/spaces/index.ts +++ b/packages/examples/sdk-backend-node/src/spaces/index.ts @@ -55,7 +55,7 @@ export const runSpacesUseCases = async (): Promise < void > => { ╚════██║██╔═══╝ ██╔══██║██║ ██╔══╝ ╚════██║ ███████║██║ ██║ ██║╚██████╗███████╗███████║ ╚══════╝╚═╝ ╚═╝ ╚═╝ ╚═════╝╚══════╝╚══════╝ - + `) console.log('PushAPI.user.create'); @@ -143,9 +143,9 @@ async function PushAPI_space_create( const response = await PushAPI.space.create({ spaceName, spaceDescription, - members: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], + listeners: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], spaceImage, - admins: [], + speakers: [], isPublic: true, signer: signer, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -191,14 +191,14 @@ async function PushAPI_space_update( spaceId, spaceName, spaceDescription, - members: [ + listeners: [ `eip155:${randomWallet1}`, `eip155:${randomWallet2}`, `eip155:${randomWallet3}`, `eip155:${signer.address}`, ], spaceImage, - admins: [`eip155:${signer.address}`], // takes signer as admin automatically, add more if you want to + speakers: [`eip155:${signer.address}`], // takes signer as admin automatically, add more if you want to scheduleAt: start, scheduleEnd: end, status: PushAPI.ChatStatus.PENDING, @@ -255,9 +255,9 @@ async function PushAPI_space_start_and_stop( dictionaries: [adjectives, colors, animals], }), spaceDescription, - members: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], + listeners: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], spaceImage, - admins: [], + speakers: [], isPublic: true, signer: signer, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -323,9 +323,9 @@ async function PushAPI_space_approve( dictionaries: [adjectives, colors, animals], }), spaceDescription, - members: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], + listeners: [`eip155:${randomWallet1}`, `eip155:${randomWallet2}`], spaceImage, - admins: [], + speakers: [], isPublic: true, signer: signer, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -621,4 +621,4 @@ async function PushAPI_space_trending(silent = !showAPIResponse) { if (!silent) { console.log(response); } -} \ No newline at end of file +} diff --git a/packages/examples/sdk-frontend/automate.sh b/packages/examples/sdk-frontend/automate.sh new file mode 100755 index 000000000..5d58755d8 --- /dev/null +++ b/packages/examples/sdk-frontend/automate.sh @@ -0,0 +1,31 @@ +#! /bin/bash + +who=$(whoami) +echo "Hey, $who!" + +sleep 1 + +delnode=$(rm -rf node_modules/) +sleep 1 +echo "Node Modules Deleted." + +sleep 1 + +delnext=$(rm -rf .next/) +sleep 1 +echo ".Next Deleted" + +sleep 1 + +clean=$(yarn cache clean) +sleep 1 +echo "Yarn Cache Cleaned." + +sleep 1 +install=`yarn` +sleep 1 +echo $install + + +sleep 1 +echo "See you soon, $who!" diff --git a/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx b/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx index ccad60268..8797bff28 100644 --- a/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx +++ b/packages/examples/sdk-frontend/components/Spaces/useSpaceComponent.tsx @@ -6,11 +6,11 @@ import { SpacesUI, ISpaceInvitesProps, } from '@pushprotocol/uiweb'; -import { useAccount, useNetwork, useSigner } from 'wagmi'; -import React, { useContext, useEffect, useState } from 'react'; +import { useAccount, useSigner } from 'wagmi'; +import React, { useContext} from 'react'; import { ENV } from '@pushprotocol/restapi/src/lib/constants'; import * as PushAPI from '@pushprotocol/restapi'; -import { is } from 'date-fns/locale'; +import { AccountContext } from '../../contexts'; export interface IUseSpaceReturnValues { spaceUI: SpacesUI; @@ -24,13 +24,10 @@ export interface IUseSpaceReturnValues { export const useSpaceComponents = (): IUseSpaceReturnValues => { const env = ENV.DEV; - const { address, isConnected } = useAccount(); - const { chain } = useNetwork(); + const { address } = useAccount(); const { data: signer } = useSigner(); - const [pgpPrivateKey, setPgpPrivateKey] = useState(''); - - console.log('address: ', address, isConnected); + const { pgpPrivateKey } = useContext(AccountContext); const spaceUI = new SpacesUI({ account: address as string, @@ -39,28 +36,6 @@ export const useSpaceComponents = (): IUseSpaceReturnValues => { env: env, }); - useEffect(() => { - (async () => { - if (!signer || !address || !chain?.id) return; - - const user = await PushAPI.user.get({ - account: address, - env, - }); - let pgpPrivateKey = null; - if (user?.encryptedPrivateKey) { - pgpPrivateKey = await PushAPI.chat.decryptPGPKey({ - encryptedPGPPrivateKey: user.encryptedPrivateKey, - account: address, - signer, - env, - }); - } - - setPgpPrivateKey(pgpPrivateKey); - })(); - }, [address, env, signer, chain]); - return { spaceUI, SpaceInvitesComponent: spaceUI.SpaceInvites, diff --git a/packages/examples/sdk-frontend/contexts/accountContext.ts b/packages/examples/sdk-frontend/contexts/accountContext.ts new file mode 100644 index 000000000..45750805a --- /dev/null +++ b/packages/examples/sdk-frontend/contexts/accountContext.ts @@ -0,0 +1,5 @@ +import { createContext } from 'react' + +const AccountContext = createContext({}); + +export default AccountContext; \ No newline at end of file diff --git a/packages/examples/sdk-frontend/contexts/index.ts b/packages/examples/sdk-frontend/contexts/index.ts new file mode 100644 index 000000000..c5064de89 --- /dev/null +++ b/packages/examples/sdk-frontend/contexts/index.ts @@ -0,0 +1,5 @@ +import AccountContext from "./accountContext"; + +export { + AccountContext +}; \ No newline at end of file diff --git a/packages/examples/sdk-frontend/pages/_app.tsx b/packages/examples/sdk-frontend/pages/_app.tsx index 6013004e0..d99c4c625 100644 --- a/packages/examples/sdk-frontend/pages/_app.tsx +++ b/packages/examples/sdk-frontend/pages/_app.tsx @@ -12,7 +12,9 @@ import { publicProvider } from 'wagmi/providers/public'; import '@rainbow-me/rainbowkit/styles.css'; import '../styles/globals.css'; import { useEffect, useState } from 'react'; -import { SpacesComponentProvider } from './spaces'; +import { SpacesUIProvider } from '@pushprotocol/uiweb'; +import { useSpaceComponents } from './../components/Spaces/useSpaceComponent'; +import { AccountContext } from '../contexts'; const { chains, provider } = configureChains([goerli], [publicProvider()]); @@ -28,8 +30,27 @@ const wagmiClient = createClient({ provider, }); +export interface ISpacesComponentProps { + children: React.ReactNode; +} + +const SpacesComponentProvider = ({ children }: ISpacesComponentProps) => { + const { spaceUI } = useSpaceComponents(); + + const customtheme = { + statusColorError: 'red', + }; + + return ( + + {children} + + ); +}; + function MyApp({ Component, pageProps }: AppProps) { const [loadWagmi, setLoadWagmi] = useState(false); + const [pgpPrivateKey, setPgpPrivateKey] = useState(''); useEffect(() => { setLoadWagmi(true); @@ -41,9 +62,11 @@ function MyApp({ Component, pageProps }: AppProps) { {loadWagmi ? ( - - - + + + + + ) : null} diff --git a/packages/examples/sdk-frontend/pages/spaces/index.tsx b/packages/examples/sdk-frontend/pages/spaces/index.tsx index 651988b8d..80cf3ae9c 100644 --- a/packages/examples/sdk-frontend/pages/spaces/index.tsx +++ b/packages/examples/sdk-frontend/pages/spaces/index.tsx @@ -3,34 +3,45 @@ import styled from 'styled-components'; import { Button, Container } from '..'; import Link from 'next/link'; -import { SpacesUIProvider } from '@pushprotocol/uiweb'; import { useSpaceComponents } from './../../components/Spaces/useSpaceComponent'; +import { useContext, useEffect, useState } from 'react'; +import { useAccount, useSigner } from 'wagmi'; +import * as PushAPI from '@pushprotocol/restapi'; +import { ENV } from '@pushprotocol/restapi/src/lib/constants'; +import { AccountContext } from '../../contexts'; +const Spaces: NextPage = () => { + const { address } = useAccount(); + const { data: signer } = useSigner(); -export interface ISpacesComponentProps { - children: React.ReactNode; -} + const { pgpPrivateKey, setPgpPrivateKey } = useContext(AccountContext); + const { SpaceWidgetComponent } = useSpaceComponents(); + const env = ENV.DEV; -export const SpacesComponentProvider = ({ - children, -}: ISpacesComponentProps) => { - const { spaceUI } = useSpaceComponents(); + useEffect(() => { + (async () => { + if (!signer || !address || pgpPrivateKey) return; - const customtheme = { - statusColorError: 'red', - }; + const user = await PushAPI.user.get({ + account: address, + env, + }); + let PgpPrivateKey = null; + if (user?.encryptedPrivateKey) { + PgpPrivateKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account: address, + signer, + env, + }); + } - return ( - - {children} - - ); -}; + setPgpPrivateKey(PgpPrivateKey); + })(); + }, [address, env, signer]); -const Spaces: NextPage = () => { - const { SpaceWidgetComponent } = useSpaceComponents(); return ( - +

Spaces UI Test

@@ -52,17 +63,17 @@ const Spaces: NextPage = () => {
-
+ ); }; export default Spaces; const Section = styled.div` - display: flex; - flex-direction: row; - justify-content: center; - align-items: center; - gap: 20px; - wrap: wrap; -}`; + display: flex; + flex-direction: row; + justify-content: center; + align-items: center; + gap: 20px; + flex-wrap: wrap; +`; diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 41c86ebf8..a9e1cdaea 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -9,96 +9,96 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [How to use in your app?](#how-to-use-in-your-app) - [Installation](#installation) - [Import SDK](#import-sdk) - - [About generating the "signer" object for different platforms](#about-generating-the-signer-object-for-different-platforms) + - [**About generating the "signer" object for different platforms**](#about-generating-the-signer-object-for-different-platforms) - [When using in SERVER-SIDE code:](#when-using-in-server-side-code) - [When using in FRONT-END code:](#when-using-in-front-end-code) - - [About blockchain agnostic address format](#about-blockchain-agnostic-address-format) + - [**About blockchain agnostic address format**](#about-blockchain-agnostic-address-format) - [Chat blockchain agnostic address format](#chat-blockchain-agnostic-address-format) - - [About Push contract addresses](#about-push-contract-addresses) + - [**About Push contract addresses**](#about-push-contract-addresses) - [Push core contract address](#push-core-contract-address) - [Push communicator contract address](#push-communicator-contract-address) - [SDK Features](#sdk-features) - [For Notification](#for-notification) - - [Fetching user notifications](#fetching-user-notifications) - - [Fetching user spam notifications](#fetching-user-spam-notifications) - - [Fetching user subscriptions](#fetching-user-subscriptions) - - [Fetching channel details](#fetching-channel-details) - - [Searching for channel(s)](#searching-for-channels) - - [Opt in to a channel](#opt-in-to-a-channel) - - [Opt out to a channel](#opt-out-to-a-channel) - - [Sending notification](#sending-notification) - - [Direct payload for single recipient(target)](#direct-payload-for-single-recipienttarget) - - [Direct payload for group of recipients(subset)](#direct-payload-for-group-of-recipientssubset) - - [Direct payload for all recipients(broadcast)](#direct-payload-for-all-recipientsbroadcast) - - [IPFS payload for single recipient(target)](#ipfs-payload-for-single-recipienttarget) - - [IPFS payload for group of recipients(subset)](#ipfs-payload-for-group-of-recipientssubset) - - [IPFS payload for all recipients(broadcast)](#ipfs-payload-for-all-recipientsbroadcast) - - [Minimal payload for single recipient(target)](#minimal-payload-for-single-recipienttarget) - - [Minimal payload for a group of recipient(subset)](#minimal-payload-for-a-group-of-recipientsubset) - - [Minimal payload for all recipients(broadcast)](#minimal-payload-for-all-recipientsbroadcast) - - [Graph payload for single recipient(target)](#graph-payload-for-single-recipienttarget) - - [Graph payload for group of recipients(subset)](#graph-payload-for-group-of-recipientssubset) - - [Graph payload for all recipients(broadcast)](#graph-payload-for-all-recipientsbroadcast) + - [**Fetching user notifications**](#fetching-user-notifications) + - [**Fetching user spam notifications**](#fetching-user-spam-notifications) + - [**Fetching user subscriptions**](#fetching-user-subscriptions) + - [**Fetching channel details**](#fetching-channel-details) + - [**Searching for channel(s)**](#searching-for-channels) + - [**Opt in to a channel**](#opt-in-to-a-channel) + - [**Opt out to a channel**](#opt-out-to-a-channel) + - [**Sending notification**](#sending-notification) + - [**Direct payload for single recipient(target)**](#direct-payload-for-single-recipienttarget) + - [**Direct payload for group of recipients(subset)**](#direct-payload-for-group-of-recipientssubset) + - [**Direct payload for all recipients(broadcast)**](#direct-payload-for-all-recipientsbroadcast) + - [**IPFS payload for single recipient(target)**](#ipfs-payload-for-single-recipienttarget) + - [**IPFS payload for group of recipients(subset)**](#ipfs-payload-for-group-of-recipientssubset) + - [**IPFS payload for all recipients(broadcast)**](#ipfs-payload-for-all-recipientsbroadcast) + - [**Minimal payload for single recipient(target)**](#minimal-payload-for-single-recipienttarget) + - [**Minimal payload for a group of recipient(subset)**](#minimal-payload-for-a-group-of-recipientsubset) + - [**Minimal payload for all recipients(broadcast)**](#minimal-payload-for-all-recipientsbroadcast) + - [**Graph payload for single recipient(target)**](#graph-payload-for-single-recipienttarget) + - [**Graph payload for group of recipients(subset)**](#graph-payload-for-group-of-recipientssubset) + - [**Graph payload for all recipients(broadcast)**](#graph-payload-for-all-recipientsbroadcast) - [Notification Helper Utils](#notification-helper-utils) - - [Parsing notifications](#parsing-notifications) + - [**Parsing notifications**](#parsing-notifications) - [Advanced Notifications (WIP)](#advanced-notifications-wip) - [DEPRECATED](#deprecated) - - [Get a channel's subscriber list of addresses](#get-a-channels-subscriber-list-of-addresses) + - [**Get a channel's subscriber list of addresses**](#get-a-channels-subscriber-list-of-addresses) - [For Chat](#for-chat) - - [Create user for chat](#create-user-for-chat) - - [Get user data for chat](#get-user-data-for-chat) - - [Decrypting encrypted pgp private key from user data](#decrypting-encrypted-pgp-private-key-from-user-data) - - [Updating chat user profile](#updating-user-profile) - - [Fetching list of user chats](#fetching-list-of-user-chats) - - [Fetching list of user chat requests](#fetching-list-of-user-chat-requests) - - [Fetching conversation hash between two users](#fetching-conversation-hash-between-two-users) - - [Fetching latest chat between two users](#fetching-latest-chat-between-two-users) - - [Fetching chat history between two users](#fetching-chat-history-between-two-users) - - [To send a message](#to-send-a-message) - - [To approve a chat request](#to-approve-a-chat-request) - - [To create a group](#to-create-a-group) - - [To create a token gated group](#to-create-a-token-gated-group) - - [To update group details](#to-update-group-details) - - [To update token gated group details](#to-update-token-gated-group-details) - - [To get group details by group name](#to-get-group-details-by-group-name) - - [To get group details by chatId](#to-get-group-details-by-chatid) - - [Chat Helper Utils](#chat-helper-utils) - - [Decrypting messages](#decrypting-messages) + - [**Create user for chat**](#create-user-for-chat) + - [**Get user data for chat**](#get-user-data-for-chat) + - [**Decrypting encrypted pgp private key from user data**](#decrypting-encrypted-pgp-private-key-from-user-data) + - [**Updating User Profile**](#updating-user-profile) + - [**Fetching list of user chats**](#fetching-list-of-user-chats) + - [**Fetching list of user chat requests**](#fetching-list-of-user-chat-requests) + - [**Fetching conversation hash between two users**](#fetching-conversation-hash-between-two-users) + - [**Fetching latest chat between two users**](#fetching-latest-chat-between-two-users) + - [**Fetching chat history between two users**](#fetching-chat-history-between-two-users) + - [**To send a message**](#to-send-a-message) + - [**To approve a chat request**](#to-approve-a-chat-request) + - [**To create a group**](#to-create-a-group) + - [**To create a token gated group**](#to-create-a-token-gated-group) + - [**To update group details**](#to-update-group-details) + - [**To update token gated group details**](#to-update-token-gated-group-details) + - [**To get group details by group name**](#to-get-group-details-by-group-name) + - [**To get group details by chatId**](#to-get-group-details-by-chatid) + - [**Chat Helper Utils**](#chat-helper-utils) + - [**Decrypting messages**](#decrypting-messages) - [For Video](#for-video) - - [Instance Variables](#instance-variables) - - [peerInstance](#peerinstance) - - [signer](#signer) - - [chainId](#chainid) - - [pgpPrivateKey](#pgpprivatekey) - - [env](#env) - - [data](#data) - - [setData](#setdata) - - [Methods](#methods) - - [constructor](#constructor) - - [create](#create) - - [request](#request) - - [acceptRequest](#acceptrequest) - - [connect](#connect) - - [disconnect](#disconnect) - - [enableVideo](#enablevideo) - - [enableAudio](#enableaudio) - - [isInitiator](#isinitiator) + - [**Instance Variables**](#instance-variables) + - [**peerInstance**](#peerinstance) + - [**signer**](#signer) + - [**chainId**](#chainid) + - [**pgpPrivateKey**](#pgpprivatekey) + - [**env**](#env) + - [**data**](#data) + - [**setData**](#setdata) + - [**Methods**](#methods) + - [**constructor**](#constructor) + - [**create**](#create) + - [**request**](#request) + - [**acceptRequest**](#acceptrequest) + - [**connect**](#connect) + - [**disconnect**](#disconnect) + - [**enableVideo**](#enablevideo) + - [**enableAudio**](#enableaudio) + - [**isInitiator**](#isinitiator) - [For Spaces](#for-spaces) - - [To create a space](#to-create-a-space) - - [To create a token gated space](#to-create-a-token-gated-space) - - [To update space details](#to-update-space-details) - - [To update token gated space details](#to-update-token-gated-space-details) - - [To get space details by spaceId](#to-get-space-details-by-spaceId) - - [To start a space](#to-start-a-space) - - [To stop a space](#to-stop-a-space) - - [To approve a space request](#to-approve-a-space-request) - - [To add listeners to space](#to-add-listeners-to-space) - - [To remove listeners from space](#to-remove-listeners-from-space) - - [To add speakers to space](#to-add-speakers-to-space) - - [To remove speakers from space](#to-remove-speakers-from-space) - - [Fetching list of user spaces](#fetching-list-of-user-spaces) - - [Fetching list of user space requests](#fetching-list-of-user-space-requests) - - [Fetching list of trending spaces](#fetching-list-of-trending-spaces) + - [**To create a space**](#to-create-a-space) + - [**To create a token gated space**](#to-create-a-token-gated-space) + - [**To update space details**](#to-update-space-details) + - [**To update token gated space details**](#to-update-token-gated-space-details) + - [**To get space details by spaceId**](#to-get-space-details-by-spaceid) + - [**To start a space**](#to-start-a-space) + - [**To stop a space**](#to-stop-a-space) + - [**To approve a space request**](#to-approve-a-space-request) + - [**To add listeners to space**](#to-add-listeners-to-space) + - [**To remove listeners from space**](#to-remove-listeners-from-space) + - [**To add speakers to space**](#to-add-speakers-to-space) + - [**To remove speakers from space**](#to-remove-speakers-from-space) + - [**Fetching list of user spaces**](#fetching-list-of-user-spaces) + - [**Fetching list of user space requests**](#fetching-list-of-user-space-requests) + - [**Fetching list of trending spaces**](#fetching-list-of-trending-spaces) # How to use in your app? diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 2042dd33c..f4c6775d3 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -6,7 +6,7 @@ const { ENV } = Constants; export const API_BASE_URL = { [ENV.PROD]: 'https://backend.epns.io/apis', [ENV.STAGING]: 'https://backend-staging.epns.io/apis', - [ENV.DEV]: 'https://backend-dev.epns.io/apis', + [ENV.DEV]: 'http://localhost:4000/apis', /** * **This is for local development only** */ diff --git a/packages/restapi/src/lib/payloads/constants.ts b/packages/restapi/src/lib/payloads/constants.ts index 8930689f9..a3c5d9a41 100644 --- a/packages/restapi/src/lib/payloads/constants.ts +++ b/packages/restapi/src/lib/payloads/constants.ts @@ -78,4 +78,11 @@ export enum SPACE_INVITE_ROLES { SPEAKER, } +export enum SPACE_ROLES { + HOST, + CO_HOST, + SPEAKER, + LISTENER +} + export const DEFAULT_DOMAIN = 'push.org'; diff --git a/packages/restapi/src/lib/space/Space.ts b/packages/restapi/src/lib/space/Space.ts index 942271874..a7f16931f 100644 --- a/packages/restapi/src/lib/space/Space.ts +++ b/packages/restapi/src/lib/space/Space.ts @@ -12,8 +12,6 @@ import { requestToBePromoted } from './requestToBePromoted'; import { acceptPromotionRequest } from './acceptPromotionRequest'; import { rejectPromotionRequest } from './rejectPromotionRequest'; import { connectPromotor } from './connectPromotor'; -import { addSpeaker } from './addSpeaker'; -import { removeSpeaker } from './removeSpeaker'; import { join } from './join'; import { leave } from './leave'; import { stop } from './stop'; @@ -24,13 +22,28 @@ import { VideoStreamMerger } from 'video-stream-merger'; import { ChatStatus, EnvOptionsType, + LiveSpaceData, SignerType, - SpaceDTO, SpaceData, + SpaceSpecificData, } from '../types'; import { VIDEO_CALL_TYPE } from '../payloads/constants'; +import getLiveSpaceData from './helpers/getLiveSpaceData'; +import sendLiveSpaceData from './helpers/sendLiveSpaceData'; +import { META_ACTION } from '../types/metaTypes'; +import { broadcastRaisedHand } from './broadcastRaisedHand'; +import { onReceiveMetaMessage } from './onReceiveMetaMessage'; +import { onJoinListener } from './onJoinListener'; +import { pCAIP10ToWallet } from '../helpers'; + +export const initLiveSpaceData: LiveSpaceData = { + host: null, + coHosts: [], + speakers: [], + listeners: [], +}; -const initSpaceSpecificData = { +export const initSpaceSpecificData: SpaceSpecificData = { members: [], pendingMembers: [], contractAddressERC20: null, @@ -48,9 +61,10 @@ const initSpaceSpecificData = { scheduleEnd: null, status: null, inviteeDetails: {}, + liveSpaceData: initLiveSpaceData, }; -export const initSpaceData = { +export const initSpaceData: SpaceData = { ...initSpaceSpecificData, connectionData: initVideoCallData, }; @@ -64,17 +78,13 @@ export interface SpaceConstructorType extends EnvOptionsType { } // declaring the Space class - export class Space extends Video { - /* - - temporarily store the streamKey on the class - - will be used by the host to cast to the stream - */ - // protected streamKey: string | null = null; - +export class Space extends Video { protected mergeStreamObject: VideoStreamMerger | null = null; - protected spaceSpecificData: SpaceDTO; - protected setSpaceSpecificData: (fn: (data: SpaceDTO) => SpaceDTO) => void; + protected spaceSpecificData: SpaceSpecificData; + protected setSpaceSpecificData: ( + fn: (data: SpaceSpecificData) => SpaceSpecificData + ) => void; // will be exposed and should be used from outside the class to change state setSpaceData: (fn: (data: SpaceData) => SpaceData) => void; @@ -96,7 +106,11 @@ export interface SpaceConstructorType extends EnvOptionsType { pgpPrivateKey, env, callType: VIDEO_CALL_TYPE.PUSH_SPACE, - onReceiveStream: (receivedStream: MediaStream) => { + onReceiveStream: async ( + receivedStream: MediaStream, + senderAddress: string, + audio: boolean | null + ) => { // for a space, that has started broadcast & the local peer is the host if ( this.spaceSpecificData.status === ChatStatus.ACTIVE && @@ -104,6 +118,34 @@ export interface SpaceConstructorType extends EnvOptionsType { this.data.meta.broadcast.hostAddress === this.data.local.address ) { addToMergedStream(this.mergeStreamObject!, receivedStream); + + // update live space info + const oldLiveSpaceData = await getLiveSpaceData({ + localAddress: this.data.local.address, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + spaceId: this.spaceSpecificData.spaceId, + }); + const updatedLiveSpaceData = produce(oldLiveSpaceData, (draft) => { + // TODO: Create distinction between speakers and co hosts + draft.speakers.push({ + address: senderAddress, + audio, + emojiReactions: null, + }); + }); + await sendLiveSpaceData({ + liveSpaceData: updatedLiveSpaceData, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + spaceId: this.spaceSpecificData.spaceId, + signer: this.signer, + action: META_ACTION.PROMOTE_TO_ADMIN, // TODO: Add a meta action for SPEAKER_JOINED + }); + this.setSpaceSpecificData(() => ({ + ...this.spaceSpecificData, + liveSpaceData: updatedLiveSpaceData, + })); } }, setData: function () { @@ -169,7 +211,7 @@ export interface SpaceConstructorType extends EnvOptionsType { // set the local address inside video call 'data' this.setData((oldVideoCallData) => { return produce(oldVideoCallData, (draft) => { - draft.local.address = address; + draft.local.address = pCAIP10ToWallet(address); }); }); @@ -178,8 +220,7 @@ export interface SpaceConstructorType extends EnvOptionsType { // init the spaceSpecificData class variable this.spaceSpecificData = initSpaceSpecificData; - }; - + } // adding instance methods @@ -193,6 +234,12 @@ export interface SpaceConstructorType extends EnvOptionsType { public start = start; + public onReceiveMetaMessage = onReceiveMetaMessage; + + // host will call this function from socket + // will fire a meta message if a new listener has joined the space + public onJoinListener = onJoinListener; + // to promote a listener to a speaker/co-host public inviteToPromote = inviteToPromote; public acceptPromotionInvite = acceptPromotionInvite; @@ -201,17 +248,11 @@ export interface SpaceConstructorType extends EnvOptionsType { // listener requests to be promoted to a speaker public requestToBePromoted = requestToBePromoted; + public broadcastRaisedHand = broadcastRaisedHand; // will be called by the host after receiving the request to be promoted public acceptPromotionRequest = acceptPromotionRequest; public connectPromotor = connectPromotor; public rejectPromotionRequest = rejectPromotionRequest; - /* - - add/remove speaker to the space group as admins - - these methods are only to be used when the space hasnt started yet - */ - public addSpeaker = addSpeaker; - public removeSpeaker = removeSpeaker; - /* - add/remove co-host to the space group as admins - add/remove them from the meta message diff --git a/packages/restapi/src/lib/space/addSpeaker.ts b/packages/restapi/src/lib/space/addSpeaker.ts deleted file mode 100644 index 37924f724..000000000 --- a/packages/restapi/src/lib/space/addSpeaker.ts +++ /dev/null @@ -1,34 +0,0 @@ -import { EnvOptionsType } from '../types'; -import { groupDtoToSpaceDto } from '../chat/helpers'; -import { addAdmins } from '../chat/addAdmins'; - -import type Space from './Space'; - -export interface AddSpeakerType extends EnvOptionsType { - address: string; -} - -export async function addSpeaker( - this: Space, - options: AddSpeakerType -): Promise { - const { address } = options; - try { - const group = await addAdmins({ - chatId: this.spaceSpecificData.spaceId, - admins: [address], - signer: this.signer, - env: this.env, - pgpPrivateKey: this.pgpPrivateKey, - }); - - // update space specific data - this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); - } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${addSpeaker.name} -: `, - err - ); - throw Error(`[Push SDK] - API - Error - API ${addSpeaker.name} -: ${err}`); - } -} diff --git a/packages/restapi/src/lib/space/broadcastRaisedHand.ts b/packages/restapi/src/lib/space/broadcastRaisedHand.ts new file mode 100644 index 000000000..38c5251ea --- /dev/null +++ b/packages/restapi/src/lib/space/broadcastRaisedHand.ts @@ -0,0 +1,40 @@ +import { produce } from 'immer'; +import type Space from './Space'; +import getLiveSpaceData from './helpers/getLiveSpaceData'; +import sendLiveSpaceData from './helpers/sendLiveSpaceData'; +import { META_ACTION } from '../types/metaTypes'; + +export interface BroadcastRaisedHandType { + promoteeAddress: string; +} + +export async function broadcastRaisedHand( + this: Space, + options: BroadcastRaisedHandType +) { + const { promoteeAddress } = options || {}; + + // update live space info + const oldLiveSpaceData = await getLiveSpaceData({ + localAddress: this.data.local.address, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + spaceId: this.spaceSpecificData.spaceId, + }); + const updatedLiveSpaceData = produce(oldLiveSpaceData, (draft) => { + const listnerIndex = draft.listeners.findIndex(listner => listner.address === promoteeAddress); + draft.listeners[listnerIndex].handRaised = true; + }); + await sendLiveSpaceData({ + liveSpaceData: updatedLiveSpaceData, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + spaceId: this.spaceSpecificData.spaceId, + signer: this.signer, + action: META_ACTION.USER_INTERACTION, + }); + this.setSpaceSpecificData(() => ({ + ...this.spaceSpecificData, + liveSpaceData: updatedLiveSpaceData, + })); +} diff --git a/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts b/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts new file mode 100644 index 000000000..4417ba0c1 --- /dev/null +++ b/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts @@ -0,0 +1,64 @@ +import { conversationHash, history } from '../../chat'; +import { MessageType } from '../../constants'; +import { EnvOptionsType, LiveSpaceData } from '../../types'; +import { initLiveSpaceData } from '../Space'; + +interface GetLatestMessageType extends EnvOptionsType { + localAddress: string; + spaceId: string; + pgpPrivateKey: string; +} + +const getLiveSpaceData = async ({ + localAddress, + spaceId, + pgpPrivateKey, + env, +}: GetLatestMessageType) => { + const threadhash = ( + await conversationHash({ + account: localAddress, + conversationId: spaceId, + env, + }) + ).threadHash; + + let liveSpaceData = initLiveSpaceData; + + // fetch the message history to retrieve the latest meta message + for (let i = 0; i < 10; i++) { + const messages = await history({ + threadhash, + account: localAddress, + pgpPrivateKey, + toDecrypt: true, + env, + }); + + let latestMetaMessage = null; + for (const message of messages) { + if ( + message.messageType === MessageType.META && + typeof message.messageObj === 'object' && + message.messageObj !== null + ) { + latestMetaMessage = message; + break; + } + } + + if ( + latestMetaMessage !== null && + typeof latestMetaMessage.messageObj === 'object' && + latestMetaMessage.messageObj !== null + ) { + // found the latest meta message + liveSpaceData = latestMetaMessage.messageObj?.meta?.info + ?.arbitrary as LiveSpaceData; + } + } + + return liveSpaceData; +}; + +export default getLiveSpaceData; diff --git a/packages/restapi/src/lib/space/helpers/getPlainAddress.ts b/packages/restapi/src/lib/space/helpers/getPlainAddress.ts new file mode 100644 index 000000000..d24da128a --- /dev/null +++ b/packages/restapi/src/lib/space/helpers/getPlainAddress.ts @@ -0,0 +1,5 @@ +const getPlainAddress = (prefixedAddress: string) => { + return prefixedAddress.replace('eip155:', ''); +}; + +export default getPlainAddress; diff --git a/packages/restapi/src/lib/space/helpers/getSpaceListeners.ts b/packages/restapi/src/lib/space/helpers/getSpaceListeners.ts new file mode 100644 index 000000000..e989dd2a7 --- /dev/null +++ b/packages/restapi/src/lib/space/helpers/getSpaceListeners.ts @@ -0,0 +1,25 @@ +const getSpaceListeners = ( + members: { + wallet: string; + publicKey: string; + isSpeaker: boolean; + image: string; + }[] +) => { + const listeners: { + wallet: string; + publicKey: string; + isSpeaker: boolean; + image: string; + }[] = []; + + members.forEach((member) => { + if (!member.isSpeaker) { + listeners.push(member); + } + }); + + return listeners; +}; + +export default getSpaceListeners; diff --git a/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts b/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts new file mode 100644 index 000000000..7ca8b99dd --- /dev/null +++ b/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts @@ -0,0 +1,41 @@ +import { send } from '../../chat'; +import { MessageType } from '../../constants'; +import { EnvOptionsType, LiveSpaceData, SignerType } from '../../types'; +import { META_ACTION } from '../../types/metaTypes'; + +interface SendLiveSpaceData extends EnvOptionsType { + liveSpaceData?: LiveSpaceData; + action: META_ACTION; + spaceId: string; + pgpPrivateKey: string; + signer: SignerType; +} + +const sendLiveSpaceData = async ({ + liveSpaceData, + action, + spaceId, + pgpPrivateKey, + signer, + env, +}: SendLiveSpaceData) => { + await send({ + receiverAddress: spaceId, + pgpPrivateKey, + env, + signer, + messageType: MessageType.META, + messageObj: { + content: 'PUSH SPACE META MESSAGE', + meta: { + action, + info: { + affected: [], + arbitrary: liveSpaceData, + }, + }, + }, + }); +}; + +export default sendLiveSpaceData; diff --git a/packages/restapi/src/lib/space/index.ts b/packages/restapi/src/lib/space/index.ts index d2824b32e..e2ea49306 100644 --- a/packages/restapi/src/lib/space/index.ts +++ b/packages/restapi/src/lib/space/index.ts @@ -1,3 +1,5 @@ +export * from './helpers/getPlainAddress'; + export * from './spaces'; export * from './trending'; export * from './get'; diff --git a/packages/restapi/src/lib/space/initialize.ts b/packages/restapi/src/lib/space/initialize.ts index 85f3dc682..27dc51e5d 100644 --- a/packages/restapi/src/lib/space/initialize.ts +++ b/packages/restapi/src/lib/space/initialize.ts @@ -1,5 +1,7 @@ +import { ChatStatus } from '../types'; import type Space from './Space'; import { get } from './get'; +import getLiveSpaceData from './helpers/getLiveSpaceData'; export interface InitializeType { spaceId: string; @@ -13,5 +15,17 @@ export async function initialize(this: Space, options: InitializeType) { env: this.env, }); - this.setSpaceSpecificData(() => space); + let liveSpaceData = this.spaceSpecificData.liveSpaceData; + + // if the space is active then fetch the latest meta message and update the live space data state + if (space.status === ChatStatus.ACTIVE) { + liveSpaceData = await getLiveSpaceData({ + localAddress: this.data.local.address, + spaceId, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + }); + } + + this.setSpaceSpecificData(() => ({ ...space, liveSpaceData })); } diff --git a/packages/restapi/src/lib/space/join.ts b/packages/restapi/src/lib/space/join.ts index 7e3342c59..8bb82c441 100644 --- a/packages/restapi/src/lib/space/join.ts +++ b/packages/restapi/src/lib/space/join.ts @@ -1,9 +1,9 @@ -import { - SPACE_REQUEST_TYPE, -} from '../payloads/constants'; +import { SPACE_REQUEST_TYPE } from '../payloads/constants'; import { ChatStatus } from '../types'; import { approve } from './approve'; import { get } from './get'; +import getIncomingIndexFromAddress from '../video/helpers/getIncomingIndexFromAddress'; +import getPlainAddress from './helpers/getPlainAddress'; import type Space from './Space'; /** @@ -25,8 +25,9 @@ export async function join(this: Space) { let isSpeaker = false; let isListner = false; + const localAddress = getPlainAddress(this.data.local.address); space.members.forEach((member) => { - if (member.wallet === this.data.local.address) { + if (getPlainAddress(member.wallet) === localAddress) { if (member.isSpeaker) { isSpeaker = true; } else { @@ -37,17 +38,38 @@ export async function join(this: Space) { let isSpeakerPending = false; space.pendingMembers.forEach((pendingMember) => { if ( - pendingMember.wallet === this.data.local.address && + getPlainAddress(pendingMember.wallet) === localAddress && pendingMember.isSpeaker ) { isSpeakerPending = true; } }); + console.log( + 'ISSPEAKER', + isSpeaker, + 'isListner', + isListner, + 'isSpeakerPending', + isSpeakerPending + ); + + const hostAddress = getPlainAddress(space.spaceCreator); + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + hostAddress + ); + + // check if we arent already connected to the host + if ((isSpeaker || isSpeakerPending) && incomingIndex > -1) { + return Promise.resolve(); + } + // acc to the found role (speaker or listner), executing req logic // if speaker is pending then approve first or if listner is pending/not found then approve first - if (isSpeakerPending || !isListner) { + if (!isSpeaker && !isListner) { + console.log('CALLING APPROVE'); await approve({ signer: this.signer, pgpPrivateKey: this.pgpPrivateKey, @@ -58,7 +80,7 @@ export async function join(this: Space) { if (isSpeaker || isSpeakerPending) { // Call the host and join the mesh connection - const hostAddress = space.spaceCreator.replace('eip155:', ''); + console.log('CALLING REQUEST'); await this.request({ senderAddress: this.data.local.address, recipientAddress: hostAddress, @@ -74,8 +96,12 @@ export async function join(this: Space) { spaceId: this.spaceSpecificData.spaceId, env: this.env, }); + console.log('UPDATED SPACE', updatedSpace); // update space specific data - this.setSpaceSpecificData(() => updatedSpace); + this.setSpaceSpecificData(() => ({ + ...updatedSpace, + liveSpaceData: this.spaceSpecificData.liveSpaceData, + })); } catch (err) { console.error(`[Push SDK] - API - Error - API ${join.name} -: `, err); throw Error(`[Push SDK] - API - Error - API ${join.name} -: ${err}`); diff --git a/packages/restapi/src/lib/space/leave.ts b/packages/restapi/src/lib/space/leave.ts index 12121a86c..abbfc4b0b 100644 --- a/packages/restapi/src/lib/space/leave.ts +++ b/packages/restapi/src/lib/space/leave.ts @@ -10,7 +10,7 @@ export async function leave(this: Space): Promise { // handle the case where a listner is leaving // disconnect with every incoming peer in the mesh connection - this.data.incoming.forEach(({ address }) => { + this.data.incoming.slice(1).forEach(({ address }) => { this.disconnect({ peerAddress: address, details: { diff --git a/packages/restapi/src/lib/space/onJoinListener.ts b/packages/restapi/src/lib/space/onJoinListener.ts new file mode 100644 index 000000000..176dfdcbc --- /dev/null +++ b/packages/restapi/src/lib/space/onJoinListener.ts @@ -0,0 +1,71 @@ +import { pCAIP10ToWallet } from '../helpers'; +import getLiveSpaceData from './helpers/getLiveSpaceData'; +import getSpaceListeners from './helpers/getSpaceListeners'; +import sendLiveSpaceData from './helpers/sendLiveSpaceData'; + +import { ListenerPeer, SpaceDTO } from '../types'; +import { META_ACTION } from '../types/metaTypes'; +import type Space from './Space'; + +export interface OnJoinListenerType { + receivedSpaceData: SpaceDTO; +} + +export async function onJoinListener(this: Space, options: OnJoinListenerType) { + const { receivedSpaceData } = options || {}; + + if ( + pCAIP10ToWallet(this.spaceSpecificData.spaceCreator) !== + this.data.local.address + ) { + return; + } + + // check whether any new listener has joined by comparing this.spaceSpecificData and receivedLiveSpaceData + const fetchedLiveSpaceData = await getLiveSpaceData({ + localAddress: this.data.local.address, + spaceId: this.spaceSpecificData.spaceId, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + }); + const localListeners = fetchedLiveSpaceData.listeners; + const receivedListeners = getSpaceListeners(receivedSpaceData.members); + + const localListenerAddresses: { + [key: string]: number; + } = {}; + localListeners.map((listener, index) => { + localListenerAddresses[pCAIP10ToWallet(listener.address)] = index; + }); + + const updatedListeners: ListenerPeer[] = []; + + let areListenersChanged = false; + + for (const listener of receivedListeners) { + const index = localListenerAddresses[pCAIP10ToWallet(listener.wallet)]; + + if (!areListenersChanged) areListenersChanged = Boolean(!index); + + updatedListeners.push( + index + ? localListeners[index] + : { + address: listener.wallet, + handRaised: false, + emojiReactions: null, + } + ); + } + + if (areListenersChanged) { + sendLiveSpaceData({ + spaceId: this.spaceSpecificData.spaceId, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + signer: this.signer, + liveSpaceData: { ...fetchedLiveSpaceData, listeners: updatedListeners }, + action: META_ACTION.ADD_LISTENER, + }); + } +} diff --git a/packages/restapi/src/lib/space/onReceiveMetaMessage.ts b/packages/restapi/src/lib/space/onReceiveMetaMessage.ts new file mode 100644 index 000000000..26b626592 --- /dev/null +++ b/packages/restapi/src/lib/space/onReceiveMetaMessage.ts @@ -0,0 +1,18 @@ +import { LiveSpaceData } from '../types'; +import type Space from './Space'; + +export interface OnReceiveMetaMessageType { + receivedLiveSpaceData: LiveSpaceData; +} + +export async function onReceiveMetaMessage( + this: Space, + options: OnReceiveMetaMessageType +) { + const { receivedLiveSpaceData } = options || {}; + + this.setSpaceSpecificData(() => ({ + ...this.spaceSpecificData, + liveSpaceData: receivedLiveSpaceData, + })); +} diff --git a/packages/restapi/src/lib/space/rejectPromotionRequest.ts b/packages/restapi/src/lib/space/rejectPromotionRequest.ts index b4eddee56..abc5cc7bf 100644 --- a/packages/restapi/src/lib/space/rejectPromotionRequest.ts +++ b/packages/restapi/src/lib/space/rejectPromotionRequest.ts @@ -1,4 +1,8 @@ +import { produce } from 'immer'; import type Space from './Space'; +import getLiveSpaceData from './helpers/getLiveSpaceData'; +import sendLiveSpaceData from './helpers/sendLiveSpaceData'; +import { META_ACTION } from '../types/metaTypes'; export interface RejectPromotionRequestType { promoteeAddress: string; @@ -14,4 +18,28 @@ export async function rejectPromotionRequest( this.disconnect({ peerAddress: promoteeAddress, }); + + // update live space info + const oldLiveSpaceData = await getLiveSpaceData({ + localAddress: this.data.local.address, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + spaceId: this.spaceSpecificData.spaceId, + }); + const updatedLiveSpaceData = produce(oldLiveSpaceData, (draft) => { + const listnerIndex = draft.listeners.findIndex(listner => listner.address === promoteeAddress); + draft.listeners[listnerIndex].handRaised = false; + }); + await sendLiveSpaceData({ + liveSpaceData: updatedLiveSpaceData, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + spaceId: this.spaceSpecificData.spaceId, + signer: this.signer, + action: META_ACTION.USER_INTERACTION, // TODO: Add a reject request type + }); + this.setSpaceSpecificData(() => ({ + ...this.spaceSpecificData, + liveSpaceData: updatedLiveSpaceData, + })); } diff --git a/packages/restapi/src/lib/space/removeSpeaker.ts b/packages/restapi/src/lib/space/removeSpeaker.ts deleted file mode 100644 index 84c214d02..000000000 --- a/packages/restapi/src/lib/space/removeSpeaker.ts +++ /dev/null @@ -1,37 +0,0 @@ -import { EnvOptionsType } from '../types'; -import { groupDtoToSpaceDto } from '../chat/helpers'; -import { - removeAdmins -} from '../chat/removeAdmins'; -import type Space from './Space'; - -export interface RemoveSpeakerType extends EnvOptionsType { - address: string; -} - -export async function removeSpeaker( - this: Space, - options: RemoveSpeakerType -): Promise { - const { address } = options; - try { - const group = await removeAdmins({ - chatId: this.spaceSpecificData.spaceId, - admins: [address], - signer: this.signer, - env: this.env, - pgpPrivateKey: this.pgpPrivateKey, - }); - - // update space specific data - this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); - } catch (err) { - console.error( - `[Push SDK] - API - Error - API ${removeSpeaker.name} -: `, - err - ); - throw Error( - `[Push SDK] - API - Error - API ${removeSpeaker.name} -: ${err}` - ); - } -} diff --git a/packages/restapi/src/lib/space/requestToBePromoted.ts b/packages/restapi/src/lib/space/requestToBePromoted.ts index b52992841..80b9c7d13 100644 --- a/packages/restapi/src/lib/space/requestToBePromoted.ts +++ b/packages/restapi/src/lib/space/requestToBePromoted.ts @@ -3,7 +3,6 @@ import type Space from './Space'; export interface RequestToBePromotedType { role: SPACE_INVITE_ROLES; - spaceId: string; promotorAddress: string; } @@ -11,13 +10,13 @@ export async function requestToBePromoted( this: Space, options: RequestToBePromotedType ) { - const { role, spaceId, promotorAddress } = options || {}; + const { role, promotorAddress } = options || {}; // requesting host to include local computer into the mesh connection this.request({ senderAddress: this.data.local.address, recipientAddress: promotorAddress, - chatId: spaceId, + chatId: this.spaceSpecificData.spaceId, details: { type: SPACE_REQUEST_TYPE.REQUEST_TO_PROMOTE, data: { diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts index f15f28449..79a641030 100644 --- a/packages/restapi/src/lib/space/start.ts +++ b/packages/restapi/src/lib/space/start.ts @@ -1,4 +1,9 @@ -import { EnvOptionsType, SignerType, ChatStatus } from '../types'; +import { + EnvOptionsType, + SignerType, + ChatStatus, + LiveSpaceData, +} from '../types'; import { groupDtoToSpaceDto, getSpacesMembersList, @@ -19,6 +24,9 @@ export interface StartSpaceType extends EnvOptionsType { import type Space from './Space'; import { produce } from 'immer'; +import { pCAIP10ToWallet } from '../helpers'; +import { META_ACTION } from '../types/metaTypes'; +import sendLiveSpaceData from './helpers/sendLiveSpaceData'; type StartType = { livepeerApiKey: string; @@ -28,8 +36,6 @@ export async function start(this: Space, options: StartType): Promise { const { livepeerApiKey } = options || {}; try { - // TODO: Only allow the host to execute this function - // host should have there audio stream if (!this.data.local.stream) { throw new Error('Local audio stream not found'); @@ -46,6 +52,11 @@ export async function start(this: Space, options: StartType): Promise { ); } + // Only host is allowed to start a space + if (this.data.local.address !== pCAIP10ToWallet(space.spaceCreator)) { + throw new Error('Only host is allowed to start a space'); + } + const convertedMembers = getSpacesMembersList( space.members, space.pendingMembers @@ -70,11 +81,32 @@ export async function start(this: Space, options: StartType): Promise { status: ChatStatus.ACTIVE, }); + const liveSpaceData: LiveSpaceData = { + host: { + address: this.data.local.address, + audio: this.data.local.audio, + emojiReactions: null, + }, + coHosts: [], + speakers: [], + listeners: [], + }; + + await sendLiveSpaceData({ + liveSpaceData, + action: META_ACTION.CREATE_SPACE, + spaceId: this.spaceSpecificData.spaceId, + signer: this.signer, + pgpPrivateKey: this.pgpPrivateKey, + env: this.env, + }); + // update space data this.setSpaceData((oldSpaceData) => { return produce(oldSpaceData, (draft) => { draft = { ...groupDtoToSpaceDto(group), + liveSpaceData, connectionData: draft.connectionData, }; draft.connectionData.meta.broadcast = { diff --git a/packages/restapi/src/lib/space/stop.ts b/packages/restapi/src/lib/space/stop.ts index 4f69914ec..9a3e82114 100644 --- a/packages/restapi/src/lib/space/stop.ts +++ b/packages/restapi/src/lib/space/stop.ts @@ -48,7 +48,10 @@ export async function stop(this: Space): Promise { }); // update space specific data - this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); + this.setSpaceSpecificData(() => ({ + ...groupDtoToSpaceDto(group), + liveSpaceData: this.spaceSpecificData.liveSpaceData, + })); // stop livepeer playback @@ -56,7 +59,7 @@ export async function stop(this: Space): Promise { - disconnect with every incoming peer in the mesh connection - other peers should also end their connections as we want to destroy the mesh connection */ - this.data.incoming.forEach(({ address }) => { + this.data.incoming.slice(1).forEach(({ address }) => { this.disconnect({ peerAddress: address, details: { diff --git a/packages/restapi/src/lib/space/update.ts b/packages/restapi/src/lib/space/update.ts index 266baf456..2ccbea8ef 100644 --- a/packages/restapi/src/lib/space/update.ts +++ b/packages/restapi/src/lib/space/update.ts @@ -63,7 +63,10 @@ export async function update( }); // update space specific data - this.setSpaceSpecificData(() => groupDtoToSpaceDto(group)); + this.setSpaceSpecificData(() => ({ + ...groupDtoToSpaceDto(group), + liveSpaceData: this.spaceSpecificData.liveSpaceData, + })); } catch (err) { console.error(`[Push SDK] - API - Error - API ${update.name} -: `, err); throw Error(`[Push SDK] - API - Error - API ${update.name} -: ${err}`); diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index a3b440803..e99f6d158 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -306,7 +306,7 @@ export interface Member { export enum ChatStatus { ACTIVE = 'ACTIVE', PENDING = 'PENDING', - ENDED = 'ENDED' + ENDED = 'ENDED', } export interface GroupDTO { members: { @@ -368,7 +368,34 @@ export interface SpaceDTO { inviteeDetails?: { [key: string]: SPACE_INVITE_ROLES }; } -export interface SpaceData extends SpaceDTO { +export interface Peer { + address: string; + emojiReactions: { + emoji: string; + expiresIn: string; + } | null; +} + +export interface ListenerPeer extends Peer { + handRaised: boolean; +} + +export interface AdminPeer extends Peer { + audio: boolean | null; +} + +export interface LiveSpaceData { + host: AdminPeer | null; + coHosts: AdminPeer[]; + speakers: AdminPeer[]; + listeners: ListenerPeer[]; +} + +export interface SpaceSpecificData extends SpaceDTO { + liveSpaceData: LiveSpaceData; +} + +export interface SpaceData extends SpaceSpecificData { connectionData: VideoCallData; } diff --git a/packages/restapi/src/lib/types/metaTypes.ts b/packages/restapi/src/lib/types/metaTypes.ts index e87c1ee7b..a5fc4ddf9 100644 --- a/packages/restapi/src/lib/types/metaTypes.ts +++ b/packages/restapi/src/lib/types/metaTypes.ts @@ -2,7 +2,7 @@ * This file defines the type for meta property for a Push Chat message */ -const enum META_ACTION { +export const enum META_ACTION { /** * DEFAULT GROUP ACTIONS */ diff --git a/packages/restapi/src/lib/video/Video.ts b/packages/restapi/src/lib/video/Video.ts index f1d340979..df7618e72 100644 --- a/packages/restapi/src/lib/video/Video.ts +++ b/packages/restapi/src/lib/video/Video.ts @@ -55,6 +55,7 @@ export const initVideoCallData: VideoCallData = { video: null, address: '', }, + // TODO: Remove the default element in incoming array incoming: [ { stream: null, @@ -74,7 +75,7 @@ export class Video { protected pgpPrivateKey: string; protected env: ENV; protected callType: VIDEO_CALL_TYPE; - protected onReceiveStream: (receivedStream: MediaStream) => void; + protected onReceiveStream: (receivedStream: MediaStream, senderAddress: string, audio:boolean | null) => Promise; // storing the peer instance private peerInstances: { @@ -91,8 +92,8 @@ export class Video { env = Constants.ENV.PROD, setData, callType = VIDEO_CALL_TYPE.PUSH_VIDEO, - onReceiveStream = () => { - return; + onReceiveStream = async () => { + return Promise.resolve(); }, }: { signer: SignerType; @@ -101,7 +102,7 @@ export class Video { setData: (fn: (data: VideoCallData) => VideoCallData) => void; env?: ENV; callType?: VIDEO_CALL_TYPE; - onReceiveStream?: (receivedStream: MediaStream) => void; + onReceiveStream?: (receivedStream: MediaStream, senderAddress: string, audio:boolean | null) => Promise; }) { this.signer = signer; this.chainId = chainId; @@ -257,14 +258,33 @@ export class Video { value: this.data.local.audio, }) ); + // send the addresses the local peer is connected to remote peer + const connectedAddresses = getConnectedAddresses({ + incomingPeers: this.data.incoming, + }); + console.log( + 'REQUEST - SENDING THE CONNECTED ADDRESSES', + 'connectedAddresses', + connectedAddresses + ); + this.peerInstances[recipientAddress].send( + JSON.stringify({ + type: 'connectedAddresses', + value: connectedAddresses, + }) + ); }); this.peerInstances[recipientAddress].on('data', (data: any) => { if (isJSON(data)) { const parsedData = JSON.parse(data); - if (parsedData.type === 'connectedAddress') { - console.log('CONNECTED ADDRESSES', parsedData.value); + if (parsedData.type === 'connectedAddresses') { + console.log( + 'REQUEST - RECEIVING CONNECTED ADDRESSES', + 'CONNECTED ADDRESSES', + parsedData.value + ); const receivedConnectedAddresses = parsedData.value; const localConnectedAddresses = getConnectedAddresses({ @@ -278,17 +298,15 @@ export class Video { localConnectedAddresses, receivedConnectedAddresses, }); - for (const connectToAddress of connectToAddresses) { - this.request({ - senderAddress, - recipientAddress: connectToAddress, - chatId, - details: { - type: SPACE_REQUEST_TYPE.ESTABLISH_MESH, - data: {}, - }, - }); - } + this.request({ + senderAddress, + recipientAddress: connectToAddresses, + chatId, + details: { + type: SPACE_REQUEST_TYPE.ESTABLISH_MESH, + data: {}, + }, + }); } if (parsedData.type === 'isVideoOn') { @@ -371,13 +389,13 @@ export class Video { 'stream', (currentStream: MediaStream) => { console.log('received incoming stream', currentStream); - this.onReceiveStream(currentStream); + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + recipientAddress + ); + this.onReceiveStream(currentStream, recipientAddress, this.data.incoming[incomingIndex].audio) this.setData((oldData) => { return produce(oldData, (draft) => { - const incomingIndex = getIncomingIndexFromAddress( - oldData.incoming, - recipientAddress - ); draft.incoming[incomingIndex].stream = currentStream; }); }); @@ -478,6 +496,7 @@ export class Video { status: VideoCallStatus.RETRY_INITIALIZED, chatId, signalData: null, + callType: this.callType, env: this.env, } ); @@ -527,6 +546,22 @@ export class Video { }) ); + // send the addresses the local peer is connected to remote peer + const connectedAddresses = getConnectedAddresses({ + incomingPeers: this.data.incoming, + }); + console.log( + 'ACCEPT REQUEST - SENDING THE CONNECTED ADDRESSES', + 'connectedAddresses', + connectedAddresses + ); + this.peerInstances[recipientAddress].send( + JSON.stringify({ + type: 'connectedAddresses', + value: connectedAddresses, + }) + ); + // set videoCallInfo state with status connected for the receiver's end this.setData((oldData) => { return produce(oldData, (draft) => { @@ -543,8 +578,12 @@ export class Video { if (isJSON(data)) { const parsedData = JSON.parse(data); - if (parsedData.type === 'connectedAddress') { - console.log('CONNECTED ADDRESSES', parsedData.value); + if (parsedData.type === 'connectedAddresses') { + console.log( + 'ACCEPT REQUEST - RECEIVING CONNECTED ADDRESSES', + 'CONNECTED ADDRESSES', + parsedData.value + ); const receivedConnectedAddresses = parsedData.value; const localConnectedAddresses = getConnectedAddresses({ @@ -558,25 +597,15 @@ export class Video { localConnectedAddresses, receivedConnectedAddresses, }); - for (const connectToAddress of connectToAddresses) { - this.request({ - senderAddress, - recipientAddress: connectToAddress, - chatId, - details: { - type: SPACE_REQUEST_TYPE.ESTABLISH_MESH, - data: {}, - }, - }); - } - - // send the addresses the local peer is connected to remote peer - this.peerInstances[recipientAddress].send( - JSON.stringify({ - type: 'connectedAddresses', - value: localConnectedAddresses, - }) - ); + this.request({ + senderAddress, + recipientAddress: connectToAddresses, + chatId, + details: { + type: SPACE_REQUEST_TYPE.ESTABLISH_MESH, + data: {}, + }, + }); } if (parsedData.type === 'isVideoOn') { @@ -659,13 +688,13 @@ export class Video { 'stream', (currentStream: MediaStream) => { console.log('received incoming stream', currentStream); - this.onReceiveStream(currentStream); + const incomingIndex = getIncomingIndexFromAddress( + this.data.incoming, + recipientAddress + ); + this.onReceiveStream(currentStream, recipientAddress, this.data.incoming[incomingIndex].audio); this.setData((oldData) => { return produce(oldData, (draft) => { - const incomingIndex = getIncomingIndexFromAddress( - oldData.incoming, - recipientAddress - ); draft.incoming[incomingIndex].stream = currentStream; }); }); @@ -707,17 +736,6 @@ export class Video { this.peerInstances[peerAddress]?.signal(signalData); - // send the addresses the local peer is connected to remote peer - const connectedAddresses = getConnectedAddresses({ - incomingPeers: this.data.incoming, - }); - this.peerInstances[peerAddress].send( - JSON.stringify({ - type: 'connectedAddresses', - value: connectedAddresses, - }) - ); - // set videoCallInfo state with status connected for the caller's end this.setData((oldData) => { return produce(oldData, (draft) => { @@ -737,6 +755,8 @@ export class Video { const { peerAddress, details } = options || {}; try { + console.log("DISCONNECT OPTIONS", options); + const incomingIndex = getIncomingIndexFromAddress( this.data.incoming, peerAddress @@ -800,20 +820,16 @@ export class Video { if (this.data.local.video !== state) { // need to change the video state - const incomingIndex = getIncomingIndexFromAddress( - this.data.incoming, - peerAddress - ); - - if ( - this.data.incoming[incomingIndex].status === VideoCallStatus.CONNECTED - ) { - this.peerInstances[peerAddress]?.send( - JSON.stringify({ - type: 'isVideoOn', - value: state, - }) - ); + // signal all the connected peers that the local peer has changed their video state + for (const incomingPeer of this.data.incoming) { + if (incomingPeer.status === VideoCallStatus.CONNECTED) { + this.peerInstances[incomingPeer.address]?.send( + JSON.stringify({ + type: 'isVideoOn', + value: state, + }) + ); + } } if (this.data.local.stream) { if (state) { @@ -836,17 +852,13 @@ export class Video { if (this.data.local.audio !== state) { // need to change the audio state - const incomingIndex = getIncomingIndexFromAddress( - this.data.incoming, - peerAddress - ); - - if ( - this.data.incoming[incomingIndex].status === VideoCallStatus.CONNECTED - ) { - this.peerInstances[peerAddress]?.send( - JSON.stringify({ type: 'isAudioOn', value: state }) - ); + // signal all the connected peers that the local peer has changed their audio state + for (const incomingPeer of this.data.incoming) { + if (incomingPeer.status === VideoCallStatus.CONNECTED) { + this.peerInstances[incomingPeer.address]?.send( + JSON.stringify({ type: 'isAudioOn', value: state }) + ); + } } if (this.data.local.stream) { if (state) { diff --git a/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts b/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts index 7e9d9a149..89671145d 100644 --- a/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts +++ b/packages/restapi/src/lib/video/helpers/getConnectedAddresses.ts @@ -1,3 +1,4 @@ +import getPlainAddress from '../../space/helpers/getPlainAddress'; import { PeerData, VideoCallStatus } from '../../types'; const getConnectedAddresses = ({ @@ -8,7 +9,7 @@ const getConnectedAddresses = ({ const connectedAddresses: string[] = []; incomingPeers.forEach((incomingPeer) => { if (incomingPeer.status === VideoCallStatus.CONNECTED) { - connectedAddresses.push(incomingPeer.address); + connectedAddresses.push(getPlainAddress(incomingPeer.address)); } }); return connectedAddresses; diff --git a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts index 935375d6e..ab4b2664e 100644 --- a/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts +++ b/packages/restapi/src/lib/video/helpers/sendVideoCallNotification.ts @@ -93,8 +93,7 @@ const sendVideoCallNotification = async ( cta: '', img: '', additionalMeta: { - // type: `${callType}+1`, - type: `${VIDEO_CALL_TYPE.PUSH_VIDEO}+1`, + type: `${callType}+1`, data: JSON.stringify(videoData), }, }, diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 032942928..182d1e341 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,29 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.3...uiweb-1.1.4) (2023-07-20) + + +### Bug Fixes + +* merge main ([24784e9](https://github.com/ethereum-push-notification-service/push-sdk/commit/24784e9ceca8f3757481f3be72efd0ca1ff3fba8)) + + + +## [1.1.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.2...uiweb-1.1.3) (2023-07-20) + + +### Bug Fixes + +* fixed bugs ([#566](https://github.com/ethereum-push-notification-service/push-sdk/issues/566)) ([481d8fc](https://github.com/ethereum-push-notification-service/push-sdk/commit/481d8fcd7c40325654ba490640daabc38ee2f96e)) +* Merge branch 'main' into deployment ([9f77f39](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f77f391b26111006891c10a3cc8eab06e26f14f)) + + + +## [1.1.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.1...uiweb-1.1.2) (2023-07-18) + + + ## [1.1.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.0...uiweb-1.1.1) (2023-07-17) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index f61be7256..b8a2a0e2a 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.1", + "version": "1.1.4", "publishConfig": { "registry": "https://registry.npmjs.org/" }, @@ -13,7 +13,7 @@ "html-react-parser": "^1.4.13", "gif-picker-react": "^1.1.0", "font-awesome": "^4.7.0", - "moment":"^2.29.4" + "moment": "^2.29.4" }, "peerDependencies": { "@pushprotocol/restapi": "^1.2.15", diff --git a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx index 1af763bba..535924540 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx @@ -1,4 +1,4 @@ -import React, { useEffect, useState, useContext } from 'react'; +import React, { useEffect, useState, useContext, useRef } from 'react'; import styled from 'styled-components'; import { MinimisedModalHeader } from './MinimisedModalHeader'; @@ -45,9 +45,11 @@ export const ChatAndNotification = () => { requestsFeed, chatsFeed, selectedChatId, + setFinishedFetchingChats, + setFinishedFetchingRequests, setChats } = useContext(ChatMainStateContext); - const { setInboxNotifsFeed, setSpamNotifsFeed } = useContext( + const { setInboxNotifsFeed, setSpamNotifsFeed,setFinishedFetchingInbox,setFinishedFetchingSpam } = useContext( NotificationMainStateContext ); const { @@ -63,6 +65,7 @@ export const ChatAndNotification = () => { const { fetchRequests } = useFetchRequests(); const { fetchChats } = useFetchChats(); const { fetchChat } = useFetchChat(); + const modalRef = useRef(null); const { fetchUserSubscriptions } = useFetchUserSubscriptions(); useChatNotificationSocket({}); @@ -73,6 +76,10 @@ export const ChatAndNotification = () => { setRequestsFeed({}); setInboxNotifsFeed({}); setSpamNotifsFeed({}); + setFinishedFetchingInbox(false); + setFinishedFetchingSpam(false); + setFinishedFetchingChats(false); + setFinishedFetchingRequests(false); // set active tab if present if (activeChosenTab) { setActiveTab(activeChosenTab); @@ -157,7 +164,7 @@ export const ChatAndNotification = () => { selectedChat = getDefaultFeedObject({ user: result }); } } - + } setSearchedChats({ [selectedChat.did.toLowerCase() ?? selectedChat.chatId]: selectedChat, @@ -182,13 +189,31 @@ export const ChatAndNotification = () => { setModalOpen(!modalOpen); }; - const toggleOverflow = (val: string) => { - if (typeof window != 'undefined' && window.document) { - document.body.style.overflowY = val; - } - }; - + + useEffect(() => { + const modalElement = modalRef.current; + if (!modalElement) return; + + const handleScroll = (event: WheelEvent) => { + const { scrollTop, scrollHeight, clientHeight } = modalElement; + const isScrolledToBottom = scrollTop + clientHeight >= scrollHeight; + + // If scrolled to the bottom of the modal, prevent further scrolling + if (isScrolledToBottom && event.deltaY > 0) { + // event.preventDefault(); + event.stopPropagation(); + } + }; + + modalElement.addEventListener('wheel', handleScroll); + + // Cleanup the event listener when the component unmounts + return () => { + modalElement.removeEventListener('wheel', handleScroll); + }; + }, []); + return ( { background="#fff" right="12px" bottom="18px" + className='modal' overflow="hidden" - + ref={modalRef} + // onMouseEnter={() => toggleOverflow('hidden')} // onMouseLeave={() => toggleOverflow('auto')} > diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx index 4b13966ce..68e1679cc 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx @@ -17,7 +17,7 @@ import { SidebarPlaceholder } from '../SidebarPlaceholder'; import type { ChatMainStateContextType } from '../../../../../context/chatAndNotification/chat/chatMainStateContext'; export const ChatsFeedList = () => { - const { chatsFeed, setChatsFeed } = + const { chatsFeed, setChatsFeed,finishedFetchingChats,setFinishedFetchingChats } = useContext(ChatMainStateContext); const pageRef = useRef(null); const [page, setPage] = useState(1); @@ -46,7 +46,7 @@ export const ChatsFeedList = () => { useEffect(() => { if ( !isInViewport1 || - loading + loading || finishedFetchingChats // || // Object.keys(chatsFeed).length < chatLimit ) { @@ -66,6 +66,7 @@ export const ChatsFeedList = () => { try { setPaginateLoading(true); const feeds = await fetchChats({ page, chatLimit }); + if(!Object.keys(feeds || {}).length) setFinishedFetchingChats(true); const newFeed: ChatFeedsType = { ...chatsFeed, ...feeds }; setChatsFeed(newFeed); } catch (error) { diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx index 4b8481ac1..f337fdde2 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx @@ -11,7 +11,7 @@ import { useIsInViewport } from '../../../../../hooks'; import type { ChatMainStateContextType } from '../../../../../context/chatAndNotification/chat/chatMainStateContext'; export const RequestsFeedList = () => { - const { requestsFeed, setRequestsFeed } = useContext(ChatMainStateContext); + const { requestsFeed, setRequestsFeed,finishedFetchingRequests,setFinishedFetchingRequests } = useContext(ChatMainStateContext); const pageRef = useRef(null); const [page, setPage] = useState(1); const [paginateLoading, setPaginateLoading] = useState(false); @@ -38,7 +38,7 @@ export const RequestsFeedList = () => { useEffect(() => { if ( !isInViewport1 || - loading + loading || finishedFetchingRequests // || // Object.keys(requestsFeed).length < requestLimit ) { @@ -58,6 +58,7 @@ export const RequestsFeedList = () => { try { setPaginateLoading(true); const feeds = await fetchRequests({ page, requestLimit }); + if(!Object.keys(feeds || {}).length) setFinishedFetchingRequests(true); const newFeed: ChatFeedsType = { ...requestsFeed, ...feeds }; setRequestsFeed(newFeed); } catch (error) { @@ -75,7 +76,7 @@ export const RequestsFeedList = () => { justifyContent="start" width='100%' flexDirection="column" - + > {(!loading || paginateLoading) && Object.keys(requestsFeed || {}).length ? ( diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx index be5f08311..7a24fc805 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx @@ -28,6 +28,8 @@ export const InboxNotificationFeedList = () => { setAllInboxNotifsFeed, setSpamNotifsFeed, spamNotifsFeed, + finishedFetchingInbox, + setFinishedFetchingInbox, } = useContext(NotificationMainStateContext); const pageRef = useRef(null); const { account, env } = useContext(ChatAndNotificationPropsContext); @@ -36,7 +38,7 @@ export const InboxNotificationFeedList = () => { const isInViewport1 = useIsInViewport(pageRef, '1px'); const { fetchNotification, loading } = useFetchNotification(); - + const fetchSpamNotificationList = async () => { const feeds: NotificationFeedsType | undefined = await fetchNotification({ page: 1, @@ -90,10 +92,10 @@ export const InboxNotificationFeedList = () => { }, [fetchNotification, env, page, account]); useEffect(() => { - + if ( !isInViewport1 || - loading + loading || finishedFetchingInbox || Object.keys(inboxNotifsFeed).length < notificationLimit ) { @@ -112,9 +114,10 @@ export const InboxNotificationFeedList = () => { } try { setPaginateLoading(true); - const feeds = await fetchNotification({ page, limit: notificationLimit }); + const feeds = await fetchNotification({ page, limit: notificationLimit }); + if(!Object.keys(feeds || {}).length) setFinishedFetchingInbox(true); const newFeed:NotificationFeedsType = {...inboxNotifsFeed,...feeds}; - + setInboxNotifsFeed(newFeed); } catch (error) { console.log(error); diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx index 8c2543c42..de6c554fa 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx @@ -16,7 +16,7 @@ import type { NotificationFeedsType } from '../../../../../types'; import useFetchNotification from '../../../../../hooks/notifications/useFetchNotification'; export const SpamNotificationFeedList = () => { - const { spamNotifsFeed, setSpamNotifsFeed } = useContext( + const { spamNotifsFeed, setSpamNotifsFeed,finishedFetchingSpam,setFinishedFetchingSpam } = useContext( NotificationMainStateContext ); const pageRef = useRef(null); @@ -48,7 +48,7 @@ export const SpamNotificationFeedList = () => { useEffect(() => { if ( !isInViewport1 || - loading || + loading || finishedFetchingSpam|| Object.keys(spamNotifsFeed).length < notificationLimit ) { return; @@ -72,8 +72,9 @@ export const SpamNotificationFeedList = () => { limit: notificationLimit, spam: true, }); + if(!Object.keys(feeds || {}).length) setFinishedFetchingSpam(true); const newFeed: NotificationFeedsType = { ...spamNotifsFeed, ...feeds }; - + setSpamNotifsFeed(newFeed); } catch (error) { @@ -90,7 +91,7 @@ export const SpamNotificationFeedList = () => { justifyContent="start" flexDirection="column" width="100%" - + padding="0 3px" > {(!loading || paginateLoading) && diff --git a/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx index 7bc1f19ff..9dd2c647a 100644 --- a/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBanner.tsx @@ -1,5 +1,5 @@ -import React from 'react'; -import styled from 'styled-components'; +import React, { useEffect } from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { SpaceBannerLoadingSkeleton } from './SpaceBannerLoadingSkeleton'; @@ -11,15 +11,19 @@ import { ParticipantContainer } from '../reusables/ParticipantContainer'; import { HostPfpContainer } from '../reusables'; import live from './../../../icons/live.svg'; -import scheduled from './../../../icons/scheduled.svg'; -import { useGetSpaceInfo } from './../../../hooks'; +import { Scheduled } from '../../../icons/scheduled'; +import { + useGetSpaceInfo, + usePushSpaceSocket, + useSpaceData, +} from './../../../hooks'; export interface ISpaceBannerProps { spaceId: string; orientation?: 'maximized' | 'minimized' | 'pill'; isInvite?: boolean; onBannerClick?: (arg: string) => void; - onJoin?: any; + actionCallback?: any; } /** @@ -38,11 +42,22 @@ export const SpaceBanner: React.FC = ({ orientation, isInvite, onBannerClick, - onJoin, + actionCallback, }) => { const theme = React.useContext(ThemeContext); const spaceData = useGetSpaceInfo(spaceId); + const { + spacesObjectRef, + spaceObjectData, + initSpaceObject, + setSpaceWidgetId, + isSpeaker, + isListener, + account, + env, + } = useSpaceData(); + const spaceStatus = getSpaceStatus(spaceData?.status); const handleClick = () => { @@ -51,77 +66,76 @@ export const SpaceBanner: React.FC = ({ } }; + const handleJoinSpace = async () => { + await initSpaceObject(spaceData?.spaceId as string); + actionCallback(); + setSpaceWidgetId(spaceData?.spaceId as string); + }; + + usePushSpaceSocket({ account, env }); + // Check if the spaceData is not available, show the skeleton loading effect if (!spaceData) { return ; } return ( - - {orientation === 'maximized' && ( - - )} - {orientation === 'maximized' ? null : ( - - )} - - {orientation === 'pill' - ? `${spaceData?.spaceName.slice(0, 20)}...` - : spaceData?.spaceName} - - - - - - {isInvite === true && spaceStatus === 'Live' ? ( - Join this space - ) : isInvite === true && - spaceStatus === 'Scheduled' ? ( - Remind Me - ) : null} - + + {isInvite === true && spaceStatus === 'Live' ? ( + + Join this space + + ) : isInvite === true && spaceStatus === 'Scheduled' ? ( + Remind Me + ) : null} + + ); }; @@ -163,14 +177,17 @@ const Container = styled.div` : props.orientation === 'minimized' ? '12px' : '24px'}; - color: ${(props) => (props.status === 'Live' ? '#f5f5f5' : '#1E1E1E')}; + color: ${(props) => + props.status === 'Live' + ? `${props.theme.titleTextColor}` + : `${props.theme.textColorPrimary}`}; min-width: 0; text-overflow: ellipsis; overflow: hidden; - cursor: ${props => props.clickable && 'pointer'}; + cursor: ${(props) => props.clickable && 'pointer'}; `; -const Title = styled.div<{ orientation?: string }>` +const Title = styled.div` display: flex; flex-direction: row; justify-content: flex-start; @@ -185,6 +202,10 @@ const Title = styled.div<{ orientation?: string }>` ? '16px' : '12px'}; line-height: 130%; + color: ${(props) => + props.status === 'Live' + ? props.theme.titleTextColor + : props.theme.textColorPrimary}; width: 90%; line-clamp: ${(props) => (props.orientation === 'maximized' ? '3' : '2')}; @@ -202,7 +223,7 @@ const Status = styled.div` align-items: center; `; -const Time = styled.div<{ orientation?: string }>` +const Time = styled.div` display: ${(props) => (props.orientation === 'maximized' ? 'flex' : 'none')}; flex-direction: row; justify-content: center; @@ -216,23 +237,31 @@ const Icon = styled.img` align-self: center; `; -const TimeText = styled.div<{ status?: string }>` +const TimeText = styled.div` font-weight: 500; font-size: 14px; line-height: 150%; - color: ${(props) => (props.status === 'Live' ? '#fff' : '#71717A')}; + color: ${(props) => + props.status === 'Live' + ? `${props.theme.titleTextColor}` + : `${props.theme.textColorSecondary}`}; `; -const InviteButton = styled.button<{ status?: string }>` +const InviteButton = styled.button` display: flex; justify-content: center; align-items: center; height: 36px; width: 100%; - color: ${(props) => (props.status === 'Live' ? '#FFF' : '#8B5CF6')}; + color: ${(props) => + props.status === 'Live' + ? `${props.theme.titleTextColor}` + : `${props.theme.btnColorPrimary}`}; border-radius: 8px; border: ${(props) => - props.status === 'Live' ? '1px solid #FFF' : '1px solid #8B5CF6'}; + props.status === 'Live' + ? `1px solid ${props.theme.titleTextColor}` + : `1px solid ${props.theme.btnColorPrimary}`}; background: transparent; cursor: pointer; `; diff --git a/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx index 013d43705..f52e29e9f 100644 --- a/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceBanner/SpaceBannerLoadingSkeleton.tsx @@ -33,6 +33,7 @@ const SkeletonContainer = styled.div` border-radius: 17px; border: 1px solid lightgrey; position: relative; + width: inherit; &:after { content: ''; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx index ee1244992..d7d105731 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWButton/SCWButton.tsx @@ -3,6 +3,7 @@ import styled from 'styled-components'; import { ISpacesTheme } from '../../theme'; import { ThemeContext } from '../../theme/ThemeProvider'; +import { SpacesLogo } from '../../../../icons/SpacesLogo'; export interface ISCWButtonProps { // Space Creation Widget Button Interface btnText?: string; @@ -14,7 +15,7 @@ export interface ISCWButtonProps { // Space Creation Widget Button Interface const defaultProps: ISCWButtonProps = { btnText: 'Create your Space', customStyle: { - padding: '20px', + padding: '14px 20px', borderRadius: '12px', border: '0px solid transparent', fontSize: '1rem', @@ -23,7 +24,7 @@ const defaultProps: ISCWButtonProps = { export const SCWButton: React.FC = (props) => { const { btnText, customStyle, onCreate } = props; - + const theme = useContext(ThemeContext); return ( @@ -33,7 +34,10 @@ export const SCWButton: React.FC = (props) => { theme={theme} onClick={onCreate} > - {btnText} + + + {btnText} +
) @@ -46,12 +50,21 @@ const CreateButton = styled.button` border: ${props => props.customStyle.border}; font-size: ${props => props.customStyle.fontSize}; - background-image: ${(props) => props.theme.titleBg}; + background: ${(props) => props.theme.btnColorPrimary}; color: ${(props) => props.theme.titleTextColor}; + display: flex; + align-items: center; + + font-family: 'Strawford'; + cursor: pointer; `; +const BtnText = styled.div` + margin-left: 6px; +`; + SCWButton.defaultProps = defaultProps; export default SCWButton; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx index 5054e6235..572a236b3 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWCreateModal/SCWCreateModal.tsx @@ -1,5 +1,5 @@ -import React, { MouseEventHandler } from 'react' -import styled from 'styled-components' +import React, { MouseEventHandler, useContext } from 'react' +import styled, { ThemeProvider } from 'styled-components' import { Modal } from '../../reusables/Modal' import { Button } from '../../reusables/Button'; @@ -7,6 +7,7 @@ import { ModalHeader } from '../../reusables/ModalHeader'; import { TextInputWithCounter } from '../../reusables/TextInput'; import { CalendarPurple } from '../../../../icons/CalendarPurple'; +import { ThemeContext } from '../../theme/ThemeProvider'; export interface ISCWCModalProps { // Space Creation Widget Create Modal Interface isInviteVisible?: any; @@ -21,7 +22,8 @@ export interface ISCWCModalProps { // Space Creation Widget Create Modal Interfa } export const SCWCreateModal: React.FC = (props) => { - const { + const theme = useContext(ThemeContext); + const { isInviteVisible, closeCreateModal, handleNameChange, handleDescriptionChange, nameValue, descriptionValue, isDescriptionEnabled, isScheduleVisible, onClose, @@ -29,10 +31,11 @@ export const SCWCreateModal: React.FC = (props) => { const secBtn = { background: 'transparent', - borderColor: '#8b5cf6' + borderColor: theme.btnOutline } return ( + @@ -74,11 +77,12 @@ export const SCWCreateModal: React.FC = (props) => { customStyle={secBtn} onClick={isScheduleVisible} > - +
+ ) } @@ -87,4 +91,4 @@ const ButtonContainer = styled.div` display: flex; justify-content: space-between; width: 100%; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx index 94c8ac684..1f81b2682 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SCWInviteModal/SCWInviteModal.tsx @@ -1,6 +1,6 @@ /* eslint-disable no-prototype-builtins */ -import React, { useState, MouseEventHandler, useContext, useEffect } from 'react' -import styled from 'styled-components' +import React, { useState, MouseEventHandler, useContext } from 'react' +import styled, { ThemeProvider } from 'styled-components' import * as PushAPI from '@pushprotocol/restapi'; import { ModalHeader } from '../../reusables/ModalHeader'; @@ -10,14 +10,22 @@ import { SearchInput } from '../../reusables/SearchInput'; import { ProfileContainer } from '../../reusables/ProfileContainer'; import { ThemeContext } from '../../theme/ThemeProvider'; import { Spinner } from '../../reusables/Spinner'; +import { createIcon } from '../../helpers/blockies'; import CircularProgressSpinner from '../../../loader/loader'; import { useSpaceData } from '../../../../hooks'; import SettingsIcon from '../../../../icons/settingsBlack.svg'; +import { SettingsLogo } from '../../../../icons/SettingsLogo'; import { Image } from '../../../../config'; -import { createIcon } from '../../helpers/blockies'; + +export interface ICustomSearchResult { + account: string; + name?: string; + handle?: string; + image?: string; // dataURL as string +} export interface ISCWIModalProps { // Space Creation Widget Create Modal Interface closeInviteModal?: MouseEventHandler; @@ -32,12 +40,8 @@ export interface ISCWIModalProps { // Space Creation Widget Create Modal Interfa setAdminsList?: any; adminsAddressList?: any; setAdminsAddressList?: any; - onClose: () => void; -} - -interface User { - handle: string; - name: string; + onClose: any; + btnString?: string; } export const SCWInviteModal: React.FC = (props) => { @@ -51,17 +55,18 @@ export const SCWInviteModal: React.FC = (props) => { setAdminsList, adminsAddressList, setAdminsAddressList, - onClose + onClose, + btnString, } = props; const theme = useContext(ThemeContext); - const { env, account } = useSpaceData(); + const { env, account, customSearch } = useSpaceData(); const [invitedMember, setInvitedMember] = useState('') const [loadingAccount, setLoadingAccount] = useState(false) const [searchedUser, setSearchedUser]= useState({}); - const [errorMsg, setErrorMsg] = useState(''); + const [errorMsg, setErrorMsg] = useState(''); const searchMember = async (event: any) => { setInvitedMember(event.target.value) @@ -70,7 +75,36 @@ export const SCWInviteModal: React.FC = (props) => { handleError('Cannot add Host to members'); return; } - + + if (customSearch) { + const customUserResponse = customSearch(event.target.value); + + const hasAccount = (obj: any, uniqueKey: string) => { + const keys = Object.keys(obj); + return keys.length < 4 && keys[0] === uniqueKey; + } + + if(hasAccount(customUserResponse, 'account')) { + const icon = createIcon({ + seed: customUserResponse.account, + size: 10, + scale: 3, + }); + + const searchedUser = { + handle: customUserResponse.account, + name: customUserResponse.account, + image: icon.toDataURL(), + }; + + setSearchedUser(searchedUser) + } else { + setSearchedUser(customUserResponse); + } + + return; + } + try { setLoadingAccount(true); const response = await PushAPI.user.get({ @@ -86,7 +120,7 @@ export const SCWInviteModal: React.FC = (props) => { }); const nullUser = { - walletAddress: event.target.value, + handle: event.target.value, name: event.target.value, image: icon.toDataURL(), }; @@ -131,7 +165,7 @@ export const SCWInviteModal: React.FC = (props) => { setInvitedAddressList([...invitedAddressList, user.did.substring(7)]) setInvitedMembersList([...invitedMembersList, user]); } else { - setInvitedAddressList([...invitedAddressList, user.walletAddress]) + setInvitedAddressList([...invitedAddressList, user.handle]) setInvitedMembersList([...invitedMembersList, user]); } @@ -144,7 +178,7 @@ export const SCWInviteModal: React.FC = (props) => { setAdminsAddressList([...adminsAddressList, user.did.substring(7)]); } else { setAdminsList([...adminsList, user]) - setAdminsAddressList([...adminsAddressList, user.walletAddress]); + setAdminsAddressList([...adminsAddressList, user.handle]); } const updatedArray = invitedMembersList.filter((item: any) => item !== user) @@ -154,7 +188,7 @@ export const SCWInviteModal: React.FC = (props) => { const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.did.substring(7)) setInvitedAddressList(updateAddressArray); } else { - const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.walletAddress) + const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.handle) setInvitedAddressList(updateAddressArray); } @@ -169,7 +203,7 @@ export const SCWInviteModal: React.FC = (props) => { const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.did.substring(7)) setInvitedAddressList(updateAddressArray); } else { - const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.walletAddress) + const updateAddressArray = invitedAddressList.filter((item: string) => item !== user.handle) setInvitedAddressList(updateAddressArray); } }; @@ -182,15 +216,13 @@ export const SCWInviteModal: React.FC = (props) => { const updateAdminAddressArray = adminsAddressList.filter((item: string) => item !== user.did.substring(7)) setAdminsAddressList(updateAdminAddressArray); } else { - const updateAddressArray = adminsAddressList.filter((item: string) => item !== user.walletAddress) + const updateAddressArray = adminsAddressList.filter((item: string) => item !== user.handle) setAdminsAddressList(updateAddressArray); } }; - const tempImageUrl = "https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg"; - return ( -
+ @@ -214,11 +246,10 @@ export const SCWInviteModal: React.FC = (props) => { { Object.keys(searchedUser).length === 0 ? null - : searchedUser.hasOwnProperty('walletAddress') ? + : searchedUser.hasOwnProperty('handle') ? Add +} @@ -228,7 +259,6 @@ export const SCWInviteModal: React.FC = (props) => { : Add +} @@ -244,22 +274,17 @@ export const SCWInviteModal: React.FC = (props) => { Invited Members {invitedMembersList.length} { invitedMembersList.map((item: any) => { - if (item.hasOwnProperty('walletAddress')) { + if (item.hasOwnProperty('handle')) { return - Settings icon + } - // btnCallback={() => handleDeleteInvitedUser(item)} removeCallback={() => handleDeleteInvitedUser(item)} promoteCallback={() => handlePromoteToAdmin(item)} border @@ -272,14 +297,9 @@ export const SCWInviteModal: React.FC = (props) => { imageUrl={item.profile.picture} contBtn={ - Settings icon + } - // btnCallback={() => handleDeleteInvitedUser(item)} removeCallback={() => handleDeleteInvitedUser(item)} promoteCallback={() => handlePromoteToAdmin(item)} border @@ -297,22 +317,17 @@ export const SCWInviteModal: React.FC = (props) => { Speakers {adminsList.length} { adminsList.map((item: any) => { - if (item.hasOwnProperty('walletAddress')) { + if (item.hasOwnProperty('handle')) { return - Settings icon + } - // btnCallback={() => handleDeleteInvitedUser(item)} removeCallback={() => handleDeleteInvitedAdmin(item)} // promoteCallback={() => handlePromoteToAdmin(item)} border @@ -325,14 +340,9 @@ export const SCWInviteModal: React.FC = (props) => { imageUrl={item.profile.picture} contBtn={ - Settings icon + } - // btnCallback={() => handleDeleteInvitedUser(item)} removeCallback={() => handleDeleteInvitedAdmin(item)} // promoteCallback={() => handlePromoteToAdmin(item)} border @@ -351,11 +361,11 @@ export const SCWInviteModal: React.FC = (props) => { { isLoading ? - : 'Create Space' + : btnString ?? 'Create Space' } -
+ ) } @@ -406,13 +416,13 @@ const ContBtn = styled.button` line-height: 18px; width: max-content; background: transparent; - color: #8B5CF6; + color: ${props => props.theme.btnColorPrimary}; border-radius: 6px; font-weight: 500; font-size: 12px; padding: 4px 8px; border-radius: 8px; - border: 1px solid #8B5CF6; + border: 1px solid ${props => props.theme.btnOutline}; cursor: pointer; `; @@ -420,4 +430,4 @@ const ErrorMessage = styled.div` color: #E93636; font-size: 14px; margin-bottom: 8px; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx index 54bee046c..0ce55df81 100644 --- a/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceCreationWidget/SpaceCreationWidget.tsx @@ -7,14 +7,14 @@ import { SCWScheduleModal } from './SCWScheduleModal/SCWScheduleModal'; import { SCWInviteModal } from './SCWInviteModal/SCWInviteModal'; import { SCWButton } from './SCWButton'; -import { useSpaceData } from '../../../hooks'; +import { useSpaceData, usePushSpaceSocket } from '../../../hooks'; export interface ISpaceCreateWidgetProps { - CustomComponent?: any; + children?: React.ReactNode; } export const SpaceCreationWidget:React.FC = (props) => { - const { CustomComponent } = props; + const { children } = props; const [isCreateModalVisible, setIsCreateModalVisible] = useState(false); const [isScheduleModalVisible, setIsScheduleModalVisible] = useState(false); @@ -35,7 +35,9 @@ export const SpaceCreationWidget:React.FC = (props) => time: Date.now(), }) - const { signer, env, account } = useSpaceData(); + const { signer, env, account, pgpPrivateKey } = useSpaceData(); + + usePushSpaceSocket({ account, env }); const handleNameChange = (event: any) => { setSpaceState((prevState) => ({...prevState, spaceName: event.target.value})) @@ -99,8 +101,8 @@ export const SpaceCreationWidget:React.FC = (props) => time: Date.now(), }) } - - const testCreateSpace = async () => { + + const createSpace = async () => { const spaceCreate = { spaceName: spaceState.spaceName.length === 0 ? `${account}'s Space` : spaceState.spaceName, spaceDescription: 'Push Space', @@ -110,13 +112,13 @@ export const SpaceCreationWidget:React.FC = (props) => isPublic: true, scheduleAt: spaceState.time > Date.now() ? new Date(spaceState.time) : new Date(Date.now() + 120000), signer: signer as PushAPI.SignerType, - env + env, + ...(pgpPrivateKey && pgpPrivateKey !== '' && { pgpPrivateKey }), // Conditionally add pgpPrivateKey } try { setLoading(true); const response = await PushAPI.space.create(spaceCreate); - console.log(response); } catch (e:any) { console.error(e.message); @@ -128,65 +130,65 @@ export const SpaceCreationWidget:React.FC = (props) => }; return ( - - { - CustomComponent - ? - - : - - } - - {isCreateModalVisible && - - } - - {isScheduleModalVisible && - - } - - {isInviteModalVisible && - - } - +
+ + {!children && + + } + + {children &&
{children}
} + + {isCreateModalVisible && + + } + + {isScheduleModalVisible && + + } + + {isInviteModalVisible && + + } +
+
) } const SCWContainer = styled.div` - font-family: 'Strawford'; // update to fontFamily theme -`; \ No newline at end of file + font-family: 'Strawford'; // update to fontFamily theme +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx b/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx index 1cb55ff6f..efb7035e8 100644 --- a/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceFeed/SpaceFeed.tsx @@ -1,5 +1,5 @@ -import React, { useState } from 'react'; -import styled from 'styled-components'; +import React, { useContext, useState } from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { SpaceIFeeds } from '@pushprotocol/restapi'; @@ -13,22 +13,26 @@ import { useMySpaces, usePopularSpaces, useSpaceRequests, + usePushSpaceSocket, } from '../../../hooks'; import { ISpacePaginationData } from '../../../context/spacesContext'; import spacesIcon from '../../../icons/Spaces.svg'; +import { ThemeContext } from '../theme/ThemeProvider'; enum OrientationEnums { Horizontal = 'horizontal', Vertical = 'vertical', } -enum Tabs { +export enum FeedTabs { ForYou = 'For You', Popular = 'Popular', HostedByYou = 'Hosted by you', } +type TabsValues = keyof typeof FeedTabs; + enum FilterEnums { All = 'All', Live = 'Live', @@ -38,7 +42,7 @@ export interface ISpaceFeedProps { orientation?: 'horizontal' | 'vertical'; height?: number; width?: number; - sortingOrder?: string[]; + sortingOrder?: Array; showTabs?: boolean; filter?: FilterEnums.All | FilterEnums.Live | FilterEnums.Scheduled; showFilter?: boolean; @@ -46,17 +50,18 @@ export interface ISpaceFeedProps { } export const SpaceFeed: React.FC = ({ - orientation = 'veritcal', + orientation = OrientationEnums.Vertical, height, width, - sortingOrder = [Tabs.Popular, Tabs.ForYou, Tabs.HostedByYou], + sortingOrder = ['Popular', 'ForYou', 'HostedByYou'], showTabs = true, filter = FilterEnums.All, showFilter = true, onBannerClickHandler, }) => { - const [tab, setTab] = useState(sortingOrder[0]); + const theme = useContext(ThemeContext); const [filterTab, setFilterTab] = useState(filter); + const { selectedFeedTab, setSelectedFeedTab } = useSpaceData(); const { account, @@ -66,13 +71,12 @@ export const SpaceFeed: React.FC = ({ setPopularSpaces, spaceRequests, setSpaceRequests, + env, } = useSpaceData(); - const listInnerRef = useFeedScroll(mySpaces.apiData?.length); + usePushSpaceSocket({ account, env }); - const handleTabChange = (tab: string) => { - setTab(tab); - }; + const listInnerRef = useFeedScroll(mySpaces.apiData?.length); const handleFilterData = (spacesList: SpaceIFeeds[]) => { if (filterTab === FilterEnums.All) { @@ -91,17 +95,17 @@ export const SpaceFeed: React.FC = ({ }; const handleMySpacesFilter = (spacesList: SpaceIFeeds[]) => { - if (tab === Tabs.HostedByYou) { + if (selectedFeedTab === FeedTabs.HostedByYou) { return spacesList.filter( (space: SpaceIFeeds) => - space.spaceInformation?.spaceCreator.slice(7).toUpperCase() === + space.spaceInformation?.spaceCreator?.toUpperCase() === account?.toUpperCase() ); } - if (tab === Tabs.ForYou) { + if (selectedFeedTab === FeedTabs.ForYou) { return spacesList.filter( (space: SpaceIFeeds) => - space.spaceInformation?.spaceCreator.slice(7).toUpperCase() !== + space.spaceInformation?.spaceCreator?.toUpperCase() !== account?.toUpperCase() ); } else { @@ -147,19 +151,17 @@ export const SpaceFeed: React.FC = ({ }; const loadMoreData = async () => { - if (tab === Tabs.ForYou) { + if (selectedFeedTab === FeedTabs.ForYou) { incrementSpacePage(mySpaces); } - if (tab === Tabs.Popular) { + if (selectedFeedTab === FeedTabs.Popular) { incrementSpacePage(popularSpaces); } - if (tab === Tabs.HostedByYou) { + if (selectedFeedTab === FeedTabs.HostedByYou) { incrementSpacePage(spaceRequests); } }; - console.log(account); - const onScroll = () => { if (listInnerRef.current) { const { scrollTop } = listInnerRef.current; @@ -181,7 +183,14 @@ export const SpaceFeed: React.FC = ({ mySpaceLoading || popularSpaceLoading || spaceRequestsLoading; return ( -
+ +
{orientation === OrientationEnums.Horizontal ? ( {orientation === OrientationEnums.Horizontal @@ -214,108 +223,81 @@ export const SpaceFeed: React.FC = ({ <> - {sortingOrder.map((tabName: string) => { + {sortingOrder.map((tabName: TabsValues) => { return ( handleTabChange(tabName)} + active={selectedFeedTab === FeedTabs[tabName]} + onClick={() => setSelectedFeedTab(FeedTabs[tabName])} > - {tabName} + {FeedTabs[tabName]} ); })} - - setFilterTab(FilterEnums.All)} + + setFilterTab(FilterEnums.All)} + > + All + + setFilterTab(FilterEnums.Live)} + > + Live + + setFilterTab(FilterEnums.Scheduled)} + > + Scheduled + + + - All - - setFilterTab(FilterEnums.Live)} - > - Live - - setFilterTab(FilterEnums.Scheduled)} - > - Scheduled - - - - - {tab === Tabs.ForYou ? ( - - {mySpaces.apiData && - (handleFilterData( - handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) - ).length === 0 ? ( - - - Join a space - - Get started by joining a space - - - ) : ( - handleFilterData( + + {selectedFeedTab === FeedTabs.ForYou ? ( + + {mySpaces.apiData && + (handleFilterData( handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) - ).map((space: SpaceIFeeds) => { - return ( - - ); - }) - ))} - - ) : tab === Tabs.Popular ? ( - - Popular Spaces - {popularSpaces && - handleFilterData( - popularSpaces.apiData as SpaceIFeeds[] - ).map((space: SpaceIFeeds) => { - return ( - - ); - })} - - ) : ( - - {mySpaces.apiData && - (handleFilterData( - handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) - ).length === 0 ? ( - - - Create a space - - Get started by creating a space - - - ) : ( + ).length === 0 ? ( + + + Join a space + + Get started by joining a space + + + ) : ( + handleFilterData( + handleMySpacesFilter( + mySpaces.apiData as SpaceIFeeds[] + ) + ).map((space: SpaceIFeeds) => { + return ( + + ); + }) + ))} + + ) : selectedFeedTab === FeedTabs.Popular ? ( + + {popularSpaces.apiData && handleFilterData( - handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) + popularSpaces.apiData as SpaceIFeeds[] ).map((space: SpaceIFeeds) => { return ( = ({ } /> ); - }) - ))} - - )} - {loading && } - - - - )} -
+ })} + + ) : ( + + {mySpaces.apiData && + (handleFilterData( + handleMySpacesFilter(mySpaces.apiData as SpaceIFeeds[]) + ).length === 0 ? ( + + + Create a space + + Get started by creating a space + + + ) : ( + handleFilterData( + handleMySpacesFilter( + mySpaces.apiData as SpaceIFeeds[] + ) + ).map((space: SpaceIFeeds) => { + return ( + + ); + }) + ))} + + )} + {loading && } + + + + )} +
+ ); }; @@ -344,16 +357,16 @@ const ScrollContainer = styled.div<{ height?: number; width?: number }>` width: ${(props) => (props.width ? `${props.width}px` : 'inherit')}; height: ${(props) => (props.height ? `${props.height}px` : 'auto')}; overflow-y: auto; -}`; +`; const Container = styled.div` display: flex; flex-direction: column; align-items: center; - background: #ffffff; - border: 1px solid #dcdcdf; + background: ${(props) => props.theme.bgColorPrimary}; + border: 1px solid ${(props) => props.theme.borderColor}; border-radius: 12px; padding: 24px 32px; -}`; +`; const Navigation = styled.div<{ showTabs?: boolean; @@ -365,8 +378,9 @@ const Navigation = styled.div<{ justify-content: space-between; align-items: center; width: ${(props) => (props.width ? `${props.width}px` : 'inherit')}; - border-bottom: 1px solid #DCDCDF; + border-bottom: 1px solid ${(props) => props.theme.borderColor}; margin-bottom: ${(props) => (props.showFilter ? '0' : '27px')}; + background: ${(props) => props.theme.bgColorPrimary}; }`; const NavButtonWrapper = styled.div` @@ -374,21 +388,25 @@ const NavButtonWrapper = styled.div` flex-direction: row; justify-content: space-between; align-items: center; -}`; +`; const NavButton = styled.button<{ active?: boolean }>` padding: 10px 30px; font-weight: 450; font-size: 14px; border: none; - border-bottom: ${(props) => (props.active ? '2px solid #8B5CF6' : 'none')}; + border-bottom: ${(props) => + props.active ? `2px solid ${props.theme.btnColorPrimary}` : 'none'}; background: none; - color : ${(props) => (props.active ? '#000000' : '#71717A')}; + color: ${(props) => + props.active + ? `${props.theme.textColorPrimary}` + : `${props.theme.textColorSecondary}`}; &:hover { cursor: pointer; } -}`; +`; const Spaces = styled.div<{ orientation?: string }>` display: flex; @@ -396,23 +414,23 @@ const Spaces = styled.div<{ orientation?: string }>` props.orientation === 'horizontal' ? 'row' : 'column'}; justify-content: flex-start; align-items: center; - background: #ffffff; + background: ${(props) => props.theme.bgColorPrimary}; width: ${(props) => props.orientation === 'horizontal' ? 'inherit' : '100%'}; height: auto; gap: 16px; -}`; +`; const PopularSpaces = styled.div` display: flex; flex-direction: column; justify-content: space-between; align-items: center; - background: #ffffff; - width: 100%; + background: ${(props) => props.theme.bgColorPrimary}; + width: 100%; height: auto; gap: 16px; -}`; +`; const Text = styled.div` width: 100%; @@ -420,17 +438,17 @@ const Text = styled.div` font-family: 'Strawford'; font-weight: 450; font-size: 18px; -}`; +`; const Filter = styled.div<{ showFilter?: boolean }>` display: ${(props) => (props.showFilter ? 'flex' : 'none')}; flex-direction: row; justify-content: flex-start; align-items: center; - background: #ffffff; + background: ${(props) => props.theme.bgColorPrimary}; width: 100%; margin: 22px 0; -}`; +`; const FilterButton = styled.button<{ active: boolean }>` display: inline-flex; @@ -439,16 +457,22 @@ const FilterButton = styled.button<{ active: boolean }>` justify-content: center; align-items: center; border-radius: 99px; - border: 1px solid #C4B5FD; - background: ${(props) => (props.active ? '#8B5CF6' : '#EDE9FE')}; - color: ${(props) => (!props.active ? '#8B5CF6' : '#FFF')}; + border: 1px solid ${(props) => props.theme.borderColor}; + background: ${(props) => + props.active + ? `${props.theme.btnColorPrimary}` + : `${props.theme.bgColorSecondary}`}; + color: ${(props) => + props.active + ? `${props.theme.titleTextColor}` + : `${props.theme.textColorPrimary}`}; margin-right: 8px; font-size: 14px; &:hover { cursor: pointer; } -}`; +`; const NoSpaces = styled.div` display: flex; @@ -456,23 +480,23 @@ const NoSpaces = styled.div` justify-content: center; align-items: center; margin: 130px 0; -}`; +`; const SpacesIcon = styled.img` width: 36px; height: 36px; -}`; +`; const NoSpacesTextV1 = styled.div` font-family: 'Strawford'; font-weight: 450; font-size: 16px; - color: #000; + color: ${(props) => props.theme.textColorPrimary}}; }`; const NoSpacesTextV2 = styled.div` font-family: 'Strawford'; font-weight: 450; - color: #71717A; + color: ${(props) => props.theme.textColorSecondary}}; font-size: 14px; -}`; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx b/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx index 6e808f5fa..7ae369c2a 100644 --- a/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceInvites/SpaceInvites.tsx @@ -1,67 +1,43 @@ -import React, { useEffect, useState } from 'react'; -import styled from 'styled-components'; +import React, { useContext, useEffect, useState } from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { Modal } from '../reusables/Modal'; import { Spinner } from '../reusables/Spinner'; import { ModalHeader } from '../reusables/ModalHeader'; -import { useFeedScroll, useSpaceData, useSpaceRequests } from '../../../hooks'; +import { + useFeedScroll, + useSpaceData, + useSpaceRequests, + usePushSpaceSocket, +} from '../../../hooks'; import { SpaceBanner } from '../SpaceBanner'; +import { ISpacesTheme } from '../theme'; +import { ThemeContext } from '../theme/ThemeProvider'; + export interface ISpaceInvitesProps { children?: React.ReactNode; + actionCallback?: any; + onBannerClickHandler?: (arg: string) => void; } -// temp -let spaceId = ""; +interface IThemeProps { + theme?: ISpacesTheme; +} export const SpaceInvites: React.FC = ({ children, + actionCallback, + onBannerClickHandler, }: ISpaceInvitesProps) => { + const theme = useContext(ThemeContext); const [modalOpen, setModalOpen] = useState(false); const { spaceRequests, setSpaceRequests } = useSpaceData(); const containerRef = useFeedScroll(spaceRequests.apiData?.length); - const [playBackUrl, setPlayBackUrl] = useState(''); - const { - spacesObjectRef, - spaceObjectData, - initSpaceObject, - setSpaceWidgetId, - isSpeaker, - isListener, - account, - } = useSpaceData(); - - const handleJoinSpace = async (space: any) => { - await initSpaceObject(space?.spaceId as string); - - if (isSpeaker) { - // create audio stream - await spacesObjectRef.current.createAudioStream(); - spaceId = space?.spaceId; // temp - } - if (isListener) { - await spacesObjectRef?.current?.join(); - const playBackUrl = spaceObjectData.spaceDescription; - setPlayBackUrl(playBackUrl); - handleCloseModal(); - setSpaceWidgetId(space?.spaceId as string); - console.log('space joined'); - } - }; + const { account, env } = useSpaceData(); - useEffect(() => { - if (!spaceObjectData?.connectionData?.local.stream || !isSpeaker) return; - const joinSpaceAsSpeaker = async () => { - console.log('joining as a speaker'); - await spacesObjectRef?.current?.join(); - setSpaceWidgetId(spaceId); - console.log('space joined'); - handleCloseModal(); - }; - joinSpaceAsSpeaker(); - // eslint-disable-next-line react-hooks/exhaustive-deps - }, [spaceObjectData?.connectionData?.local.stream]); + usePushSpaceSocket({ account, env }); const handleOpenModal = () => { setModalOpen(true); @@ -71,6 +47,20 @@ export const SpaceInvites: React.FC = ({ setModalOpen(false); }; + const handleCustomClose = () => { + if (actionCallback) { + actionCallback(); + } + + setModalOpen(false); + }; + + const handleClick = (spaceId: string) => { + if (onBannerClickHandler) { + return onBannerClickHandler(spaceId || ''); + } + }; + const loadMoreData = () => { if ( loading === false && @@ -78,7 +68,6 @@ export const SpaceInvites: React.FC = ({ spaceRequests.lastPage && spaceRequests.currentPage < spaceRequests.lastPage ) { - console.log('Load More Data'); setSpaceRequests({ currentPage: spaceRequests.currentPage + 1, lastPage: spaceRequests.lastPage + 1, @@ -97,7 +86,7 @@ export const SpaceInvites: React.FC = ({ const { loading } = useSpaceRequests(account); return ( - <> + {!children && } {children &&
{children}
} @@ -122,7 +111,10 @@ export const SpaceInvites: React.FC = ({ spaceId={space.spaceId} orientation="maximized" isInvite={true} - onJoin={() => handleJoinSpace(space)} + actionCallback={handleCustomClose} + onBannerClick={ + onBannerClickHandler ? handleClick : undefined + } /> ); }) @@ -132,20 +124,20 @@ export const SpaceInvites: React.FC = ({ )} - +
); }; -const Button = styled.button` +const Button = styled.button` padding: 8px 16px; - background-color: #8b5cf6; - color: #fff; + background-color: ${(props) => props.theme.btnColorPrimary}; + color: ${(props) => props.theme.textColorPrimary}; border: none; border-radius: 4px; cursor: pointer; `; -const ScrollContainer = styled.div` +const ScrollContainer = styled.div` max-height: 400px; width: inherit; margin-top: 24px; @@ -161,12 +153,12 @@ const ScrollContainer = styled.div` -webkit-appearance: none; width: 4px; height: auto; - background: #8b5cf6; + background: ${(props) => props.theme.btnColorPrimary}; border-radius: 99px; } `; -const InviteContainer = styled.div` +const InviteContainer = styled.div` display: flex; flex-direction: column; gap: 16px; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/EndWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/EndWidgetContent.tsx new file mode 100644 index 000000000..13785109b --- /dev/null +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/EndWidgetContent.tsx @@ -0,0 +1,66 @@ +import React, { MouseEventHandler } from 'react'; +import { Item, Container, Image, Text } from '../../../config'; +import SpaceEnded from '../../../icons/SpaceEnded.svg'; +import { SpaceInfoText } from './ScheduledWidgetContent'; + +import { ThemeProvider } from 'styled-components'; +import { ThemeContext } from '../theme/ThemeProvider'; + +interface IEndWidgetContentProps { + onClose: MouseEventHandler; + toggleWidgetVisibility: () => void; +} + +export const EndWidgetContent: React.FC = ({ + onClose, + toggleWidgetVisibility, +}) => { + const theme = React.useContext(ThemeContext); + const handleCloseWidget: React.MouseEventHandler = ( + event + ) => { + // Call for hiding the widget + toggleWidgetVisibility(); + + // Call for running onClose handler from prop + onClose(event); + }; + + return ( + + + End Icon + This Space has ended + + + Close + + + + + ); +}; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx index c7cf15281..90791a589 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveSpaceProfileContainer.tsx @@ -1,3 +1,4 @@ +import React from 'react'; import { IMediaStream } from '@pushprotocol/restapi'; import { Image, Item, Text } from '../../../config'; @@ -5,6 +6,9 @@ import HandIcon from '../../../icons/hand.svg'; import MicOffIcon from '../../../icons/micoff.svg'; import { VideoPlayer } from './VideoPlayer'; +import { ThemeProvider } from 'styled-components'; +import { ThemeContext } from '../theme/ThemeProvider'; + export interface ILiveSpaceProfileContainerProps { wallet: string; isHost?: boolean; @@ -18,6 +22,7 @@ export interface ILiveSpaceProfileContainerProps { export const LiveSpaceProfileContainer = ( options: ILiveSpaceProfileContainerProps ) => { + const theme = React.useContext(ThemeContext); const { wallet, isHost, @@ -29,62 +34,64 @@ export const LiveSpaceProfileContainer = ( } = options || {}; return ( - - Profile pic - - {wallet.slice(7, 12).concat('...')} - {stream && } - - {requested ? ( - - - Requested - - Hand Icon - - ) : ( - - - {isHost ? 'Host' : isSpeaker ? 'Speaker' : 'Listener'} - - {!mic && ( + + + Profile pic + + {wallet.replace('eip155:', '').slice(0, -36) + '...'} + {stream && } + + {requested ? ( + + + Requested + Mic Off Icon - )} - - )} - + + ) : ( + + + {isHost ? 'Host' : isSpeaker ? 'Speaker' : 'Listener'} + + {!mic && ( + Mic Off Icon + )} + + )} + + ); }; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx index 93c056e70..88fa19aff 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx @@ -1,37 +1,52 @@ -import React, { useEffect, useState } from 'react'; -import styled from 'styled-components'; +import React, { useEffect, useState, useRef, useContext } from 'react'; +import styled, { keyframes, ThemeProvider } from 'styled-components'; +import { Player } from '@livepeer/react'; +import * as PushAPI from '@pushprotocol/restapi'; +import { SpaceDTO } from '@pushprotocol/restapi'; import { LiveSpaceProfileContainer } from './LiveSpaceProfileContainer'; import { SpaceMembersSectionModal } from './SpaceMembersSectionModal'; +import { createBlockie } from '../helpers/blockies'; +import { ThemeContext } from '../theme/ThemeProvider'; + +import CircularProgressSpinner from '../../loader/loader'; + import { Button, Image, Item, Text } from '../../../config'; import MicOnIcon from '../../../icons/micon.svg'; import MicEngagedIcon from '../../../icons/MicEngage.svg'; import MuteIcon from '../../../icons/Muted.svg'; import ShareIcon from '../../../icons/Share.svg'; import MembersIcon from '../../../icons/Members.svg'; -import { SpaceDTO } from '@pushprotocol/restapi'; - import { useSpaceData } from '../../../hooks'; -import { Player } from '@livepeer/react'; +import { SpaceStatus } from './WidgetContent'; +import { pCAIP10ToWallet } from '../../../helpers'; interface LiveWidgetContentProps { spaceData?: SpaceDTO; // temp props only for testing demo purpose for now isHost?: boolean; + setSpaceStatusState: React.Dispatch>; } + export const LiveWidgetContent: React.FC = ({ spaceData, isHost, + setSpaceStatusState, }) => { - const tempImageUrl = - 'https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg'; const [showMembersModal, setShowMembersModal] = useState(false); - const [isMicOn, setIsMicOn] = useState(true); const [playBackUrl, setPlayBackUrl] = useState(''); + const [isLoading, setIsLoading] = useState(false); + const [isDDOpen, setIsDDOpen] = useState(false); + + const dropdownRef = useRef(null); + + const theme = useContext(ThemeContext); + const { spacesObjectRef, spaceObjectData, + setSpaceObjectData, isSpeaker, isListener, setSpaceWidgetId, @@ -39,57 +54,116 @@ export const LiveWidgetContent: React.FC = ({ initSpaceObject, } = useSpaceData(); + console.log( + '🚀 ~ file: LiveWidgetContent.tsx:53 ~ spacesObjectRef:', + spacesObjectRef + ); + + const isMicOn = spaceObjectData?.connectionData?.local?.audio; + + const handleMicState = async () => { + await spacesObjectRef?.current?.enableAudio?.({ state: !isMicOn }); + }; + + const handleDDState = () => { + setIsDDOpen(!isDDOpen); + }; + const handleJoinSpace = async () => { if (!spaceData) { return; } + setIsLoading(!isLoading); + await initSpaceObject(spaceData?.spaceId as string); - + // useEffects below will handle the rest + }; + + const handleEndSpace = async () => { + if (!spacesObjectRef?.current) return; + await spacesObjectRef?.current?.stop?.(); + spacesObjectRef.current = null; + setSpaceObjectData?.(PushAPI.space.initSpaceData); + setSpaceStatusState?.(SpaceStatus.Ended); + setIsLoading(false); + }; + + const handleLeaveSpace = async () => { + if (!spacesObjectRef?.current) return; + if (isHost || isSpeaker) { + await spacesObjectRef?.current?.leave?.(); + spacesObjectRef.current = null; + setSpaceObjectData?.(PushAPI.space.initSpaceData); + console.log('Space left'); + } if (isListener) { - console.log('joining as a listner'); - await spacesObjectRef?.current?.join(); - setSpaceWidgetId(spaceData?.spaceId as string); - console.log('space joined'); + spacesObjectRef.current = null; + setSpaceObjectData?.(PushAPI.space.initSpaceData); } + setIsLoading(false); }; - useEffect(()=>{ + // for listener + useEffect(() => { + const JoinAsListner = async () => { + console.log('isListner', isListener); + if ( + isListener && + !isHost && + spaceObjectData.connectionData.local.address + ) { + console.log('joining as a listener'); + await spacesObjectRef?.current?.join?.(); + // setSpaceWidgetId?.(spaceData?.spaceId as string); + setIsLoading(!isLoading); + console.log('space joined'); + } + }; + JoinAsListner(); + }, [isListener]); + + // for speaker + useEffect(() => { const createAudioStream = async () => { - console.log("isSpeaker", isSpeaker); - if (isSpeaker) { + console.log('isSpeaker', isSpeaker); + if (isSpeaker && !spaceObjectData?.connectionData?.local?.stream) { // create audio stream as we'll need it to start the mesh connection console.log('creating audio stream'); - await spacesObjectRef.current.createAudioStream(); + await spacesObjectRef?.current?.createAudioStream?.(); } - } + }; createAudioStream(); - }, [isSpeaker]) + }, [isSpeaker]); + // joining as a speaker useEffect(() => { - if (!spaceObjectData?.connectionData?.local.stream || !isSpeaker) return; + if ( + !spaceObjectData?.connectionData?.local?.stream || + !isSpeaker || + (spaceObjectData?.connectionData?.incoming?.length ?? 0) > 1 + ) + return; + const joinSpaceAsSpeaker = async () => { console.log('joining as a speaker'); - await spacesObjectRef?.current?.join(); - setSpaceWidgetId(spaceData?.spaceId as string); + await spacesObjectRef?.current?.join?.(); + // setSpaceWidgetId?.(spaceData?.spaceId as string); + setIsLoading(!isLoading); console.log('space joined'); }; joinSpaceAsSpeaker(); - // eslint-disable-next-line react-hooks/exhaustive-deps - }, [spaceObjectData?.connectionData?.local.stream]); + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [spaceObjectData?.connectionData?.local?.stream]); useEffect(() => { - if (!spaceObjectData.spaceDescription) return; - const playBackUrl = spaceObjectData.spaceDescription; + if (!spaceObjectData?.spaceDescription) return; + const playBackUrl = spaceObjectData?.spaceDescription; setPlayBackUrl(playBackUrl); - }, [spaceObjectData.spaceDescription]); - - // console.log('spaceObjectData', spaceObjectData); - // console.log('playBackUrl', playBackUrl); - // console.log('isListener', isListener); + }, [spaceObjectData?.spaceDescription]); return ( - <> + = ({ overflowY={'auto'} alignContent={'flex-start'} > - {isSpeaker && - spaceObjectData.connectionData.incoming.map((profile) => ( - - ))} + {/* local peer details if speaker or host */} + {(isSpeaker || isHost) && ( + + )} + + {/* remote peer details if speaker or host */} + {(isSpeaker || isHost) && + spaceObjectData?.connectionData?.incoming + ?.slice(1) + .map((profile) => ( + + ))} + + {/* details of everyone in the space if a listner */} {isListener && - spaceObjectData.members.map((profile) => ( - + !isHost && + spaceObjectData?.members.map((profile) => ( +
+ + + {isDDOpen ? ( + + Invite to Speak + + ) : null} +
))}
{isJoined ? ( = ({ alignItems={'center'} gap={'8px'} padding={'10px'} - onClick={() => - isHost || isSpeaker ? setIsMicOn(!isMicOn) : null - } + onClick={() => (isHost || isSpeaker ? handleMicState() : null)} > = ({ } alt="Mic Icon" /> - + {isHost || isSpeaker ? isMicOn ? 'Speaking' @@ -176,24 +294,23 @@ export const LiveWidgetContent: React.FC = ({ alt="Share Icon" /> - {isListener && playBackUrl.length > 0 && ( - + {isListener && !isHost && playBackUrl.length > 0 && ( + + + )} ) : ( @@ -203,13 +320,17 @@ export const LiveWidgetContent: React.FC = ({ border={'none'} borderRadius={'8px'} cursor={'pointer'} - background={ - 'linear-gradient(87.17deg, #EA4EE4 0%, #D23CDF 0.01%, #8B5CF6 100%), linear-gradient(87.17deg, #EA4E93 0%, #DB2777 0.01%, #9963F7 100%), linear-gradient(87.17deg, #B6A0F5 0%, #F46EF7 50.52%, #FFDED3 100%, #FFCFC5 100%), linear-gradient(0deg, #8B5CF6, #8B5CF6), linear-gradient(87.17deg, #B6A0F5 0%, #F46EF7 57.29%, #FF95D5 100%), #FFFFFF' - } + background={`${theme.titleBg}`} onClick={handleJoinSpace} > - - Join this space + + {isLoading ? : 'Join this Space'} )} @@ -219,11 +340,56 @@ export const LiveWidgetContent: React.FC = ({ /> ) : null} - +
); }; -const PeerPlayer = styled(Player)` - width: 0; - height: 0; -}`; +const DropDown = styled.div<{ theme?: any; isDDOpen: any }>` + position: absolute; + top: 0px; + right: 0px; + + display: flex; + flex-direction: column; + gap: 12px; + + justify-content: center; + align-items: start; + + animation: ${({ isDDOpen }) => (isDDOpen ? fadeIn : fadeOut)} 0.2s ease-in-out; + padding: 16px; + background: ${(props) => props.theme.bgColorPrimary}; + color: ${(props) => props.theme.textColorPrimary}; + border-radius: 16px; + + border: 1px solid ${(props) => props.theme.borderColor}; +`; + +const DDItem = styled.div` + cursor: pointer; +`; + +const fadeIn = keyframes` + from { + opacity: 0; + } + to { + opacity: 1; + } +`; + +const fadeOut = keyframes` + from { + opacity: 1; + } + to { + opacity: 0; + visibility: hidden; + } +`; + +const PeerPlayerDiv = styled.div` + visibility: hidden; + position: absolute; + border: 5px solid red; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx index 8b041f9c3..19cfa3d12 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/ScheduledWidgetContent.tsx @@ -1,52 +1,70 @@ -import styled from 'styled-components'; +import React, { useEffect, useState } from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { Button, Container, Image, Item, Text } from '../../../config'; import { formatDate } from '../../../helpers'; +import CircularProgressSpinner from '../../loader/loader'; import SpacesIcon from '../../../icons/Spaces.svg'; import TwitterIcon from '../../../icons/twitterVector.svg'; import CopyIcon from '../../../icons/copyVector.svg'; -import AtIcon from '../../../icons/atVector.svg'; +import LensterIcon from '../../../icons/lensterVector.svg'; import { SpaceDTO } from '@pushprotocol/restapi'; import { useSpaceData } from '../../../hooks'; -import { useEffect, useState } from 'react'; +import { generateLensterShareURL } from '../helpers/share'; +import { ShareConfig } from '../exportedTypes'; +import { SpaceStatus } from './WidgetContent'; + +import { ThemeContext } from '../theme/ThemeProvider'; + +enum ShareOptions { + Twitter = 'Twitter', + Lenster = 'Lenster', + CopyShareUrl = 'Copy Link', +} + +export type ShareOptionsValues = keyof typeof ShareOptions; interface ScheduledWidgetContentProps { - account?: string; spaceData?: SpaceDTO; - shareUrl?: string; + share?: ShareConfig; // temp props only for testing demo purpose for now isHost?: boolean; isTimeToStartSpace?: boolean; isMember?: boolean; - isSpaceLive: boolean; - setIsSpaceLive: React.Dispatch>; + spaceStatusState: any; + setSpaceStatusState: React.Dispatch>; } export const ScheduledWidgetContent: React.FC = ({ - account, spaceData, - shareUrl, + share, isHost, isMember, - isSpaceLive, - setIsSpaceLive, + spaceStatusState, + setSpaceStatusState, }: ScheduledWidgetContentProps) => { + const theme = React.useContext(ThemeContext); + const { spacesObjectRef, initSpaceObject, spaceObjectData } = useSpaceData(); + const isTimeToStartSpace = true; - const { - spacesObjectRef, - initSpaceObject, - spaceObjectData, - } = useSpaceData(); + const [isStarted, setIsStarted] = useState(false); + const [isLoading, setIsLoading] = useState(false); + + const { shareUrl, shareOptions = ['Twitter', 'Lenster', 'CopyShareUrl'] } = + share || {}; const handleStartSpace = async () => { + setIsLoading(!isLoading); + console.log('initializing space object'); - await initSpaceObject(spaceData?.spaceId as string); + await initSpaceObject?.(spaceData?.spaceId as string); console.log('creating audio stream'); - await spacesObjectRef.current.createAudioStream(); + await spacesObjectRef?.current?.createAudioStream?.(); + setIsLoading(!isLoading); setIsStarted(true); console.log('Space Started'); }; @@ -63,6 +81,19 @@ export const ScheduledWidgetContent: React.FC = ({ window.open(tweetUrl, '_blank'); }; + const handleShareLenster = () => { + if (!shareUrl) return; + const url = shareUrl; + const lensterShareText = 'Join this space'; + + const lensterShareUrl = generateLensterShareURL({ + text: lensterShareText, + url, + }); + + window.open(lensterShareUrl, '_blank'); + }; + const handleCopyLink = async () => { try { if (!shareUrl) return; @@ -75,144 +106,165 @@ export const ScheduledWidgetContent: React.FC = ({ } }; + const handleShareAction = (shareOption: ShareOptionsValues) => { + switch (shareOption) { + case ShareOptions.Twitter: + handleShareTweet(); + break; + case ShareOptions.Lenster: + handleShareLenster(); + break; + default: + handleCopyLink(); + break; + } + }; + + const getShareOptionDetails = (shareOption: ShareOptionsValues) => { + let icon = ''; + let alt = ''; + + switch (shareOption) { + case ShareOptions.Twitter: + icon = TwitterIcon; + alt = 'Twitter Icon'; + break; + case ShareOptions.Lenster: + icon = LensterIcon; + alt = 'Lenster Icon'; + break; + default: + icon = CopyIcon; + alt = 'Copy Icon'; + break; + } + + return { icon, alt }; + }; + useEffect(() => { async function startSpace() { - if(isSpaceLive) return; - if (!spaceObjectData?.connectionData?.local.stream || !isStarted) return; - await spacesObjectRef.current.start({ - livepeerApiKey: '2638ace1-0a3a-4853-b600-016e6125b9bc', + if (spaceStatusState === SpaceStatus.Live) return; + if (!spaceObjectData?.connectionData?.local?.stream || !isStarted) return; + await spacesObjectRef?.current?.start?.({ + livepeerApiKey: '6d29b32d-78d4-4a5c-9848-a4a0669eb530', }); setIsStarted(false); - setIsSpaceLive && setIsSpaceLive(true); + setSpaceStatusState && setSpaceStatusState(SpaceStatus.Live); } startSpace(); }, [isStarted]); - console.log('Rendering ScheduledWidgetContent'); - console.log('isStarted?', isStarted); - return ( - - Spaces Icon - {isHost ? ( - isTimeToStartSpace ? ( - It’s time to start your space + + + Spaces Icon + {isHost ? ( + isTimeToStartSpace ? ( + It’s time to start your space + ) : ( + + Your space is scheduled.
Share and let people know when to + join! +
+ ) ) : ( - Your space is scheduled.
Share and let people know when to - join! + This space will go live on{' '} + {formatDate((spaceData?.scheduleAt as any) || new Date())}
- ) - ) : ( - - This space will go live on{' '} - {formatDate((spaceData?.scheduleAt as any) || new Date())} - - )} - {isHost && isTimeToStartSpace && ( - - )} - {!isHost && !isMember && ( - - )} - {!isHost && isMember && ( - - )} - {(!isHost || (isHost && !isTimeToStartSpace)) && shareUrl && ( - - - - Twitter Icon - - - Twitter + )} + {isHost && isTimeToStartSpace && ( + + )} + {!isHost && !isMember && ( + + )} + {!isHost && isMember && ( + + )} + {(!isHost || (isHost && !isTimeToStartSpace)) && shareUrl && ( + + {shareOptions.map((shareOption) => { + const { icon, alt } = getShareOptionDetails(shareOption); + return ( + + handleShareAction(shareOption)} + > + {alt} + + + {ShareOptions[shareOption]} + + + ); + })} + + )} +
+
); }; -const SpaceInfoText = styled.span` +export const SpaceInfoText = styled.span` font-size: 18px; font-weight: 600; text-align: center; + color: ${({ theme }) => theme.textColorPrimary}; `; const ShareLinkItem = styled.div` @@ -223,7 +275,7 @@ const ShareLinkItem = styled.div` `; const ShareLinkButton = styled.button` - background: #e4e4e7; + background: ${({ theme }) => theme.bgColorSecondary}; border-radius: 14px; padding: 16px; border: none; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx index a93c9054a..12edd0a70 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/SpaceWidget.tsx @@ -1,5 +1,5 @@ -import React, { MouseEventHandler, useEffect, useState } from 'react'; -import styled from 'styled-components'; +import React, { MouseEventHandler, useEffect, useState, useRef } from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { SpaceDTO } from '@pushprotocol/restapi'; import * as PushAPI from '@pushprotocol/restapi'; @@ -7,9 +7,11 @@ import { WidgetContent } from './WidgetContent'; import { WidgetHeader } from './WidgetHeader'; import { ISpaceWidgetProps } from '../exportedTypes'; -import { isLiveSpace, isHostOfSpace, isMemberOfSpace } from './helpers/utils'; +import { isHostOfSpace, isMemberOfSpace } from './helpers/utils'; -import { useSpaceData } from '../../../hooks'; +import { usePushSpaceSocket, useSpaceData } from '../../../hooks'; + +import { ThemeContext } from '../theme/ThemeProvider'; const DEFAULT_OFFSET = 16; const DEFAULT_MAXWIDTH = 415; @@ -23,27 +25,31 @@ export const SpaceWidget: React.FC = ( width, zIndex = 1000, spaceId, - shareUrl, + share, onClose = (() => { /** */ }) as MouseEventHandler, isTimeToStartSpace, } = options || {}; - const [widgetHidden, setWidgetHidden] = useState(!spaceId); - const { account, spaceObjectData, initSpaceObject, env } = useSpaceData(); + const spaceStatusRef = useRef(); + + const [widgetHidden, setWidgetHidden] = useState(!spaceId); const [isMinimized, setIsMinimized] = useState(false); - const { getSpaceInfo, setSpaceInfo } = useSpaceData(); const [spaceData, setSpaceData] = useState(); - const isLive = spaceData && spaceData?.status === 'ACTIVE' ? true : false; - // console.log('isLiveInWidget', isLive) + const { getSpaceInfo, setSpaceInfo, account, env, spaceInfo } = + useSpaceData(); + + usePushSpaceSocket({ account, env }); useEffect(() => { if (!spaceId) { return; } + setWidgetHidden(!spaceId); + const fetchData = async () => { try { if (getSpaceInfo(spaceId)) { @@ -59,7 +65,13 @@ export const SpaceWidget: React.FC = ( }; fetchData(); - }, [spaceId]); + }, [env, getSpaceInfo, setSpaceInfo, spaceId]); + + useEffect(() => { + if (spaceId && spaceInfo[spaceId]) { + spaceStatusRef.current = spaceInfo[spaceId].status; + } + }, [spaceId, spaceInfo]); // To Be Implemented Later via Meta messages. // useEffect(() => { @@ -84,33 +96,37 @@ export const SpaceWidget: React.FC = ( // Implement the SpaceWidget component return ( - + + + ); }; @@ -125,14 +141,14 @@ interface WidgetContainerProps { const Container = styled.div` font-family: 'Strawford'; // update to fontFamily theme border-radius: 12px; // update acc to theme - border: 1px solid #dcdcdf; // update acc to theme + border: 1px solid ${(props) => props.theme.borderColor}; // update acc to theme display: flex; flex-direction: column; width: ${(props) => (props.width ? `${props.width}px` : 'auto')}; max-width: ${(props) => props.width ? `${props.width}px` : `${DEFAULT_MAXWIDTH}px`}; min-width: 320px; - background: white; + background: ${(props) => props.theme.bgColorPrimary}; justify-content: flex-start; position: fixed; bottom: ${(props) => props.bottomOffset}px; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx index 15a363597..1cddf6790 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/SpacesInfo.tsx @@ -1,104 +1,163 @@ -import React, { useContext, MouseEventHandler } from 'react' +import React, { useContext, MouseEventHandler, useState } from 'react' import styled from 'styled-components'; +import * as PushAPI from '@pushprotocol/restapi'; import { Modal } from '../reusables/Modal' import { ModalHeader } from '../reusables/ModalHeader' -import { IThemeProviderProps, ThemeContext } from '../theme/ThemeProvider'; +import { ThemeContext } from '../theme/ThemeProvider'; import { Button } from '../reusables/Button'; import { ProfileContainer } from '../reusables/ProfileContainer'; import Accordion from '../reusables/Accordion'; +import { SCWInviteModal } from '../SpaceCreationWidget/SCWInviteModal'; + +import { useSpaceData } from '../../../hooks'; export interface ISpacesInfoProps { closeSpacesInfo: MouseEventHandler; -} - -interface IThemeProps { - theme: IThemeProviderProps; + spaceData: any; } export const SpacesInfo: React.FC = (props) => { - const tempImageUrl = "https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg"; + const { spaceData } = props; const theme = useContext(ThemeContext); + const [isInviteVisible, setIsInviteVisible] = useState(false); + + const [invitedMembersList, setInvitedMembersList] = useState([]) + const [invitedAddressList, setInvitedAddressList] = useState([]) + + const [adminsList, setAdminsList] = useState([]) + const [adminsAddressList, setAdminsAddressList] = useState([]) + + const [isLoading, setLoading] = useState(false); + + const { signer, env, pgpPrivateKey } = useSpaceData(); + const customStyle = { - color: theme.textColorPrimary, - background: theme.bgColorPrimary, - borderColor: theme.borderColor, + color: theme?.textColorPrimary, + background: theme?.bgColorPrimary, + borderColor: theme?.borderColor, fontWeight: '500', padding: '14px', } - const TEMP_MEMBERS = [ - { - handle: 's4m4', - name: 'Samarendra' - }, - { - handle: 'aamsa', - name: 'Aam Saltman' - }, - { - handle: 's4m4', - name: 'Samarendra' - }, - { - handle: 'aamsa', - name: 'Aam Saltman' - }, - ] + const showExplicitInvite: React.MouseEventHandler = () => { + setIsInviteVisible(!isInviteVisible); + } + + const closeInviteModal = () => { + setIsInviteVisible(false); + } + + const adminsArray = spaceData?.members?.filter((member: { isSpeaker: boolean; }) => member.isSpeaker); + + const updateSpace = async () => { + const spaceUpdate = { + spaceName: spaceData?.spaceName, + spaceDescription: 'Push Space', + listeners: invitedAddressList, + spaceImage: 'asd', + speakers: adminsAddressList, + isPublic: true, + scheduleAt: new Date(Date.now() + 120000), + signer: signer as PushAPI.SignerType, + env, + spaceId: spaceData?.spaceId, + status: spaceData?.status, + ...(pgpPrivateKey && pgpPrivateKey !== '' && { pgpPrivateKey }), // Conditionally add pgpPrivateKey + } + + try { + setLoading(true); + const response = await PushAPI.space.update(spaceUpdate); + + console.log(response); + } catch (e:any) { + console.error(e.message); + } finally { + setLoading(false); + closeInviteModal(); + } + }; return ( - + - larryscruff's space - Ac orci quam cras in placerat. Sollicitudin tristique sed nisi proin duis. + {spaceData?.spaceName} + {spaceData?.spaceDescription} - - { - TEMP_MEMBERS.map((item) => { + + {spaceData?.pendingMembers && + spaceData.pendingMembers.map((item: any) => { return + handle={item?.wallet?.substring(7)} + name={item?.wallet?.substring(7)} + imageUrl={item?.image} + /> }) } - - + {adminsArray && + adminsArray.slice(1).map((item: any) => { + return + }) + } + + { + isInviteVisible ? + + : null + } ) @@ -107,7 +166,7 @@ export const SpacesInfo: React.FC = (props) => { /** styling */ const SpacesInfoContainer = styled.div` - color: black; + color: ${(props => props.theme?.textColorPrimary)}; `; const SpacesDetailsContainer = styled.div` @@ -119,6 +178,6 @@ const Title = styled.div` font-weight: 500; `; -const Description = styled.div` - color: ${(props => props.theme.textColorSecondary)}; -`; \ No newline at end of file +const Description = styled.div` + color: ${(props => props.theme?.textColorSecondary)}; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx index 3156b2065..017643c19 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/VideoPlayer.tsx @@ -10,16 +10,16 @@ export const VideoPlayer: React.FC = ({ videoCallData }) => { const incomingVideoRef = useRef(null); useEffect(() => { - if (!incomingVideoRef.current) return; + if (!incomingVideoRef?.current) return; const video = incomingVideoRef.current; video.srcObject = videoCallData; video.play(); - }, [incomingVideoRef, videoCallData]); + }, [incomingVideoRef?.current, videoCallData]); return ; }; const Video = styled.video` - height:0; - width:0; -}`; + height: 0; + width: 0; +`; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx index a5ee0c810..2e83d2149 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetContent.tsx @@ -1,10 +1,12 @@ -import React, { useEffect, useState } from 'react'; +import React, { useEffect, useState, MouseEventHandler } from 'react'; import styled from 'styled-components'; import { LiveWidgetContent } from './LiveWidgetContent'; import { ScheduledWidgetContent } from './ScheduledWidgetContent'; import { SpaceDTO } from '@pushprotocol/restapi'; import { useSpaceData } from '../../../hooks'; +import { EndWidgetContent } from './EndWidgetContent'; +import { ShareConfig } from '../exportedTypes'; const LIVE_WIDGET_CONTENT_FIXED_HEIGHT = '485px'; const SCHEDULED_WIDGET_CONTENT_FIXED_HEIGHT = '350px'; @@ -12,55 +14,81 @@ const SCHEDULED_WIDGET_CONTENT_FIXED_HEIGHT = '350px'; interface WidgetContentProps { account?: string; //Temp Prop to Test Host functionality spaceData?: SpaceDTO; - shareUrl?: string; + share?: ShareConfig; isMinimized: boolean; // temp props only for testing demo purpose for now isHost?: boolean; - isLive: boolean; + spaceStatus: any; isTimeToStartSpace?: boolean; isMember?: boolean; + onClose: MouseEventHandler; + toggleWidgetVisibility: () => void; } + +export enum SpaceStatus { + Live = 'ACTIVE', + Scheduled = 'PENDING', + Ended = 'ENDED', +} + export const WidgetContent: React.FC = ({ account, spaceData, - shareUrl, + share, isHost, isTimeToStartSpace, isMember, isMinimized, - isLive, + spaceStatus, + onClose, + toggleWidgetVisibility, }: WidgetContentProps) => { - // const { isLive } = useSpaceData(); - console.log('isLiveInWidgetContent', isLive); - const [isSpaceLive, setIsSpaceLive] = useState(false); - console.log('isSpaceLive', isSpaceLive); + const [spaceStatusState, setSpaceStatusState] = useState( + SpaceStatus.Scheduled + ); - console.log('Rendering WidgetContent'); useEffect(() => { - setIsSpaceLive(isLive); - }, [isLive]); + if (spaceStatus === SpaceStatus.Live) { + setSpaceStatusState(SpaceStatus.Live); + } + if (spaceStatus === SpaceStatus.Scheduled) { + setSpaceStatusState(SpaceStatus.Scheduled); + } + if (spaceStatus === SpaceStatus.Ended) { + setSpaceStatusState(SpaceStatus.Ended); + } + }, [spaceStatus]); return ( - {isSpaceLive ? ( - - ) : ( + {spaceStatusState === SpaceStatus.Live ? ( + + ) : spaceStatusState === SpaceStatus.Scheduled ? ( + ) : ( + )} @@ -71,10 +99,10 @@ export const WidgetContent: React.FC = ({ const Container = styled.div<{ height: string; isMinimized: boolean }>` display: flex; flex-direction: column; - border-bottom: ${(props) => props.theme.border}; + border-bottom: ${(props) => props.theme.borderColor}; height: ${(props) => (props.isMinimized ? '0' : props.height)}; - transition: height 200ms ease-out; + transition: height 300ms ease-out; overflow: hidden; align-items: center; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx index 7a3068ad4..d2ff481f4 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/WidgetHeader.tsx @@ -1,5 +1,10 @@ -import React, { useState, MouseEventHandler, useContext } from 'react'; -import styled from 'styled-components'; +import React, { + useState, + useEffect, + MouseEventHandler, + useContext, +} from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { Item, Text } from '../../../config'; import { formatDate } from '../../../helpers'; @@ -15,6 +20,8 @@ import { SpacesInfo } from './SpacesInfo'; import { ThemeContext } from '../theme/ThemeProvider'; import { useSpaceData } from '../../../hooks'; +import { SpaceStatus } from './WidgetContent'; + export interface IWidgetHeaderProps { onClose: MouseEventHandler; spaceData?: any; @@ -23,7 +30,7 @@ export interface IWidgetHeaderProps { toggleWidgetVisibility: () => void; // temp props - isLive?: boolean; + spaceStatus?: any; isHost?: boolean; } @@ -34,7 +41,7 @@ export const WidgetHeader: React.FC = ({ setIsMinimized, toggleWidgetVisibility, spaceData, - isLive, + spaceStatus, }: IWidgetHeaderProps) => { const theme = useContext(ThemeContext); // const { isLive } = useSpaceData(); @@ -43,6 +50,8 @@ export const WidgetHeader: React.FC = ({ 'https://imgv3.fotor.com/images/blog-richtext-image/10-profile-picture-ideas-to-make-you-stand-out.jpg'; const [isSpacesInfoVisible, setIsSpacesInfoVisible] = useState(false); + const [isSpaceLive, setIsSpaceLive] = useState(SpaceStatus.Scheduled); + const handleCloseWidget: React.MouseEventHandler = ( event ) => { @@ -62,114 +71,141 @@ export const WidgetHeader: React.FC = ({ setIsSpacesInfoVisible(false); }; + useEffect(() => { + if (spaceStatus === SpaceStatus.Live) { + setIsSpaceLive(SpaceStatus.Live); + } + if (spaceStatus === SpaceStatus.Scheduled) { + setIsSpaceLive(SpaceStatus.Scheduled); + } + if (spaceStatus === SpaceStatus.Ended) { + setIsSpaceLive(SpaceStatus.Ended); + } + }, [spaceStatus]); + return ( - - {!isLive && ( -
- - - - - {isHost && } - - Settings icon - - - setIsMinimized(!isMinimized)} - src={isMinimized ? CaretUpIcon : CaretDownIcon} - alt="Maximize/Minimize icon" + + + {(isSpaceLive === SpaceStatus.Scheduled || + isSpaceLive === SpaceStatus.Ended) && ( +
+ + - - - -
- )} -
- - {spaceData?.spaceName || 'Test Space'} - - {isLive && ( - - - Settings icon - - - setIsMinimized(!isMinimized)} - src={isMinimized ? CaretUpIcon : CaretDownIcon} - alt="Maximize/Minimize icon" - /> + {isHost && } + + Settings icon + + + setIsMinimized(!isMinimized)} + src={isMinimized ? CaretUpIcon : CaretDownIcon} + alt="Maximize/Minimize icon" + /> + + + + +
+ )} +
+ + {spaceData?.spaceName || 'Test Space'} + + {isSpaceLive === SpaceStatus.Live && ( - + + Settings icon + + + setIsMinimized(!isMinimized)} + src={isMinimized ? CaretUpIcon : CaretDownIcon} + alt="Maximize/Minimize icon" + /> + + + + + + )} +
+ {isSpaceLive === SpaceStatus.Scheduled && ( + + Calendar Icon + + {formatDate(spaceData?.scheduleAt || new Date())} )} -
- {!isLive && ( - - Calendar Icon - - {formatDate(spaceData?.scheduleAt || new Date())} - - - )} - {isLive && ( -
- - Calendar Icon - - Live - - - - - + {isSpaceLive === SpaceStatus.Live && ( +
+ + Calendar Icon + + Live + - {/* + + + + + {/* +190 Listeners */} - -
- )} - {isSpacesInfoVisible ? ( - - ) : null} - +
+
+ )} + {isSpacesInfoVisible ? ( + + ) : null} +
+ ); }; @@ -206,7 +242,7 @@ const Button = styled.button<{ padding: ${(props) => props.padding ?? '0px'}; color: ${(props) => props.color ?? 'inherit'}; margin-left: 10px; - background: rgba(255, 255, 255, 0.2); + background: ${(props) => props.theme.btnColorPrimary}}; border-radius: 6px; border: none; cursor: pointer; diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts b/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts index bc518b603..7a7532433 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/helpers/utils.ts @@ -3,13 +3,13 @@ import { getSpaceStatus } from '../../helpers/space'; export const isHostOfSpace = (account: string, spaceData: SpaceDTO) => { return ( - account.toUpperCase() === spaceData?.spaceCreator.slice(7).toUpperCase() + account.toUpperCase() === spaceData?.spaceCreator.toUpperCase() ); }; export const isMemberOfSpace = (account: string, spaceData: SpaceDTO) => { const isMemberArr = spaceData?.members.filter( - (member) => member.wallet.slice(7).toUpperCase() === account.toUpperCase() + (member) => member.wallet.toUpperCase() === account.toUpperCase() ); return isMemberArr?.length > 0; }; diff --git a/packages/uiweb/src/lib/components/space/SpacesUI.tsx b/packages/uiweb/src/lib/components/space/SpacesUI.tsx index 0db6e0989..0d52374ee 100644 --- a/packages/uiweb/src/lib/components/space/SpacesUI.tsx +++ b/packages/uiweb/src/lib/components/space/SpacesUI.tsx @@ -4,7 +4,8 @@ import { ISpaceBannerProps, SpaceBanner } from './SpaceBanner'; import { SpaceWidget } from './SpaceWidget'; import { ISpaceFeedProps, SpaceFeed } from './SpaceFeed'; import { ISpaceInvitesProps, SpaceInvites } from './SpaceInvites'; -import { SpaceCreationWidget } from './SpaceCreationWidget'; +import { ISpaceCreateWidgetProps, SpaceCreationWidget } from './SpaceCreationWidget'; +import { ICustomSearchResult } from './SpaceCreationWidget/SCWInviteModal'; import { SignerType } from '../../types'; import { ENV } from '../../config'; @@ -16,12 +17,14 @@ export class SpacesUI { public signer: SignerType; public pgpPrivateKey: string; public env: ENV; + public customSearch: ICustomSearchResult | undefined; constructor(props: ISpacesUIProps) { this.account = props.account; this.signer = props.signer; this.pgpPrivateKey = props.pgpPrivateKey; this.env = props.env; + this.customSearch = props.customSearch; } SpaceBanner: React.FC = (options: ISpaceBannerProps) => { @@ -40,11 +43,11 @@ export class SpacesUI { useEffect(() => { setSpaceId(spaceId); }, [spaceId, setSpaceId]); - + useEffect(() => { - setSpaceId(spaceWidgetId); - }, [spaceWidgetId, setSpaceId]); - + if (spaceWidgetId) setSpaceId(spaceWidgetId); + }, [spaceWidgetId]); + return ; } @@ -56,8 +59,8 @@ export class SpacesUI { return ; }; - SpaceCreationButtonWidget = () => { - return + SpaceCreationButtonWidget = (options: ISpaceCreateWidgetProps) => { + return } connectToSockets = () => { diff --git a/packages/uiweb/src/lib/components/space/exportedTypes.ts b/packages/uiweb/src/lib/components/space/exportedTypes.ts index 9c4aaf140..e45295ac1 100644 --- a/packages/uiweb/src/lib/components/space/exportedTypes.ts +++ b/packages/uiweb/src/lib/components/space/exportedTypes.ts @@ -1,15 +1,23 @@ import { MouseEventHandler } from "react"; +import { ICustomSearchResult } from "./SpaceCreationWidget/SCWInviteModal"; + import { ENV } from "../../config"; import { SignerType } from "../../types"; +import { ShareOptionsValues } from "./SpaceWidget/ScheduledWidgetContent"; export interface ISpacesUIProps { account: string; signer: SignerType; pgpPrivateKey: string; env: ENV; + customSearch?: ICustomSearchResult | undefined; } +export interface ShareConfig { + shareUrl?: string; + shareOptions?: Array; +} export interface ISpaceWidgetProps { // Add props specific to the SpaceWidget class method account?: string; @@ -18,7 +26,7 @@ export interface ISpaceWidgetProps { zIndex?: number; spaceId?: string; width?: number; - shareUrl?: string; + share?: ShareConfig; onClose?: MouseEventHandler; // props only for testing demo purpose for now diff --git a/packages/uiweb/src/lib/components/space/helpers/account.ts b/packages/uiweb/src/lib/components/space/helpers/account.ts new file mode 100644 index 000000000..916b5bbae --- /dev/null +++ b/packages/uiweb/src/lib/components/space/helpers/account.ts @@ -0,0 +1,16 @@ +import { ENV } from "../../../config"; + +const ACCOUNT_START_TYPE = { + NFT: 'nft', + GENERAL: 'eip155' +} + +export const isNftProfile = (account: string) => { + return account && account.split(':')[0] === ACCOUNT_START_TYPE.NFT; +} + +export const spaceChainId = (account: string, env: ENV): number => { + if (account && isNftProfile(account)) + return Number(account.split(':')[2]); + return env === ENV.PROD ? 1: 5; // Ethereum Mainnet Id +} \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/space/helpers/blockies.ts b/packages/uiweb/src/lib/components/space/helpers/blockies.ts index 7cfb98eb3..4e68911b4 100644 --- a/packages/uiweb/src/lib/components/space/helpers/blockies.ts +++ b/packages/uiweb/src/lib/components/space/helpers/blockies.ts @@ -117,3 +117,13 @@ export function createIcon(opts: Options): HTMLCanvasElement { return canvas; } + +export function createBlockie(account: string): HTMLCanvasElement { + const iconParams = { + seed: account, + size: 10, + scale: 3, + }; + + return createIcon(iconParams); +} diff --git a/packages/uiweb/src/lib/components/space/helpers/share.ts b/packages/uiweb/src/lib/components/space/helpers/share.ts new file mode 100644 index 000000000..8c5686fa0 --- /dev/null +++ b/packages/uiweb/src/lib/components/space/helpers/share.ts @@ -0,0 +1,14 @@ +const LENSTER_URL = 'https://lenster.xyz'; + +export interface ILensterUrlProps { + text: string; + url: string; +} +export const generateLensterShareURL = ({text, url}: ILensterUrlProps): string => { + const encodedText = encodeURIComponent(text); + const encodedURL = encodeURIComponent(url); + + const outputURL = `${LENSTER_URL}/?text=${encodedText}&url=${encodedURL}`; + + return outputURL; +} diff --git a/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx b/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx index d962d5fdd..409880a2c 100644 --- a/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/Accordion.tsx @@ -14,7 +14,7 @@ interface IAccordionProps { const Accordion: React.FC = ({ title, items, children }) => { const theme = useContext(ThemeContext) - const [isOpen, setIsOpen] = useState(true); + const [isOpen, setIsOpen] = useState(false); const toggleAccordion = () => { setIsOpen((prevIsOpen) => !prevIsOpen); @@ -86,4 +86,4 @@ const Image = styled.img` height: ${(props: any): string => props.height || '24px'}; width: ${(props: any): string => props.width || '20px'}; align-self: center; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx b/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx index 1938bf21b..9cb11ad76 100644 --- a/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/DateTimePicker.tsx @@ -30,7 +30,7 @@ const DateTimePicker: React.FC = (props) => { const getTime = (hours: number, minutes: number, ampm: string, propsDate: Date) => { let totalMinutes = hours * 60 + minutes; - + if (ampm === 'PM' && hours !== 12) { totalMinutes += 12 * 60; } else if (ampm === 'AM' && hours === 12) { @@ -48,7 +48,7 @@ const DateTimePicker: React.FC = (props) => { const hours = parseInt(selectedHours, 10); const minutes = parseInt(selectedMinutes, 10); const ampm = selectedAMPM; - + const newTimeEpoch = getTime(hours, minutes, ampm, propsDate); setTimeHumanReadable(newTimeEpoch); @@ -118,8 +118,7 @@ const Input = styled.input` width: 330px; background: #FFFFFF; - border: 1px solid ${(props => props.theme.btnOutline)}; - box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border: 2px solid ${(props => props.theme.btnOutline)}; border-radius: 12px; font-size: 16px; @@ -137,8 +136,7 @@ const Select = styled.select<{ width?: string }>` margin-top: 12px; background: #FFFFFF; - border: 1px solid ${(props => props.theme.btnOutline)}; - box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border: 2px solid ${(props => props.theme.btnOutline)}; border-radius: 12px; font-size: 16px; diff --git a/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx b/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx index 3c410a760..e205ca4a8 100644 --- a/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/HostPfpContainer.tsx @@ -1,42 +1,61 @@ import React from 'react'; -import styled from 'styled-components'; +import styled, { ThemeProvider } from 'styled-components'; +import { ThemeContext } from '../theme/ThemeProvider'; + +import { ISpacesTheme } from '../theme'; export interface IHostPfpContainerProps { name?: string; handle?: string; imageUrl?: string; - statusTheme: "Live" | "Scheduled" | "Ended"; + statusTheme: 'Live' | 'Scheduled' | 'Ended'; + imageHeight?: string; +} + +interface IThemeProps { + theme?: ISpacesTheme; + statusTheme?: string; imageHeight?: string; } export const HostPfpContainer: React.FC = ({ - name = "Host Name", - handle = "Host Handle", - imageUrl = "", + name = 'Host Name', + handle = 'Host Handle', + imageUrl = '', statusTheme, imageHeight, }: IHostPfpContainerProps) => { + const theme = React.useContext(ThemeContext); return ( - - - - - - - {name} - Host - - {handle && - - {/* Fetch the handle from Lenster */}@{handle} - - } - - + + + + + + + + {name} + + Host + + + {handle && ( + + {/* Fetch the handle from Lenster */}@{handle} + + )} + + + ); }; -const ProfileContainer = styled.div` +const ProfileContainer = styled.div` display: flex; flex-direction: row; justify-content: space-between; @@ -48,13 +67,13 @@ const PfpContainer = styled.div` display: flex; `; -const Pfp = styled.img<{ imageHeight?: string }>` - height: ${(props) => (props.imageHeight ?? '32px')}; - width: ${(props) => (props.imageHeight ?? '32px')};; +const Pfp = styled.img` + height: ${(props) => props.imageHeight ?? '32px'}; + width: ${(props) => props.imageHeight ?? '32px'}; border-radius: 50%; `; -const HostContainer = styled.div` +const HostContainer = styled.div` display: flex; flex-direction: column; justify-content: center; @@ -65,7 +84,7 @@ const HostContainer = styled.div` text-overflow: ellipsis; `; -const HostName = styled.div` +const HostName = styled.div` display: flex; flex-direction: row; font-weight: 600; @@ -73,13 +92,17 @@ const HostName = styled.div` width: 100%; `; -const Name = styled.span` +const Name = styled.span` text-overflow: ellipsis; white-space: nowrap; overflow: hidden; + color:color: ${(props) => + props.statusTheme === 'Live' + ? `${props.theme.titleTextColor}` + : `${props.theme.textColorPrimary}`}; `; -const Host = styled.div<{ statusTheme?: string }>` +const Host = styled.div` display: flex; flex-direction: row; align-items: center; @@ -90,16 +113,22 @@ const Host = styled.div<{ statusTheme?: string }>` height: 19px; background: ${(props) => props.statusTheme === 'Live' - ? 'rgba(255, 255, 255, 0.2);' - : 'rgba(139, 92, 246, 0.2)'}; - color: ${(props) => (props.statusTheme === 'Live' ? 'inherit' : '#8B5CF6')}; + ? `${props.theme.btnOutline}` + : `${props.theme.btnOutline}`}; + color: ${(props) => + props.statusTheme === 'Live' + ? 'inherit' + : `${props.theme.bgColorSecondary}`}; border-radius: 6px; font-weight: 500; font-size: 10px; `; -const HostHandle = styled.div<{ statusTheme?: string }>` - color: ${(props) => (props.statusTheme === 'Live' ? '#F5F5F5E5' : '#71717A')}; +const HostHandle = styled.div` + color: ${(props) => + props.statusTheme === 'Live' + ? `${props.theme.titleTextColor}` + : `${props.theme.textColorSecondary}`}; padding: 0; font-weight: 450; font-size: 14px; diff --git a/packages/uiweb/src/lib/components/space/reusables/Modal.tsx b/packages/uiweb/src/lib/components/space/reusables/Modal.tsx index b45a54949..6f2115048 100644 --- a/packages/uiweb/src/lib/components/space/reusables/Modal.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/Modal.tsx @@ -36,7 +36,7 @@ const ClickawayCloseModal = ({ children, clickawayClose, width }: IModalProps) = export const Modal = ({ clickawayClose, children, width }: IModalProps) => { const theme = useContext(ThemeContext) return ( - + {clickawayClose ? ( {children} ) : ( @@ -53,7 +53,7 @@ export const Modal = ({ clickawayClose, children, width }: IModalProps) => { /* styling */ -const ModalOverlay = styled.div` +const ModalOverlay = styled.div` position: fixed; top: 0; left: 0; @@ -61,8 +61,10 @@ const ModalOverlay = styled.div` height: 100%; background-color: rgba(0, 0, 0, 0.4); /* Black with 40% opacity */ display: flex; + color: ${props => props.theme.textColorPrimary ?? '#000'}; justify-content: center; align-items: center; + z-index: 10; `; const ModalParent = styled.div` @@ -80,4 +82,4 @@ const ModalParent = styled.div` border-radius: 12px; width: ${(props => props.width ? props.width : 'auto')}; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx b/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx index e6df966a6..07ac0d6f6 100644 --- a/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/ModalHeader.tsx @@ -1,8 +1,9 @@ -import { MouseEventHandler } from 'react'; -import styled from 'styled-components'; +import { MouseEventHandler, useContext } from 'react'; +import styled, { ThemeProvider } from 'styled-components'; import { CloseSvg } from '../../../icons/CloseSvg'; import { ArrowLeft } from '../../../icons/ArrowLeft'; +import { ThemeContext } from '../theme/ThemeProvider'; export interface IModalHeaderProps { heading: string; @@ -12,8 +13,9 @@ export interface IModalHeaderProps { } export const ModalHeader = (props: IModalHeaderProps) => { + const theme = useContext(ThemeContext); return ( -
+
{props.backCallback ? ( @@ -23,7 +25,9 @@ export const ModalHeader = (props: IModalHeaderProps) => { {props.heading} - {props.headingBadgeNumber && {props.headingBadgeNumber}} + {props.headingBadgeNumber && ( + {props.headingBadgeNumber} + )} {props.closeCallback ? ( @@ -32,7 +36,7 @@ export const ModalHeader = (props: IModalHeaderProps) => { ) : null}
-
+ ); }; @@ -43,6 +47,7 @@ const Header = styled.div` width: 100%; margin-bottom: 24px; + color: ${(props) => props.theme.textColorPrimary}; `; const BackBtn = styled.button` @@ -91,7 +96,7 @@ const NumberBadge = styled.div` display: flex; justify-content: center; align-items: center; - background:#8B5CF6; + background: ${(props) => props.theme.btnColorPrimary}; color: #fff; border-radius: 8px; margin-left: 8px; diff --git a/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx b/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx index 789f016ce..d65eb73c9 100644 --- a/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/ParticipantContainer.tsx @@ -66,7 +66,7 @@ const ParticipantsIconContainer = styled.div<{ orientation?: string }>` padding: 0 4px; }`; -const ParticipantsIcon = styled.img<{ imageHeight?: any }>` +const ParticipantsIcon = styled.img<{ imageHeight?: any }>` height: ${(props) => (props.imageHeight ? props.imageHeight : '31px')}; border-radius: 50%; @@ -74,19 +74,19 @@ const ParticipantsIcon = styled.img<{ imageHeight?: any }>` position: relative; top: 0; left: 0; - z-index: 3; + // z-index: 3; } &.index1 { position: relative; top: 0; left: -50%; - z-index: 2; + // z-index: 2; } &.index2 { position: relative; top: 0; left: -100%; - z-index: 1; + // z-index: 1; } }`; diff --git a/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx b/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx index 4eed4f884..1c49480bd 100644 --- a/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/ProfileContainer.tsx @@ -1,5 +1,5 @@ import React, { useContext, useState, useRef, useEffect } from 'react'; -import styled, { keyframes } from 'styled-components'; +import styled, { keyframes, ThemeProvider } from 'styled-components'; import { ThemeContext } from '../theme/ThemeProvider'; export interface IProfileContainerProps { @@ -43,15 +43,16 @@ export const ProfileContainer: React.FC = ({ setIsDDOpen(false); } }; - + document.addEventListener('mousedown', handleOutsideClick); - + return () => { document.removeEventListener('mousedown', handleOutsideClick); }; }, []); return ( + @@ -90,6 +91,7 @@ export const ProfileContainer: React.FC = ({ : null } + ); }; @@ -104,6 +106,7 @@ const ParentContainer = styled.div<{ border?: boolean }>` padding: 8px 16px; border: ${(props => props.border ? '1px solid #E4E4E7' : 'none')}; + color: ${props => props.theme.textColorPrimary ?? '#000'}; border-radius: 16px; `; @@ -162,7 +165,7 @@ const Host = styled.div` line-height: 18px; width: max-content; background: rgba(139, 92, 246, 0.2); - color: #8B5CF6; + color: ${props => props.theme.btnColorPrimary}; border-radius: 6px; font-weight: 500; font-size: 12px; diff --git a/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx b/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx index 5f44c25e2..b0f8539ca 100644 --- a/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/SearchInput.tsx @@ -1,5 +1,5 @@ import { ChangeEvent, useContext } from 'react'; -import styled from 'styled-components'; +import styled, { ThemeProvider } from 'styled-components'; import { ISpacesTheme } from '../theme'; import { ThemeContext } from '../theme/ThemeProvider'; @@ -21,6 +21,7 @@ export const SearchInput = (props: ISearchInputProps) => { }; return ( + @@ -32,6 +33,7 @@ export const SearchInput = (props: ISearchInputProps) => { + ); }; @@ -42,7 +44,7 @@ const InputContainer = styled.div` margin: 16px 0; - font-family: 'Strawford'; // update to fontFamily theme + font-family: 'Strawford'; // update to fontFamily theme `; const LabelContainer = styled.div` @@ -50,6 +52,7 @@ const LabelContainer = styled.div` justify-content: space-between; font-weight: 500; + color: ${props => props.theme.textColorPrimary ?? '#000'} `; const Input = styled.input` @@ -59,8 +62,7 @@ const Input = styled.input` width: 330px; background: #FFFFFF; - border: 1px solid ${(props => props.theme.btnOutline)}; - box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border: 2px solid ${(props => props.theme.btnOutline)}; border-radius: 12px; `; @@ -73,4 +75,4 @@ const CloseBtn = styled.div` right: 0; top: 0; padding: 1.75rem 0.75rem; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx b/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx index d635de040..0d975ac6f 100644 --- a/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/Spinner.tsx @@ -1,6 +1,7 @@ import React, { useContext } from 'react'; -import styled, { keyframes } from 'styled-components'; +import styled, { keyframes, ThemeProvider } from 'styled-components'; import { SpinnerSvg } from '../../../icons/SpinnerSvg'; +import { ThemeContext } from '../theme/ThemeProvider'; type SpinnerPropType = { size?: string; @@ -11,10 +12,13 @@ type SpinLoaderPropType = { }; export const Spinner: React.FC = ({ size = 42 }) => { + const theme = useContext(ThemeContext); return ( - - - + + + + + ); }; diff --git a/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx b/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx index d87d90a2d..509945f4d 100644 --- a/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx +++ b/packages/uiweb/src/lib/components/space/reusables/TextInput.tsx @@ -1,5 +1,5 @@ import React, { ChangeEvent, useContext } from 'react'; -import styled from 'styled-components'; +import styled, { ThemeProvider } from 'styled-components'; import { ISpacesTheme } from '../theme'; import { ThemeContext } from '../theme/ThemeProvider'; @@ -24,6 +24,7 @@ export const TextInputWithCounter = (props: ITextInputProps) => { }; return ( + @@ -31,6 +32,7 @@ export const TextInputWithCounter = (props: ITextInputProps) => { + ); }; @@ -41,7 +43,7 @@ const InputContainer = styled.div` margin: 16px 0; - font-family: 'Strawford'; // update to fontFamily theme + font-family: 'Strawford'; // update to fontFamily theme `; const LabelContainer = styled.div` @@ -49,6 +51,7 @@ const LabelContainer = styled.div` justify-content: space-between; font-weight: 500; + color: ${props => props.theme.textColorPrimary ?? '#000'} `; const Input = styled.input` @@ -58,14 +61,13 @@ const Input = styled.input` width: 330px; background: #FFFFFF; - border: 1px solid ${(props => props.theme.btnOutline)}; - box-shadow: -1px -1px 2px ${(props => props.theme.btnOutline)}, 1px 1px 2px ${(props => props.theme.btnOutline)}; + border: 2px solid ${(props => props.theme.btnOutline)}; border-radius: 12px; - font-family: 'Strawford'; // update to fontFamily theme + font-family: 'Strawford'; // update to fontFamily theme font-size: 14px; `; const CharCounter = styled.div` color: ${(props => props.theme.textColorSecondary)}; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/space/theme/index.ts b/packages/uiweb/src/lib/components/space/theme/index.ts index 99c70253e..52c116397 100644 --- a/packages/uiweb/src/lib/components/space/theme/index.ts +++ b/packages/uiweb/src/lib/components/space/theme/index.ts @@ -36,7 +36,7 @@ export const lightTheme: ISpacesTheme = { containerBorderRadius: '12px', statusColorError: '#E93636', statusColorSuccess: '#30CC8B', - iconColorPrimary: '#82828A' + iconColorPrimary: '#82828A', }; export const darkTheme: ISpacesTheme = { @@ -54,5 +54,5 @@ export const darkTheme: ISpacesTheme = { containerBorderRadius: '12px', statusColorError: '#E93636', statusColorSuccess: '#30CC8B', - iconColorPrimary: '#71717A' + iconColorPrimary: '#71717A', }; diff --git a/packages/uiweb/src/lib/context/chatAndNotification/chat/chatMainStateContext.tsx b/packages/uiweb/src/lib/context/chatAndNotification/chat/chatMainStateContext.tsx index 033be516f..53dcfe7eb 100644 --- a/packages/uiweb/src/lib/context/chatAndNotification/chat/chatMainStateContext.tsx +++ b/packages/uiweb/src/lib/context/chatAndNotification/chat/chatMainStateContext.tsx @@ -26,6 +26,10 @@ export type ChatMainStateContextType = { setConnectedProfile: (connectedProfile: IUser) => void; searchedChats: ChatFeedsType | null; setSearchedChats: (chats:ChatFeedsType | null) => void; + finishedFetchingChats:boolean; + finishedFetchingRequests:boolean; + setFinishedFetchingChats: (flag: boolean) => void; + setFinishedFetchingRequests: (flag: boolean) => void; } export const ChatMainStateContext = createContext({} as ChatMainStateContextType); @@ -38,6 +42,9 @@ const [requestsFeed,setRequestsFeed] =useState({} as ChatFeedsTyp const [chats,setChats] = useState >(new Map()); const [selectedChatId,setSelectedChatId] = useState(null); const [searchedChats,setSearchedChats] = useState(null); +const [finishedFetchingChats,setFinishedFetchingChats] = useState(false); +const [finishedFetchingRequests,setFinishedFetchingRequests] = useState(false); + @@ -47,20 +54,20 @@ const [searchedChats,setSearchedChats] = useState(null); setChatsFeed(prevChatsFeed => ({ [id]: newChatFeed , ...prevChatsFeed, - + })); } const setRequestFeed = (id: string,newRequestFeed:IFeeds) => { setRequestsFeed(prevRequestsFeed => ({ [id]: newRequestFeed , ...prevRequestsFeed, - + })); } const setWeb3Name = (id: string,web3Name:string) => { setWeb3NameList(prev => ({ ...prev, - [id]: web3Name + [id]: web3Name })); } @@ -73,7 +80,7 @@ const [searchedChats,setSearchedChats] = useState(null); return ( - (null); web3NameList, setWeb3NameList, setWeb3Name, + finishedFetchingChats, + finishedFetchingRequests, + setFinishedFetchingChats, + setFinishedFetchingRequests }}> {children} diff --git a/packages/uiweb/src/lib/context/chatAndNotification/notifcation/notificationMainStateContext.tsx b/packages/uiweb/src/lib/context/chatAndNotification/notifcation/notificationMainStateContext.tsx index af1a1b04e..6c9068dd7 100644 --- a/packages/uiweb/src/lib/context/chatAndNotification/notifcation/notificationMainStateContext.tsx +++ b/packages/uiweb/src/lib/context/chatAndNotification/notifcation/notificationMainStateContext.tsx @@ -24,6 +24,10 @@ export type NotificationMainStateContextType = { subscriptionStatus: Map; setSubscriptionStatus: (subscriptionStatus: Map) => void; setChannelSubscriptionStatus: (id: string, status: boolean) => void; + finishedFetchingInbox:boolean; + finishedFetchingSpam:boolean; + setFinishedFetchingInbox: (flag: boolean) => void; + setFinishedFetchingSpam: (flag: boolean) => void; }; export const NotificationMainStateContext = @@ -47,6 +51,8 @@ const NotificationMainStateContextProvider = ({ const [subscriptionStatus, setSubscriptionStatus] = useState>(new Map()); const [searchedNotifications, setSearchedNotifications] = useState(null); + const [finishedFetchingInbox,setFinishedFetchingInbox] = useState(false); + const [finishedFetchingSpam,setFinishedFetchingSpam] = useState(false); const setInboxNotifFeed = ( id: string, @@ -89,6 +95,10 @@ const NotificationMainStateContextProvider = ({ subscriptionStatus, setChannelSubscriptionStatus, setSubscriptionStatus, + finishedFetchingInbox, + finishedFetchingSpam, + setFinishedFetchingInbox, + setFinishedFetchingSpam }} > {children} diff --git a/packages/uiweb/src/lib/context/spacesContext.ts b/packages/uiweb/src/lib/context/spacesContext.ts index cac6e2f4d..8393f75bd 100644 --- a/packages/uiweb/src/lib/context/spacesContext.ts +++ b/packages/uiweb/src/lib/context/spacesContext.ts @@ -3,6 +3,7 @@ import * as PushAPI from '@pushprotocol/restapi'; import { SpaceDTO, SpaceIFeeds } from '@pushprotocol/restapi'; import { SignerType } from '../types'; import { ENV } from '../config'; +import { FeedTabs } from '../components/space/SpaceFeed'; export interface ISpaceInfo { [key: string]: SpaceDTO; @@ -18,6 +19,13 @@ export interface ISpacePaginationData { lastPage?: number; } +export interface ICustomSearchResult { + account: string; + name?: string; + handle?: string; + image?: string; // dataURL as string +} + export interface ISpaceDataContextValues { account: string; setAccount: React.Dispatch>; @@ -27,6 +35,10 @@ export interface ISpaceDataContextValues { setPgpPrivateKey: React.Dispatch>; env: ENV; setEnv: React.Dispatch>; + chainId: number; + setChainId: React.Dispatch>; + selectedFeedTab: FeedTabs; + setSelectedFeedTab: React.Dispatch>; trendingListData: any; setTrendingListData: React.Dispatch>; spaceInfo: ISpaceInfo; @@ -50,6 +62,9 @@ export interface ISpaceDataContextValues { isListener: boolean; speakerData: ISpaceSpeakerData; setSpeakerData: (key: string, value: PushAPI.video.VideoDataType) => void; + acceptSpaceRequest: (spaceMetaData: PushAPI.video.VideoDataType) => Promise; + connectSpaceRequest: (spaceMetaData: PushAPI.video.VideoDataType) => Promise; + customSearch?: (query: string) => ICustomSearchResult; } export const initialSpaceDataContextValues: ISpaceDataContextValues = { @@ -69,10 +84,18 @@ export const initialSpaceDataContextValues: ISpaceDataContextValues = { setEnv: () => { /**/ }, + chainId: 1, + setChainId: () => { + /** */ + }, trendingListData: null, setTrendingListData: () => { /**/ }, + selectedFeedTab: "Popular" as FeedTabs, + setSelectedFeedTab: () => { + /** */ + }, spaceInfo: {} as ISpaceInfo, setSpaceInfo: () => { /**/ @@ -124,6 +147,13 @@ export const initialSpaceDataContextValues: ISpaceDataContextValues = { setSpeakerData: () => { /** */ }, + acceptSpaceRequest: async () => { + /** */ + }, + connectSpaceRequest: async () => { + /** */ + }, + customSearch: undefined, }; export const SpaceDataContext = createContext( diff --git a/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx index e716dbaf0..9538a1987 100644 --- a/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx +++ b/packages/uiweb/src/lib/dataProviders/SpaceDataProvider.tsx @@ -14,14 +14,21 @@ import { import { ENV } from '../config'; import * as PushAPI from '@pushprotocol/restapi'; -import { usePushSpaceSocket, useSpaceNotificationSocket } from '../hooks'; +import { useSpaceNotificationSocket } from '../hooks'; import { LivepeerConfig, - Player, createReactClient, studioProvider, } from '@livepeer/react'; +import { spaceChainId } from '../components/space/helpers/account'; +import { walletToPCAIP10 } from '../helpers'; + +export enum FeedTabs { + ForYou = 'For You', + Popular = 'Popular', + HostedByYou = 'Hosted by you', +} export interface ISpacesUIProviderProps { spaceUI: SpacesUI; @@ -35,13 +42,17 @@ export const SpacesUIProvider = ({ children, }: ISpacesUIProviderProps) => { const spacesObjectRef = useRef({} as PushAPI.space.Space); - const [account, setAccount] = useState(spaceUI.account); + const [account, setAccount] = useState(walletToPCAIP10(spaceUI.account)); const [signer, setSigner] = useState(spaceUI.signer); const [pgpPrivateKey, setPgpPrivateKey] = useState( spaceUI.pgpPrivateKey ); const [env, setEnv] = useState(spaceUI.env); + const [chainId, setChainId] = useState( + spaceChainId(spaceUI.account, spaceUI.env) + ); const [spaceWidgetId, setSpaceWidgetId] = useState(''); + const [selectedFeedTab, setSelectedFeedTab] = useState(FeedTabs['Popular']); const [speakerData, setSpeakerData] = useState({} as ISpaceSpeakerData); @@ -76,7 +87,7 @@ export const SpacesUIProvider = ({ const livepeerClient = createReactClient({ provider: studioProvider({ - apiKey: '2638ace1-0a3a-4853-b600-016e6125b9bc', + apiKey: '6d29b32d-78d4-4a5c-9848-a4a0669eb530', }), }); @@ -104,13 +115,49 @@ export const SpacesUIProvider = ({ signer, pgpPrivateKey, address: account, - chainId: 5, // TODO: Make this dynamic + chainId: chainId, env, setSpaceData: setSpaceObjectData, }); await spacesObjectRef.current.initialize({ spaceId }); }; + const acceptSpaceRequest = async ({ + senderAddress, + recipientAddress, + chatId, + signalData, + }: PushAPI.video.VideoDataType) => { + console.log( + 'INSIDE WRAPPER ACCEPT REQUEST', + 'spacesObjectRef?.current', + spacesObjectRef?.current + ); + + await spacesObjectRef.current?.acceptRequest({ + recipientAddress: senderAddress, + senderAddress: recipientAddress, + chatId, + signalData, + }); + }; + + const connectSpaceRequest = async ({ + senderAddress, + signalData, + }: PushAPI.video.VideoDataType) => { + console.log( + 'INSIDE WRAPPER CONNECT', + 'spacesObjectRef?.current', + spacesObjectRef?.current + ); + + await spacesObjectRef.current.connect({ + peerAddress: senderAddress, + signalData, + }); + }; + const getSpaceInfo = (spaceId: string): SpaceDTO | undefined => { return spaceInfo[spaceId]; }; @@ -124,17 +171,22 @@ export const SpacesUIProvider = ({ const existingIds = new Set( prevState.apiData?.map((space: SpaceIFeeds) => space.spaceId) ); - console.log('Existing ID', existingIds); const uniqueSpaces = apiData?.filter( (space) => !existingIds.has(space.spaceId) ); - console.log('Unique Spaces', uniqueSpaces); + + let updatedApiData: SpaceIFeeds[] = []; + if (prevState.apiData) { + updatedApiData = [...prevState.apiData, ...uniqueSpaces]; + updatedApiData.sort((a, b) => new Date(b.intentTimestamp).getTime() - new Date(a.intentTimestamp).getTime()); + } else { + updatedApiData = uniqueSpaces; + } return { ...prevState, - ...(uniqueSpaces && - prevState.apiData && { - apiData: [...prevState.apiData, ...uniqueSpaces], - }), + ...(updatedApiData.length > 0 && { + apiData: updatedApiData, + }), }; } return { @@ -154,17 +206,22 @@ export const SpacesUIProvider = ({ const existingIds = new Set( prevState.apiData?.map((space: SpaceIFeeds) => space.spaceId) ); - console.log('Existing ID', existingIds); const uniqueSpaces = apiData?.filter( (space) => !existingIds.has(space.spaceId) ); - console.log('Unique Spaces', uniqueSpaces); + + let updatedApiData: SpaceIFeeds[] = []; + if (prevState.apiData) { + updatedApiData = [...prevState.apiData, ...uniqueSpaces]; + updatedApiData.sort((a, b) => new Date(b.intentTimestamp).getTime() - new Date(a.intentTimestamp).getTime()); + } else { + updatedApiData = uniqueSpaces; + } return { ...prevState, - ...(uniqueSpaces && - prevState.apiData && { - apiData: [...prevState.apiData, ...uniqueSpaces], - }), + ...(updatedApiData.length > 0 && { + apiData: updatedApiData, + }), }; } return { @@ -184,17 +241,22 @@ export const SpacesUIProvider = ({ const existingIds = new Set( prevState.apiData?.map((space: SpaceIFeeds) => space.spaceId) ); - console.log('Existing ID', existingIds); const uniqueSpaces = apiData?.filter( (space) => !existingIds.has(space.spaceId) ); - console.log('Unique Spaces', uniqueSpaces); + + let updatedApiData: SpaceIFeeds[] = []; + if (prevState.apiData) { + updatedApiData = [...prevState.apiData, ...uniqueSpaces]; + updatedApiData.sort((a, b) => new Date(b.intentTimestamp).getTime() - new Date(a.intentTimestamp).getTime()); + } else { + updatedApiData = uniqueSpaces; + } return { ...prevState, - ...(uniqueSpaces && - prevState.apiData && { - apiData: [...prevState.apiData, ...uniqueSpaces], - }), + ...(updatedApiData.length > 0 && { + apiData: updatedApiData, + }), }; } return { @@ -209,16 +271,16 @@ export const SpacesUIProvider = ({ spaceObjectData?.members?.find((member) => { if ( account?.toUpperCase() === - spaceObjectData.spaceCreator.replace('eip155:', '').toUpperCase() + spaceObjectData.spaceCreator.toUpperCase() ) return false; - const address = member.wallet.replace('eip155:', ''); + const address = member.wallet; return ( address?.toUpperCase() === account?.toUpperCase() && member.isSpeaker ); }) || spaceObjectData?.pendingMembers?.find((member) => { - const address = member.wallet.replace('eip155:', ''); + const address = member.wallet; return ( address?.toUpperCase() === account?.toUpperCase() && member.isSpeaker ); @@ -227,21 +289,22 @@ export const SpacesUIProvider = ({ const isListener = Boolean( spaceObjectData?.members?.find((member) => { - console.log('member', member); - const address = member.wallet.replace('eip155:', ''); + const address = member.wallet; return ( address.toUpperCase() === account.toUpperCase() && !member.isSpeaker ); }) || spaceObjectData?.pendingMembers?.find((member) => { - console.log('pending member', member); - const address = member.wallet.replace('eip155:', ''); + const address = member.wallet; return ( address.toUpperCase() === account.toUpperCase() && !member.isSpeaker ); - }) + }) || + !isSpeaker ); + const customSearch = undefined; + const value: ISpaceDataContextValues = { account, setAccount, @@ -251,6 +314,8 @@ export const SpacesUIProvider = ({ setPgpPrivateKey, env, setEnv, + chainId, + setChainId, trendingListData, setTrendingListData, spaceInfo, @@ -258,6 +323,8 @@ export const SpacesUIProvider = ({ getSpaceInfo, spaceWidgetId, setSpaceWidgetId, + selectedFeedTab, + setSelectedFeedTab, mySpaces, setMySpaces: setMySpacePaginationInfo, popularSpaces, @@ -273,20 +340,49 @@ export const SpacesUIProvider = ({ isListener, speakerData, setSpeakerData: setSpeakerDataItem, + acceptSpaceRequest, + connectSpaceRequest, + customSearch, + }; + + const resetStates = () => { + setSpaceWidgetId(''); + setSpeakerData({} as ISpaceSpeakerData); + setSpaceObjectData(PushAPI.space.initSpaceData); + setSpaceRequests({ + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData); + setMySpaces({ + apiData: [] as SpaceIFeeds[], + currentPage: 1, + lastPage: 2, + } as ISpacePaginationData); }; useEffect(() => { - setAccount(spaceUI.account); + resetStates(); + setAccount(walletToPCAIP10(spaceUI.account)); setSigner(spaceUI.signer); setEnv(spaceUI.env); setPgpPrivateKey(spaceUI.pgpPrivateKey); - }, [spaceUI]); + + // reset + setChainId(spaceChainId(spaceUI.account, spaceUI.env)); + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [spaceUI.account, spaceUI.env, spaceUI.pgpPrivateKey, spaceUI.signer]); const PROVIDER_THEME = Object.assign({}, lightTheme, theme); spaceUI.init(); - useSpaceNotificationSocket({ account, env }); - usePushSpaceSocket({ account, env }); + useSpaceNotificationSocket({ + account, + env, + acceptSpaceRequest, + connectSpaceRequest, + }); + // usePushSpaceSocket({ account, env }); return ( diff --git a/packages/uiweb/src/lib/helpers/address.ts b/packages/uiweb/src/lib/helpers/address.ts index 40fbf8d50..5c1912572 100644 --- a/packages/uiweb/src/lib/helpers/address.ts +++ b/packages/uiweb/src/lib/helpers/address.ts @@ -1,13 +1,36 @@ import { ethers } from 'ethers'; import type { Web3Provider } from '@ethersproject/providers'; -export const walletToPCAIP10 = (account: string): string => { - if (account.includes('eip155:')) { - return account; +/** + * + * @param wallet nft:eip155:nftChainId:nftContractAddress:nftTokenId + * @returns + */ +export const isValidCAIP10NFTAddress = (wallet: string): boolean => { + try { + const walletComponent = wallet.split(':'); + return ( + (walletComponent.length === 5 || walletComponent.length === 6)&& + walletComponent[0].toLowerCase() === 'nft' && + !isNaN(Number(walletComponent[4])) && + Number(walletComponent[4]) > 0 && + !isNaN(Number(walletComponent[2])) && + Number(walletComponent[2]) > 0 && + ethers.utils.isAddress(walletComponent[3]) && + walletComponent[1] === 'eip155' + ); + } catch (err) { + return false; } - return 'eip155:' + account; }; +export const walletToPCAIP10 = (account:string): string => { + if(isValidCAIP10NFTAddress(account) || account.includes('eip155:')){ + return account + } + return 'eip155:' + account +} + export const pCAIP10ToWallet = (wallet: string): string => { if(wallet) wallet = wallet.replace('eip155:', ''); diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts index 4f6ad64c7..f3d8e61a0 100644 --- a/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts @@ -243,7 +243,7 @@ const useChatNotificationSocket = ({ } let chainId = 1; (async () => { - chainId = await signer.getChainId(); + chainId = await signer?.getChainId(); })(); // this is auto-connect on instantiation const connectionObject = createSocketConnection({ diff --git a/packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts b/packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts index 8386d1210..1c81fc7d6 100644 --- a/packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts +++ b/packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts @@ -19,7 +19,7 @@ const useFetchUserSubscriptions = () => { const fetchUserSubscriptions = useCallback(async () => { setLoading(true); try { - const chainId = await signer.getChainId(); + const chainId = await signer?.getChainId(); const results = await PushAPI.user.getSubscriptions({ user: convertAddressToAddrCaip(account, chainId), // user address in CAIP env, diff --git a/packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts b/packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts index 035784e87..8f7e87729 100644 --- a/packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts +++ b/packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts @@ -26,7 +26,7 @@ const useOnSubscribeToChannel = () => { if (!address) return; console.log(signer) - const chainId = await signer.getChainId(); + const chainId = await signer?.getChainId(); await PushAPI.channels.subscribe({ signer: signer, diff --git a/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts b/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts index 1e50445c6..f0380cc37 100644 --- a/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts +++ b/packages/uiweb/src/lib/hooks/space/useGetSpaceInfo.ts @@ -8,7 +8,7 @@ import { SpaceDTO } from '@pushprotocol/restapi'; import { ENV } from '../../config'; export const useGetSpaceInfo = (spaceId: string): SpaceDTO | undefined => { - const { getSpaceInfo, setSpaceInfo, env }: ISpaceDataContextValues = + const { getSpaceInfo, setSpaceInfo, env, spaceInfo }: ISpaceDataContextValues = useContext(SpaceDataContext); const [spaceData, setSpaceDataState] = useState( getSpaceInfo(spaceId) @@ -18,6 +18,10 @@ export const useGetSpaceInfo = (spaceId: string): SpaceDTO | undefined => { if (!spaceId) { return; } + if(getSpaceInfo(spaceId)) { + setSpaceDataState(getSpaceInfo(spaceId)); + return; + } const fetchData = async () => { if (!spaceData) { try { @@ -29,9 +33,8 @@ export const useGetSpaceInfo = (spaceId: string): SpaceDTO | undefined => { } } }; - fetchData(); - }, [spaceId, spaceData, getSpaceInfo, setSpaceInfo]); + }, [spaceId, spaceData, getSpaceInfo, setSpaceInfo, spaceInfo, env]); return spaceData; }; diff --git a/packages/uiweb/src/lib/hooks/space/useMySpaces.ts b/packages/uiweb/src/lib/hooks/space/useMySpaces.ts index d78de24ff..67344ff86 100644 --- a/packages/uiweb/src/lib/hooks/space/useMySpaces.ts +++ b/packages/uiweb/src/lib/hooks/space/useMySpaces.ts @@ -17,6 +17,7 @@ export const useMySpaces = (account?: string) => { account: account, page: mySpaces.currentPage, limit: LIMIT, + toDecrypt: false, env, }); diff --git a/packages/uiweb/src/lib/hooks/space/usePushSpaceSocket.tsx b/packages/uiweb/src/lib/hooks/space/usePushSpaceSocket.tsx index 8346b7b3e..979212ba2 100644 --- a/packages/uiweb/src/lib/hooks/space/usePushSpaceSocket.tsx +++ b/packages/uiweb/src/lib/hooks/space/usePushSpaceSocket.tsx @@ -3,7 +3,7 @@ import { useCallback, useEffect, useState } from 'react'; import { ENV } from '../../config'; import { useSpaceData } from './useSpaceData'; import * as PushAPI from "@pushprotocol/restapi"; -import { SpaceDTO, SpaceIFeeds } from '@pushprotocol/restapi'; +import { SpaceDTO } from '@pushprotocol/restapi'; const SPACE_SOCKET_TYPE = 'chat'; @@ -16,7 +16,7 @@ export const usePushSpaceSocket = ({ account, env = ENV.PROD, }: PushSDKSocketHookOptions) => { - const { spaceRequests, setSpaceRequests } = useSpaceData(); + const { spaceRequests, setSpaceRequests, popularSpaces, setPopularSpaces, mySpaces, setMySpaces, setSpaceInfo } = useSpaceData(); const [pushSpaceSocket, setPushSpaceSocket] = useState(null); const [isPushSDKSocketConnected, setIsPushSDKSocketConnected] = useState(false); @@ -37,26 +37,95 @@ export const usePushSpaceSocket = ({ } ); - pushSpaceSocket?.on('SPACES', (spaceInfo: SpaceDTO) => { - console.log(spaceInfo); + pushSpaceSocket?.on('SPACES', async (spaceInfo: SpaceDTO) => { + console.log(spaceInfo, spaceRequests, popularSpaces, mySpaces); - const updatedData = spaceRequests?.apiData?.map(item => { - if (item.spaceId === spaceInfo.spaceId) { - return { - ...item, - spaceInformation: spaceInfo - }; + /* TODO: In future, store all space info in SpaceInfo state itself, and mySpaces, popularSpaces, requests only store spaceId + so as to only update spaceInfo once and it should reflect at every place*/ + setSpaceInfo(spaceInfo.spaceId, spaceInfo); + + const isSpaceInvite: boolean = spaceInfo?.pendingMembers?.some(member => member.wallet === account); + if(isSpaceInvite) { + const isInInvites: boolean = spaceRequests?.apiData?.some(invite => invite.spaceId === spaceInfo.spaceId) ?? false; + if (isInInvites) { + const updatedRequests = spaceRequests?.apiData?.map(item => { + if (item.spaceId === spaceInfo.spaceId) { + return { + ...item, + spaceInformation: spaceInfo + }; + } + return item; + }); + + setSpaceRequests({ + apiData: updatedRequests as PushAPI.SpaceIFeeds[] + }) + } else { + const spaceFeed: PushAPI.SpaceIFeeds = await PushAPI.space.space({ + account: account as string, + env, + recipient: spaceInfo.spaceId, + toDecrypt: false + }) + const updatedRequests: PushAPI.SpaceIFeeds[] = [ + spaceFeed, + ...(spaceRequests?.apiData || []), + ]; + + setSpaceRequests({ + apiData: updatedRequests as PushAPI.SpaceIFeeds[] + }) + } + } else { + const isInMySpaces: boolean = mySpaces?.apiData?.some(invite => invite.spaceId === spaceInfo.spaceId) ?? false; + if (isInMySpaces) { + const updatedMySpaces = mySpaces?.apiData?.map(item => { + if (item.spaceId === spaceInfo.spaceId) { + return { + ...item, + spaceInformation: spaceInfo + }; + } + return item; + }); + + setMySpaces({ + apiData: updatedMySpaces as PushAPI.SpaceIFeeds[] + }) + } else { + const spaceFeed: PushAPI.SpaceIFeeds = await PushAPI.space.space({ + account: account as string, + env, + recipient: spaceInfo.spaceId, + toDecrypt: false + }) + const updatedMySpaces: PushAPI.SpaceIFeeds[] = [ + spaceFeed, + ...(mySpaces?.apiData || []), + ]; + + setMySpaces({ + apiData: updatedMySpaces as PushAPI.SpaceIFeeds[] + }) + } } - return item; - }); - - setSpaceRequests({ - apiData: updatedData as PushAPI.SpaceIFeeds[] - }) + + const updatedPopularSpaces = popularSpaces?.apiData?.map(item => { + if (item.spaceId === spaceInfo.spaceId) { + return { + ...item, + spaceInformation: spaceInfo + }; + } + return item; + }); + + setPopularSpaces({ + apiData: updatedPopularSpaces as PushAPI.SpaceIFeeds[] + }) }); - }, [ - pushSpaceSocket - ]); + }, [account, mySpaces, popularSpaces, pushSpaceSocket, setMySpaces, setPopularSpaces, setSpaceInfo, setSpaceRequests, spaceRequests, env]); const removeSocketEvents = useCallback(() => { pushSpaceSocket?.off(EVENTS.CONNECT); diff --git a/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts b/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts index a8daa4ac6..a5ef2fdca 100644 --- a/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts +++ b/packages/uiweb/src/lib/hooks/space/useSpaceNotificationSocket.ts @@ -1,22 +1,28 @@ import { useCallback, useEffect, useState } from 'react'; import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; import * as PushAPI from '@pushprotocol/restapi'; -import { useSpaceData } from './useSpaceData'; import { ENV } from '../../config'; +import { pCAIP10ToWallet } from '../../helpers'; const NOTIFICATION_SOCKET_TYPE = 'notification'; export type SDKSpaceNotificationSocketHookOptions = { account?: string | null; env?: ENV; + acceptSpaceRequest: ( + spaceMetaData: PushAPI.video.VideoDataType + ) => Promise; + connectSpaceRequest: ( + spaceMetaData: PushAPI.video.VideoDataType + ) => Promise; }; export const useSpaceNotificationSocket = ({ account, + acceptSpaceRequest, + connectSpaceRequest, env = ENV.PROD, }: SDKSpaceNotificationSocketHookOptions) => { - const { spacesObjectRef } = useSpaceData(); - const [notificationSocket, setNotificationSocket] = useState(null); const [isNotificationSocketConnected, setIsNotificationSocketConnected] = useState(false); @@ -33,53 +39,44 @@ export const useSpaceNotificationSocket = ({ notificationSocket?.on(EVENTS.USER_FEEDS, (feedItem: any) => { const { payload } = feedItem; - console.log('RECEIVED USER FEEDS NOTIF', payload); + console.log( + 'USER FEEDS NOTIFICATION RECEIVED', + payload?.data?.additionalMeta?.type, + `${PushAPI.payloads.ADDITIONAL_META_TYPE.PUSH_SPACE}+1` + ); if ( payload?.data?.additionalMeta?.type === - `${PushAPI.payloads.ADDITIONAL_META_TYPE.PUSH_VIDEO}+1` + `${PushAPI.payloads.ADDITIONAL_META_TYPE.PUSH_SPACE}+1` ) { - const { - status, - callDetails, - senderAddress, - recipientAddress, - signalData, - chatId, - }: PushAPI.video.VideoDataType = JSON.parse( + const receivedSpaceMetaData: PushAPI.video.VideoDataType = JSON.parse( payload.data.additionalMeta.data ); + const { callDetails, status } = receivedSpaceMetaData; + + console.log('RECEIVED ADDITIONAL META DATA', receivedSpaceMetaData); + if (status === PushAPI.VideoCallStatus.INITIALIZED) { if ( callDetails?.type === PushAPI.payloads.SPACE_REQUEST_TYPE.JOIN_SPEAKER ) { + console.log( + 'ON HOST, ACCEPTING REQUEST OF AN ADDED SPEAKER TO JOIN' + ); // TODO: see if check for speaker is req - spacesObjectRef.current?.acceptRequest({ - senderAddress: recipientAddress, - recipientAddress: senderAddress, - signalData, - chatId, - }); + acceptSpaceRequest(receivedSpaceMetaData); } if ( callDetails?.type === PushAPI.payloads.SPACE_REQUEST_TYPE.ESTABLISH_MESH ) { - spacesObjectRef.current?.acceptRequest({ - signalData, - senderAddress: recipientAddress, - recipientAddress: senderAddress, - chatId: chatId, - }); + acceptSpaceRequest(receivedSpaceMetaData); } } if (status === PushAPI.VideoCallStatus.RECEIVED) { - spacesObjectRef.current?.connect({ - signalData, - peerAddress: senderAddress, - }); + connectSpaceRequest(receivedSpaceMetaData); } if (status === PushAPI.VideoCallStatus.DISCONNECTED) { if ( @@ -95,7 +92,7 @@ export const useSpaceNotificationSocket = ({ } } }); - }, [notificationSocket]); + }, [acceptSpaceRequest, connectSpaceRequest, notificationSocket]); const removeSocketEvents = useCallback(() => { notificationSocket?.off(EVENTS.CONNECT); @@ -128,7 +125,7 @@ export const useSpaceNotificationSocket = ({ } const main = async () => { const connectionObject = createSocketConnection({ - user: account, + user: pCAIP10ToWallet(account), env, socketType: NOTIFICATION_SOCKET_TYPE, socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, diff --git a/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts b/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts index b9c67c0a7..4871b917b 100644 --- a/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts +++ b/packages/uiweb/src/lib/hooks/space/useSpaceRequests.ts @@ -4,7 +4,7 @@ import { useEffect, useState } from 'react'; import * as PushAPI from '@pushprotocol/restapi'; export const useSpaceRequests = (account?: string) => { - const LIMIT = 2; + const LIMIT = 10; const { spaceRequests, setSpaceRequests, env } = useSpaceData(); const [loading, setLoading] = useState(false); @@ -17,8 +17,8 @@ export const useSpaceRequests = (account?: string) => { account: account, page: spaceRequests.currentPage, limit: LIMIT, + toDecrypt: false, env, - }); const newSpaceRequests = res; diff --git a/packages/uiweb/src/lib/icons/CalendarPurple.tsx b/packages/uiweb/src/lib/icons/CalendarPurple.tsx index a3e4f8524..20c528ee1 100644 --- a/packages/uiweb/src/lib/icons/CalendarPurple.tsx +++ b/packages/uiweb/src/lib/icons/CalendarPurple.tsx @@ -1,6 +1,6 @@ import React from 'react'; -export const CalendarPurple = ({ height, width }: { height?: string, width?: string }) => { +export const CalendarPurple = ({ height, width, color }: { height?: string, width?: string, color?: string }) => { return ( < svg width={width || "15"} @@ -11,14 +11,14 @@ export const CalendarPurple = ({ height, width }: { height?: string, width?: str > { + return ( + + + + + +); +} diff --git a/packages/uiweb/src/lib/icons/SpaceEnded.svg b/packages/uiweb/src/lib/icons/SpaceEnded.svg new file mode 100644 index 000000000..0a2f000c1 --- /dev/null +++ b/packages/uiweb/src/lib/icons/SpaceEnded.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/SpacesLogo.tsx b/packages/uiweb/src/lib/icons/SpacesLogo.tsx new file mode 100644 index 000000000..ce6aabf70 --- /dev/null +++ b/packages/uiweb/src/lib/icons/SpacesLogo.tsx @@ -0,0 +1,32 @@ +import React from 'react'; + +export const SpacesLogo = ({ height, width, color }: { height?: string, width?: string, color?: string }) => { + return ( + + + + + + + + + + + + + + + ); +}; diff --git a/packages/uiweb/src/lib/icons/lensterVector.svg b/packages/uiweb/src/lib/icons/lensterVector.svg new file mode 100644 index 000000000..5aa27269c --- /dev/null +++ b/packages/uiweb/src/lib/icons/lensterVector.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/scheduled.tsx b/packages/uiweb/src/lib/icons/scheduled.tsx new file mode 100644 index 000000000..120dc233e --- /dev/null +++ b/packages/uiweb/src/lib/icons/scheduled.tsx @@ -0,0 +1,40 @@ +export const Scheduled = ({ color }: { color?: string }) => { + return ( + + + + + + + ); +}; diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index 0e9621d0f..b5896656b 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -1683,6 +1683,11 @@ minimalistic-crypto-utils@^1.0.1: resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" integrity sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg== +moment@^2.29.4: + version "2.29.4" + resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.4.tgz#3dbe052889fe7c1b2ed966fcb3a77328964ef108" + integrity sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w== + ms@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" From c07c3fab76a095998b1eac830c941116ad1e9b4f Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Fri, 21 Jul 2023 12:34:33 +0530 Subject: [PATCH 165/298] fix: signer compatibility with viem and ethers (#567) * fix: signer compatibility with viem and ethers * fix: revert space changes --- package.json | 3 +- .../sdk-backend-node/src/chat/chat.ts | 121 +++++++++++------- .../src/notification/index.ts | 65 +++++++--- .../restapi/src/lib/channels/subscribe.ts | 17 +-- .../restapi/src/lib/channels/unsubscribe.ts | 16 +-- .../restapi/src/lib/chat/helpers/crypto.ts | 8 +- .../restapi/src/lib/chat/helpers/wallet.ts | 4 +- packages/restapi/src/lib/helpers/crypto.ts | 4 +- packages/restapi/src/lib/helpers/index.ts | 1 + packages/restapi/src/lib/helpers/signer.ts | 59 +++++++++ packages/restapi/src/lib/payloads/helpers.ts | 4 +- packages/restapi/src/lib/types/index.ts | 34 ++++- .../ChatAndNotificationWidget.tsx | 2 +- packages/uiweb/src/lib/types/index.ts | 35 ++++- yarn.lock | 79 ++++++++++++ 15 files changed, 345 insertions(+), 107 deletions(-) create mode 100644 packages/restapi/src/lib/helpers/signer.ts diff --git a/package.json b/package.json index 3b2dda4ec..49514fb87 100644 --- a/package.json +++ b/package.json @@ -51,7 +51,8 @@ "tslib": "^2.3.0", "unique-names-generator": "^4.7.1", "uuid": "^9.0.0", - "video-stream-merger": "^4.0.1" + "video-stream-merger": "^4.0.1", + "viem": "^1.3.0" }, "devDependencies": { "@commitlint/cli": "^17.0.0", diff --git a/packages/examples/sdk-backend-node/src/chat/chat.ts b/packages/examples/sdk-backend-node/src/chat/chat.ts index 91cc898e1..31b4bb6d8 100644 --- a/packages/examples/sdk-backend-node/src/chat/chat.ts +++ b/packages/examples/sdk-backend-node/src/chat/chat.ts @@ -9,18 +9,49 @@ import { } from 'unique-names-generator'; import { ENV } from '../types'; import { config } from '../config'; +import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; +import { createWalletClient, http } from 'viem'; +import { goerli } from 'viem/chains'; // CONFIGS const { env, showAPIResponse } = config; +/***************** SAMPLE SIGNER GENERATION *********************/ +/** + * USING VIEM + */ // Random Wallet Signers -const signer = ethers.Wallet.createRandom(); -const signerSecondAccount = ethers.Wallet.createRandom(); - +const signer = createWalletClient({ + account: privateKeyToAccount(generatePrivateKey()), + chain: goerli, + transport: http(), +}); +const signerAddress = signer.account.address; +const secondSigner = createWalletClient({ + account: privateKeyToAccount(generatePrivateKey()), + chain: goerli, + transport: http(), +}); +const secondSignerAddress = secondSigner.account.address; // Dummy Wallet Addresses -const randomWallet1 = ethers.Wallet.createRandom().address; -const randomWallet2 = ethers.Wallet.createRandom().address; -const randomWallet3 = ethers.Wallet.createRandom().address; +const randomWallet1 = privateKeyToAccount(generatePrivateKey()).address; +const randomWallet2 = privateKeyToAccount(generatePrivateKey()).address; +const randomWallet3 = privateKeyToAccount(generatePrivateKey()).address; + +/** + * USING ETHERS + */ +// // Random Wallet Signers +// const signer = ethers.Wallet.createRandom(); +// const signerAddress = signer.address; +// const secondSigner = ethers.Wallet.createRandom(); +// const secondSignerAddress = secondSigner.address; +// // Dummy Wallet Addresses +// const randomWallet1 = ethers.Wallet.createRandom().address; +// const randomWallet2 = ethers.Wallet.createRandom().address; +// const randomWallet3 = ethers.Wallet.createRandom().address; + +/************************************************************* */ // Group Chat Data const groupName = uniqueNamesGenerator({ @@ -101,7 +132,7 @@ async function PushAPI_user_create(silent = !showAPIResponse) { }); const user_2 = await PushAPI.user.create({ - signer: signerSecondAccount, + signer: secondSigner, env: env as ENV, }); @@ -117,7 +148,7 @@ async function PushAPI_user_create(silent = !showAPIResponse) { // Push Chat - PushAPI.user.get async function PushAPI_user_get(silent = !showAPIResponse) { const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -132,7 +163,7 @@ async function PushAPI_user_get(silent = !showAPIResponse) { async function PushAPI_chat_decryptPGPKey(silent = !showAPIResponse) { // get user and derive encrypted PGP key const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -153,7 +184,7 @@ async function PushAPI_chat_decryptPGPKey(silent = !showAPIResponse) { async function PushAPI_chat_chats(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -166,7 +197,7 @@ async function PushAPI_chat_chats(silent = !showAPIResponse) { // Actual api const response = await PushAPI.chat.chats({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, toDecrypt: true, pgpPrivateKey: pgpDecrpyptedPvtKey, env: env as ENV, @@ -182,7 +213,7 @@ async function PushAPI_chat_chats(silent = !showAPIResponse) { async function PushAPI_chat_requests(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -195,7 +226,7 @@ async function PushAPI_chat_requests(silent = !showAPIResponse) { // Actual api const response = await PushAPI.chat.requests({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, toDecrypt: true, pgpPrivateKey: pgpDecrpyptedPvtKey, env: env as ENV, @@ -211,8 +242,8 @@ async function PushAPI_chat_requests(silent = !showAPIResponse) { async function PushAPI_chat_conversationHash(silent = !showAPIResponse) { // conversation hash are also called link inside chat messages const conversationHash = await PushAPI.chat.conversationHash({ - account: `eip155:${signer.address}`, - conversationId: `eip155:${signerSecondAccount.address}`, // 2nd address + account: `eip155:${signerAddress}`, + conversationId: `eip155:${secondSignerAddress}`, // 2nd address env: env as ENV, }); @@ -226,7 +257,7 @@ async function PushAPI_chat_conversationHash(silent = !showAPIResponse) { async function PushAPI_chat_latest(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -240,15 +271,15 @@ async function PushAPI_chat_latest(silent = !showAPIResponse) { // Fetch conversation hash // conversation hash are also called link inside chat messages const conversationHash = await PushAPI.chat.conversationHash({ - account: `eip155:${signer.address}`, - conversationId: `eip155:${signerSecondAccount.address}`, // 2nd address + account: `eip155:${signerAddress}`, + conversationId: `eip155:${secondSignerAddress}`, // 2nd address env: env as ENV, }); // Actual API const response = await PushAPI.chat.latest({ threadhash: conversationHash.threadHash, // get conversation hash from conversationHash function and send the response threadhash here - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, toDecrypt: true, pgpPrivateKey: pgpDecrpyptedPvtKey, env: env as ENV, @@ -264,7 +295,7 @@ async function PushAPI_chat_latest(silent = !showAPIResponse) { async function PushAPI_chat_history(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -278,15 +309,15 @@ async function PushAPI_chat_history(silent = !showAPIResponse) { // Fetch conversation hash // conversation hash are also called link inside chat messages const conversationHash = await PushAPI.chat.conversationHash({ - account: `eip155:${signer.address}`, - conversationId: `eip155:${signerSecondAccount.address}`, // 2nd address + account: `eip155:${signerAddress}`, + conversationId: `eip155:${secondSignerAddress}`, // 2nd address env: env as ENV, }); // Actual API const response = await PushAPI.chat.history({ threadhash: conversationHash.threadHash, // get conversation hash from conversationHash function and send the response threadhash here - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, limit: 5, toDecrypt: true, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -304,7 +335,7 @@ async function PushAPI_chat_history(silent = !showAPIResponse) { async function PushAPI_chat_send(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -321,7 +352,7 @@ async function PushAPI_chat_send(silent = !showAPIResponse) { content: "Gm gm! It's me... Mario", }, messageType: 'Text', // can be "Text" | "Image" | "File" | "GIF" - receiverAddress: signerSecondAccount.address, + receiverAddress: secondSignerAddress, signer: signer, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -339,7 +370,7 @@ async function PushAPI_chat_send(silent = !showAPIResponse) { async function PushAPI_chat_approve(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signerSecondAccount.address}`, + account: `eip155:${secondSignerAddress}`, env: env as ENV, }); @@ -347,15 +378,15 @@ async function PushAPI_chat_approve(silent = !showAPIResponse) { const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, - signer: signerSecondAccount, + signer: secondSigner, }); // Actual api const approve = await PushAPI.chat.approve({ status: 'Approved', - senderAddress: signer.address, // receiver's address or chatId of a group + senderAddress: signerAddress, // receiver's address or chatId of a group - signer: signerSecondAccount, + signer: secondSigner, pgpPrivateKey: pgpDecrpyptedPvtKey, env: env as ENV, }); @@ -372,7 +403,7 @@ async function PushAPI_chat_createGroup( ): Promise { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -412,7 +443,7 @@ async function PushAPI_chat_updateGroup( ) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -435,10 +466,10 @@ async function PushAPI_chat_updateGroup( `eip155:${randomWallet1}`, `eip155:${randomWallet2}`, `eip155:${randomWallet3}`, - `eip155:${signer.address}`, + `eip155:${signerAddress}`, ], groupImage, - admins: [`eip155:${signer.address}`], // takes signer as admin automatically, add more if you want to + admins: [`eip155:${signerAddress}`], // takes signer as admin automatically, add more if you want to signer: signer, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -484,7 +515,7 @@ async function PushAPI_chat_getGroup( async function PushAPI_chat_decryptConversation(silent = !showAPIResponse) { // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, env: env as ENV, }); @@ -498,15 +529,15 @@ async function PushAPI_chat_decryptConversation(silent = !showAPIResponse) { // Fetch conversation hash // conversation hash are also called link inside chat messages const conversationHash = await PushAPI.chat.conversationHash({ - account: `eip155:${signer.address}`, - conversationId: `eip155:${signerSecondAccount.address}`, // 2nd address + account: `eip155:${signerAddress}`, + conversationId: `eip155:${secondSignerAddress}`, // 2nd address env: env as ENV, }); // Chat History const encryptedChats = await PushAPI.chat.history({ threadhash: conversationHash.threadHash, // get conversation hash from conversationHash function and send the response threadhash here - account: `eip155:${signer.address}`, + account: `eip155:${signerAddress}`, limit: 5, toDecrypt: false, pgpPrivateKey: pgpDecrpyptedPvtKey, @@ -530,7 +561,7 @@ async function PushAPI_chat_decryptConversation(silent = !showAPIResponse) { // Push Chat - Socket Connection async function PushChatSDKSocket(silent = !showAPIResponse) { const pushSDKSocket = createSocketConnection({ - user: `eip155:${signer.address}`, + user: `eip155:${signerAddress}`, socketType: 'chat', socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, env: env as ENV, @@ -546,7 +577,7 @@ async function PushChatSDKSocket(silent = !showAPIResponse) { // send a chat from other wallet to this one to see the result // Fetch user const user = await PushAPI.user.get({ - account: `eip155:${signerSecondAccount.address}`, + account: `eip155:${secondSignerAddress}`, env: env as ENV, }); @@ -554,16 +585,16 @@ async function PushChatSDKSocket(silent = !showAPIResponse) { const pgpDecrpyptedPvtKey = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, - signer: signerSecondAccount, + signer: secondSigner, }); // Actual api const response = await PushAPI.chat.send({ messageContent: "Gm gm! It's me... Mario", messageType: 'Text', - receiverAddress: `eip155:${signer.address}`, + receiverAddress: `eip155:${signerAddress}`, - signer: signerSecondAccount, + signer: secondSigner, pgpPrivateKey: pgpDecrpyptedPvtKey, env: env as ENV, }); @@ -596,7 +627,7 @@ async function PushAPI_chat_video_call_notification( ) { // Fetch user const user = await PushAPI.user.get({ - account: signer.address, + account: signerAddress, env: env as ENV, }); @@ -628,8 +659,8 @@ async function PushAPI_chat_video_call_notification( domain: 'push.org', }, }, - recipients: signerSecondAccount.address, // recipient address - channel: signer.address, // your channel address + recipients: secondSignerAddress, // recipient address + channel: signerAddress, // your channel address env: env as ENV, }); diff --git a/packages/examples/sdk-backend-node/src/notification/index.ts b/packages/examples/sdk-backend-node/src/notification/index.ts index 1df6f2a79..259ec1dd9 100644 --- a/packages/examples/sdk-backend-node/src/notification/index.ts +++ b/packages/examples/sdk-backend-node/src/notification/index.ts @@ -3,6 +3,10 @@ import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; import { ethers } from 'ethers'; import { config } from '../config'; +import { createWalletClient, http } from 'viem'; +import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; +import { goerli } from 'viem/chains'; + enum ENV { PROD = 'prod', STAGING = 'staging', @@ -18,12 +22,38 @@ const { env, showAPIResponse } = config; // If you own a channel, you can use your channel address as well const channelPrivateKey: string = process.env.WALLET_PRIVATE_KEY!; -const signerChannel = new ethers.Wallet(`0x${channelPrivateKey}`); -const channelAddress = signerChannel.address; -// Some Random Accounts -const signer = ethers.Wallet.createRandom(); -const signerSecondAccount = ethers.Wallet.createRandom(); +/***************** SAMPLE SIGNER GENERATION *********************/ +/** + * USING VIEM + */ +const signerChannel = createWalletClient({ + account: privateKeyToAccount(`0x${channelPrivateKey}`), + chain: goerli, + transport: http(), +}); +const channelAddress = signerChannel.account.address; +// Random Wallet Signers +const signer = createWalletClient({ + account: privateKeyToAccount(generatePrivateKey()), + chain: goerli, + transport: http(), +}); +const signerAddress = signer.account.address; +// Dummy Wallet Addresses +const randomWallet1 = privateKeyToAccount(generatePrivateKey()).address; + +/** + * USING ETHERS + */ +// const signerChannel = new ethers.Wallet(`0x${channelPrivateKey}`); +// const channelAddress = signerChannel.address; +// // Random Wallet Signers +// const signer = ethers.Wallet.createRandom(); +// const signerAddress = signer.address; +// // Dummy Wallet Addresses +// const randomWallet1 = ethers.Wallet.createRandom().address; +/************************************************************* */ // Push Notification - Run Notifications Use cases export const runNotificaitonsUseCases = async (): Promise => { @@ -82,7 +112,7 @@ export const runNotificaitonsUseCases = async (): Promise => { // Push Notification - PushAPI.user.getFeeds async function PushAPI_user_getFeeds(silent = !showAPIResponse) { const notifications = await PushAPI.user.getFeeds({ - user: `eip155:5:${signer.address}`, // user address in CAIP + user: `eip155:5:${signerAddress}`, // user address in CAIP env: env as ENV, }); @@ -95,7 +125,7 @@ async function PushAPI_user_getFeeds(silent = !showAPIResponse) { // Push Notification - PushAPI.user.getFeeds - Spam async function PushAPI_user_getFeeds__spam(silent = !showAPIResponse) { const notifications = await PushAPI.user.getFeeds({ - user: `eip155:5:${signer.address}`, // user address in CAIP + user: `eip155:5:${signerAddress}`, // user address in CAIP spam: true, env: env as ENV, }); @@ -109,7 +139,7 @@ async function PushAPI_user_getFeeds__spam(silent = !showAPIResponse) { // Push Notification - PushAPI.user.getSubscriptions async function PushAPI_user_getSubscriptions(silent = !showAPIResponse) { const subscriptions = await PushAPI.user.getSubscriptions({ - user: `eip155:5:${signer.address}`, // user address in CAIP + user: `eip155:5:${signerAddress}`, // user address in CAIP env: env as ENV, }); @@ -152,7 +182,7 @@ async function PushAPI_channels_subscribe(silent = !showAPIResponse) { const response = await PushAPI.channels.subscribe({ signer: signer, channelAddress: `eip155:5:${channelAddress}`, // channel address in CAIP - userAddress: `eip155:5:${signer.address}`, // user address in CAIP + userAddress: `eip155:5:${signerAddress}`, // user address in CAIP onSuccess: () => { console.log('opt in success'); }, @@ -173,7 +203,7 @@ async function PushAPI_channels_unsubscribe(silent = !showAPIResponse) { const response = await PushAPI.channels.unsubscribe({ signer: signer, channelAddress: `eip155:5:${channelAddress}`, // channel address in CAIP - userAddress: `eip155:5:${signer.address}`, // user address in CAIP + userAddress: `eip155:5:${signerAddress}`, // user address in CAIP onSuccess: () => { console.log('opt out success'); }, @@ -209,8 +239,8 @@ async function PushAPI_payloads_sendNotification__direct_payload_single_recipien cta: '', img: '', }, - recipients: `eip155:5:${signer.address}`, // recipient address - channel: `eip155:5:${signerChannel.address}`, // your channel address + recipients: `eip155:5:${signerAddress}`, // recipient address + channel: `eip155:5:${channelAddress}`, // your channel address env: env as ENV, }); @@ -239,11 +269,8 @@ async function PushAPI_payloads_sendNotification__direct_payload_group_of_recipi cta: '', img: '', }, - recipients: [ - `eip155:5:${signer.address}`, - `eip155:5:${signerSecondAccount.address}`, - ], // recipient addresses - channel: `eip155:5:${signerChannel.address}`, // your channel address + recipients: [`eip155:5:${signerAddress}`, `eip155:5:${randomWallet1}`], // recipient addresses + channel: `eip155:5:${channelAddress}`, // your channel address env: env as ENV, }); @@ -272,7 +299,7 @@ async function PushAPI_payloads_sendNotification__direct_payload_all_recipients_ cta: '', img: '', }, - channel: `eip155:5:${signerChannel.address}`, // your channel address + channel: `eip155:5:${channelAddress}`, // your channel address env: env as ENV, }); @@ -298,7 +325,7 @@ async function PushAPI_channels_getSubscribers(silent = !showAPIResponse) { // Push Notification - Socket Connection async function PushSDKSocket(silent = !showAPIResponse) { const pushSDKSocket = createSocketConnection({ - user: `eip155:5:${signer.address}`, // CAIP, see below + user: `eip155:5:${signerAddress}`, // CAIP, see below socketOptions: { autoConnect: false }, env: env as ENV, }); diff --git a/packages/restapi/src/lib/channels/subscribe.ts b/packages/restapi/src/lib/channels/subscribe.ts index 4db84c914..9bfc4dde9 100644 --- a/packages/restapi/src/lib/channels/subscribe.ts +++ b/packages/restapi/src/lib/channels/subscribe.ts @@ -3,6 +3,7 @@ import { getCAIPAddress, getConfig, getCAIPDetails, + signTypedData } from '../helpers'; import { getTypeInformation, @@ -10,15 +11,7 @@ import { getSubscriptionMessage } from './signature.helpers'; import Constants, {ENV} from '../constants'; - -type SignerType = { - _signTypedData: ( - domain: any, - types: any, - value: any - ) => Promise -} - +import { SignerType } from "../types"; export type SubscribeOptionsType = { signer: SignerType; channelAddress: string; @@ -76,11 +69,7 @@ export const subscribe = async ( ); // sign a message using EIP712 - const signature = await signer._signTypedData( - domainInformation, - typeInformation, - messageInformation - ); + const signature = await signTypedData(signer, domainInformation, typeInformation, messageInformation); const verificationProof = signature; // might change diff --git a/packages/restapi/src/lib/channels/unsubscribe.ts b/packages/restapi/src/lib/channels/unsubscribe.ts index 19ec57b36..839dd83b7 100644 --- a/packages/restapi/src/lib/channels/unsubscribe.ts +++ b/packages/restapi/src/lib/channels/unsubscribe.ts @@ -3,6 +3,7 @@ import { getCAIPAddress, getConfig, getCAIPDetails, + signTypedData } from '../helpers'; import { getTypeInformation, @@ -10,14 +11,7 @@ import { getSubscriptionMessage } from './signature.helpers'; import Constants, {ENV} from '../constants'; - -type SignerType = { - _signTypedData: ( - domain: any, - types: any, - value: any - ) => Promise -} +import { SignerType } from "../types"; export type UnSubscribeOptionsType = { signer: SignerType; @@ -76,11 +70,7 @@ export const unsubscribe = async ( ); // sign a message using EIP712 - const signature = await signer._signTypedData( - domainInformation, - typeInformation, - messageInformation - ); + const signature = await signTypedData(signer, domainInformation, typeInformation, messageInformation); const verificationProof = signature; // might change diff --git a/packages/restapi/src/lib/chat/helpers/crypto.ts b/packages/restapi/src/lib/chat/helpers/crypto.ts index 86e64b590..46e8dcba3 100644 --- a/packages/restapi/src/lib/chat/helpers/crypto.ts +++ b/packages/restapi/src/lib/chat/helpers/crypto.ts @@ -16,6 +16,8 @@ import { decryptWithWalletRPCMethod, isValidETHAddress, walletToPCAIP10, + signTypedData, + signMessage, } from '../../helpers'; import { get as getUser } from '../../user'; import { createUserService } from './service'; @@ -289,7 +291,8 @@ export const getEip191Signature = async ( } const _signer = wallet?.signer; // EIP191 signature - const signature = await _signer?.signMessage(message); + + const signature = await signMessage(_signer, message); const sigType = version === 'v1' ? 'eip191' : 'eip191v2'; return { verificationProof: `${sigType}:${signature}` }; }; @@ -316,7 +319,8 @@ export const getEip712Signature = async ( const domain = getDomainInformation(chainId); // sign a message using EIP712 - const signedMessage = await _signer?._signTypedData!( + const signedMessage = await signTypedData( + _signer, isDomainEmpty ? {} : domain, typeInformation, { data: hash } diff --git a/packages/restapi/src/lib/chat/helpers/wallet.ts b/packages/restapi/src/lib/chat/helpers/wallet.ts index 0633efdd3..1481e62bf 100644 --- a/packages/restapi/src/lib/chat/helpers/wallet.ts +++ b/packages/restapi/src/lib/chat/helpers/wallet.ts @@ -1,4 +1,4 @@ -import { pCAIP10ToWallet } from "../../helpers"; +import { pCAIP10ToWallet, getAddress } from "../../helpers"; import { SignerType, walletType } from "../../types"; export const getWallet = (options: walletType): { @@ -22,5 +22,5 @@ export const getAccountAddress = async (options: walletType): Promise => signer } = options || {}; - return account || (await signer?.getAddress()) || '' + return account || (await getAddress(signer as SignerType)) || '' } \ No newline at end of file diff --git a/packages/restapi/src/lib/helpers/crypto.ts b/packages/restapi/src/lib/helpers/crypto.ts index b03e10ac6..d3af27c08 100644 --- a/packages/restapi/src/lib/helpers/crypto.ts +++ b/packages/restapi/src/lib/helpers/crypto.ts @@ -32,6 +32,7 @@ import { import { verifyProfileSignature } from '../chat/helpers/signature'; import { upgrade } from '../user/upgradeUser'; import PROGRESSHOOK from '../progressHook'; +import { getAddress } from './signer'; const KDFSaltSize = 32; // bytes const AESGCMNonceSize = 12; // property iv @@ -51,7 +52,8 @@ if (typeof window !== 'undefined' && window.crypto) { /** DEPRECATED */ export const getPublicKey = async (options: walletType): Promise => { const { account, signer } = options || {}; - const address: string = account || (await signer?.getAddress()) || ''; + const address: string = + account || (await getAddress(signer as SignerType)) || ''; const metamaskProvider = new ethers.providers.Web3Provider( (window as any).ethereum ); diff --git a/packages/restapi/src/lib/helpers/index.ts b/packages/restapi/src/lib/helpers/index.ts index 718ba6cd2..182450d34 100644 --- a/packages/restapi/src/lib/helpers/index.ts +++ b/packages/restapi/src/lib/helpers/index.ts @@ -2,3 +2,4 @@ export * from './config'; export * from './address'; export * from './api'; export * from './crypto'; +export * from './signer'; diff --git a/packages/restapi/src/lib/helpers/signer.ts b/packages/restapi/src/lib/helpers/signer.ts new file mode 100644 index 000000000..89cbe4fbf --- /dev/null +++ b/packages/restapi/src/lib/helpers/signer.ts @@ -0,0 +1,59 @@ +import { SignerType } from '../types'; + +export const signMessage = async ( + signer: SignerType, + message: string +): Promise => { + // Check the signer type using type guards + if ('signMessage' in signer) { + // If the signer has a signMessage function with the ethersV5SignerType signature + if ('_signTypedData' in signer) { + // It's ethersV5SignerType, use its signMessage function + const signature = await signer.signMessage(message); + return signature; + } else { + // It's viemSignerType, use its signMessage function + const signature = await signer.signMessage({ + message, + account: signer.account, + }); + return signature; + } + } else { + throw new Error('Invalid signer type provided.'); + } +}; + +export const signTypedData = async ( + signer: SignerType, + domain: any, + types: any, + value: any +): Promise => { + // Check the signer type using type guards + if ('_signTypedData' in signer) { + // It's ethersV5SignerType, use its functions + const signature = await signer._signTypedData(domain, types, value); + return signature; + } else if ('signTypedData' in signer) { + // It's viemSignerType, use its functions + const signature = await signer.signTypedData({ + account: signer.account, + domain, + types, + primaryType: 'Data', + message: value, + }); + return signature; + } else { + throw new Error('Invalid signer type provided.'); + } +}; + +export const getAddress = async (signer: SignerType): Promise => { + if ('getAddress' in signer) { + return await signer.getAddress(); + } else { + return signer.account['address'] ?? ''; + } +}; diff --git a/packages/restapi/src/lib/payloads/helpers.ts b/packages/restapi/src/lib/payloads/helpers.ts index 500a53cd2..6022c9996 100644 --- a/packages/restapi/src/lib/payloads/helpers.ts +++ b/packages/restapi/src/lib/payloads/helpers.ts @@ -1,6 +1,6 @@ import { v4 as uuidv4 } from 'uuid'; import { ENV } from '../constants'; -import { getCAIPAddress } from '../helpers'; +import { getCAIPAddress, signTypedData } from '../helpers'; import * as CryptoJS from 'crypto-js'; import { @@ -252,7 +252,7 @@ export async function getVerificationProof({ chainId: chainId, verifyingContract: verifyingContract, }; - const signature = await signer._signTypedData(domain, type, message); + const signature = await signTypedData(signer, domain, type, message); verificationProof = `eip712v2:${signature}::uid::${uuid}`; break; } diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index e99f6d158..596af742b 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -1,4 +1,4 @@ -import { ethers } from 'ethers'; +import { Bytes, TypedDataDomain, TypedDataField, providers } from 'ethers'; import { ADDITIONAL_META_TYPE, IDENTITY_TYPE, @@ -469,10 +469,38 @@ export interface UserInfo { isAdmin: boolean; } -export type SignerType = ethers.Signer & { - _signTypedData?: (domain: any, types: any, value: any) => Promise; +type ethersV5SignerType = { + _signTypedData: ( + domain: TypedDataDomain, + types: Record>, + value: Record + ) => Promise; + getChainId: () => Promise; + getAddress: () => Promise; + signMessage: (message: Bytes | string) => Promise; privateKey?: string; + provider?: providers.Provider; }; +type viemSignerType = { + signTypedData: (args: { + account: any; + domain: any; + types: any; + primaryType: any; + message: any; + }) => Promise<`0x${string}`>; + getChainId: () => Promise; + signMessage: (args: { + message: any; + account: any; + [key: string]: any; + }) => Promise<`0x${string}`>; + account: { [key: string]: any }; + privateKey?: string; + provider?: providers.Provider; +}; + +export type SignerType = ethersV5SignerType | viemSignerType; export type EnvOptionsType = { env?: ENV; diff --git a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotificationWidget.tsx b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotificationWidget.tsx index 37e3dc39d..4d7ace1be 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotificationWidget.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotificationWidget.tsx @@ -17,7 +17,7 @@ export type ChatAndNotificationProps = { activeTab?: PushTabs, activeChat?: string, onClose?: () => void, - signer?: WithRequiredProperty + signer?: SignerType env?: Env; }; diff --git a/packages/uiweb/src/lib/types/index.ts b/packages/uiweb/src/lib/types/index.ts index 6f2fd1781..5a48d32f5 100644 --- a/packages/uiweb/src/lib/types/index.ts +++ b/packages/uiweb/src/lib/types/index.ts @@ -1,8 +1,7 @@ import type { ReactElement } from 'react'; -import React from 'react'; import type { ENV } from '../config'; -import type { ethers } from 'ethers'; import type { ParsedResponseType, IFeeds, } from '@pushprotocol/restapi'; +import { Bytes, TypedDataDomain, TypedDataField, providers } from 'ethers'; export interface IMessageIPFS { fromCAIP10: string; @@ -38,10 +37,38 @@ export interface ITheme { moduleColor?: string; } -export type SignerType = ethers.Signer & { - _signTypedData?: (domain: any, types: any, value: any) => Promise; +type ethersV5SignerType = { + _signTypedData: ( + domain: TypedDataDomain, + types: Record>, + value: Record + ) => Promise; + getChainId: () => Promise; + getAddress: () => Promise; + signMessage: (message: Bytes | string) => Promise; privateKey?: string; + provider?: providers.Provider; }; +type viemSignerType = { + signTypedData: (args: { + account: any; + domain: any; + types: any; + primaryType: any; + message: any; + }) => Promise<`0x${string}`>; + getChainId: () => Promise; + signMessage: (args: { + message: any; + account: any; + [key: string]: any; + }) => Promise<`0x${string}`>; + account: { [key: string]: any }; + privateKey?: string; + provider?: providers.Provider; +}; + +export type SignerType = ethersV5SignerType | viemSignerType; export type ParsedNotificationType = ParsedResponseType & { channel:string; diff --git a/yarn.lock b/yarn.lock index 3be1ac607..bc45eb097 100644 --- a/yarn.lock +++ b/yarn.lock @@ -2,6 +2,11 @@ # yarn lockfile v1 +"@adraffy/ens-normalize@1.9.0": + version "1.9.0" + resolved "https://registry.yarnpkg.com/@adraffy/ens-normalize/-/ens-normalize-1.9.0.tgz#223572538f6bea336750039bb43a4016dcc8182d" + integrity sha512-iowxq3U30sghZotgl4s/oJRci6WPBfNO5YYgk2cIOMCHr3LeGPcsZjCEr+33Q4N+oV3OABDAtA+pyvWjbvBifQ== + "@ampproject/remapping@^2.1.0": version "2.2.0" resolved "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.0.tgz" @@ -2319,6 +2324,23 @@ dependencies: events "3.3.0" +"@noble/curves@1.0.0", "@noble/curves@~1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.0.0.tgz#e40be8c7daf088aaf291887cbc73f43464a92932" + integrity sha512-2upgEu0iLiDVDZkNLeFV2+ht0BAVgQnEmCk6JsOch9Rp8xfkMCbvbAZlA2pBHQc73dbl+vFOXfqkf4uemdn0bw== + dependencies: + "@noble/hashes" "1.3.0" + +"@noble/hashes@1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.0.tgz#085fd70f6d7d9d109671090ccae1d3bec62554a1" + integrity sha512-ilHEACi9DwqJB0pw7kv+Apvh50jiiSyR/cQ3y4W7lOR5mhvn/50FLUfsnfJz0BDZtl/RR16kXvptiv6q1msYZg== + +"@noble/hashes@~1.3.0": + version "1.3.1" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.1.tgz#8831ef002114670c603c458ab8b11328406953a9" + integrity sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA== + "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz" @@ -3017,6 +3039,28 @@ estree-walker "^2.0.1" picomatch "^2.2.2" +"@scure/base@~1.1.0": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.1.tgz#ebb651ee52ff84f420097055f4bf46cfba403938" + integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== + +"@scure/bip32@1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@scure/bip32/-/bip32-1.3.0.tgz#6c8d980ef3f290987736acd0ee2e0f0d50068d87" + integrity sha512-bcKpo1oj54hGholplGLpqPHRbIsnbixFtc06nwuNM5/dwSXOq/AAYoIBRsBmnZJSdfeNW5rnff7NTAz3ZCqR9Q== + dependencies: + "@noble/curves" "~1.0.0" + "@noble/hashes" "~1.3.0" + "@scure/base" "~1.1.0" + +"@scure/bip39@1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@scure/bip39/-/bip39-1.2.0.tgz#a207e2ef96de354de7d0002292ba1503538fc77b" + integrity sha512-SX/uKq52cuxm4YFXWFaVByaSHJh2w3BnokVSeUJVCv6K7WulT9u2BuNRBhuFl8vAuYnzx9bEu9WgpcNYTrYieg== + dependencies: + "@noble/hashes" "~1.3.0" + "@scure/base" "~1.1.0" + "@segment/loosely-validate-event@^2.0.0": version "2.0.0" resolved "https://registry.npmjs.org/@segment/loosely-validate-event/-/loosely-validate-event-2.0.0.tgz" @@ -3922,6 +3966,11 @@ "@urql/core" ">=2.3.1" wonka "^4.0.14" +"@wagmi/chains@1.6.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@wagmi/chains/-/chains-1.6.0.tgz#eb992ad28dbaaab729b5bcab3e5b461e8a035656" + integrity sha512-5FRlVxse5P4ZaHG3GTvxwVANSmYJas1eQrTBHhjxVtqXoorm0aLmCHbhmN8Xo1yu09PaWKlleEvfE98yH4AgIw== + "@web3-react/abstract-connector@^6.0.7": version "6.0.7" resolved "https://registry.npmjs.org/@web3-react/abstract-connector/-/abstract-connector-6.0.7.tgz" @@ -4117,6 +4166,11 @@ abab@^2.0.3, abab@^2.0.5: resolved "https://registry.npmjs.org/abab/-/abab-2.0.6.tgz" integrity sha512-j2afSsaIENvHZN2B8GOpF566vZ5WVk5opAiMTvWgaQT8DkbOqsTfvNAvHoRGU2zzP8cPoqys+xHTRDWW8L+/BA== +abitype@0.8.11: + version "0.8.11" + resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.8.11.tgz#66e1cf2cbf46f48d0e57132d7c1c392447536cc1" + integrity sha512-bM4v2dKvX08sZ9IU38IN5BKmN+ZkOSd2oI4a9f0ejHYZQYV6cDr7j+d95ga0z2XHG36Y4jzoG5Z7qDqxp7fi/A== + abort-controller@^3.0.0: version "3.0.0" resolved "https://registry.npmjs.org/abort-controller/-/abort-controller-3.0.0.tgz" @@ -9255,6 +9309,11 @@ isobject@^3.0.0, isobject@^3.0.1: resolved "https://registry.npmjs.org/isobject/-/isobject-3.0.1.tgz" integrity sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg== +isomorphic-ws@5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-5.0.0.tgz#e5529148912ecb9b451b46ed44d53dae1ce04bbf" + integrity sha512-muId7Zzn9ywDsyXgTIafTry2sV3nySZeUDe6YedVd1Hvuuep5AsIlqK+XefWpYTyJG5e503F2xIuT2lcU6rCSw== + istanbul-lib-coverage@^3.0.0, istanbul-lib-coverage@^3.2.0: version "3.2.0" resolved "https://registry.npmjs.org/istanbul-lib-coverage/-/istanbul-lib-coverage-3.2.0.tgz" @@ -15200,6 +15259,21 @@ video-stream-merger@^4.0.1: resolved "https://registry.yarnpkg.com/video-stream-merger/-/video-stream-merger-4.0.1.tgz#b0061251bd211121d1256ccf9e2be9477e59d5cb" integrity sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA== +viem@^1.3.0: + version "1.3.0" + resolved "https://registry.yarnpkg.com/viem/-/viem-1.3.0.tgz#99c941e9bcfc62b53ffc5bd7470d7900a00d876c" + integrity sha512-gCtachbNPG9G9D7UNuiqLaLf8IFV15FypBrSpXEFeeEczXxI+Jgi9FTwDS+NJLreVrjBeZXQVj1ITTqKpItw4w== + dependencies: + "@adraffy/ens-normalize" "1.9.0" + "@noble/curves" "1.0.0" + "@noble/hashes" "1.3.0" + "@scure/bip32" "1.3.0" + "@scure/bip39" "1.2.0" + "@wagmi/chains" "1.6.0" + abitype "0.8.11" + isomorphic-ws "5.0.0" + ws "8.12.0" + vlq@^1.0.0: version "1.0.1" resolved "https://registry.npmjs.org/vlq/-/vlq-1.0.1.tgz" @@ -15558,6 +15632,11 @@ ws@7.4.6: resolved "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz" integrity sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A== +ws@8.12.0: + version "8.12.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.12.0.tgz#485074cc392689da78e1828a9ff23585e06cddd8" + integrity sha512-kU62emKIdKVeEIOIKVegvqpXMSTAMLJozpHZaJNDYqBjzlSYXQGviYwN1osDLJ9av68qHd4a2oSjd7yD4pacig== + ws@^6.1.4: version "6.2.2" resolved "https://registry.npmjs.org/ws/-/ws-6.2.2.tgz" From 74da5f1ef7b9f6835761c6ce8cc43599de5ab8ba Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 21 Jul 2023 12:35:24 +0530 Subject: [PATCH 166/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.26?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 12 ++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 245f086b4..8efc12d2b 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.26](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.25...restapi-0.0.1-alpha.26) (2023-07-21) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([3f3369a](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f3369a1bda71a82cde8ef386901265a62a91a2c)) +* merge main ([c07ce16](https://github.com/ethereum-push-notification-service/push-sdk/commit/c07ce1628321dd3bae46d08e08bfc7986795bb64)) +* space feed API path fix ([00d91b1](https://github.com/ethereum-push-notification-service/push-sdk/commit/00d91b1860525c15618f130970c9173100424a23)) +* use SpaceIFeeds ([5b7f2fc](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7f2fc2398a2203925059aa2721e855ea9f98d4)) + + + ## [0.0.1-alpha.25](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.24...restapi-0.0.1-alpha.25) (2023-07-19) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 60295bc28..cdd9a9490 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.25", + "version": "0.0.1-alpha.26", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 8972cea9193d160680f140a022759647249a2beb Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 22 Jul 2023 10:33:12 +0530 Subject: [PATCH 167/298] Update README.md --- packages/restapi/README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index a9e1cdaea..f12881d5c 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -9,7 +9,7 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [How to use in your app?](#how-to-use-in-your-app) - [Installation](#installation) - [Import SDK](#import-sdk) - - [**About generating the "signer" object for different platforms**](#about-generating-the-signer-object-for-different-platforms) + - [About generating the "signer" object for different platforms](#about-generating-the-signer-object-for-different-platforms) - [When using in SERVER-SIDE code:](#when-using-in-server-side-code) - [When using in FRONT-END code:](#when-using-in-front-end-code) - [**About blockchain agnostic address format**](#about-blockchain-agnostic-address-format) From bfeee5f055af7b995de40fb3af2f17ce9b003d10 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 22 Jul 2023 10:42:33 +0530 Subject: [PATCH 168/298] Update README.md --- packages/restapi/README.md | 152 ++++++++++++++++++------------------- 1 file changed, 76 insertions(+), 76 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index f12881d5c..9438227ff 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -12,93 +12,93 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [About generating the "signer" object for different platforms](#about-generating-the-signer-object-for-different-platforms) - [When using in SERVER-SIDE code:](#when-using-in-server-side-code) - [When using in FRONT-END code:](#when-using-in-front-end-code) - - [**About blockchain agnostic address format**](#about-blockchain-agnostic-address-format) + - [About blockchain agnostic address format](#about-blockchain-agnostic-address-format) - [Chat blockchain agnostic address format](#chat-blockchain-agnostic-address-format) - - [**About Push contract addresses**](#about-push-contract-addresses) + - [About Push contract addresses](#about-push-contract-addresses) - [Push core contract address](#push-core-contract-address) - [Push communicator contract address](#push-communicator-contract-address) - [SDK Features](#sdk-features) - [For Notification](#for-notification) - - [**Fetching user notifications**](#fetching-user-notifications) - - [**Fetching user spam notifications**](#fetching-user-spam-notifications) - - [**Fetching user subscriptions**](#fetching-user-subscriptions) - - [**Fetching channel details**](#fetching-channel-details) - - [**Searching for channel(s)**](#searching-for-channels) - - [**Opt in to a channel**](#opt-in-to-a-channel) - - [**Opt out to a channel**](#opt-out-to-a-channel) - - [**Sending notification**](#sending-notification) - - [**Direct payload for single recipient(target)**](#direct-payload-for-single-recipienttarget) - - [**Direct payload for group of recipients(subset)**](#direct-payload-for-group-of-recipientssubset) - - [**Direct payload for all recipients(broadcast)**](#direct-payload-for-all-recipientsbroadcast) - - [**IPFS payload for single recipient(target)**](#ipfs-payload-for-single-recipienttarget) - - [**IPFS payload for group of recipients(subset)**](#ipfs-payload-for-group-of-recipientssubset) - - [**IPFS payload for all recipients(broadcast)**](#ipfs-payload-for-all-recipientsbroadcast) - - [**Minimal payload for single recipient(target)**](#minimal-payload-for-single-recipienttarget) - - [**Minimal payload for a group of recipient(subset)**](#minimal-payload-for-a-group-of-recipientsubset) - - [**Minimal payload for all recipients(broadcast)**](#minimal-payload-for-all-recipientsbroadcast) - - [**Graph payload for single recipient(target)**](#graph-payload-for-single-recipienttarget) - - [**Graph payload for group of recipients(subset)**](#graph-payload-for-group-of-recipientssubset) - - [**Graph payload for all recipients(broadcast)**](#graph-payload-for-all-recipientsbroadcast) + - [Fetching user notifications](#fetching-user-notifications) + - [Fetching user spam notifications](#fetching-user-spam-notifications) + - [Fetching user subscriptions](#fetching-user-subscriptions) + - [Fetching channel details](#fetching-channel-details) + - [Searching for channel(s)](#searching-for-channels) + - [Opt in to a channel](#opt-in-to-a-channel) + - [Opt out to a channel](#opt-out-to-a-channel) + - [Sending notification](#sending-notification) + - [Direct payload for single recipient(target)](#direct-payload-for-single-recipienttarget) + - [Direct payload for group of recipients(subset)](#direct-payload-for-group-of-recipientssubset) + - [Direct payload for all recipients(broadcast)](#direct-payload-for-all-recipientsbroadcast) + - [IPFS payload for single recipient(target)](#ipfs-payload-for-single-recipienttarget) + - [IPFS payload for group of recipients(subset)](#ipfs-payload-for-group-of-recipientssubset) + - [IPFS payload for all recipients(broadcast)](#ipfs-payload-for-all-recipientsbroadcast) + - [Minimal payload for single recipient(target)](#minimal-payload-for-single-recipienttarget) + - [Minimal payload for a group of recipient(subset)](#minimal-payload-for-a-group-of-recipientsubset) + - [Minimal payload for all recipients(broadcast)](#minimal-payload-for-all-recipientsbroadcast) + - [Graph payload for single recipient(target)](#graph-payload-for-single-recipienttarget) + - [Graph payload for group of recipients(subset)](#graph-payload-for-group-of-recipientssubset) + - [Graph payload for all recipients(broadcast)](#graph-payload-for-all-recipientsbroadcast) - [Notification Helper Utils](#notification-helper-utils) - - [**Parsing notifications**](#parsing-notifications) + - [Parsing notifications](#parsing-notifications) - [Advanced Notifications (WIP)](#advanced-notifications-wip) - [DEPRECATED](#deprecated) - - [**Get a channel's subscriber list of addresses**](#get-a-channels-subscriber-list-of-addresses) + - [Get a channel's subscriber list of addresses](#get-a-channels-subscriber-list-of-addresses) - [For Chat](#for-chat) - - [**Create user for chat**](#create-user-for-chat) - - [**Get user data for chat**](#get-user-data-for-chat) - - [**Decrypting encrypted pgp private key from user data**](#decrypting-encrypted-pgp-private-key-from-user-data) - - [**Updating User Profile**](#updating-user-profile) - - [**Fetching list of user chats**](#fetching-list-of-user-chats) - - [**Fetching list of user chat requests**](#fetching-list-of-user-chat-requests) - - [**Fetching conversation hash between two users**](#fetching-conversation-hash-between-two-users) - - [**Fetching latest chat between two users**](#fetching-latest-chat-between-two-users) - - [**Fetching chat history between two users**](#fetching-chat-history-between-two-users) - - [**To send a message**](#to-send-a-message) - - [**To approve a chat request**](#to-approve-a-chat-request) - - [**To create a group**](#to-create-a-group) - - [**To create a token gated group**](#to-create-a-token-gated-group) - - [**To update group details**](#to-update-group-details) - - [**To update token gated group details**](#to-update-token-gated-group-details) - - [**To get group details by group name**](#to-get-group-details-by-group-name) - - [**To get group details by chatId**](#to-get-group-details-by-chatid) - - [**Chat Helper Utils**](#chat-helper-utils) - - [**Decrypting messages**](#decrypting-messages) + - [Create user for chat](#create-user-for-chat) + - [Get user data for chat](#get-user-data-for-chat) + - [Decrypting encrypted pgp private key from user data](#decrypting-encrypted-pgp-private-key-from-user-data) + - [Updating User Profile](#updating-user-profile) + - [Fetching list of user chats](#fetching-list-of-user-chats) + - [Fetching list of user chat requests](#fetching-list-of-user-chat-requests) + - [Fetching conversation hash between two users](#fetching-conversation-hash-between-two-users) + - [Fetching latest chat between two users](#fetching-latest-chat-between-two-users) + - [Fetching chat history between two users](#fetching-chat-history-between-two-users) + - [To send a message](#to-send-a-message) + - [To approve a chat request](#to-approve-a-chat-request) + - [To create a group](#to-create-a-group) + - [To create a token gated group](#to-create-a-token-gated-group) + - [To update group details](#to-update-group-details) + - [To update token gated group details](#to-update-token-gated-group-details) + - [To get group details by group name](#to-get-group-details-by-group-name) + - [To get group details by chatId](#to-get-group-details-by-chatid) + - [Chat Helper Utils](#chat-helper-utils) + - [Decrypting messages](#decrypting-messages) - [For Video](#for-video) - - [**Instance Variables**](#instance-variables) - - [**peerInstance**](#peerinstance) - - [**signer**](#signer) - - [**chainId**](#chainid) - - [**pgpPrivateKey**](#pgpprivatekey) - - [**env**](#env) - - [**data**](#data) - - [**setData**](#setdata) - - [**Methods**](#methods) - - [**constructor**](#constructor) - - [**create**](#create) - - [**request**](#request) - - [**acceptRequest**](#acceptrequest) - - [**connect**](#connect) - - [**disconnect**](#disconnect) - - [**enableVideo**](#enablevideo) - - [**enableAudio**](#enableaudio) - - [**isInitiator**](#isinitiator) + - [Instance Variables](#instance-variables) + - [peerInstance](#peerinstance) + - [signer](#signer) + - [chainId](#chainid) + - [pgpPrivateKey](#pgpprivatekey) + - [env](#env) + - [data](#data) + - [setData](#setdata) + - [Methods](#methods) + - [constructor](#constructor) + - [create](#create) + - [request](#request) + - [acceptRequest](#acceptrequest) + - [connect](#connect) + - [disconnect](#disconnect) + - [enableVideo](#enablevideo) + - [enableAudio](#enableaudio) + - [isInitiator](#isinitiator) - [For Spaces](#for-spaces) - - [**To create a space**](#to-create-a-space) - - [**To create a token gated space**](#to-create-a-token-gated-space) - - [**To update space details**](#to-update-space-details) - - [**To update token gated space details**](#to-update-token-gated-space-details) - - [**To get space details by spaceId**](#to-get-space-details-by-spaceid) - - [**To start a space**](#to-start-a-space) - - [**To stop a space**](#to-stop-a-space) - - [**To approve a space request**](#to-approve-a-space-request) - - [**To add listeners to space**](#to-add-listeners-to-space) - - [**To remove listeners from space**](#to-remove-listeners-from-space) - - [**To add speakers to space**](#to-add-speakers-to-space) - - [**To remove speakers from space**](#to-remove-speakers-from-space) - - [**Fetching list of user spaces**](#fetching-list-of-user-spaces) - - [**Fetching list of user space requests**](#fetching-list-of-user-space-requests) - - [**Fetching list of trending spaces**](#fetching-list-of-trending-spaces) + - [To create a space](#to-create-a-space) + - [To create a token gated space](#to-create-a-token-gated-space) + - [To update space details](#to-update-space-details) + - [To update token gated space details](#to-update-token-gated-space-details) + - [To get space details by spaceId](#to-get-space-details-by-spaceid) + - [To start a space](#to-start-a-space) + - [To stop a space](#to-stop-a-space) + - [To approve a space request](#to-approve-a-space-request) + - [To add listeners to space](#to-add-listeners-to-space) + - [To remove listeners from space](#to-remove-listeners-from-space) + - [To add speakers to space](#to-add-speakers-to-space) + - [To remove speakers from space](#to-remove-speakers-from-space) + - [Fetching list of user spaces](#fetching-list-of-user-spaces) + - [Fetching list of user space requests](#fetching-list-of-user-space-requests) + - [Fetching list of trending spaces](#fetching-list-of-trending-spaces) # How to use in your app? From 110fca57d197e3688d2b5a1714a771a142391af9 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 22 Jul 2023 10:45:43 +0530 Subject: [PATCH 169/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 4 ++++ packages/restapi/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 26587e562..90c24c680 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.2...restapi-1.4.3) (2023-07-22) + + + ## [1.4.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.1...restapi-1.4.2) (2023-07-20) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index ba91e9d60..d6df83be9 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.2", + "version": "1.4.3", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 599f04ddaa26aa71c6ed8e644c81874fd3b13781 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 24 Jul 2023 16:37:30 +0530 Subject: [PATCH 170/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.27?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 13 +++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 969ea1e3d..c63a3da49 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.27](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.26...restapi-0.0.1-alpha.27) (2023-07-24) + + +### Bug Fixes + +* merge alpha ([16a55af](https://github.com/ethereum-push-notification-service/push-sdk/commit/16a55af713da0394ab9d82e13fed6d64190b247d)) +* Merge branch 'alpha' into alpha-deployment ([6ea669a](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ea669a5aa3cebe693de259c1ea28787c0407d2a)) +* signer compatibility with viem ([3df201c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3df201c7474b88d270d6e868bc516f223539e74c)) +* signer compatibility with viem and ethers ([1edea43](https://github.com/ethereum-push-notification-service/push-sdk/commit/1edea431ccf7f19cc0430deb2ce7a5c61390d99f)) +* signer compatibility with viem and ethers ([#567](https://github.com/ethereum-push-notification-service/push-sdk/issues/567)) ([c07c3fa](https://github.com/ethereum-push-notification-service/push-sdk/commit/c07c3fab76a095998b1eac830c941116ad1e9b4f)) + + + ## [1.4.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.2...restapi-1.4.3) (2023-07-22) ## [1.4.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.1...restapi-1.4.2) (2023-07-20) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index cdd9a9490..0d3219349 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.26", + "version": "0.0.1-alpha.27", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 9e691d8b92fd575efab2a083754364ea007bdbae Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 27 Jul 2023 17:45:39 +0530 Subject: [PATCH 171/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 4 ++++ packages/restapi/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d0241adc9..617d9f259 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.3...restapi-1.4.4) (2023-07-27) + + + ## [1.4.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.2...restapi-1.4.3) (2023-07-22) ## [1.4.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.1...restapi-1.4.2) (2023-07-20) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index d6df83be9..63b9e4d6f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.3", + "version": "1.4.4", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 3e8e7d88adb1b5ee9ee4cc07b012a5407df63a74 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 27 Jul 2023 18:16:33 +0530 Subject: [PATCH 172/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 4 ++++ packages/uiweb/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 182d1e341..c5fbf59f3 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.4...uiweb-1.1.5) (2023-07-27) + + + ## [1.1.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.3...uiweb-1.1.4) (2023-07-20) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index b8a2a0e2a..f9ef5e68e 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.4", + "version": "1.1.5", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From ebddf3aecb522ce8ed11d7390e29d84394bf0b94 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 28 Jul 2023 15:34:56 +0530 Subject: [PATCH 173/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index c5fbf59f3..d81aa9dba 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.5...uiweb-1.1.6) (2023-07-28) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([e33017a](https://github.com/ethereum-push-notification-service/push-sdk/commit/e33017afb2d4e9361d5df47e0f7e726ecdffbc32)) + + + ## [1.1.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.4...uiweb-1.1.5) (2023-07-27) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index f9ef5e68e..db0dfad7d 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.5", + "version": "1.1.6", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From f9c5178562333321227ebcc45d4ea2074a7c173f Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 31 Jul 2023 16:51:44 +0530 Subject: [PATCH 174/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index d81aa9dba..ced9a14af 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.6...uiweb-1.1.7) (2023-07-31) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([9755baf](https://github.com/ethereum-push-notification-service/push-sdk/commit/9755baf3d4bcd3ab3fd365fad9d8fb7623fda58f)) + + + ## [1.1.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.5...uiweb-1.1.6) (2023-07-28) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index db0dfad7d..18011909a 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.6", + "version": "1.1.7", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 67680657981a847e23a4dbad6d2fd6a7bc127743 Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Wed, 2 Aug 2023 15:15:20 +0530 Subject: [PATCH 175/298] fix: add: scw sig verification (#593) --- packages/restapi/package.json | 1 + .../restapi/src/lib/chat/helpers/service.ts | 6 +- .../restapi/src/lib/chat/helpers/signature.ts | 35 +- packages/restapi/src/lib/helpers/crypto.ts | 6 +- packages/restapi/src/lib/user/getUser.ts | 4 +- .../restapi/src/lib/user/getUsersBatch.ts | 4 +- .../src/lib/user/profile.updateUser.ts | 21 +- packages/restapi/yarn.lock | 1349 ++++++++++++++++- 8 files changed, 1392 insertions(+), 34 deletions(-) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index d6df83be9..6476c7c53 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -9,6 +9,7 @@ "ethers": "^5.6.8" }, "dependencies": { + "@ambire/signature-validator": "^1.3.1", "@livepeer/webrtmp-sdk": "^0.2.3", "@metamask/eth-sig-util": "^5.0.2", "buffer": "^6.0.3", diff --git a/packages/restapi/src/lib/chat/helpers/service.ts b/packages/restapi/src/lib/chat/helpers/service.ts index bfb8c90ed..b08f0cc22 100644 --- a/packages/restapi/src/lib/chat/helpers/service.ts +++ b/packages/restapi/src/lib/chat/helpers/service.ts @@ -61,9 +61,9 @@ export const createUserService = async (options: CreateUserOptionsType) => { return axios .post(requestUrl, body) - .then((response) => { + .then(async (response) => { if (response.data) - response.data.publicKey = verifyPGPPublicKey( + response.data.publicKey = await verifyPGPPublicKey( response.data.encryptedPrivateKey, response.data.publicKey, response.data.did @@ -104,7 +104,7 @@ export const authUpdateUserService = async (options: CreateUserOptionsType) => { return axios .put(requestUrl, body) - .then((response) => { + .then(async (response) => { if (response.data) response.data.publicKey = verifyPGPPublicKey( response.data.encryptedPrivateKey, diff --git a/packages/restapi/src/lib/chat/helpers/signature.ts b/packages/restapi/src/lib/chat/helpers/signature.ts index 96371baa0..665e846ad 100644 --- a/packages/restapi/src/lib/chat/helpers/signature.ts +++ b/packages/restapi/src/lib/chat/helpers/signature.ts @@ -4,6 +4,7 @@ import { } from '@metamask/eth-sig-util'; import * as ethers from 'ethers'; import { hashMessage } from 'ethers/lib/utils'; +import { verifyMessage } from '@ambire/signature-validator'; /** * @@ -82,11 +83,11 @@ export const getTypedData = ( * @param chainId * @returns */ -export const verifyProfileSignature = ( +export const verifyProfileSignature = async ( verificationProof: string, signedData: string, address: string -): boolean => { +): Promise => { const SIG_TYPE_V2 = 'eip712v2'; const SIG_TYPE_V3 = 'eip191'; let chainId: number | null = null; @@ -133,12 +134,28 @@ export const verifyProfileSignature = ( } } else { // EIP191 sig validation - const recoveredAddress = ethers.utils.recoverAddress( - hashMessage(signedData), - signature - ); - if (recoveredAddress.toLowerCase() === address.toLowerCase()) { - return true; - } else return false; + try { + // EOA Wallet + const recoveredAddress = ethers.utils.recoverAddress( + hashMessage(signedData), + signature + ); + if (recoveredAddress.toLowerCase() === address.toLowerCase()) { + return true; + } else return false; + } catch (err) { + try { + // SCW Wallet + const verificationResult: boolean = await verifyMessage({ + signer: address.toLowerCase(), + message: signedData, + signature: signature, + provider: ethers.getDefaultProvider(1), + }); + return verificationResult; + } catch (err) { + return false; + } + } } }; diff --git a/packages/restapi/src/lib/helpers/crypto.ts b/packages/restapi/src/lib/helpers/crypto.ts index d3af27c08..e843753e0 100644 --- a/packages/restapi/src/lib/helpers/crypto.ts +++ b/packages/restapi/src/lib/helpers/crypto.ts @@ -480,11 +480,11 @@ export const preparePGPPublicKey = async ( return chatPublicKey; }; -export const verifyPGPPublicKey = ( +export const verifyPGPPublicKey = async ( encryptedPrivateKey: string, publicKey: string, did: string -): string => { +): Promise => { try { if (publicKey !== '' && publicKey.includes('signature')) { const { key, signature: verificationProof } = JSON.parse(publicKey); @@ -494,7 +494,7 @@ export const verifyPGPPublicKey = ( signedData = 'Create Push Chat Profile \n' + generateHash(key); else signedData = 'Create Push Profile \n' + generateHash(key); if ( - verifyProfileSignature( + await verifyProfileSignature( verificationProof, signedData, isValidCAIP10NFTAddress(did) diff --git a/packages/restapi/src/lib/user/getUser.ts b/packages/restapi/src/lib/user/getUser.ts index 67dfefd9b..fa5bf052d 100644 --- a/packages/restapi/src/lib/user/getUser.ts +++ b/packages/restapi/src/lib/user/getUser.ts @@ -15,9 +15,9 @@ export const get = async (options: AccountEnvOptionsType): Promise => { const requestUrl = `${API_BASE_URL}/v2/users/?caip10=${caip10}`; return axios .get(requestUrl) - .then((response) => { + .then(async (response) => { if (response.data) { - response.data.publicKey = verifyPGPPublicKey( + response.data.publicKey = await verifyPGPPublicKey( response.data.encryptedPrivateKey, response.data.publicKey, response.data.did diff --git a/packages/restapi/src/lib/user/getUsersBatch.ts b/packages/restapi/src/lib/user/getUsersBatch.ts index 8997ca348..eebcda782 100644 --- a/packages/restapi/src/lib/user/getUsersBatch.ts +++ b/packages/restapi/src/lib/user/getUsersBatch.ts @@ -35,8 +35,8 @@ export const getBatch = async (options: GetBatchType): Promise => { return axios .post(requestUrl, requestBody) .then((response) => { - response.data.users.forEach((user: any, index: number) => { - response.data.users[index].publicKey = verifyPGPPublicKey( + response.data.users.forEach(async (user: any, index: number) => { + response.data.users[index].publicKey = await verifyPGPPublicKey( user.encryptedPrivateKey, user.publicKey, user.did diff --git a/packages/restapi/src/lib/user/profile.updateUser.ts b/packages/restapi/src/lib/user/profile.updateUser.ts index 5ced944d0..175452e19 100644 --- a/packages/restapi/src/lib/user/profile.updateUser.ts +++ b/packages/restapi/src/lib/user/profile.updateUser.ts @@ -57,18 +57,21 @@ export const profileUpdate = async ( throw new Error('User not Found!'); } let blockedUsersList = null; - if(profile.blockedUsersList ){ - - for (const element of profile.blockedUsersList ) { + if (profile.blockedUsersList) { + for (const element of profile.blockedUsersList) { // Check if the element is a valid CAIP-10 address if (!isValidETHAddress(element)) { - throw new Error('Invalid address in the blockedUsersList: ' + element); + throw new Error( + 'Invalid address in the blockedUsersList: ' + element + ); } } - const convertedBlockedListUsersPromise = profile.blockedUsersList.map(async (each) => { - return getUserDID(each, env); - }); + const convertedBlockedListUsersPromise = profile.blockedUsersList.map( + async (each) => { + return getUserDID(each, env); + } + ); blockedUsersList = await Promise.all(convertedBlockedListUsersPromise); } @@ -77,7 +80,7 @@ export const profileUpdate = async ( desc: profile.desc ? profile.desc : user.profile.desc, picture: profile.picture ? profile.picture : user.profile.picture, // If profile.blockedUsersList is empty no users in block list - blockedUsersList: profile.blockedUsersList ? blockedUsersList : [] + blockedUsersList: profile.blockedUsersList ? blockedUsersList : [], }; const hash = CryptoJS.SHA256(JSON.stringify(updatedProfile)).toString(); const signature = await sign({ @@ -96,7 +99,7 @@ export const profileUpdate = async ( progressHook?.(PROGRESSHOOK['PUSH-PROFILE-UPDATE-01'] as ProgressHookType); const response = await axios.put(apiEndpoint, body); if (response.data) - response.data.publicKey = verifyPGPPublicKey( + response.data.publicKey = await verifyPGPPublicKey( response.data.encryptedPrivateKey, response.data.publicKey, response.data.did diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index 5bb63c29d..e631eb124 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -2,6 +2,15 @@ # yarn lockfile v1 +"@ambire/signature-validator@^1.3.1": + version "1.3.1" + resolved "https://registry.yarnpkg.com/@ambire/signature-validator/-/signature-validator-1.3.1.tgz#d899aae3b26f65a3557b4d43b6fe4b50c6f9074b" + integrity sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ== + dependencies: + ethers "^5.6.5" + tap-spec "^5.0.0" + tape "^5.5.3" + "@chainsafe/as-sha256@^0.3.1": version "0.3.1" resolved "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz" @@ -44,6 +53,348 @@ "@ethereumjs/rlp" "^4.0.1" ethereum-cryptography "^1.1.2" +"@ethersproject/abi@5.7.0", "@ethersproject/abi@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/abi/-/abi-5.7.0.tgz#b3f3e045bbbeed1af3947335c247ad625a44e449" + integrity sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA== + dependencies: + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/abstract-provider@5.7.0", "@ethersproject/abstract-provider@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz#b0a8550f88b6bf9d51f90e4795d48294630cb9ef" + integrity sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/networks" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/web" "^5.7.0" + +"@ethersproject/abstract-signer@5.7.0", "@ethersproject/abstract-signer@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz#13f4f32117868452191a4649723cb086d2b596b2" + integrity sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ== + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + +"@ethersproject/address@5.7.0", "@ethersproject/address@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/address/-/address-5.7.0.tgz#19b56c4d74a3b0a46bfdbb6cfcc0a153fc697f37" + integrity sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + +"@ethersproject/base64@5.7.0", "@ethersproject/base64@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/base64/-/base64-5.7.0.tgz#ac4ee92aa36c1628173e221d0d01f53692059e1c" + integrity sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ== + dependencies: + "@ethersproject/bytes" "^5.7.0" + +"@ethersproject/basex@5.7.0", "@ethersproject/basex@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/basex/-/basex-5.7.0.tgz#97034dc7e8938a8ca943ab20f8a5e492ece4020b" + integrity sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + +"@ethersproject/bignumber@5.7.0", "@ethersproject/bignumber@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/bignumber/-/bignumber-5.7.0.tgz#e2f03837f268ba655ffba03a57853e18a18dc9c2" + integrity sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + bn.js "^5.2.1" + +"@ethersproject/bytes@5.7.0", "@ethersproject/bytes@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/bytes/-/bytes-5.7.0.tgz#a00f6ea8d7e7534d6d87f47188af1148d71f155d" + integrity sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A== + dependencies: + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/constants@5.7.0", "@ethersproject/constants@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/constants/-/constants-5.7.0.tgz#df80a9705a7e08984161f09014ea012d1c75295e" + integrity sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + +"@ethersproject/contracts@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/contracts/-/contracts-5.7.0.tgz#c305e775abd07e48aa590e1a877ed5c316f8bd1e" + integrity sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg== + dependencies: + "@ethersproject/abi" "^5.7.0" + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + +"@ethersproject/hash@5.7.0", "@ethersproject/hash@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/hash/-/hash-5.7.0.tgz#eb7aca84a588508369562e16e514b539ba5240a7" + integrity sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g== + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/base64" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/hdnode@5.7.0", "@ethersproject/hdnode@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/hdnode/-/hdnode-5.7.0.tgz#e627ddc6b466bc77aebf1a6b9e47405ca5aef9cf" + integrity sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg== + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/basex" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/pbkdf2" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/wordlists" "^5.7.0" + +"@ethersproject/json-wallets@5.7.0", "@ethersproject/json-wallets@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz#5e3355287b548c32b368d91014919ebebddd5360" + integrity sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g== + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hdnode" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/pbkdf2" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + aes-js "3.0.0" + scrypt-js "3.0.1" + +"@ethersproject/keccak256@5.7.0", "@ethersproject/keccak256@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/keccak256/-/keccak256-5.7.0.tgz#3186350c6e1cd6aba7940384ec7d6d9db01f335a" + integrity sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg== + dependencies: + "@ethersproject/bytes" "^5.7.0" + js-sha3 "0.8.0" + +"@ethersproject/logger@5.7.0", "@ethersproject/logger@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/logger/-/logger-5.7.0.tgz#6ce9ae168e74fecf287be17062b590852c311892" + integrity sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig== + +"@ethersproject/networks@5.7.1", "@ethersproject/networks@^5.7.0": + version "5.7.1" + resolved "https://registry.yarnpkg.com/@ethersproject/networks/-/networks-5.7.1.tgz#118e1a981d757d45ccea6bb58d9fd3d9db14ead6" + integrity sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ== + dependencies: + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/pbkdf2@5.7.0", "@ethersproject/pbkdf2@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz#d2267d0a1f6e123f3771007338c47cccd83d3102" + integrity sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + +"@ethersproject/properties@5.7.0", "@ethersproject/properties@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/properties/-/properties-5.7.0.tgz#a6e12cb0439b878aaf470f1902a176033067ed30" + integrity sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw== + dependencies: + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/providers@5.7.2": + version "5.7.2" + resolved "https://registry.yarnpkg.com/@ethersproject/providers/-/providers-5.7.2.tgz#f8b1a4f275d7ce58cf0a2eec222269a08beb18cb" + integrity sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg== + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/base64" "^5.7.0" + "@ethersproject/basex" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/networks" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/web" "^5.7.0" + bech32 "1.1.4" + ws "7.4.6" + +"@ethersproject/random@5.7.0", "@ethersproject/random@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/random/-/random-5.7.0.tgz#af19dcbc2484aae078bb03656ec05df66253280c" + integrity sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/rlp@5.7.0", "@ethersproject/rlp@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/rlp/-/rlp-5.7.0.tgz#de39e4d5918b9d74d46de93af80b7685a9c21304" + integrity sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/sha2@5.7.0", "@ethersproject/sha2@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/sha2/-/sha2-5.7.0.tgz#9a5f7a7824ef784f7f7680984e593a800480c9fb" + integrity sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + hash.js "1.1.7" + +"@ethersproject/signing-key@5.7.0", "@ethersproject/signing-key@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/signing-key/-/signing-key-5.7.0.tgz#06b2df39411b00bc57c7c09b01d1e41cf1b16ab3" + integrity sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + bn.js "^5.2.1" + elliptic "6.5.4" + hash.js "1.1.7" + +"@ethersproject/solidity@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/solidity/-/solidity-5.7.0.tgz#5e9c911d8a2acce2a5ebb48a5e2e0af20b631cb8" + integrity sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/strings@5.7.0", "@ethersproject/strings@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/strings/-/strings-5.7.0.tgz#54c9d2a7c57ae8f1205c88a9d3a56471e14d5ed2" + integrity sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/transactions@5.7.0", "@ethersproject/transactions@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/transactions/-/transactions-5.7.0.tgz#91318fc24063e057885a6af13fdb703e1f993d3b" + integrity sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ== + dependencies: + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + +"@ethersproject/units@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/units/-/units-5.7.0.tgz#637b563d7e14f42deeee39245275d477aae1d8b1" + integrity sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/wallet@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/wallet/-/wallet-5.7.0.tgz#4e5d0790d96fe21d61d38fb40324e6c7ef350b2d" + integrity sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA== + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/hdnode" "^5.7.0" + "@ethersproject/json-wallets" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/wordlists" "^5.7.0" + +"@ethersproject/web@5.7.1", "@ethersproject/web@^5.7.0": + version "5.7.1" + resolved "https://registry.yarnpkg.com/@ethersproject/web/-/web-5.7.1.tgz#de1f285b373149bee5928f4eb7bcb87ee5fbb4ae" + integrity sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w== + dependencies: + "@ethersproject/base64" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/wordlists@5.7.0", "@ethersproject/wordlists@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/wordlists/-/wordlists-5.7.0.tgz#8fb2c07185d68c3e09eb3bfd6e779ba2774627f5" + integrity sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@jridgewell/resolve-uri@^3.0.3": version "3.1.0" resolved "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz" @@ -80,6 +431,18 @@ dependencies: events "3.3.0" +"@ljharb/resumer@^0.0.1": + version "0.0.1" + resolved "https://registry.yarnpkg.com/@ljharb/resumer/-/resumer-0.0.1.tgz#8a940a9192dd31f6a1df17564bbd26dc6ad3e68d" + integrity sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw== + dependencies: + "@ljharb/through" "^2.3.9" + +"@ljharb/through@^2.3.9": + version "2.3.9" + resolved "https://registry.yarnpkg.com/@ljharb/through/-/through-2.3.9.tgz#85f221eb82f9d555e180e87d6e50fb154af85408" + integrity sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ== + "@metamask/eth-sig-util@^5.0.2": version "5.0.2" resolved "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz" @@ -186,6 +549,11 @@ acorn@^8.4.1: resolved "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz" integrity sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw== +aes-js@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.0.0.tgz#e21df10ad6c2053295bcbb8dab40b09dbea87e4d" + integrity sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw== + ansi-colors@4.1.1: version "4.1.1" resolved "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.1.tgz" @@ -206,6 +574,11 @@ ansi-regex@^5.0.1: resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== +ansi-styles@^2.2.1: + version "2.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe" + integrity sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA== + ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz" @@ -238,6 +611,36 @@ argparse@^2.0.1: resolved "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz" integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== +array-buffer-byte-length@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz#fabe8bc193fea865f317fe7807085ee0dee5aead" + integrity sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A== + dependencies: + call-bind "^1.0.2" + is-array-buffer "^3.0.1" + +array.prototype.every@^1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/array.prototype.every/-/array.prototype.every-1.1.4.tgz#2762daecd9cec87cb63f3ca6be576817074a684e" + integrity sha512-Aui35iRZk1HHLRAyF7QP0KAnOnduaQ6fo6k1NVWfRc0xTs2AZ70ytlXvOmkC6Di4JmUs2Wv3DYzGtCQFSk5uGg== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + is-string "^1.0.7" + +arraybuffer.prototype.slice@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.1.tgz#9b5ea3868a6eebc30273da577eb888381c0044bb" + integrity sha512-09x0ZWFEjj4WD8PDbykUwo3t9arLn8NIzmmYEJFpYekOAQjpkGSyrQhNoRTcwwcFRu+ycWF78QZ63oWTqSjBcw== + dependencies: + array-buffer-byte-length "^1.0.0" + call-bind "^1.0.2" + define-properties "^1.2.0" + get-intrinsic "^1.2.1" + is-array-buffer "^3.0.2" + is-shared-array-buffer "^1.0.2" + asn1.js@^5.0.0: version "5.4.1" resolved "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz" @@ -253,6 +656,11 @@ assertion-error@^1.1.0: resolved "https://registry.npmjs.org/assertion-error/-/assertion-error-1.1.0.tgz" integrity sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw== +available-typed-arrays@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz#92f95616501069d07d10edb2fc37d3e1c65123b7" + integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== + balanced-match@^1.0.0: version "1.0.2" resolved "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz" @@ -263,16 +671,26 @@ base64-js@^1.3.1: resolved "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz" integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== +bech32@1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/bech32/-/bech32-1.1.4.tgz#e38c9f37bf179b8eb16ae3a772b40c356d4832e9" + integrity sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ== + binary-extensions@^2.0.0: version "2.2.0" resolved "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz" integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== -bn.js@^4.0.0, bn.js@^4.11.8: +bn.js@^4.0.0, bn.js@^4.11.8, bn.js@^4.11.9: version "4.12.0" resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== +bn.js@^5.2.1: + version "5.2.1" + resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.1.tgz#0bc527a6a0d18d0aa8d5b0538ce4a77dccfa7b70" + integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== + brace-expansion@^1.1.7: version "1.1.11" resolved "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz" @@ -295,6 +713,11 @@ braces@~3.0.2: dependencies: fill-range "^7.0.1" +brorand@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" + integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== + browser-stdout@1.3.1: version "1.3.1" resolved "https://registry.npmjs.org/browser-stdout/-/browser-stdout-1.3.1.tgz" @@ -305,6 +728,11 @@ buffer-from@^1.1.2: resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== +buffer-shims@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/buffer-shims/-/buffer-shims-1.0.0.tgz#9978ce317388c649ad8793028c3477ef044a8b51" + integrity sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g== + buffer@^6.0.3: version "6.0.3" resolved "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz" @@ -313,6 +741,14 @@ buffer@^6.0.3: base64-js "^1.3.1" ieee754 "^1.2.1" +call-bind@^1.0.0, call-bind@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + camelcase@^4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/camelcase/-/camelcase-4.1.0.tgz" @@ -348,6 +784,17 @@ chai@^4.3.7: pathval "^1.1.1" type-detect "^4.0.5" +chalk@^1.0.0: + version "1.1.3" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-1.1.3.tgz#a8115c55e4a702fe4d150abd3872822a7e09fc98" + integrity sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A== + dependencies: + ansi-styles "^2.2.1" + escape-string-regexp "^1.0.2" + has-ansi "^2.0.0" + strip-ansi "^3.0.0" + supports-color "^2.0.0" + chalk@^2.4.1: version "2.4.2" resolved "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" @@ -450,6 +897,11 @@ core-js@^3.27.2: resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.31.0.tgz#4471dd33e366c79d8c0977ed2d940821719db344" integrity sha512-NIp2TQSGfR6ba5aalZD+ZQ1fSxGhDo/s1w0nx3RYzf2pnJxt7YynxFlFScP6eV7+GZsKO95NSjGxyJsU3DZgeQ== +core-util-is@~1.0.0: + version "1.0.3" + resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.3.tgz#a6042d3634c2b27e9328f837b965fac83808db85" + integrity sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ== + create-require@^1.1.0: version "1.1.1" resolved "https://registry.npmjs.org/create-require/-/create-require-1.1.1.tgz" @@ -507,6 +959,43 @@ deep-eql@^4.1.2: dependencies: type-detect "^4.0.0" +deep-equal@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/deep-equal/-/deep-equal-2.2.2.tgz#9b2635da569a13ba8e1cc159c2f744071b115daa" + integrity sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA== + dependencies: + array-buffer-byte-length "^1.0.0" + call-bind "^1.0.2" + es-get-iterator "^1.1.3" + get-intrinsic "^1.2.1" + is-arguments "^1.1.1" + is-array-buffer "^3.0.2" + is-date-object "^1.0.5" + is-regex "^1.1.4" + is-shared-array-buffer "^1.0.2" + isarray "^2.0.5" + object-is "^1.1.5" + object-keys "^1.1.1" + object.assign "^4.1.4" + regexp.prototype.flags "^1.5.0" + side-channel "^1.0.4" + which-boxed-primitive "^1.0.2" + which-collection "^1.0.1" + which-typed-array "^1.1.9" + +define-properties@^1.1.3, define-properties@^1.1.4, define-properties@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/define-properties/-/define-properties-1.2.0.tgz#52988570670c9eacedd8064f4a990f2405849bd5" + integrity sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA== + dependencies: + has-property-descriptors "^1.0.0" + object-keys "^1.1.1" + +defined@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/defined/-/defined-1.0.1.tgz#c0b9db27bfaffd95d6f61399419b893df0f91ebf" + integrity sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q== + diff@5.0.0: version "5.0.0" resolved "https://registry.npmjs.org/diff/-/diff-5.0.0.tgz" @@ -517,6 +1006,31 @@ diff@^4.0.1: resolved "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz" integrity sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A== +dotignore@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/dotignore/-/dotignore-0.1.2.tgz#f942f2200d28c3a76fbdd6f0ee9f3257c8a2e905" + integrity sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw== + dependencies: + minimatch "^3.0.4" + +duplexer@^0.1.1: + version "0.1.2" + resolved "https://registry.yarnpkg.com/duplexer/-/duplexer-0.1.2.tgz#3abe43aef3835f8ae077d136ddce0f276b0400e6" + integrity sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg== + +elliptic@6.5.4: + version "6.5.4" + resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.4.tgz#da37cebd31e79a1367e941b592ed1fbebd58abbb" + integrity sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ== + dependencies: + bn.js "^4.11.9" + brorand "^1.1.0" + hash.js "^1.0.0" + hmac-drbg "^1.0.1" + inherits "^2.0.4" + minimalistic-assert "^1.0.1" + minimalistic-crypto-utils "^1.0.1" + emoji-regex@^8.0.0: version "8.0.0" resolved "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz" @@ -534,6 +1048,84 @@ err-code@^3.0.1: resolved "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz" integrity sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA== +es-abstract@^1.19.0, es-abstract@^1.20.4: + version "1.22.1" + resolved "https://registry.yarnpkg.com/es-abstract/-/es-abstract-1.22.1.tgz#8b4e5fc5cefd7f1660f0f8e1a52900dfbc9d9ccc" + integrity sha512-ioRRcXMO6OFyRpyzV3kE1IIBd4WG5/kltnzdxSCqoP8CMGs/Li+M1uF5o7lOkZVFjDs+NLesthnF66Pg/0q0Lw== + dependencies: + array-buffer-byte-length "^1.0.0" + arraybuffer.prototype.slice "^1.0.1" + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + es-set-tostringtag "^2.0.1" + es-to-primitive "^1.2.1" + function.prototype.name "^1.1.5" + get-intrinsic "^1.2.1" + get-symbol-description "^1.0.0" + globalthis "^1.0.3" + gopd "^1.0.1" + has "^1.0.3" + has-property-descriptors "^1.0.0" + has-proto "^1.0.1" + has-symbols "^1.0.3" + internal-slot "^1.0.5" + is-array-buffer "^3.0.2" + is-callable "^1.2.7" + is-negative-zero "^2.0.2" + is-regex "^1.1.4" + is-shared-array-buffer "^1.0.2" + is-string "^1.0.7" + is-typed-array "^1.1.10" + is-weakref "^1.0.2" + object-inspect "^1.12.3" + object-keys "^1.1.1" + object.assign "^4.1.4" + regexp.prototype.flags "^1.5.0" + safe-array-concat "^1.0.0" + safe-regex-test "^1.0.0" + string.prototype.trim "^1.2.7" + string.prototype.trimend "^1.0.6" + string.prototype.trimstart "^1.0.6" + typed-array-buffer "^1.0.0" + typed-array-byte-length "^1.0.0" + typed-array-byte-offset "^1.0.0" + typed-array-length "^1.0.4" + unbox-primitive "^1.0.2" + which-typed-array "^1.1.10" + +es-get-iterator@^1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/es-get-iterator/-/es-get-iterator-1.1.3.tgz#3ef87523c5d464d41084b2c3c9c214f1199763d6" + integrity sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.3" + has-symbols "^1.0.3" + is-arguments "^1.1.1" + is-map "^2.0.2" + is-set "^2.0.2" + is-string "^1.0.7" + isarray "^2.0.5" + stop-iteration-iterator "^1.0.0" + +es-set-tostringtag@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz#338d502f6f674301d710b80c8592de8a15f09cd8" + integrity sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg== + dependencies: + get-intrinsic "^1.1.3" + has "^1.0.3" + has-tostringtag "^1.0.0" + +es-to-primitive@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/es-to-primitive/-/es-to-primitive-1.2.1.tgz#e55cd4c9cdc188bcefb03b366c736323fc5c898a" + integrity sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA== + dependencies: + is-callable "^1.1.4" + is-date-object "^1.0.1" + is-symbol "^1.0.2" + escalade@^3.1.1: version "3.1.1" resolved "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz" @@ -544,7 +1136,7 @@ escape-string-regexp@4.0.0: resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -escape-string-regexp@^1.0.5: +escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== @@ -559,6 +1151,42 @@ ethereum-cryptography@^1.1.2: "@scure/bip32" "1.1.5" "@scure/bip39" "1.1.1" +ethers@^5.6.5: + version "5.7.2" + resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.7.2.tgz#3a7deeabbb8c030d4126b24f84e525466145872e" + integrity sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg== + dependencies: + "@ethersproject/abi" "5.7.0" + "@ethersproject/abstract-provider" "5.7.0" + "@ethersproject/abstract-signer" "5.7.0" + "@ethersproject/address" "5.7.0" + "@ethersproject/base64" "5.7.0" + "@ethersproject/basex" "5.7.0" + "@ethersproject/bignumber" "5.7.0" + "@ethersproject/bytes" "5.7.0" + "@ethersproject/constants" "5.7.0" + "@ethersproject/contracts" "5.7.0" + "@ethersproject/hash" "5.7.0" + "@ethersproject/hdnode" "5.7.0" + "@ethersproject/json-wallets" "5.7.0" + "@ethersproject/keccak256" "5.7.0" + "@ethersproject/logger" "5.7.0" + "@ethersproject/networks" "5.7.1" + "@ethersproject/pbkdf2" "5.7.0" + "@ethersproject/properties" "5.7.0" + "@ethersproject/providers" "5.7.2" + "@ethersproject/random" "5.7.0" + "@ethersproject/rlp" "5.7.0" + "@ethersproject/sha2" "5.7.0" + "@ethersproject/signing-key" "5.7.0" + "@ethersproject/solidity" "5.7.0" + "@ethersproject/strings" "5.7.0" + "@ethersproject/transactions" "5.7.0" + "@ethersproject/units" "5.7.0" + "@ethersproject/wallet" "5.7.0" + "@ethersproject/web" "5.7.1" + "@ethersproject/wordlists" "5.7.0" + ethjs-util@^0.1.6: version "0.1.6" resolved "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz" @@ -585,6 +1213,14 @@ execa@^1.0.0: signal-exit "^3.0.0" strip-eof "^1.0.0" +figures@^1.4.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" + integrity sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ== + dependencies: + escape-string-regexp "^1.0.5" + object-assign "^4.1.0" + fill-range@^7.0.1: version "7.0.1" resolved "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" @@ -612,6 +1248,13 @@ flat@^5.0.2: resolved "https://registry.npmjs.org/flat/-/flat-5.0.2.tgz" integrity sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ== +for-each@^0.3.3: + version "0.3.3" + resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" + integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== + dependencies: + is-callable "^1.1.3" + fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" @@ -622,6 +1265,26 @@ fsevents@~2.3.2: resolved "https://registry.npmjs.org/fsevents/-/fsevents-2.3.2.tgz" integrity sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA== +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + +function.prototype.name@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.5.tgz#cce0505fe1ffb80503e6f9e46cc64e46a12a9621" + integrity sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + es-abstract "^1.19.0" + functions-have-names "^1.2.2" + +functions-have-names@^1.2.2, functions-have-names@^1.2.3: + version "1.2.3" + resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" + integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== + get-browser-rtc@^1.1.0: version "1.1.0" resolved "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz" @@ -642,6 +1305,21 @@ get-func-name@^2.0.0: resolved "https://registry.npmjs.org/get-func-name/-/get-func-name-2.0.0.tgz" integrity sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig== +get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@^1.2.0, get-intrinsic@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" + integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-proto "^1.0.1" + has-symbols "^1.0.3" + +get-package-type@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" + integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== + get-stream@^4.0.0: version "4.1.0" resolved "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz" @@ -649,6 +1327,14 @@ get-stream@^4.0.0: dependencies: pump "^3.0.0" +get-symbol-description@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.0.tgz#7fdb81c900101fbd564dd5f1a30af5aadc1e58d6" + integrity sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.1" + glob-parent@~5.1.2: version "5.1.2" resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" @@ -668,11 +1354,57 @@ glob@7.2.0: once "^1.3.0" path-is-absolute "^1.0.0" +glob@^7.2.3: + version "7.2.3" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" + integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== + 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" + +globalthis@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.3.tgz#5852882a52b80dc301b0660273e1ed082f0b6ccf" + integrity sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA== + dependencies: + define-properties "^1.1.3" + +gopd@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" + integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== + dependencies: + get-intrinsic "^1.1.3" + graceful-fs@^4.2.4: version "4.2.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== +has-ansi@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" + integrity sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg== + dependencies: + ansi-regex "^2.0.0" + +has-bigints@^1.0.1, has-bigints@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.2.tgz#0871bd3e3d51626f6ca0966668ba35d5602d6eaa" + integrity sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ== + +has-dynamic-import@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz#9bca87846aa264f2ad224fcd014946f5e5182f52" + integrity sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.1" + has-flag@^3.0.0: version "3.0.0" resolved "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz" @@ -683,6 +1415,45 @@ has-flag@^4.0.0: resolved "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz" integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== +has-property-descriptors@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz#610708600606d36961ed04c196193b6a607fa861" + integrity sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ== + dependencies: + get-intrinsic "^1.1.1" + +has-proto@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" + integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== + +has-symbols@^1.0.2, has-symbols@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" + integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== + +has-tostringtag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" + integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== + dependencies: + has-symbols "^1.0.2" + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + +hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: + version "1.1.7" + resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" + integrity sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA== + dependencies: + inherits "^2.0.3" + minimalistic-assert "^1.0.1" + he@1.2.0: version "1.2.0" resolved "https://registry.npmjs.org/he/-/he-1.2.0.tgz" @@ -693,6 +1464,15 @@ hls.js@^1.4.0: resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.4.8.tgz#6fedcb5224d7361e4f38046ffd45286d8a645df8" integrity sha512-wYL7W49M6oKv0+P4RW50YkJaxDzgnHMMrN+YoLpow07hVgaedAdX9HfKkehTb04UEfeJhNSef5ucICYPsHOfqg== +hmac-drbg@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/hmac-drbg/-/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1" + integrity sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg== + dependencies: + hash.js "^1.0.3" + minimalistic-assert "^1.0.0" + minimalistic-crypto-utils "^1.0.1" + ieee754@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz" @@ -711,16 +1491,49 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.1, inherits@^2.0.3: +inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.1, inherits@~2.0.3: version "2.0.4" resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== +internal-slot@^1.0.4, internal-slot@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/internal-slot/-/internal-slot-1.0.5.tgz#f2a2ee21f668f8627a4667f309dc0f4fb6674986" + integrity sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ== + dependencies: + get-intrinsic "^1.2.0" + has "^1.0.3" + side-channel "^1.0.4" + invert-kv@^2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz" integrity sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA== +is-arguments@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/is-arguments/-/is-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" + integrity sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: + version "3.0.2" + resolved "https://registry.yarnpkg.com/is-array-buffer/-/is-array-buffer-3.0.2.tgz#f2653ced8412081638ecb0ebbd0c41c6e0aecbbe" + integrity sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.2.0" + is-typed-array "^1.1.10" + +is-bigint@^1.0.1: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-bigint/-/is-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" + integrity sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg== + dependencies: + has-bigints "^1.0.1" + is-binary-path@~2.1.0: version "2.1.0" resolved "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz" @@ -728,11 +1541,43 @@ is-binary-path@~2.1.0: dependencies: binary-extensions "^2.0.0" +is-boolean-object@^1.1.0: + version "1.1.2" + resolved "https://registry.yarnpkg.com/is-boolean-object/-/is-boolean-object-1.1.2.tgz#5c6dc200246dd9321ae4b885a114bb1f75f63719" + integrity sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.2.7: + version "1.2.7" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" + integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== + +is-core-module@^2.9.0: + version "2.12.1" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.12.1.tgz#0c0b6885b6f80011c71541ce15c8d66cf5a4f9fd" + integrity sha512-Q4ZuBAe2FUsKtyQJoQHlvP8OvBERxO3jEmy1I7hcRXcJBGGHFh/aJBswbXuS9sgrDH2QUO8ilkwNPHvHMd8clg== + dependencies: + has "^1.0.3" + +is-date-object@^1.0.1, is-date-object@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.5.tgz#0841d5536e724c25597bf6ea62e1bd38298df31f" + integrity sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ== + dependencies: + has-tostringtag "^1.0.0" + is-extglob@^2.1.1: version "2.1.1" resolved "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== +is-finite@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.1.0.tgz#904135c77fb42c0641d6aa1bcdbc4daa8da082f3" + integrity sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w== + is-fullwidth-code-point@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" @@ -762,6 +1607,23 @@ is-hex-prefixed@1.0.0: resolved "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz" integrity sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA== +is-map@^2.0.1, is-map@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/is-map/-/is-map-2.0.2.tgz#00922db8c9bf73e81b7a335827bc2a43f2b91127" + integrity sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg== + +is-negative-zero@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.2.tgz#7bf6f03a28003b8b3965de3ac26f664d765f3150" + integrity sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA== + +is-number-object@^1.0.4: + version "1.0.7" + resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.7.tgz#59d50ada4c45251784e9904f5246c742f07a42fc" + integrity sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ== + dependencies: + has-tostringtag "^1.0.0" + is-number@^7.0.0: version "7.0.0" resolved "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz" @@ -772,6 +1634,26 @@ is-plain-obj@^2.1.0: resolved "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz" integrity sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA== +is-regex@^1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" + integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-set@^2.0.1, is-set@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/is-set/-/is-set-2.0.2.tgz#90755fa4c2562dc1c5d4024760d6119b94ca18ec" + integrity sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g== + +is-shared-array-buffer@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz#8f259c573b60b6a32d4058a1a07430c0a7344c79" + integrity sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA== + dependencies: + call-bind "^1.0.2" + is-stream@^1.1.0: version "1.1.0" resolved "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz" @@ -782,11 +1664,62 @@ is-stream@^2.0.0: resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== +is-string@^1.0.5, is-string@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" + integrity sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg== + dependencies: + has-tostringtag "^1.0.0" + +is-symbol@^1.0.2, is-symbol@^1.0.3: + version "1.0.4" + resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.4.tgz#a6dac93b635b063ca6872236de88910a57af139c" + integrity sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg== + dependencies: + has-symbols "^1.0.2" + +is-typed-array@^1.1.10, is-typed-array@^1.1.9: + version "1.1.12" + resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.12.tgz#d0bab5686ef4a76f7a73097b95470ab199c57d4a" + integrity sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg== + dependencies: + which-typed-array "^1.1.11" + is-unicode-supported@^0.1.0: version "0.1.0" resolved "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz" integrity sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw== +is-weakmap@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/is-weakmap/-/is-weakmap-2.0.1.tgz#5008b59bdc43b698201d18f62b37b2ca243e8cf2" + integrity sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA== + +is-weakref@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/is-weakref/-/is-weakref-1.0.2.tgz#9529f383a9338205e89765e0392efc2f100f06f2" + integrity sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ== + dependencies: + call-bind "^1.0.2" + +is-weakset@^2.0.1: + version "2.0.2" + resolved "https://registry.yarnpkg.com/is-weakset/-/is-weakset-2.0.2.tgz#4569d67a747a1ce5a994dfd4ef6dcea76e7c0a1d" + integrity sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.1" + +isarray@^2.0.5: + version "2.0.5" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723" + integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== + +isarray@~1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" + integrity sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ== + isexe@^2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz" @@ -797,6 +1730,11 @@ js-base64@^3.7.2: resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.5.tgz#21e24cf6b886f76d6f5f165bfcd69cc55b9e3fca" integrity sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA== +js-sha3@0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.8.0.tgz#b9b7a5da73afad7dedd0f8c463954cbde6818840" + integrity sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q== + js-yaml@4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz" @@ -891,6 +1829,11 @@ lodash.uniqby@4.5.0: lodash._baseiteratee "~4.7.0" lodash._baseuniq "~4.6.0" +lodash@^4.17.10: + version "4.17.21" + resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" + integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== + log-symbols@4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" @@ -932,11 +1875,16 @@ mimic-fn@^2.0.0: resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" integrity sha512-OqbOk5oEQeAZ8WXWydlu9HJjz9WVdEIvamMCcXmuqUYjTknH/sqsWvhQ3vgwKFRR1HpjvNBKQ37nbJgYzGqGcg== -minimalistic-assert@^1.0.0: +minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" resolved "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== +minimalistic-crypto-utils@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" + integrity sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg== + minimatch@5.0.1: version "5.0.1" resolved "https://registry.npmjs.org/minimatch/-/minimatch-5.0.1.tgz" @@ -944,13 +1892,18 @@ minimatch@5.0.1: dependencies: brace-expansion "^2.0.1" -minimatch@^3.0.4: +minimatch@^3.0.4, minimatch@^3.1.1: version "3.1.2" resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" integrity sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw== dependencies: brace-expansion "^1.1.7" +minimist@^1.2.8: + version "1.2.8" + resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.8.tgz#c1a464e7693302e082a075cee0c057741ac4772c" + integrity sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA== + mocha-typescript@^1.1.17: version "1.1.17" resolved "https://registry.npmjs.org/mocha-typescript/-/mocha-typescript-1.1.17.tgz" @@ -1042,6 +1995,39 @@ number-is-nan@^1.0.0: resolved "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" integrity sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ== +object-assign@^4.1.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" + integrity sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg== + +object-inspect@^1.12.3, object-inspect@^1.9.0: + version "1.12.3" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" + integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== + +object-is@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/object-is/-/object-is-1.1.5.tgz#b9deeaa5fc7f1846a0faecdceec138e5778f53ac" + integrity sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.3" + +object-keys@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.1.1.tgz#1c47f272df277f3b1daf061677d9c82e2322c60e" + integrity sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA== + +object.assign@^4.1.4: + version "4.1.4" + resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.1.4.tgz#9673c7c7c351ab8c4d0b516f4343ebf4dfb7799f" + integrity sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + has-symbols "^1.0.3" + object-keys "^1.1.1" + once@^1.3.0, once@^1.3.1, once@^1.4.0: version "1.4.0" resolved "https://registry.npmjs.org/once/-/once-1.4.0.tgz" @@ -1113,6 +2099,11 @@ p-try@^1.0.0: resolved "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz" integrity sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww== +parse-ms@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/parse-ms/-/parse-ms-1.0.1.tgz#56346d4749d78f23430ca0c713850aef91aa361d" + integrity sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg== + path-exists@^3.0.0: version "3.0.0" resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" @@ -1133,6 +2124,11 @@ path-key@^2.0.0, path-key@^2.0.1: resolved "https://registry.npmjs.org/path-key/-/path-key-2.0.1.tgz" integrity sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw== +path-parse@^1.0.7: + version "1.0.7" + resolved "https://registry.yarnpkg.com/path-parse/-/path-parse-1.0.7.tgz#fbc114b60ca42b30d9daf5858e4bd68bbedb6735" + integrity sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw== + pathval@^1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz" @@ -1143,6 +2139,30 @@ picomatch@^2.0.4, picomatch@^2.2.1: resolved "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== +plur@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/plur/-/plur-1.0.0.tgz#db85c6814f5e5e5a3b49efc28d604fec62975156" + integrity sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw== + +pretty-ms@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/pretty-ms/-/pretty-ms-2.1.0.tgz#4257c256df3fb0b451d6affaab021884126981dc" + integrity sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg== + dependencies: + is-finite "^1.0.1" + parse-ms "^1.0.0" + plur "^1.0.0" + +process-nextick-args@~1.0.6: + version "1.0.7" + resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-1.0.7.tgz#150e20b756590ad3f91093f25a4f2ad8bff30ba3" + integrity sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw== + +process-nextick-args@~2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" + integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== + proper-lockfile@^4.1.2: version "4.1.2" resolved "https://registry.yarnpkg.com/proper-lockfile/-/proper-lockfile-4.1.2.tgz#c8b9de2af6b2f1601067f98e01ac66baa223141f" @@ -1177,6 +2197,24 @@ randombytes@^2.1.0: dependencies: safe-buffer "^5.1.0" +re-emitter@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/re-emitter/-/re-emitter-1.1.3.tgz#fa9e319ffdeeeb35b27296ef0f3d374dac2f52a7" + integrity sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg== + +readable-stream@2.2.9: + version "2.2.9" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.2.9.tgz#cf78ec6f4a6d1eb43d26488cac97f042e74b7fc8" + integrity sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg== + dependencies: + buffer-shims "~1.0.0" + core-util-is "~1.0.0" + inherits "~2.0.1" + isarray "~1.0.0" + process-nextick-args "~1.0.6" + string_decoder "~1.0.0" + util-deprecate "~1.0.1" + readable-stream@^3.6.0: version "3.6.2" resolved "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz" @@ -1186,6 +2224,19 @@ readable-stream@^3.6.0: string_decoder "^1.1.1" util-deprecate "^1.0.1" +readable-stream@~2.3.6: + version "2.3.8" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.8.tgz#91125e8042bba1b9887f49345f6277027ce8be9b" + integrity sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA== + 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" + readdirp@~3.6.0: version "3.6.0" resolved "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" @@ -1193,6 +2244,20 @@ readdirp@~3.6.0: dependencies: picomatch "^2.2.1" +regexp.prototype.flags@^1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz#fe7ce25e7e4cca8db37b6634c8a2c7009199b9cb" + integrity sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA== + dependencies: + call-bind "^1.0.2" + define-properties "^1.2.0" + functions-have-names "^1.2.3" + +repeat-string@^1.5.2: + version "1.6.1" + resolved "https://registry.yarnpkg.com/repeat-string/-/repeat-string-1.6.1.tgz#8dcae470e1c88abc2d600fff4a776286da75e637" + integrity sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w== + require-directory@^2.1.1: version "2.1.1" resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" @@ -1208,21 +2273,59 @@ requires-port@^1.0.0: resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== +resolve@^2.0.0-next.4: + version "2.0.0-next.4" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-2.0.0-next.4.tgz#3d37a113d6429f496ec4752d2a2e58efb1fd4660" + integrity sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ== + dependencies: + is-core-module "^2.9.0" + path-parse "^1.0.7" + supports-preserve-symlinks-flag "^1.0.0" + retry@^0.12.0: version "0.12.0" resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== +safe-array-concat@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/safe-array-concat/-/safe-array-concat-1.0.0.tgz#2064223cba3c08d2ee05148eedbc563cd6d84060" + integrity sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.2.0" + has-symbols "^1.0.3" + isarray "^2.0.5" + safe-buffer@^5.1.0, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== +safe-buffer@~5.1.0, safe-buffer@~5.1.1: + version "5.1.2" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" + integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== + +safe-regex-test@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/safe-regex-test/-/safe-regex-test-1.0.0.tgz#793b874d524eb3640d1873aad03596db2d4f2295" + integrity sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.1.3" + is-regex "^1.1.4" + safer-buffer@^2.1.0: version "2.1.2" resolved "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== +scrypt-js@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-3.0.1.tgz#d314a57c2aef69d1ad98a138a21fe9eafa9ee312" + integrity sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA== + semver@^5.5.0: version "5.7.1" resolved "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz" @@ -1252,6 +2355,15 @@ shebang-regex@^1.0.0: resolved "https://registry.npmjs.org/shebang-regex/-/shebang-regex-1.0.0.tgz" integrity sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ== +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" + integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + signal-exit@^3.0.0, signal-exit@^3.0.2: version "3.0.7" resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" @@ -1270,6 +2382,20 @@ simple-peer@^9.11.1: randombytes "^2.1.0" readable-stream "^3.6.0" +split@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/split/-/split-1.0.0.tgz#c4395ce683abcd254bc28fe1dabb6e5c27dcffae" + integrity sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ== + dependencies: + through "2" + +stop-iteration-iterator@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz#6a60be0b4ee757d1ed5254858ec66b10c49285e4" + integrity sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ== + dependencies: + internal-slot "^1.0.4" + string-width@^1.0.1: version "1.0.2" resolved "https://registry.npmjs.org/string-width/-/string-width-1.0.2.tgz" @@ -1296,6 +2422,33 @@ string-width@^4.1.0, string-width@^4.2.0: is-fullwidth-code-point "^3.0.0" strip-ansi "^6.0.1" +string.prototype.trim@^1.2.7: + version "1.2.7" + resolved "https://registry.yarnpkg.com/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz#a68352740859f6893f14ce3ef1bb3037f7a90533" + integrity sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + +string.prototype.trimend@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz#c4a27fa026d979d79c04f17397f250a462944533" + integrity sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + +string.prototype.trimstart@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz#e90ab66aa8e4007d92ef591bbf3cd422c56bdcf4" + integrity sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA== + dependencies: + call-bind "^1.0.2" + define-properties "^1.1.4" + es-abstract "^1.20.4" + string_decoder@^1.1.1: version "1.3.0" resolved "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz" @@ -1303,6 +2456,20 @@ string_decoder@^1.1.1: dependencies: safe-buffer "~5.2.0" +string_decoder@~1.0.0: + version "1.0.3" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.0.3.tgz#0fc67d7c141825de94282dd536bec6b9bce860ab" + integrity sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ== + dependencies: + safe-buffer "~5.1.0" + +string_decoder@~1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" + integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== + dependencies: + safe-buffer "~5.1.0" + strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" @@ -1348,6 +2515,11 @@ supports-color@8.1.1: dependencies: has-flag "^4.0.0" +supports-color@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-2.0.0.tgz#535d045ce6b6363fa40117084629995e9df324c7" + integrity sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g== + supports-color@^5.3.0: version "5.5.0" resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" @@ -1362,6 +2534,75 @@ supports-color@^7.1.0: dependencies: has-flag "^4.0.0" +supports-preserve-symlinks-flag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09" + integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== + +tap-out@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/tap-out/-/tap-out-2.1.0.tgz#c093079a915036de8b835bfa3297f14458b15358" + integrity sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw== + dependencies: + re-emitter "1.1.3" + readable-stream "2.2.9" + split "1.0.0" + trim "0.0.1" + +tap-spec@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/tap-spec/-/tap-spec-5.0.0.tgz#7329e4e66e8aa68da2a164215abbb903a7c5d352" + integrity sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw== + dependencies: + chalk "^1.0.0" + duplexer "^0.1.1" + figures "^1.4.0" + lodash "^4.17.10" + pretty-ms "^2.1.0" + repeat-string "^1.5.2" + tap-out "^2.1.0" + through2 "^2.0.0" + +tape@^5.5.3: + version "5.6.6" + resolved "https://registry.yarnpkg.com/tape/-/tape-5.6.6.tgz#dc555729d557184764a0d61130304d21977e4ca2" + integrity sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA== + dependencies: + "@ljharb/resumer" "^0.0.1" + "@ljharb/through" "^2.3.9" + array.prototype.every "^1.1.4" + call-bind "^1.0.2" + deep-equal "^2.2.2" + defined "^1.0.1" + dotignore "^0.1.2" + for-each "^0.3.3" + get-package-type "^0.1.0" + glob "^7.2.3" + has "^1.0.3" + has-dynamic-import "^2.0.1" + inherits "^2.0.4" + is-regex "^1.1.4" + minimist "^1.2.8" + object-inspect "^1.12.3" + object-is "^1.1.5" + object-keys "^1.1.1" + object.assign "^4.1.4" + resolve "^2.0.0-next.4" + string.prototype.trim "^1.2.7" + +through2@^2.0.0: + version "2.0.5" + resolved "https://registry.yarnpkg.com/through2/-/through2-2.0.5.tgz#01c1e39eb31d07cb7d03a96a70823260b23132cd" + integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== + dependencies: + readable-stream "~2.3.6" + xtend "~4.0.1" + +through@2: + version "2.3.8" + resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" + integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== + to-regex-range@^5.0.1: version "5.0.1" resolved "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" @@ -1374,6 +2615,11 @@ tr46@~0.0.3: resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== +trim@0.0.1: + version "0.0.1" + resolved "https://registry.yarnpkg.com/trim/-/trim-0.0.1.tgz#5858547f6b290757ee95cccc666fb50084c460dd" + integrity sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ== + ts-node@^10.9.1: version "10.9.1" resolved "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz" @@ -1421,11 +2667,60 @@ type-detect@^4.0.0, type-detect@^4.0.5: resolved "https://registry.npmjs.org/type-detect/-/type-detect-4.0.8.tgz" integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== +typed-array-buffer@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz#18de3e7ed7974b0a729d3feecb94338d1472cd60" + integrity sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw== + dependencies: + call-bind "^1.0.2" + get-intrinsic "^1.2.1" + is-typed-array "^1.1.10" + +typed-array-byte-length@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz#d787a24a995711611fb2b87a4052799517b230d0" + integrity sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA== + dependencies: + call-bind "^1.0.2" + for-each "^0.3.3" + has-proto "^1.0.1" + is-typed-array "^1.1.10" + +typed-array-byte-offset@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz#cbbe89b51fdef9cd6aaf07ad4707340abbc4ea0b" + integrity sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg== + dependencies: + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + for-each "^0.3.3" + has-proto "^1.0.1" + is-typed-array "^1.1.10" + +typed-array-length@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/typed-array-length/-/typed-array-length-1.0.4.tgz#89d83785e5c4098bec72e08b319651f0eac9c1bb" + integrity sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng== + dependencies: + call-bind "^1.0.2" + for-each "^0.3.3" + is-typed-array "^1.1.9" + typescript@^5.0.2: version "5.0.2" resolved "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz" integrity sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw== +unbox-primitive@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/unbox-primitive/-/unbox-primitive-1.0.2.tgz#29032021057d5e6cdbd08c5129c226dff8ed6f9e" + integrity sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw== + dependencies: + call-bind "^1.0.2" + has-bigints "^1.0.2" + has-symbols "^1.0.3" + which-boxed-primitive "^1.0.2" + url-parse@^1.5.7: version "1.5.10" resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" @@ -1439,7 +2734,7 @@ use-sync-external-store@1.2.0: resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a" integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== -util-deprecate@^1.0.1: +util-deprecate@^1.0.1, util-deprecate@~1.0.1: version "1.0.2" resolved "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz" integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== @@ -1467,11 +2762,43 @@ whatwg-url@^5.0.0: tr46 "~0.0.3" webidl-conversions "^3.0.0" +which-boxed-primitive@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz#13757bc89b209b049fe5d86430e21cf40a89a8e6" + integrity sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg== + dependencies: + is-bigint "^1.0.1" + is-boolean-object "^1.1.0" + is-number-object "^1.0.4" + is-string "^1.0.5" + is-symbol "^1.0.3" + +which-collection@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/which-collection/-/which-collection-1.0.1.tgz#70eab71ebbbd2aefaf32f917082fc62cdcb70906" + integrity sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A== + dependencies: + is-map "^2.0.1" + is-set "^2.0.1" + is-weakmap "^2.0.1" + is-weakset "^2.0.1" + which-module@^2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" integrity sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q== +which-typed-array@^1.1.10, which-typed-array@^1.1.11, which-typed-array@^1.1.9: + version "1.1.11" + resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.11.tgz#99d691f23c72aab6768680805a271b69761ed61a" + integrity sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew== + dependencies: + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + for-each "^0.3.3" + gopd "^1.0.1" + has-tostringtag "^1.0.0" + which@^1.2.9: version "1.3.1" resolved "https://registry.npmjs.org/which/-/which-1.3.1.tgz" @@ -1506,6 +2833,16 @@ wrappy@1: resolved "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz" integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== +ws@7.4.6: + version "7.4.6" + resolved "https://registry.yarnpkg.com/ws/-/ws-7.4.6.tgz#5654ca8ecdeee47c33a9a4bf6d28e2be2980377c" + integrity sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A== + +xtend@~4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" + integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== + y18n@^3.2.1: version "3.2.2" resolved "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz" From e7a0c34a81d458867a61b39470fe5b35cd8ea99a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 2 Aug 2023 15:26:05 +0530 Subject: [PATCH 176/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.28?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index c63a3da49..a4f3ad745 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.28](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.27...restapi-0.0.1-alpha.28) (2023-08-02) + + +### Bug Fixes + +* add: scw sig verification ([#593](https://github.com/ethereum-push-notification-service/push-sdk/issues/593)) ([6768065](https://github.com/ethereum-push-notification-service/push-sdk/commit/67680657981a847e23a4dbad6d2fd6a7bc127743)) +* Merge branch 'alpha' into alpha-deployment ([6c19940](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c19940b4d72d9443b8afd06ddc2a6f9e29582a7)) +* merged main ([c5533f8](https://github.com/ethereum-push-notification-service/push-sdk/commit/c5533f8dce7b88cb1f14aa72f83579a8e01dcf36)) + + + ## [0.0.1-alpha.27](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.26...restapi-0.0.1-alpha.27) (2023-07-24) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 7a7575569..239c0ab19 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.27", + "version": "0.0.1-alpha.28", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 26b6b739d8b6b8a38ae10ae87270ca4d8782db51 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 2 Aug 2023 16:08:02 +0530 Subject: [PATCH 177/298] fix: url correction --- packages/restapi/src/lib/config.ts | 31 +++++++++++++++--------------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index f4c6775d3..c4ed49fb2 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -6,7 +6,8 @@ const { ENV } = Constants; export const API_BASE_URL = { [ENV.PROD]: 'https://backend.epns.io/apis', [ENV.STAGING]: 'https://backend-staging.epns.io/apis', - [ENV.DEV]: 'http://localhost:4000/apis', + [ENV.DEV]: 'https://backend-dev.epns.io/apis', + /** * **This is for local development only** */ @@ -23,7 +24,7 @@ const BLOCKCHAIN_NETWORK = { OPTIMISM_TESTNET: 'eip155:420', OPTIMISM_MAINNET: 'eip155:10', POLYGON_ZK_EVM_TESTNET: 'eip155:1442', - POLYGON_ZK_EVM_MAINNET: 'eip155:1101' + POLYGON_ZK_EVM_MAINNET: 'eip155:1101', }; export type ALIAS_CHAIN = 'POLYGON' | 'BSC' | 'OPTIMISM' | 'POLYGONZKEVM'; @@ -52,8 +53,8 @@ export const ALIAS_CHAIN_ID = { [ENV.STAGING]: 1442, [ENV.DEV]: 1442, [ENV.LOCAL]: 420, - } -} + }, +}; export interface ConfigType { API_BASE_URL: string; @@ -76,12 +77,12 @@ const CONFIG = { }, [BLOCKCHAIN_NETWORK.OPTIMISM_MAINNET]: { API_BASE_URL: API_BASE_URL[ENV.PROD], - EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa' + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', }, [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_MAINNET]: { API_BASE_URL: API_BASE_URL[ENV.PROD], - EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa' - } + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, }, [ENV.STAGING]: { [BLOCKCHAIN_NETWORK.ETH_GOERLI]: { @@ -98,12 +99,12 @@ const CONFIG = { }, [BLOCKCHAIN_NETWORK.OPTIMISM_TESTNET]: { API_BASE_URL: API_BASE_URL[ENV.STAGING], - EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa' + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', }, [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_TESTNET]: { API_BASE_URL: API_BASE_URL[ENV.STAGING], - EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa' - } + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, }, [ENV.DEV]: { [BLOCKCHAIN_NETWORK.ETH_GOERLI]: { @@ -120,12 +121,12 @@ const CONFIG = { }, [BLOCKCHAIN_NETWORK.OPTIMISM_TESTNET]: { API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_COMMUNICATOR_CONTRACT: '0x4305D572F2bf38Fc2AE8D0172055b1EFd18F57a6' + EPNS_COMMUNICATOR_CONTRACT: '0x4305D572F2bf38Fc2AE8D0172055b1EFd18F57a6', }, [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_TESTNET]: { API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_COMMUNICATOR_CONTRACT: '0x630b152e4185c63D7177c656b56b26f878C61572' - } + EPNS_COMMUNICATOR_CONTRACT: '0x630b152e4185c63D7177c656b56b26f878C61572', + }, }, [ENV.LOCAL]: { [BLOCKCHAIN_NETWORK.ETH_GOERLI]: { @@ -146,8 +147,8 @@ const CONFIG = { }, [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_TESTNET]: { API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_COMMUNICATOR_CONTRACT: '0x630b152e4185c63D7177c656b56b26f878C61572' - } + EPNS_COMMUNICATOR_CONTRACT: '0x630b152e4185c63D7177c656b56b26f878C61572', + }, }, }; From ed365ed1cda40d56799de5445f2582d4098d5333 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 2 Aug 2023 16:20:45 +0530 Subject: [PATCH 178/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.29?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index a4f3ad745..df79f7b15 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.29](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.28...restapi-0.0.1-alpha.29) (2023-08-02) + + +### Bug Fixes + +* url correction ([26b6b73](https://github.com/ethereum-push-notification-service/push-sdk/commit/26b6b739d8b6b8a38ae10ae87270ca4d8782db51)) + + + ## [0.0.1-alpha.28](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.27...restapi-0.0.1-alpha.28) (2023-08-02) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 239c0ab19..fa1612829 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.28", + "version": "0.0.1-alpha.29", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From e5790a2367d1b309bb51e03cae7109dcde2c61c0 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 3 Aug 2023 13:35:25 +0530 Subject: [PATCH 179/298] =?UTF-8?q?ci(socket):=20=F0=9F=8E=89=20cut=20rele?= =?UTF-8?q?ase=20to=20socket-v0.5.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/socket/CHANGELOG.md | 9 +++++++++ packages/socket/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/socket/CHANGELOG.md b/packages/socket/CHANGELOG.md index 78b0cb728..98aad4563 100644 --- a/packages/socket/CHANGELOG.md +++ b/packages/socket/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.5.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/socket-0.5.1...socket-0.5.2) (2023-08-03) + + +### Bug Fixes + +* socket options ([#601](https://github.com/ethereum-push-notification-service/push-sdk/issues/601)) ([d821535](https://github.com/ethereum-push-notification-service/push-sdk/commit/d821535d3e800c8821206fc387b346c990c02b5a)) + + + ## [0.5.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/socket-0.5.0...socket-0.5.1) (2023-05-22) diff --git a/packages/socket/package.json b/packages/socket/package.json index ff281d423..13ebf5808 100644 --- a/packages/socket/package.json +++ b/packages/socket/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/socket", - "version": "0.5.1", + "version": "0.5.2", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 3f908a02ce7faee703340e17f6441f3ebe88fd58 Mon Sep 17 00:00:00 2001 From: aman035 Date: Fri, 4 Aug 2023 13:31:22 +0530 Subject: [PATCH 180/298] fix: fixed subscribe and unsubscribe --- packages/restapi/src/lib/channels/subscribe.ts | 2 +- packages/restapi/src/lib/channels/unsubscribe.ts | 2 +- packages/restapi/src/lib/chat/helpers/crypto.ts | 3 ++- packages/restapi/src/lib/helpers/signer.ts | 5 +++-- packages/restapi/src/lib/payloads/helpers.ts | 8 +++++++- 5 files changed, 14 insertions(+), 6 deletions(-) diff --git a/packages/restapi/src/lib/channels/subscribe.ts b/packages/restapi/src/lib/channels/subscribe.ts index 9bfc4dde9..6e84984b2 100644 --- a/packages/restapi/src/lib/channels/subscribe.ts +++ b/packages/restapi/src/lib/channels/subscribe.ts @@ -69,7 +69,7 @@ export const subscribe = async ( ); // sign a message using EIP712 - const signature = await signTypedData(signer, domainInformation, typeInformation, messageInformation); + const signature = await signTypedData(signer, domainInformation, typeInformation, messageInformation, "Subscribe"); const verificationProof = signature; // might change diff --git a/packages/restapi/src/lib/channels/unsubscribe.ts b/packages/restapi/src/lib/channels/unsubscribe.ts index 839dd83b7..554fc6bf9 100644 --- a/packages/restapi/src/lib/channels/unsubscribe.ts +++ b/packages/restapi/src/lib/channels/unsubscribe.ts @@ -70,7 +70,7 @@ export const unsubscribe = async ( ); // sign a message using EIP712 - const signature = await signTypedData(signer, domainInformation, typeInformation, messageInformation); + const signature = await signTypedData(signer, domainInformation, typeInformation, messageInformation, "Unsubscribe"); const verificationProof = signature; // might change diff --git a/packages/restapi/src/lib/chat/helpers/crypto.ts b/packages/restapi/src/lib/chat/helpers/crypto.ts index 46e8dcba3..43021a45d 100644 --- a/packages/restapi/src/lib/chat/helpers/crypto.ts +++ b/packages/restapi/src/lib/chat/helpers/crypto.ts @@ -323,7 +323,8 @@ export const getEip712Signature = async ( _signer, isDomainEmpty ? {} : domain, typeInformation, - { data: hash } + { data: hash }, + 'Data' ); const verificationProof = isDomainEmpty ? `${SIG_TYPE_V2}:${signedMessage}` diff --git a/packages/restapi/src/lib/helpers/signer.ts b/packages/restapi/src/lib/helpers/signer.ts index 89cbe4fbf..bb950e9fd 100644 --- a/packages/restapi/src/lib/helpers/signer.ts +++ b/packages/restapi/src/lib/helpers/signer.ts @@ -28,7 +28,8 @@ export const signTypedData = async ( signer: SignerType, domain: any, types: any, - value: any + value: any, + primaryType: string ): Promise => { // Check the signer type using type guards if ('_signTypedData' in signer) { @@ -41,7 +42,7 @@ export const signTypedData = async ( account: signer.account, domain, types, - primaryType: 'Data', + primaryType: primaryType, message: value, }); return signature; diff --git a/packages/restapi/src/lib/payloads/helpers.ts b/packages/restapi/src/lib/payloads/helpers.ts index 6022c9996..6b7016feb 100644 --- a/packages/restapi/src/lib/payloads/helpers.ts +++ b/packages/restapi/src/lib/payloads/helpers.ts @@ -252,7 +252,13 @@ export async function getVerificationProof({ chainId: chainId, verifyingContract: verifyingContract, }; - const signature = await signTypedData(signer, domain, type, message); + const signature = await signTypedData( + signer, + domain, + type, + message, + 'Data' + ); verificationProof = `eip712v2:${signature}::uid::${uuid}`; break; } From b0dcc26f9e1e7486f674e0d7917356207dc1ec0f Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 4 Aug 2023 14:17:10 +0530 Subject: [PATCH 181/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d75bdc083..8f9a24fd2 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.4...restapi-1.4.5) (2023-08-04) + + +### Bug Fixes + +* merge main ([b9e4440](https://github.com/ethereum-push-notification-service/push-sdk/commit/b9e44408fa4c97720b12217486e8d13ef3caeb00)) + + + ## [1.4.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.3...restapi-1.4.4) (2023-07-27) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 37fd3e517..631835798 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.4", + "version": "1.4.5", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 6fc57f47d3bbee48262e072f01f6c4ffa8854d41 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 4 Aug 2023 14:26:06 +0530 Subject: [PATCH 182/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index ced9a14af..7555e7b21 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.7...uiweb-1.1.8) (2023-08-04) + + +### Bug Fixes + +* merge main ([b9e4440](https://github.com/ethereum-push-notification-service/push-sdk/commit/b9e44408fa4c97720b12217486e8d13ef3caeb00)) + + + ## [1.1.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.6...uiweb-1.1.7) (2023-07-31) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 18011909a..85147ea15 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.7", + "version": "1.1.8", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From db49939b1f5a9e0286e32ce900fbd9ef60c1534e Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Wed, 9 Aug 2023 11:01:54 +0530 Subject: [PATCH 183/298] Feat/chat components (#621) * feat: created architechture * fix: added context values (#594) * Chat dataprovider (#596) * feat: data provider for chat component * fix: replaced react.usestate to usestate * fix: added props as the initial state and changed state name * fix: reverted chat context changes and renamed values * fix: added test page for chat ui components (#597) * added chatbubble component (#602) * feat: added chatbubble component * fix: made the messageBubble's width to fit-content --------- Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> * fix: added theme * Group chat bubble (#604) * feat: moved test component to testui folder & replaced dummy data with sdk response * feat: added twitter card and address for group chat received msg * feat: made the messageaddress reusable, added account from context * fix: removed unnecessary div and unused props and console logs * feat: adding pfp in text bubbles * fix: replaced hook with function and added pfp to messagebubble * fix: fixed image alignment * fix: changed border-radius of msg bubble and changed function name * fix: fixed theme and decryptedPrivateKey name (#616) * fix: fixed theme and decryptedPrivateKey name * fix: fixed bug * fix: fixed theme reviews * Message list (#615) * fix: message list comp * fix: message list comp * fix: added pagination * fix: added pagination * fix: pagination * fix: create useChatData hook * fix: fixed minor bug * fix: socket issues fixed * fix: added theme in msgbubble (#620) * fix: added theme in msgbubble * fix: fixed import --------- Co-authored-by: Monalisha Mishra --------- Co-authored-by: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Co-authored-by: KlausMikhaelson --- .../src/app/ChatUITest/ChatUITest.tsx | 41 + .../src/app/ChatUITest/MessageBubbles.tsx | 58 + .../src/app/ChatUITest/MessageListTest.tsx | 50 + .../src/app/ChatUITest/index.ts | 0 .../src/app/ChatWidgetTest.tsx | 21 +- .../sdk-frontend-react/src/app/app.tsx | 234 +- packages/uiweb/package-lock.json | 3807 ++++++++++++++++- packages/uiweb/package.json | 7 +- .../chat/MessageBubble/MessageBubble.tsx | 319 ++ .../components/chat/MessageBubble/index.ts | 1 + .../chat/MessageList/MessageList.tsx | 190 + .../lib/components/chat/MessageList/index.ts | 1 + .../src/lib/components/chat/exportedTypes.ts | 21 + .../src/lib/components/chat/helpers/helper.ts | 2 + .../lib/components/chat/helpers/twitter.ts | 30 + .../uiweb/src/lib/components/chat/index.ts | 3 + .../components/chat/theme/ThemeProvider.tsx | 20 + .../src/lib/components/chat/theme/index.ts | 54 + .../ChatAndNotification.tsx | 14 +- .../modal/messageBox/MessageBox.tsx | 4 +- .../modal/messageBox/typebar/Typebar.tsx | 4 +- .../modal/sidebar/Sidebar.tsx | 6 +- .../sidebar/chatSidebar/ChatsFeedList.tsx | 2 +- .../sidebar/chatSidebar/RequestsFeedList.tsx | 2 +- .../InboxNotificationFeedList.tsx | 2 +- .../NotificationFeedList.tsx | 2 +- .../SpamNotificationFeedList.tsx | 2 +- packages/uiweb/src/lib/components/index.ts | 1 + packages/uiweb/src/lib/context/chatContext.ts | 52 + packages/uiweb/src/lib/context/index.ts | 2 + .../lib/dataProviders/ChatDataProvider.tsx | 81 + packages/uiweb/src/lib/dataProviders/index.ts | 3 +- packages/uiweb/src/lib/helpers/chat/chat.ts | 34 +- .../src/lib/helpers/chat/localStorage.ts | 58 +- packages/uiweb/src/lib/hooks/chat/index.ts | 11 +- .../uiweb/src/lib/hooks/chat/useChatData.ts | 11 + .../lib/hooks/chat/useFetchHistoryMessages.ts | 41 +- .../src/lib/hooks/chat/usePushChatSocket.ts | 134 + .../hooks/chatAndNotification/chat/index.ts | 8 + .../chat/useApproveChatRequest.ts | 2 +- .../chat/useFetchChat.ts | 4 +- .../chat/useFetchChats.ts | 10 +- .../chat/useFetchConversationHash.ts | 4 +- .../chat/useFetchHistoryMessages.ts | 70 + .../chat/useFetchRequests.ts | 8 +- .../chat/useIsInViewport.ts | 0 .../chat/usePushSendMessage.ts | 6 +- .../lib/hooks/chatAndNotification/index.ts | 4 +- .../notifications/index.ts | 0 .../notifications/useFetchNotification.ts | 6 +- .../useFetchUserSubscriptions.ts | 6 +- .../notifications/useOnSubscribeToChannel.ts | 4 +- .../useChatNotificationSocket.ts | 33 +- packages/uiweb/src/lib/hooks/exportedHooks.ts | 2 + packages/uiweb/src/lib/hooks/index.ts | 4 +- .../lib/hooks/{chat => }/useGetChatProfile.ts | 2 +- packages/uiweb/src/lib/index.ts | 2 + packages/uiweb/src/lib/types/index.ts | 7 +- packages/uiweb/yarn.lock | 1639 ++----- 59 files changed, 5450 insertions(+), 1696 deletions(-) create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx create mode 100644 packages/uiweb/src/lib/components/chat/MessageBubble/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx create mode 100644 packages/uiweb/src/lib/components/chat/MessageList/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/exportedTypes.ts create mode 100644 packages/uiweb/src/lib/components/chat/helpers/helper.ts create mode 100644 packages/uiweb/src/lib/components/chat/helpers/twitter.ts create mode 100644 packages/uiweb/src/lib/components/chat/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx create mode 100644 packages/uiweb/src/lib/components/chat/theme/index.ts create mode 100644 packages/uiweb/src/lib/context/chatContext.ts create mode 100644 packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx create mode 100644 packages/uiweb/src/lib/hooks/chat/useChatData.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts create mode 100644 packages/uiweb/src/lib/hooks/chatAndNotification/chat/index.ts rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/useApproveChatRequest.ts (94%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/useFetchChat.ts (91%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/useFetchChats.ts (87%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/useFetchConversationHash.ts (90%) create mode 100644 packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/useFetchRequests.ts (87%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/useIsInViewport.ts (100%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/chat/usePushSendMessage.ts (94%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/notifications/index.ts (100%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/notifications/useFetchNotification.ts (87%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/notifications/useFetchUserSubscriptions.ts (89%) rename packages/uiweb/src/lib/hooks/{ => chatAndNotification}/notifications/useOnSubscribeToChannel.ts (94%) create mode 100644 packages/uiweb/src/lib/hooks/exportedHooks.ts rename packages/uiweb/src/lib/hooks/{chat => }/useGetChatProfile.ts (91%) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx new file mode 100644 index 000000000..936f67a76 --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx @@ -0,0 +1,41 @@ +import { useState } from 'react'; +import styled from 'styled-components'; +import { Link } from 'react-router-dom'; +import { Section } from '../components/StyledComponents'; +import Loader from '../components/Loader'; + +const ChatUITest = () => { + const [isLoading, setIsLoading] = useState(false); + + const NavMenu = styled.div` + display: flex; + flex-wrap: wrap; + gap: 30px; + justify-content: center; + + @media only screen and (max-width: 900px) { + flex-direction: column; + } + `; + + return ( +
+

Chat UI Test page

+ + + +
+ + + CHAT BUBBLE + + + MESSAGE LIST + + +
+
+ ); +}; + +export default ChatUITest; diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx new file mode 100644 index 000000000..d3f70a954 --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx @@ -0,0 +1,58 @@ +import { MessageBubble } from "@pushprotocol/uiweb"; +import { useEffect, useContext, useState } from "react"; +import { EnvContext, Web3Context } from "../context"; +import * as PUSHAPI from "@pushprotocol/restapi" +import { ENV } from "@pushprotocol/uiweb"; +import { IMessagePayload } from "@pushprotocol/uiweb"; + +export const MessageBubbles = () => { + const { env } = useContext(EnvContext); + + const { library, account } = useContext(Web3Context) + const [message, setMessage] = useState([]) + const [ conversationHash , setConversationHash] = useState(''); + + const librarySigner = library.getSigner() + + const fetchMessage = async () => { + const user = await PUSHAPI.user.get({ + account: account + }) + const pgpPrivateKey = await PUSHAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: librarySigner, + env: env + }) + + const ConversationHash = await PUSHAPI.chat.conversationHash({ + account: `eip155:${account}`, + conversationId: '24b029b8e07e60291bf9d8c0c48ff993fa1e0a99105459f7404c425c92e91bac', + env: env + }); + setConversationHash(ConversationHash.threadHash); + if(ConversationHash?.threadHash){ + const chatHistory = await PUSHAPI.chat.history({ + threadhash: conversationHash, + account: account, + limit: 10, + toDecrypt: true, + pgpPrivateKey: pgpPrivateKey ? pgpPrivateKey : undefined, + env: env + }) + setMessage(chatHistory) + console.log(chatHistory) + } + } + + useEffect(() => { + fetchMessage() + }, []) + + return ( +
+ {message.map((msg) => ( + + ))} +
+ ) +} diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx new file mode 100644 index 000000000..27cf0844c --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx @@ -0,0 +1,50 @@ +import { useContext, useEffect, useState } from 'react'; +import styled from 'styled-components'; +import * as PUSHAPI from '@pushprotocol/restapi'; +import { Link } from 'react-router-dom'; +import { Section } from '../components/StyledComponents'; +import { MessageList } from '@pushprotocol/uiweb'; +import { EnvContext, Web3Context } from '../context'; +import { usePushChatSocket } from '@pushprotocol/uiweb'; + +const MessageListTest = () => { + const { account } = useContext(Web3Context) + + const { env } = useContext(EnvContext); + const [ conversationHash , setConversationHash] = useState(''); + + const fetchConversationHash = async() =>{ + const ConversationHash = await PUSHAPI.chat.conversationHash({ + account: `eip155:${account}`, + conversationId: '24b029b8e07e60291bf9d8c0c48ff993fa1e0a99105459f7404c425c92e91bac', + env: env + }); + setConversationHash(ConversationHash.threadHash); + } +console.log(conversationHash) + useEffect(()=>{ + fetchConversationHash(); + }) + + usePushChatSocket(); + return ( +
+

Chat UI Test page

+ + {/* */} + + + + + + +
+ ); +}; + +export default MessageListTest; + + +const MessageListCard = styled(Section)` +height:40vh; +`; \ No newline at end of file diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/index.ts b/packages/examples/sdk-frontend-react/src/app/ChatUITest/index.ts new file mode 100644 index 000000000..e69de29bb diff --git a/packages/examples/sdk-frontend-react/src/app/ChatWidgetTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatWidgetTest.tsx index 4835849db..b863968ca 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatWidgetTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatWidgetTest.tsx @@ -30,14 +30,19 @@ export const ChatWidgetTest = () => { console.log('in here widget'); }; + return ( - + + <> + + + ); }; diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index 4bffced3a..a025e4f7f 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -69,7 +69,16 @@ import { import { useSpaceComponents } from './SpaceUITest/useSpaceComponents'; import * as PushAPI from '@pushprotocol/restapi'; import { ChatWidgetTest } from './ChatWidgetTest'; -import { SpacesUI, SpacesUIProvider } from '@pushprotocol/uiweb'; +import { + CHAT_THEME_OPTIONS, + ChatUIProvider, + SpacesUI, + SpacesUIProvider, +} from '@pushprotocol/uiweb'; +import ChatUITest from './ChatUITest/ChatUITest'; +import MessageListTest from './ChatUITest/MessageListTest'; +import { MessageBubbles } from './ChatUITest/MessageBubbles'; +import { ChatThemeOptions } from '@pushprotocol/uiweb'; window.Buffer = window.Buffer || Buffer; @@ -294,6 +303,7 @@ export function App() { + CHAT + + CHAT UI + SPACE @@ -345,103 +358,115 @@ export function App() { element={} /> - } /> - - } /> - - } /> - - } /> - - } /> - - } /> - - } /> - } /> - - } /> - - {/* chat method routes */} - } /> - } - /> - } /> - } - /> - } - /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } /> - } - /> - } - /> - } - /> - } - /> - } /> - - {/* spaces method routes */} - } /> - } /> - } /> - } - /> - } - /> - } /> - } /> - } - /> - } - /> - } - /> - } - /> - } /> - } - /> - } - /> + } /> + + } /> + + } /> + + } /> + + } /> + + } /> + + } /> + } /> + } /> + } /> + + {/* chat method routes */} + } /> + } + /> + } /> + } + /> + } + /> + } /> + } /> + } /> + } /> + } /> + } /> + } + /> + } /> + } + /> + } + /> + } + /> + } + /> + } + /> + + {/* spaces method routes */} + } + /> + } + /> + } /> + } + /> + } + /> + } /> + } /> + } + /> + } + /> + } + /> + } + /> + } /> + } + /> + } + /> {/* spaces ui components routes */} } /> @@ -455,11 +480,22 @@ export function App() { path="createSpaceUI" element={} /> + + {/* chat ui components routes */} + } + /> + } + /> {/* */} - + {/* */} + diff --git a/packages/uiweb/package-lock.json b/packages/uiweb/package-lock.json index 764f96b37..a204cad1a 100644 --- a/packages/uiweb/package-lock.json +++ b/packages/uiweb/package-lock.json @@ -1,215 +1,3870 @@ { "name": "@pushprotocol/uiweb", - "version": "1.0.2", - "lockfileVersion": 1, + "version": "1.1.4", + "lockfileVersion": 3, "requires": true, - "dependencies": { - "@babel/runtime": { + "packages": { + "": { + "name": "@pushprotocol/uiweb", + "version": "1.1.4", + "dependencies": { + "@livepeer/react": "^2.6.0", + "@pushprotocol/socket": "^0.5.0", + "@unstoppabledomains/resolution": "^8.5.0", + "date-fns": "^2.28.0", + "emoji-picker-react": "^4.4.9", + "font-awesome": "^4.7.0", + "gif-picker-react": "^1.1.0", + "html-react-parser": "^1.4.13", + "moment": "^2.29.4", + "react-twitter-embed": "^4.0.4" + }, + "peerDependencies": { + "@pushprotocol/restapi": "^1.2.15", + "@pushprotocol/socket": "^0.5.0", + "react": ">=16.8.0", + "styled-components": "^5.3.5" + } + }, + "node_modules/@ampproject/remapping": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/@ampproject/remapping/-/remapping-2.2.1.tgz", + "integrity": "sha512-lFMjJTrFL3j7L9yBxwYfCq2k6qqwHyzuUl/XBnif78PWTJYyL/dfowQHWE3sp6U6ZzqWiiIZnpTMO96zhkjwtg==", + "peer": true, + "dependencies": { + "@jridgewell/gen-mapping": "^0.3.0", + "@jridgewell/trace-mapping": "^0.3.9" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.22.5.tgz", + "integrity": "sha512-Xmwn266vad+6DAqEB2A6V/CcZVp62BbwVmcOJc2RPuwih1kw02TjQvWVWlcKGbBPd+8/0V5DEkOcizRGYsspYQ==", + "peer": true, + "dependencies": { + "@babel/highlight": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/compat-data": { + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/compat-data/-/compat-data-7.22.9.tgz", + "integrity": "sha512-5UamI7xkUcJ3i9qVDS+KFDEK8/7oJ55/sJMB1Ge7IEapr7KfdfV/HErR+koZwOfd+SgtFKOKRhRakdg++DcJpQ==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/core": { + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/core/-/core-7.22.9.tgz", + "integrity": "sha512-G2EgeufBcYw27U4hhoIwFcgc1XU7TlXJ3mv04oOv1WCuo900U/anZSPzEqNjwdjgffkk2Gs0AN0dW1CKVLcG7w==", + "peer": true, + "dependencies": { + "@ampproject/remapping": "^2.2.0", + "@babel/code-frame": "^7.22.5", + "@babel/generator": "^7.22.9", + "@babel/helper-compilation-targets": "^7.22.9", + "@babel/helper-module-transforms": "^7.22.9", + "@babel/helpers": "^7.22.6", + "@babel/parser": "^7.22.7", + "@babel/template": "^7.22.5", + "@babel/traverse": "^7.22.8", + "@babel/types": "^7.22.5", + "convert-source-map": "^1.7.0", + "debug": "^4.1.0", + "gensync": "^1.0.0-beta.2", + "json5": "^2.2.2", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/babel" + } + }, + "node_modules/@babel/generator": { + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/generator/-/generator-7.22.9.tgz", + "integrity": "sha512-KtLMbmicyuK2Ak/FTCJVbDnkN1SlT8/kceFTiuDiiRUUSMnHMidxSCdG4ndkTOHHpoomWe/4xkvHkEOncwjYIw==", + "peer": true, + "dependencies": { + "@babel/types": "^7.22.5", + "@jridgewell/gen-mapping": "^0.3.2", + "@jridgewell/trace-mapping": "^0.3.17", + "jsesc": "^2.5.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-annotate-as-pure": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-annotate-as-pure/-/helper-annotate-as-pure-7.22.5.tgz", + "integrity": "sha512-LvBTxu8bQSQkcyKOU+a1btnNFQ1dMAd0R6PyW3arXes06F6QLWLIrd681bxRPIXlrMGR3XYnW9JyML7dP3qgxg==", + "peer": true, + "dependencies": { + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-compilation-targets": { + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/helper-compilation-targets/-/helper-compilation-targets-7.22.9.tgz", + "integrity": "sha512-7qYrNM6HjpnPHJbopxmb8hSPoZ0gsX8IvUS32JGVoy+pU9e5N0nLr1VjJoR6kA4d9dmGLxNYOjeB8sUDal2WMw==", + "peer": true, + "dependencies": { + "@babel/compat-data": "^7.22.9", + "@babel/helper-validator-option": "^7.22.5", + "browserslist": "^4.21.9", + "lru-cache": "^5.1.1", + "semver": "^6.3.1" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-environment-visitor": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-environment-visitor/-/helper-environment-visitor-7.22.5.tgz", + "integrity": "sha512-XGmhECfVA/5sAt+H+xpSg0mfrHq6FzNr9Oxh7PSEBBRUb/mL7Kz3NICXb194rCqAEdxkhPT1a88teizAFyvk8Q==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-function-name": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-function-name/-/helper-function-name-7.22.5.tgz", + "integrity": "sha512-wtHSq6jMRE3uF2otvfuD3DIvVhOsSNshQl0Qrd7qC9oQJzHvOL4qQXlQn2916+CXGywIjpGuIkoyZRRxHPiNQQ==", + "peer": true, + "dependencies": { + "@babel/template": "^7.22.5", + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-hoist-variables": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-hoist-variables/-/helper-hoist-variables-7.22.5.tgz", + "integrity": "sha512-wGjk9QZVzvknA6yKIUURb8zY3grXCcOZt+/7Wcy8O2uctxhplmUPkOdlgoNhmdVee2c92JXbf1xpMtVNbfoxRw==", + "peer": true, + "dependencies": { + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-imports": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-module-imports/-/helper-module-imports-7.22.5.tgz", + "integrity": "sha512-8Dl6+HD/cKifutF5qGd/8ZJi84QeAKh+CEe1sBzz8UayBBGg1dAIJrdHOcOM5b2MpzWL2yuotJTtGjETq0qjXg==", + "peer": true, + "dependencies": { + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-module-transforms": { + "version": "7.22.9", + "resolved": "https://registry.npmjs.org/@babel/helper-module-transforms/-/helper-module-transforms-7.22.9.tgz", + "integrity": "sha512-t+WA2Xn5K+rTeGtC8jCsdAH52bjggG5TKRuRrAGNM/mjIbO4GxvlLMFOEz9wXY5I2XQ60PMFsAG2WIcG82dQMQ==", + "peer": true, + "dependencies": { + "@babel/helper-environment-visitor": "^7.22.5", + "@babel/helper-module-imports": "^7.22.5", + "@babel/helper-simple-access": "^7.22.5", + "@babel/helper-split-export-declaration": "^7.22.6", + "@babel/helper-validator-identifier": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0" + } + }, + "node_modules/@babel/helper-plugin-utils": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-plugin-utils/-/helper-plugin-utils-7.22.5.tgz", + "integrity": "sha512-uLls06UVKgFG9QD4OeFYLEGteMIAa5kpTPcFL28yuCIIzsf6ZyKZMllKVOCZFhiZ5ptnwX4mtKdWCBE/uT4amg==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-simple-access": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-simple-access/-/helper-simple-access-7.22.5.tgz", + "integrity": "sha512-n0H99E/K+Bika3++WNL17POvo4rKWZ7lZEp1Q+fStVbUi8nxPQEBOlTmCOxW/0JsS56SKKQ+ojAe2pHKJHN35w==", + "peer": true, + "dependencies": { + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-split-export-declaration": { + "version": "7.22.6", + "resolved": "https://registry.npmjs.org/@babel/helper-split-export-declaration/-/helper-split-export-declaration-7.22.6.tgz", + "integrity": "sha512-AsUnxuLhRYsisFiaJwvp1QF+I3KjD5FOxut14q/GzovUe6orHLesW2C7d754kRm53h5gqrz6sFl6sxc4BVtE/g==", + "peer": true, + "dependencies": { + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-string-parser": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz", + "integrity": "sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.5.tgz", + "integrity": "sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-option": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-option/-/helper-validator-option-7.22.5.tgz", + "integrity": "sha512-R3oB6xlIVKUnxNUxbmgq7pKjxpru24zlimpE8WK47fACIlM0II/Hm1RS8IaOI7NgCr6LNS+jl5l75m20npAziw==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helpers": { + "version": "7.22.6", + "resolved": "https://registry.npmjs.org/@babel/helpers/-/helpers-7.22.6.tgz", + "integrity": "sha512-YjDs6y/fVOYFV8hAf1rxd1QvR9wJe1pDBZ2AREKq/SDayfPzgk0PBnVuTCE5X1acEpMMNOVUqoe+OwiZGJ+OaA==", + "peer": true, + "dependencies": { + "@babel/template": "^7.22.5", + "@babel/traverse": "^7.22.6", + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/highlight": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/highlight/-/highlight-7.22.5.tgz", + "integrity": "sha512-BSKlD1hgnedS5XRnGOljZawtag7H1yPfQp0tdNJCHoH6AZ+Pcm9VvkrK59/Yy593Ypg0zMxH2BxD1VPYUQ7UIw==", + "peer": true, + "dependencies": { + "@babel/helper-validator-identifier": "^7.22.5", + "chalk": "^2.0.0", + "js-tokens": "^4.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/parser": { + "version": "7.22.7", + "resolved": "https://registry.npmjs.org/@babel/parser/-/parser-7.22.7.tgz", + "integrity": "sha512-7NF8pOkHP5o2vpmGgNGcfAeCvOYhGLyA3Z4eBQkT1RJlWu47n63bCs93QfJ2hIAFCil7L5P2IWhs1oToVgrL0Q==", + "peer": true, + "bin": { + "parser": "bin/babel-parser.js" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@babel/plugin-syntax-jsx": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/plugin-syntax-jsx/-/plugin-syntax-jsx-7.22.5.tgz", + "integrity": "sha512-gvyP4hZrgrs/wWMaocvxZ44Hw0b3W8Pe+cMxc8V1ULQ07oh8VNbIRaoD1LRZVTvD+0nieDKjfgKg89sD7rrKrg==", + "peer": true, + "dependencies": { + "@babel/helper-plugin-utils": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + }, + "peerDependencies": { + "@babel/core": "^7.0.0-0" + } + }, + "node_modules/@babel/runtime": { "version": "7.21.5", "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.21.5.tgz", "integrity": "sha512-8jI69toZqqcsnqGGqwGS4Qb1VwLOEp4hz+CXPywcvjs60u3B4Pom/U/7rm4W8tMOYEB+E9wgD0mW1l3r8qlI9Q==", - "requires": { + "dependencies": { "regenerator-runtime": "^0.13.11" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/template": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/template/-/template-7.22.5.tgz", + "integrity": "sha512-X7yV7eiwAxdj9k94NEylvbVHLiVG1nvzCV2EAowhxLTwODV1jl9UzZ48leOC0sH7OnuHrIkllaBgneUykIcZaw==", + "peer": true, + "dependencies": { + "@babel/code-frame": "^7.22.5", + "@babel/parser": "^7.22.5", + "@babel/types": "^7.22.5" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/traverse": { + "version": "7.22.8", + "resolved": "https://registry.npmjs.org/@babel/traverse/-/traverse-7.22.8.tgz", + "integrity": "sha512-y6LPR+wpM2I3qJrsheCTwhIinzkETbplIgPBbwvqPKc+uljeA5gP+3nP8irdYt1mjQaDnlIcG+dw8OjAco4GXw==", + "peer": true, + "dependencies": { + "@babel/code-frame": "^7.22.5", + "@babel/generator": "^7.22.7", + "@babel/helper-environment-visitor": "^7.22.5", + "@babel/helper-function-name": "^7.22.5", + "@babel/helper-hoist-variables": "^7.22.5", + "@babel/helper-split-export-declaration": "^7.22.6", + "@babel/parser": "^7.22.7", + "@babel/types": "^7.22.5", + "debug": "^4.1.0", + "globals": "^11.1.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/types": { + "version": "7.22.5", + "resolved": "https://registry.npmjs.org/@babel/types/-/types-7.22.5.tgz", + "integrity": "sha512-zo3MIHGOkPOfoRXitsgHLjEXmlDaD/5KU1Uzuc9GNiZPhSqVxVRtxuPaSBZDsYZ9qV88AjtMtWW7ww98loJ9KA==", + "peer": true, + "dependencies": { + "@babel/helper-string-parser": "^7.22.5", + "@babel/helper-validator-identifier": "^7.22.5", + "to-fast-properties": "^2.0.0" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@emotion/is-prop-valid": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@emotion/is-prop-valid/-/is-prop-valid-1.2.1.tgz", + "integrity": "sha512-61Mf7Ufx4aDxx1xlDeOm8aFFigGHE4z+0sKCa+IHCeZKiyP9RLD0Mmx7m8b9/Cf37f7NAvQOOJAbQQGVr5uERw==", + "peer": true, + "dependencies": { + "@emotion/memoize": "^0.8.1" + } + }, + "node_modules/@emotion/memoize": { + "version": "0.8.1", + "resolved": "https://registry.npmjs.org/@emotion/memoize/-/memoize-0.8.1.tgz", + "integrity": "sha512-W2P2c/VRW1/1tLox0mVUalvnWXxavmv/Oum2aPsRcoDJuob75FC3Y8FbpfLwUegRcxINtGUMPq0tFCvYNTBXNA==", + "peer": true + }, + "node_modules/@emotion/stylis": { + "version": "0.8.5", + "resolved": "https://registry.npmjs.org/@emotion/stylis/-/stylis-0.8.5.tgz", + "integrity": "sha512-h6KtPihKFn3T9fuIrwvXXUOwlx3rfUvfZIcP5a6rh8Y7zjE3O06hT5Ss4S/YI1AYhuZ1kjaE/5EaOOI2NqSylQ==", + "peer": true + }, + "node_modules/@emotion/unitless": { + "version": "0.7.5", + "resolved": "https://registry.npmjs.org/@emotion/unitless/-/unitless-0.7.5.tgz", + "integrity": "sha512-OWORNpfjMsSSUBVrRBVGECkhWcULOAJz9ZW8uK9qgxD+87M7jHRcvh/A96XXNhXTLmKcoYSQtBEX7lHMO7YRwg==", + "peer": true + }, + "node_modules/@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==", + "peer": true, + "bin": { + "rlp": "bin/rlp" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "peer": true, + "dependencies": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "node_modules/@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "node_modules/@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + } + }, + "node_modules/@ethersproject/bignumber/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "node_modules/@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "node_modules/@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "node_modules/@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "node_modules/@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ] + }, + "node_modules/@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "node_modules/@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "node_modules/@ethersproject/providers/node_modules/ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "peer": true, + "engines": { + "node": ">=8.3.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "node_modules/@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@floating-ui/core": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/@floating-ui/core/-/core-1.4.1.tgz", + "integrity": "sha512-jk3WqquEJRlcyu7997NtR5PibI+y5bi+LS3hPmguVClypenMsCY3CBa3LAQnozRCtCrYWSEtAdiskpamuJRFOQ==", + "dependencies": { + "@floating-ui/utils": "^0.1.1" + } + }, + "node_modules/@floating-ui/dom": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.5.1.tgz", + "integrity": "sha512-KwvVcPSXg6mQygvA1TjbN/gh///36kKtllIF8SUm0qpFj8+rvYrpvlYdL1JoA71SHpDqgSSdGOSoQ0Mp3uY5aw==", + "dependencies": { + "@floating-ui/core": "^1.4.1", + "@floating-ui/utils": "^0.1.1" + } + }, + "node_modules/@floating-ui/react-dom": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/@floating-ui/react-dom/-/react-dom-2.0.1.tgz", + "integrity": "sha512-rZtAmSht4Lry6gdhAJDrCp/6rKN7++JnL1/Anbr/DdeyYXQPxvg/ivrbYvJulbRf4vL8b212suwMM2lxbv+RQA==", + "dependencies": { + "@floating-ui/dom": "^1.3.0" + }, + "peerDependencies": { + "react": ">=16.8.0", + "react-dom": ">=16.8.0" + } + }, + "node_modules/@floating-ui/utils": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.1.1.tgz", + "integrity": "sha512-m0G6wlnhm/AX0H12IOWtK8gASEMffnX08RtKkCgTdHb9JpHKGloI7icFfLg9ZmQeavcvR0PKmzxClyuFPSjKWw==" + }, + "node_modules/@jridgewell/gen-mapping": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/@jridgewell/gen-mapping/-/gen-mapping-0.3.3.tgz", + "integrity": "sha512-HLhSWOLRi875zjjMG/r+Nv0oCW8umGb0BgEhyX3dDX3egwZtB8PqLnjz3yedt8R5StBrzcg4aBpnh8UA9D1BoQ==", + "peer": true, + "dependencies": { + "@jridgewell/set-array": "^1.0.1", + "@jridgewell/sourcemap-codec": "^1.4.10", + "@jridgewell/trace-mapping": "^0.3.9" + }, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/resolve-uri": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", + "integrity": "sha512-F2msla3tad+Mfht5cJq7LSXcdudKTWCVYUgw6pLFOOHSTtZlj6SWNYAp+AhuqLmWdBO2X5hPrLcu8cVP8fy28w==", + "peer": true, + "engines": { + "node": ">=6.0.0" + } + }, + "node_modules/@jridgewell/set-array": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@jridgewell/set-array/-/set-array-1.1.2.tgz", + "integrity": "sha512-xnkseuNADM0gt2bs+BvhO0p78Mk762YnZdsuzFV018NoG1Sj1SCQvpSqa7XUaTam5vAGasABV9qXASMKnFMwMw==", + "peer": true, + "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==", + "peer": true + }, + "node_modules/@jridgewell/trace-mapping": { + "version": "0.3.18", + "resolved": "https://registry.npmjs.org/@jridgewell/trace-mapping/-/trace-mapping-0.3.18.tgz", + "integrity": "sha512-w+niJYzMHdd7USdiH2U6869nqhD2nbfZXND5Yp93qIbEmnDNk7PD48o+YchRVpzMU7M6jVCbenTR7PA1FLQ9pA==", + "peer": true, + "dependencies": { + "@jridgewell/resolve-uri": "3.1.0", + "@jridgewell/sourcemap-codec": "1.4.14" + } + }, + "node_modules/@jridgewell/trace-mapping/node_modules/@jridgewell/sourcemap-codec": { + "version": "1.4.14", + "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.4.14.tgz", + "integrity": "sha512-XPSJHWmi394fuUuzDnGz1wiKqWfo1yXecHQMRf2l6hztTO+nPru658AyDngaBe7isIxEkRsPR3FZh+s7iVa4Uw==", + "peer": true + }, + "node_modules/@livepeer/core": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.0.tgz", + "integrity": "sha512-Sr+DplfGfhpv2Arh53tTTL9DyPEzlVAzy+eXd8+PMIlXLVOHTgGfDgpfpaeSCB8v8WlJtrgX50vFdSWyUyxi3g==", + "dependencies": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/@livepeer/core-react": { + "version": "1.8.0", + "resolved": "https://registry.npmjs.org/@livepeer/core-react/-/core-react-1.8.0.tgz", + "integrity": "sha512-DRciHEJgpALO2a9gHAy75g9VpaU6yszALP/gatO3W/+x9/o6MSR5PRhFg5eMDJA8o1ua39ZlaDu0/irLHIeE8g==", + "dependencies": { + "@livepeer/core": "^1.8.0", + "@tanstack/query-async-storage-persister": "4.29.23", + "@tanstack/query-core": "4.29.23", + "@tanstack/react-query": "4.29.23", + "@tanstack/react-query-persist-client": "4.29.23", + "use-sync-external-store": "^1.2.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + } + }, + "node_modules/@livepeer/core/node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, + "node_modules/@livepeer/react": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/@livepeer/react/-/react-2.8.0.tgz", + "integrity": "sha512-ttQ6ggndZaGUboMHZxHS5NMMTBjZdn+SbXroMFo+Z+jiAB5TQCklYQXgsYazTE4GxtGePOLU0LndoJ0viDAJEw==", + "dependencies": { + "@livepeer/core-react": "^1.8.0", + "@radix-ui/react-dialog": "^1.0.4", + "@radix-ui/react-popover": "^1.0.6", + "@radix-ui/react-select": "^1.2.2", + "@stitches/react": "^1.2.8", + "core-js": "^3.31.1", + "livepeer": "2.8.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0", + "react-dom": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react-dom": { + "optional": true + } + } + }, + "node_modules/@livepeer/webrtmp-sdk": { + "version": "0.2.3", + "resolved": "https://registry.npmjs.org/@livepeer/webrtmp-sdk/-/webrtmp-sdk-0.2.3.tgz", + "integrity": "sha512-tJ2gGhUZfbeXmIkZHxY/WNS0C9SYUhJ/6QlYhot1CJlBuXkuoki9gSGhYhS3G7Vu/HchL1HU/DXWKhrQhlogXg==", + "peer": true, + "dependencies": { + "events": "3.3.0" + } + }, + "node_modules/@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "peer": true, + "dependencies": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "peer": true, + "dependencies": { + "@noble/hashes": "1.3.1" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==", + "peer": true, + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@pushprotocol/restapi": { + "version": "1.4.4", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.4.tgz", + "integrity": "sha512-Zjo91cyW3wPI0ingVUFvimYnO6H2PqEqtGftdBbr5HxZU9cwW71BqdVugUk6+luRGPvAurTQb1YiGJb2JHjpOQ==", + "peer": true, + "dependencies": { + "@livepeer/webrtmp-sdk": "^0.2.3", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@pushprotocol/socket": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz", + "integrity": "sha512-b6hzyUIMunmf2hLeTqTtJFvDG1Ngm+Rho00Z0mod+3khSOKy1Kwgpcpmj9bISLgr0ymeFqMYqNPj9+X89EAMZA==", + "dependencies": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@radix-ui/number": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/number/-/number-1.0.1.tgz", + "integrity": "sha512-T5gIdVO2mmPW3NNhjNgEP3cqMXjXL9UbO0BzWcXfvdBs+BohbQxvd/K5hSVKmn9/lbTdsQVKbUcP5WLCwvUbBg==", + "dependencies": { + "@babel/runtime": "^7.13.10" + } + }, + "node_modules/@radix-ui/primitive": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.0.1.tgz", + "integrity": "sha512-yQ8oGX2GVsEYMWGxcovu1uGWPCxV5BFfeeYxqPmuAzUyLT9qmaMXSAhXpb0WrspIeqYzdJpkh2vHModJPgRIaw==", + "dependencies": { + "@babel/runtime": "^7.13.10" + } + }, + "node_modules/@radix-ui/react-arrow": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-arrow/-/react-arrow-1.0.3.tgz", + "integrity": "sha512-wSP+pHsB/jQRaL6voubsQ/ZlrGBHHrOjmBnr19hxYgtS0WvAFwZhK2WP/YY5yF9uKECCEEDGxuLxq1NBK51wFA==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-primitive": "1.0.3" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-collection": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-collection/-/react-collection-1.0.3.tgz", + "integrity": "sha512-3SzW+0PW7yBBoQlT8wNcGtaxaD0XSu0uLUFgrtHY08Acx05TaHaOmVLR73c0j/cqpDy53KBMO7s0dx2wmOIDIA==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-context": "1.0.1", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-slot": "1.0.2" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-compose-refs": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.1.tgz", + "integrity": "sha512-fDSBgd44FKHa1FRMU59qBMPFcl2PZE+2nmqunj+BWFyYYjnhIDWL2ItDs3rrbJDQOtzt5nIebLCQc4QRfz6LJw==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-context": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.0.1.tgz", + "integrity": "sha512-ebbrdFoYTcuZ0v4wG5tedGnp9tzcV8awzsxYph7gXUyvnNLuTIcCk1q17JEbnVhXAKG9oX3KtchwiMIAYp9NLg==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-dialog": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.0.4.tgz", + "integrity": "sha512-hJtRy/jPULGQZceSAP2Re6/4NpKo8im6V8P2hUqZsdFiSL8l35kYsw3qbRI6Ay5mQd2+wlLqje770eq+RJ3yZg==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/primitive": "1.0.1", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-context": "1.0.1", + "@radix-ui/react-dismissable-layer": "1.0.4", + "@radix-ui/react-focus-guards": "1.0.1", + "@radix-ui/react-focus-scope": "1.0.3", + "@radix-ui/react-id": "1.0.1", + "@radix-ui/react-portal": "1.0.3", + "@radix-ui/react-presence": "1.0.1", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-slot": "1.0.2", + "@radix-ui/react-use-controllable-state": "1.0.1", + "aria-hidden": "^1.1.1", + "react-remove-scroll": "2.5.5" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-direction": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-direction/-/react-direction-1.0.1.tgz", + "integrity": "sha512-RXcvnXgyvYvBEOhCBuddKecVkoMiI10Jcm5cTI7abJRAHYfFxeu+FBQs/DvdxSYucxR5mna0dNsL6QFlds5TMA==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-dismissable-layer": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.0.4.tgz", + "integrity": "sha512-7UpBa/RKMoHJYjie1gkF1DlK8l1fdU/VKDpoS3rCCo8YBJR294GwcEHyxHw72yvphJ7ld0AXEcSLAzY2F/WyCg==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/primitive": "1.0.1", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-use-callback-ref": "1.0.1", + "@radix-ui/react-use-escape-keydown": "1.0.3" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-focus-guards": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.0.1.tgz", + "integrity": "sha512-Rect2dWbQ8waGzhMavsIbmSVCgYxkXLxxR3ZvCX79JOglzdEy4JXMb98lq4hPxUbLr77nP0UOGf4rcMU+s1pUA==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-focus-scope": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-scope/-/react-focus-scope-1.0.3.tgz", + "integrity": "sha512-upXdPfqI4islj2CslyfUBNlaJCPybbqRHAi1KER7Isel9Q2AtSJ0zRBZv8mWQiFXD2nyAJ4BhC3yXgZ6kMBSrQ==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-use-callback-ref": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-id": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.0.1.tgz", + "integrity": "sha512-tI7sT/kqYp8p96yGWY1OAnLHrqDgzHefRBKQ2YAkBS5ja7QLcZ9Z/uY7bEjPUatf8RomoXM8/1sMj1IJaE5UzQ==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-use-layout-effect": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-popover": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/@radix-ui/react-popover/-/react-popover-1.0.6.tgz", + "integrity": "sha512-cZ4defGpkZ0qTRtlIBzJLSzL6ht7ofhhW4i1+pkemjV1IKXm0wgCRnee154qlV6r9Ttunmh2TNZhMfV2bavUyA==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/primitive": "1.0.1", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-context": "1.0.1", + "@radix-ui/react-dismissable-layer": "1.0.4", + "@radix-ui/react-focus-guards": "1.0.1", + "@radix-ui/react-focus-scope": "1.0.3", + "@radix-ui/react-id": "1.0.1", + "@radix-ui/react-popper": "1.1.2", + "@radix-ui/react-portal": "1.0.3", + "@radix-ui/react-presence": "1.0.1", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-slot": "1.0.2", + "@radix-ui/react-use-controllable-state": "1.0.1", + "aria-hidden": "^1.1.1", + "react-remove-scroll": "2.5.5" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-popper": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-popper/-/react-popper-1.1.2.tgz", + "integrity": "sha512-1CnGGfFi/bbqtJZZ0P/NQY20xdG3E0LALJaLUEoKwPLwl6PPPfbeiCqMVQnhoFRAxjJj4RpBRJzDmUgsex2tSg==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@floating-ui/react-dom": "^2.0.0", + "@radix-ui/react-arrow": "1.0.3", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-context": "1.0.1", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-use-callback-ref": "1.0.1", + "@radix-ui/react-use-layout-effect": "1.0.1", + "@radix-ui/react-use-rect": "1.0.1", + "@radix-ui/react-use-size": "1.0.1", + "@radix-ui/rect": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-portal": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.0.3.tgz", + "integrity": "sha512-xLYZeHrWoPmA5mEKEfZZevoVRK/Q43GfzRXkWV6qawIWWK8t6ifIiLQdd7rmQ4Vk1bmI21XhqF9BN3jWf+phpA==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-primitive": "1.0.3" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-presence": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.0.1.tgz", + "integrity": "sha512-UXLW4UAbIY5ZjcvzjfRFo5gxva8QirC9hF7wRE4U5gz+TP0DbRk+//qyuAQ1McDxBt1xNMBTaciFGvEmJvAZCg==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-use-layout-effect": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-primitive": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-1.0.3.tgz", + "integrity": "sha512-yi58uVyoAcK/Nq1inRY56ZSjKypBNKTa/1mcL8qdl6oJeEaDbOldlzrGn7P6Q3Id5d+SYNGc5AJgc4vGhjs5+g==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-slot": "1.0.2" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-select": { + "version": "1.2.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-select/-/react-select-1.2.2.tgz", + "integrity": "sha512-zI7McXr8fNaSrUY9mZe4x/HC0jTLY9fWNhO1oLWYMQGDXuV4UCivIGTxwioSzO0ZCYX9iSLyWmAh/1TOmX3Cnw==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/number": "1.0.1", + "@radix-ui/primitive": "1.0.1", + "@radix-ui/react-collection": "1.0.3", + "@radix-ui/react-compose-refs": "1.0.1", + "@radix-ui/react-context": "1.0.1", + "@radix-ui/react-direction": "1.0.1", + "@radix-ui/react-dismissable-layer": "1.0.4", + "@radix-ui/react-focus-guards": "1.0.1", + "@radix-ui/react-focus-scope": "1.0.3", + "@radix-ui/react-id": "1.0.1", + "@radix-ui/react-popper": "1.1.2", + "@radix-ui/react-portal": "1.0.3", + "@radix-ui/react-primitive": "1.0.3", + "@radix-ui/react-slot": "1.0.2", + "@radix-ui/react-use-callback-ref": "1.0.1", + "@radix-ui/react-use-controllable-state": "1.0.1", + "@radix-ui/react-use-layout-effect": "1.0.1", + "@radix-ui/react-use-previous": "1.0.1", + "@radix-ui/react-visually-hidden": "1.0.3", + "aria-hidden": "^1.1.1", + "react-remove-scroll": "2.5.5" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-slot": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.0.2.tgz", + "integrity": "sha512-YeTpuq4deV+6DusvVUW4ivBgnkHwECUu0BiN43L5UCDFgdhsRUWAghhTF5MbvNTPzmiFOx90asDSUjWuCNapwg==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-compose-refs": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-use-callback-ref": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.1.tgz", + "integrity": "sha512-D94LjX4Sp0xJFVaoQOd3OO9k7tpBYNOXdVhkltUbGv2Qb9OXdrg/CpsjlZv7ia14Sylv398LswWBVVu5nqKzAQ==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-use-controllable-state": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.0.1.tgz", + "integrity": "sha512-Svl5GY5FQeN758fWKrjM6Qb7asvXeiZltlT4U2gVfl8Gx5UAv2sMR0LWo8yhsIZh2oQ0eFdZ59aoOOMV7b47VA==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-use-callback-ref": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } } }, - "@pushprotocol/socket": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz", - "integrity": "sha512-b6hzyUIMunmf2hLeTqTtJFvDG1Ngm+Rho00Z0mod+3khSOKy1Kwgpcpmj9bISLgr0ymeFqMYqNPj9+X89EAMZA==", - "requires": { - "socket.io-client": "^4.5.2", - "tslib": "^2.3.0" + "node_modules/@radix-ui/react-use-escape-keydown": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.0.3.tgz", + "integrity": "sha512-vyL82j40hcFicA+M4Ex7hVkB9vHgSse1ZWomAqV2Je3RleKGO5iM8KMOEtfoSB0PnIelMd2lATjTGMYqN5ylTg==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-use-callback-ref": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-use-layout-effect": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.0.1.tgz", + "integrity": "sha512-v/5RegiJWYdoCvMnITBkNNx6bCj20fiaJnWtRkU18yITptraXjffz5Qbn05uOiQnOvi+dbkznkoaMltz1GnszQ==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-use-previous": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-previous/-/react-use-previous-1.0.1.tgz", + "integrity": "sha512-cV5La9DPwiQ7S0gf/0qiD6YgNqM5Fk97Kdrlc5yBcrF3jyEZQwm7vYFqMo4IfeHgJXsRaMvLABFtd0OVEmZhDw==", + "dependencies": { + "@babel/runtime": "^7.13.10" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-use-rect": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-rect/-/react-use-rect-1.0.1.tgz", + "integrity": "sha512-Cq5DLuSiuYVKNU8orzJMbl15TXilTnJKUCltMVQg53BQOF1/C5toAaGrowkgksdBQ9H+SRL23g0HDmg9tvmxXw==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/rect": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } } }, - "@socket.io/component-emitter": { + "node_modules/@radix-ui/react-use-size": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/react-use-size/-/react-use-size-1.0.1.tgz", + "integrity": "sha512-ibay+VqrgcaI6veAojjofPATwledXiSmX+C0KrBk/xgpX9rBzPV3OsfwlhQdUOFbh+LKQorLYT+xTXW9V8yd0g==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-use-layout-effect": "1.0.1" + }, + "peerDependencies": { + "@types/react": "*", + "react": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/@radix-ui/react-visually-hidden": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.0.3.tgz", + "integrity": "sha512-D4w41yN5YRKtu464TLnByKzMDG/JlMPHtfZgQAu9v6mNakUqGUI9vUrfQKz8NK41VMm/xbZbh76NUTVtIYqOMA==", + "dependencies": { + "@babel/runtime": "^7.13.10", + "@radix-ui/react-primitive": "1.0.3" + }, + "peerDependencies": { + "@types/react": "*", + "@types/react-dom": "*", + "react": "^16.8 || ^17.0 || ^18.0", + "react-dom": "^16.8 || ^17.0 || ^18.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "@types/react-dom": { + "optional": true + } + } + }, + "node_modules/@radix-ui/rect": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@radix-ui/rect/-/rect-1.0.1.tgz", + "integrity": "sha512-fyrgCaedtvMg9NK3en0pnOYJdtfwxUcNolezkNPUsoX57X8oQk+NkqcvzHXD2uKNij6GXmWU9NDru2IWjrO4BQ==", + "dependencies": { + "@babel/runtime": "^7.13.10" + } + }, + "node_modules/@scure/base": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz", + "integrity": "sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA==", + "funding": [ + { + "type": "individual", + "url": "https://paulmillr.com/funding/" + } + ], + "peer": true + }, + "node_modules/@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "peer": true, + "dependencies": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "peer": true, + "dependencies": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@socket.io/component-emitter": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" }, - "date-fns": { + "node_modules/@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "node_modules/@stitches/react": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/react/-/react-1.2.8.tgz", + "integrity": "sha512-9g9dWI4gsSVe8bNLlb+lMkBYsnIKCZTmvqvDG+Avnn69XfmHZKiaMrx7cgTaddq7aTPPmXiTsbFcUy0xgI4+wA==", + "peerDependencies": { + "react": ">= 16.3.0" + } + }, + "node_modules/@tanstack/query-async-storage-persister": { + "version": "4.29.23", + "resolved": "https://registry.npmjs.org/@tanstack/query-async-storage-persister/-/query-async-storage-persister-4.29.23.tgz", + "integrity": "sha512-TlUCpJTwqzHyniiSCyyqe2Dw/oq5iKc7U5nQLLT3qFKUSFUa8Y7SzaNiCGm6WxOr0e3zlDze+Dh4uHx7s7CGTw==", + "dependencies": { + "@tanstack/query-persist-client-core": "4.29.23" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + } + }, + "node_modules/@tanstack/query-core": { + "version": "4.29.23", + "resolved": "https://registry.npmjs.org/@tanstack/query-core/-/query-core-4.29.23.tgz", + "integrity": "sha512-4BMHPrkfYmLP+NvqbbkV7Mk1nnphu+bNmxhhuB0+EMjKA7VfyFCfiyiTf55RRDgLaevyb9LrFK16lHW2owF52w==", + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + } + }, + "node_modules/@tanstack/query-persist-client-core": { + "version": "4.29.23", + "resolved": "https://registry.npmjs.org/@tanstack/query-persist-client-core/-/query-persist-client-core-4.29.23.tgz", + "integrity": "sha512-u0P6y4DPeXeHEZnj0LEnhcgqX8x7iV7xbUDuoRPItUYsPn+anyLjXG3d3622+wLP3XKdevff0PhXkA7j9ZOWKg==", + "dependencies": { + "@tanstack/query-core": "4.29.23" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + } + }, + "node_modules/@tanstack/react-query": { + "version": "4.29.23", + "resolved": "https://registry.npmjs.org/@tanstack/react-query/-/react-query-4.29.23.tgz", + "integrity": "sha512-u59dPBJHeyeRDSrHN3M8FT65yZDT0uPlaFDFd4K2wmDreHguRlk9t578X+cp1Cj+4oksQCE+wv09A5ZH7Odx6g==", + "dependencies": { + "@tanstack/query-core": "4.29.23", + "use-sync-external-store": "^1.2.0" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + }, + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react-dom": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react-native": "*" + }, + "peerDependenciesMeta": { + "react-dom": { + "optional": true + }, + "react-native": { + "optional": true + } + } + }, + "node_modules/@tanstack/react-query-persist-client": { + "version": "4.29.23", + "resolved": "https://registry.npmjs.org/@tanstack/react-query-persist-client/-/react-query-persist-client-4.29.23.tgz", + "integrity": "sha512-P23y5CMGfSM943pJoQjjOdQXSHH/ohjAl8vhQp+40M4Nz3lDq2d39flGRpajyh4dl4C5s0R8V6Iii7kkIQo8Jg==", + "dependencies": { + "@tanstack/query-persist-client-core": "4.29.23" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/tannerlinsley" + }, + "peerDependencies": { + "@tanstack/react-query": "4.29.23" + } + }, + "node_modules/@unstoppabledomains/resolution": { + "version": "8.5.0", + "resolved": "https://registry.npmjs.org/@unstoppabledomains/resolution/-/resolution-8.5.0.tgz", + "integrity": "sha512-csqExbiK8F5mRKoHlDZjGuIEuvi63O8PSyhUcGhnTi76Il5fCREAGNVdTiRxagPPYoxCO+Xmf6kThwtmiws1Ow==", + "dependencies": { + "@ethersproject/abi": "^5.0.1", + "bn.js": "^4.4.0", + "cross-fetch": "^3.1.4", + "crypto-js": "^4.1.1", + "elliptic": "^6.5.4" + } + }, + "node_modules/@unstoppabledomains/resolution/node_modules/cross-fetch": { + "version": "3.1.8", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-3.1.8.tgz", + "integrity": "sha512-cvA+JwZoU0Xq+h6WkMvAUqPEYy92Obet6UdKLfW60qn99ftItKjB5T+BkyWOFWe2pUyfQ+IJHmpOTznqk1M6Kg==", + "dependencies": { + "node-fetch": "^2.6.12" + } + }, + "node_modules/aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==", + "peer": true + }, + "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==", + "peer": true, + "dependencies": { + "color-convert": "^1.9.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/aria-hidden": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.3.tgz", + "integrity": "sha512-xcLxITLe2HYa1cnYnwCjkOO1PqUHQpozB8x9AR0OgWN2woOBi5kSDVxKfd0b7sb1hw5qFeJhXm9H1nu3xSfLeQ==", + "dependencies": { + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "peer": true, + "dependencies": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "peer": true + }, + "node_modules/axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "peer": true, + "dependencies": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "node_modules/babel-plugin-styled-components": { + "version": "2.1.4", + "resolved": "https://registry.npmjs.org/babel-plugin-styled-components/-/babel-plugin-styled-components-2.1.4.tgz", + "integrity": "sha512-Xgp9g+A/cG47sUyRwwYxGM4bR/jDRg5N6it/8+HxCnbT5XNKSKDT9xm4oag/osgqjC2It/vH0yXsomOG6k558g==", + "peer": true, + "dependencies": { + "@babel/helper-annotate-as-pure": "^7.22.5", + "@babel/helper-module-imports": "^7.22.5", + "@babel/plugin-syntax-jsx": "^7.22.5", + "lodash": "^4.17.21", + "picomatch": "^2.3.1" + }, + "peerDependencies": { + "styled-components": ">= 2" + } + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peer": true + }, + "node_modules/bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==", + "peer": true + }, + "node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "node_modules/brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "node_modules/browserslist": { + "version": "4.21.10", + "resolved": "https://registry.npmjs.org/browserslist/-/browserslist-4.21.10.tgz", + "integrity": "sha512-bipEBdZfVH5/pwrvqc+Ub0kUPVfGUhlKxbvfD+z1BDnPEO/X98ruXGA1WP5ASpAFKan7Qr6j736IacbZQuAlKQ==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "peer": true, + "dependencies": { + "caniuse-lite": "^1.0.30001517", + "electron-to-chromium": "^1.4.477", + "node-releases": "^2.0.13", + "update-browserslist-db": "^1.0.11" + }, + "bin": { + "browserslist": "cli.js" + }, + "engines": { + "node": "^6 || ^7 || ^8 || ^9 || ^10 || ^11 || ^12 || >=13.7" + } + }, + "node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peer": true, + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "node_modules/camelize": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/camelize/-/camelize-1.0.1.tgz", + "integrity": "sha512-dU+Tx2fsypxTgtLoE36npi3UqcjSSMNYfkqgmoEhtZrraP5VWq0K7FkWVTYa8eMPtnU/G2txVsfdCJTn9uzpuQ==", + "peer": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/caniuse-lite": { + "version": "1.0.30001519", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001519.tgz", + "integrity": "sha512-0QHgqR+Jv4bxHMp8kZ1Kn8CH55OikjKJ6JmKkZYP1F3D7w+lnFXF70nG5eNfsZS89jadi5Ywy5UCSKLAglIRkg==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/caniuse-lite" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "peer": true + }, + "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==", + "peer": true, + "dependencies": { + "ansi-styles": "^3.2.1", + "escape-string-regexp": "^1.0.5", + "supports-color": "^5.3.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/clsx": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz", + "integrity": "sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg==", + "engines": { + "node": ">=6" + } + }, + "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==", + "peer": true, + "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==", + "peer": true + }, + "node_modules/combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "dependencies": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "peer": true, + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/convert-source-map": { + "version": "1.9.0", + "resolved": "https://registry.npmjs.org/convert-source-map/-/convert-source-map-1.9.0.tgz", + "integrity": "sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==", + "peer": true + }, + "node_modules/core-js": { + "version": "3.32.0", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.0.tgz", + "integrity": "sha512-rd4rYZNlF3WuoYuRIDEmbR/ga9CeuWX9U05umAvgrrZoHY4Z++cp/xwPQMvUpBB4Ag6J8KfD80G0zwCyaSxDww==", + "hasInstallScript": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "dependencies": { + "node-fetch": "^2.6.12" + } + }, + "node_modules/crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "node_modules/css-color-keywords": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/css-color-keywords/-/css-color-keywords-1.0.0.tgz", + "integrity": "sha512-FyyrDHZKEjXDpNJYvVsV960FiqQyXc/LlYmsxl2BcdMb2WPx0OGRVgTg55rPSyLSNMqP52R9r8geSp7apN3Ofg==", + "peer": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/css-to-react-native": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/css-to-react-native/-/css-to-react-native-3.2.0.tgz", + "integrity": "sha512-e8RKaLXMOFii+02mOlqwjbD00KSEKqblnpO9e++1aXS1fPQOpS1YoqdVHBqPjHNoxeF2mimzVqawm2KCbEdtHQ==", + "peer": true, + "dependencies": { + "camelize": "^1.0.0", + "css-color-keywords": "^1.0.0", + "postcss-value-parser": "^4.0.2" + } + }, + "node_modules/custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "node_modules/date-fns": { "version": "2.30.0", "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz", "integrity": "sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==", - "requires": { + "dependencies": { "@babel/runtime": "^7.21.0" + }, + "engines": { + "node": ">=0.11" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/date-fns" } }, - "debug": { + "node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", - "requires": { + "dependencies": { "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "peer": true, + "engines": { + "node": ">=0.4.0" } }, - "dom-serializer": { + "node_modules/detect-node-es": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/detect-node-es/-/detect-node-es-1.1.0.tgz", + "integrity": "sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ==" + }, + "node_modules/dom-serializer": { "version": "1.4.1", "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz", "integrity": "sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag==", - "requires": { + "dependencies": { "domelementtype": "^2.0.1", "domhandler": "^4.2.0", "entities": "^2.0.0" }, - "dependencies": { - "entities": { - "version": "2.2.0", - "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", - "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==" - } + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" } }, - "domelementtype": { + "node_modules/dom-serializer/node_modules/entities": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", + "integrity": "sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A==", + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/domelementtype": { "version": "2.3.0", "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", - "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==" + "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ] }, - "domhandler": { + "node_modules/domhandler": { "version": "4.3.1", "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz", "integrity": "sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ==", - "requires": { + "dependencies": { "domelementtype": "^2.2.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" } }, - "domutils": { + "node_modules/domutils": { "version": "2.8.0", "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "requires": { + "dependencies": { "dom-serializer": "^1.0.1", "domelementtype": "^2.2.0", "domhandler": "^4.2.0" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/electron-to-chromium": { + "version": "1.4.483", + "resolved": "https://registry.npmjs.org/electron-to-chromium/-/electron-to-chromium-1.4.483.tgz", + "integrity": "sha512-YLwU0iF//9R3cCEfq0wgL+pf9vglE4kwAg4S5tkVVZljUDKv7Wcz67mTY4OOj+T7YUbTGuqlbqgdl/s+7Q8KTw==", + "peer": true + }, + "node_modules/elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/emoji-picker-react": { + "version": "4.4.10", + "resolved": "https://registry.npmjs.org/emoji-picker-react/-/emoji-picker-react-4.4.10.tgz", + "integrity": "sha512-/5o57w8BKiCHklyqfYCeUlm00R9tdm2ZmJd0p6Q3/Ul7E7eMh+/FduuRFn3UVQCl5F6i4kOdREMz7EJ7YI1vMg==", + "dependencies": { + "clsx": "^1.2.1" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "react": ">=16" + } + }, + "node_modules/engine.io-client": { + "version": "6.4.0", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.4.0.tgz", + "integrity": "sha512-GyKPDyoEha+XZ7iEqam49vz6auPnNJ9ZBfy89f+rMMas8AuiMWOZ9PVzu8xb9ZC6rafUqiGHSCfu22ih66E+1g==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.0.3", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + } + }, + "node_modules/engine.io-parser": { + "version": "5.0.6", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.0.6.tgz", + "integrity": "sha512-tjuoZDMAdEhVnSFleYPCtdL2GXwVTGtNjoeJd9IhIG3C1xs9uwxqRNEu5WpnDZCaozwVlK/nuQhpodhXSIMaxw==", + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/entities": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-3.0.1.tgz", + "integrity": "sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q==", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==", + "peer": true + }, + "node_modules/escalade": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", + "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", + "peer": true, + "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==", + "peer": true, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "peer": true, + "dependencies": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "node_modules/ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "peer": true, + "dependencies": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "node_modules/ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "peer": true, + "dependencies": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/events": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/events/-/events-3.3.0.tgz", + "integrity": "sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==", + "peer": true, + "engines": { + "node": ">=0.8.x" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "peer": true, + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/font-awesome": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz", + "integrity": "sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg==", + "engines": { + "node": ">=0.10.3" + } + }, + "node_modules/form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "peer": true, + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "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==", + "peer": true, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==", + "peer": true + }, + "node_modules/get-nonce": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/get-nonce/-/get-nonce-1.0.1.tgz", + "integrity": "sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q==", + "engines": { + "node": ">=6" + } + }, + "node_modules/gif-picker-react": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/gif-picker-react/-/gif-picker-react-1.3.0.tgz", + "integrity": "sha512-IYDmx9iEouC84JCrOt/HSaiRgHD8o7/catZCspUVpNEXoIunq7CF65JcmyTyoPkVJZcQz0ofjU5Gp5C2bqwOlQ==", + "engines": { + "node": ">=16.0.0", + "npm": ">=8.0.0" + }, + "peerDependencies": { + "react": ">=17", + "react-dom": ">=17" + } + }, + "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==", + "peer": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "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==", + "peer": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "dependencies": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" } }, - "emoji-picker-react": { - "version": "3.6.5", - "resolved": "https://registry.npmjs.org/emoji-picker-react/-/emoji-picker-react-3.6.5.tgz", - "integrity": "sha512-pfu3XkHSeqXjygyoKtRsmJdsNkRxhkE7hlnWrYBoPnm8V03aJ8Y9H5oRUQ+fF4WRZpjfJFsw5V7ewRVhuj/8cA==" + "node_modules/hls.js": { + "version": "1.4.10", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.10.tgz", + "integrity": "sha512-wAVSj4Fm2MqOHy5+BlYnlKxXvJlv5IuZHjlzHu18QmjRzSDFQiUDWdHs5+NsFMQrgKEBwuWDcyvaMC9dUzJ5Uw==" }, - "engine.io-client": { - "version": "6.4.0", - "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.4.0.tgz", - "integrity": "sha512-GyKPDyoEha+XZ7iEqam49vz6auPnNJ9ZBfy89f+rMMas8AuiMWOZ9PVzu8xb9ZC6rafUqiGHSCfu22ih66E+1g==", - "requires": { - "@socket.io/component-emitter": "~3.1.0", - "debug": "~4.3.1", - "engine.io-parser": "~5.0.3", - "ws": "~8.11.0", - "xmlhttprequest-ssl": "~2.0.0" + "node_modules/hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "dependencies": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" } }, - "engine.io-parser": { - "version": "5.0.6", - "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.0.6.tgz", - "integrity": "sha512-tjuoZDMAdEhVnSFleYPCtdL2GXwVTGtNjoeJd9IhIG3C1xs9uwxqRNEu5WpnDZCaozwVlK/nuQhpodhXSIMaxw==" + "node_modules/hoist-non-react-statics": { + "version": "3.3.2", + "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.2.tgz", + "integrity": "sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==", + "peer": true, + "dependencies": { + "react-is": "^16.7.0" + } }, - "entities": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/entities/-/entities-3.0.1.tgz", - "integrity": "sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q==" + "node_modules/hoist-non-react-statics/node_modules/react-is": { + "version": "16.13.1", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz", + "integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==", + "peer": true }, - "html-dom-parser": { + "node_modules/html-dom-parser": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/html-dom-parser/-/html-dom-parser-1.2.0.tgz", "integrity": "sha512-2HIpFMvvffsXHFUFjso0M9LqM+1Lm22BF+Df2ba+7QHJXjk63pWChEnI6YG27eaWqUdfnh5/Vy+OXrNTtepRsg==", - "requires": { + "dependencies": { "domhandler": "4.3.1", "htmlparser2": "7.2.0" } }, - "html-react-parser": { + "node_modules/html-react-parser": { "version": "1.4.14", "resolved": "https://registry.npmjs.org/html-react-parser/-/html-react-parser-1.4.14.tgz", "integrity": "sha512-pxhNWGie8Y+DGDpSh8cTa0k3g8PsDcwlfolA+XxYo1AGDeB6e2rdlyv4ptU9bOTiZ2i3fID+6kyqs86MN0FYZQ==", - "requires": { + "dependencies": { "domhandler": "4.3.1", "html-dom-parser": "1.2.0", "react-property": "2.0.0", "style-to-js": "1.1.1" + }, + "peerDependencies": { + "react": "0.14 || 15 || 16 || 17 || 18" } }, - "htmlparser2": { + "node_modules/htmlparser2": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-7.2.0.tgz", "integrity": "sha512-H7MImA4MS6cw7nbyURtLPO1Tms7C5H602LRETv95z1MxO/7CP7rDVROehUYeYBUYEON94NXXDEPmZuq+hX4sog==", - "requires": { + "funding": [ + "https://github.com/fb55/htmlparser2?sponsor=1", + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "dependencies": { "domelementtype": "^2.0.1", "domhandler": "^4.2.2", "domutils": "^2.8.0", "entities": "^3.0.1" } }, - "inline-style-parser": { + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peer": true + }, + "node_modules/immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==", + "peer": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/inline-style-parser": { "version": "0.1.1", "resolved": "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.1.1.tgz", "integrity": "sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q==" }, - "ms": { + "node_modules/invariant": { + "version": "2.2.4", + "resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz", + "integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==", + "dependencies": { + "loose-envify": "^1.0.0" + } + }, + "node_modules/is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==", + "peer": true, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "node_modules/js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "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==" + }, + "node_modules/jsesc": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/jsesc/-/jsesc-2.5.2.tgz", + "integrity": "sha512-OYu7XEzjkCQ3C5Ps3QIZsQfNpqoJyZZA99wd9aWd05NCtC5pWOkShK2mkL6HXQR6/Cy2lbNdPlZBpuQHXE63gA==", + "peer": true, + "bin": { + "jsesc": "bin/jsesc" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "peer": true, + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/livepeer": { + "version": "2.8.0", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.0.tgz", + "integrity": "sha512-ZYw/bew356VZ1MZE6T7NBV6xgQ6yukqutb/GiSk9Yz+vjJvxy2npu4sEhgZ1pkHFVVczcGVwjZidWWaZ+oMwGg==", + "dependencies": { + "@livepeer/core": "^1.8.0", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/livepeer/node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==", + "peer": true + }, + "node_modules/lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "dependencies": { + "lodash._stringtopath": "~4.8.0" + } + }, + "node_modules/lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "node_modules/lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "dependencies": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "node_modules/lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "node_modules/lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "node_modules/lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "dependencies": { + "lodash._basetostring": "~4.12.0" + } + }, + "node_modules/lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "node_modules/lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "dependencies": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.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==", + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "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==", + "peer": true, + "dependencies": { + "yallist": "^3.0.2" + } + }, + "node_modules/micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==", + "peer": true + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "peer": true, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "peer": true, + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "node_modules/minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "node_modules/moment": { + "version": "2.29.4", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz", + "integrity": "sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==", + "engines": { + "node": "*" + } + }, + "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==" }, - "react-property": { + "node_modules/multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node_modules/node-fetch": { + "version": "2.6.12", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz", + "integrity": "sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g==", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/node-releases": { + "version": "2.0.13", + "resolved": "https://registry.npmjs.org/node-releases/-/node-releases-2.0.13.tgz", + "integrity": "sha512-uYr7J37ae/ORWdZeQ1xxMJe3NtdmqMC/JZK+geofDrkLUApKRHPd18/TxtBOJ4A0/+uUIliorNrfYV6s1b02eQ==", + "peer": true + }, + "node_modules/openpgp": { + "version": "5.9.0", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.9.0.tgz", + "integrity": "sha512-wEI6TAinCAq8ZLZA4oZ3ZtJ2BhhHj+CiPCd8TzE7zCicr0V8tvG5UF76OtddLLOJcK63w3Aj3KiRd+VLMScirQ==", + "peer": true, + "dependencies": { + "asn1.js": "^5.0.0" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/picocolors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.0.0.tgz", + "integrity": "sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ==", + "peer": true + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "peer": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/postcss-value-parser": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz", + "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==", + "peer": true + }, + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "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==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peer": true + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "peer": true, + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/react-dom": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react-dom/-/react-dom-18.2.0.tgz", + "integrity": "sha512-6IMTriUmvsjHUjNtEDudZfuDQUoWXVxKHhlEGSk81n4YFS+r/Kl99wXiwlVXtPBtJenozv2P+hxDsw9eA7Xo6g==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0", + "scheduler": "^0.23.0" + }, + "peerDependencies": { + "react": "^18.2.0" + } + }, + "node_modules/react-is": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", + "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==", + "peer": true + }, + "node_modules/react-property": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/react-property/-/react-property-2.0.0.tgz", "integrity": "sha512-kzmNjIgU32mO4mmH5+iUyrqlpFQhF8K2k7eZ4fdLSOPFrD1XgEuSBv9LDEgxRXTMBqMd8ppT0x6TIzqE5pdGdw==" }, - "regenerator-runtime": { + "node_modules/react-remove-scroll": { + "version": "2.5.5", + "resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.5.5.tgz", + "integrity": "sha512-ImKhrzJJsyXJfBZ4bzu8Bwpka14c/fQt0k+cyFp/PBhTfyDnU5hjOtM4AG/0AMyy8oKzOTR0lDgJIM7pYXI0kw==", + "dependencies": { + "react-remove-scroll-bar": "^2.3.3", + "react-style-singleton": "^2.2.1", + "tslib": "^2.1.0", + "use-callback-ref": "^1.3.0", + "use-sidecar": "^1.1.2" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "@types/react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/react-remove-scroll-bar": { + "version": "2.3.4", + "resolved": "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz", + "integrity": "sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A==", + "dependencies": { + "react-style-singleton": "^2.2.1", + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "@types/react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/react-style-singleton": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/react-style-singleton/-/react-style-singleton-2.2.1.tgz", + "integrity": "sha512-ZWj0fHEMyWkHzKYUr2Bs/4zU6XLmq9HsgBURm7g5pAVfyn49DgUiNgY2d4lXRlYSiCif9YBGpQleewkcqddc7g==", + "dependencies": { + "get-nonce": "^1.0.0", + "invariant": "^2.2.4", + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "@types/react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/react-twitter-embed": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/react-twitter-embed/-/react-twitter-embed-4.0.4.tgz", + "integrity": "sha512-2JIL7qF+U62zRzpsh6SZDXNI3hRNVYf5vOZ1WRcMvwKouw+xC00PuFaD0aEp2wlyGaZ+f4x2VvX+uDadFQ3HVA==", + "dependencies": { + "scriptjs": "^2.5.9" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "react": "^16.0.0 || ^17.0.0 || ^18.0.0", + "react-dom": "^16.0.0 || ^17.0.0 || ^18.0.0" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "peer": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/regenerator-runtime": { "version": "0.13.11", "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz", "integrity": "sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg==" }, - "socket.io-client": { + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", + "engines": { + "node": ">= 4" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peer": true + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "peer": true + }, + "node_modules/scheduler": { + "version": "0.23.0", + "resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.23.0.tgz", + "integrity": "sha512-CtuThmgHNg7zIZWAXi3AsyIzA3n4xx7aNyjwC2VJldO2LMVDhFK+63xGqq6CsJH4rTAt6/M+N4GhZiDYPx9eUw==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + } + }, + "node_modules/scriptjs": { + "version": "2.5.9", + "resolved": "https://registry.npmjs.org/scriptjs/-/scriptjs-2.5.9.tgz", + "integrity": "sha512-qGVDoreyYiP1pkQnbnFAUIS5AjenNwwQBdl7zeos9etl+hYKWahjRTfzAZZYBv5xNHx7vNKCmaLDQZ6Fr2AEXg==" + }, + "node_modules/scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==", + "peer": true + }, + "node_modules/semver": { + "version": "6.3.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-6.3.1.tgz", + "integrity": "sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA==", + "peer": true, + "bin": { + "semver": "bin/semver.js" + } + }, + "node_modules/shallowequal": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/shallowequal/-/shallowequal-1.1.0.tgz", + "integrity": "sha512-y0m1JoUZSlPAjXVtPPW70aZWfIL/dSP7AFkRnniLCrK/8MDKog3TySTBmckD+RObVxH0v4Tox67+F14PdED2oQ==", + "peer": true + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "node_modules/simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "peer": true, + "dependencies": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "node_modules/socket.io-client": { "version": "4.6.1", "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.6.1.tgz", "integrity": "sha512-5UswCV6hpaRsNg5kkEHVcbBIXEYoVbMQaHJBXJCyEQ+CiFPV1NIOY0XOFWG4XR4GZcB8Kn6AsRs/9cy9TbqVMQ==", - "requires": { + "dependencies": { "@socket.io/component-emitter": "~3.1.0", "debug": "~4.3.2", "engine.io-client": "~6.4.0", "socket.io-parser": "~4.2.1" + }, + "engines": { + "node": ">=10.0.0" } }, - "socket.io-parser": { + "node_modules/socket.io-parser": { "version": "4.2.2", "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.2.tgz", "integrity": "sha512-DJtziuKypFkMMHCm2uIshOYC7QaylbtzQwiMYDuCKy3OPkjLzu4B2vAhTlqipRHHzrI0NJeBAizTK7X+6m1jVw==", - "requires": { + "dependencies": { "@socket.io/component-emitter": "~3.1.0", "debug": "~4.3.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "peer": true, + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "peer": true, + "dependencies": { + "is-hex-prefixed": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" } }, - "style-to-js": { + "node_modules/style-to-js": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/style-to-js/-/style-to-js-1.1.1.tgz", "integrity": "sha512-RJ18Z9t2B02sYhZtfWKQq5uplVctgvjTfLWT7+Eb1zjUjIrWzX5SdlkwLGQozrqarTmEzJJ/YmdNJCUNI47elg==", - "requires": { + "dependencies": { "style-to-object": "0.3.0" } }, - "style-to-object": { + "node_modules/style-to-object": { "version": "0.3.0", "resolved": "https://registry.npmjs.org/style-to-object/-/style-to-object-0.3.0.tgz", "integrity": "sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA==", - "requires": { + "dependencies": { "inline-style-parser": "0.1.1" } }, - "tslib": { + "node_modules/styled-components": { + "version": "5.3.11", + "resolved": "https://registry.npmjs.org/styled-components/-/styled-components-5.3.11.tgz", + "integrity": "sha512-uuzIIfnVkagcVHv9nE0VPlHPSCmXIUGKfJ42LNjxCCTDTL5sgnJ8Z7GZBq0EnLYGln77tPpEpExt2+qa+cZqSw==", + "peer": true, + "dependencies": { + "@babel/helper-module-imports": "^7.0.0", + "@babel/traverse": "^7.4.5", + "@emotion/is-prop-valid": "^1.1.0", + "@emotion/stylis": "^0.8.4", + "@emotion/unitless": "^0.7.4", + "babel-plugin-styled-components": ">= 1.12.0", + "css-to-react-native": "^3.0.0", + "hoist-non-react-statics": "^3.0.0", + "shallowequal": "^1.1.0", + "supports-color": "^5.5.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/styled-components" + }, + "peerDependencies": { + "react": ">= 16.8.0", + "react-dom": ">= 16.8.0", + "react-is": ">= 16.8.0" + } + }, + "node_modules/supports-color": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz", + "integrity": "sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==", + "peer": true, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "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==", + "peer": true, + "engines": { + "node": ">=4" + } + }, + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "node_modules/tslib": { "version": "2.5.0", "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz", "integrity": "sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg==" }, - "ws": { + "node_modules/tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "dependencies": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "node_modules/tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==", + "peer": true + }, + "node_modules/tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==", + "peer": true + }, + "node_modules/unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==", + "peer": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/update-browserslist-db": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/update-browserslist-db/-/update-browserslist-db-1.0.11.tgz", + "integrity": "sha512-dCwEFf0/oT85M1fHBg4F0jtLwJrutGoHSQXCh7u4o2t1drG+c0a9Flnqww6XUKSfQMPpJBRjU8d4RXB09qtvaA==", + "funding": [ + { + "type": "opencollective", + "url": "https://opencollective.com/browserslist" + }, + { + "type": "tidelift", + "url": "https://tidelift.com/funding/github/npm/browserslist" + }, + { + "type": "github", + "url": "https://github.com/sponsors/ai" + } + ], + "peer": true, + "dependencies": { + "escalade": "^3.1.1", + "picocolors": "^1.0.0" + }, + "bin": { + "update-browserslist-db": "cli.js" + }, + "peerDependencies": { + "browserslist": ">= 4.21.0" + } + }, + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "node_modules/use-callback-ref": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/use-callback-ref/-/use-callback-ref-1.3.0.tgz", + "integrity": "sha512-3FT9PRuRdbB9HfXhEq35u4oZkvpJ5kuYbpqhCfmiZyReuRgpnhDlbr2ZEnnuS0RrJAPn6l23xjFg9kpDM+Ms7w==", + "dependencies": { + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "@types/react": "^16.8.0 || ^17.0.0 || ^18.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/use-sidecar": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/use-sidecar/-/use-sidecar-1.1.2.tgz", + "integrity": "sha512-epTbsLuzZ7lPClpz2TyryBfztm7m+28DlEv2ZCQ3MDr5ssiwyOwGH/e5F9CkfWjJ1t4clvI58yF822/GUkjjhw==", + "dependencies": { + "detect-node-es": "^1.1.0", + "tslib": "^2.0.0" + }, + "engines": { + "node": ">=10" + }, + "peerDependencies": { + "@types/react": "^16.9.0 || ^17.0.0 || ^18.0.0", + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, + "node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "peer": true + }, + "node_modules/uuid": { + "version": "9.0.0", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.0.tgz", + "integrity": "sha512-MXcSTerfPa4uqyzStbRoTgt5XIe3x5+42+q1sDuy3R5MDk66URdLMOZe5aPX/SQd+kuYAh0FdP/pO28IkQyTeg==", + "peer": true, + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==", + "peer": true + }, + "node_modules/webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "node_modules/whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "node_modules/ws": { "version": "8.11.0", "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", - "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==" + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } }, - "xmlhttprequest-ssl": { + "node_modules/xmlhttprequest-ssl": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", - "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==" + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/yallist": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-3.1.1.tgz", + "integrity": "sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==", + "peer": true + }, + "node_modules/zustand": { + "version": "4.4.0", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.0.tgz", + "integrity": "sha512-2dq6wq4dSxbiPTamGar0NlIG/av0wpyWZJGeQYtUOLegIUvhM2Bf86ekPlmgpUtS5uR7HyetSiktYrGsdsyZgQ==", + "dependencies": { + "use-sync-external-store": "1.2.0" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@types/react": ">=16.8", + "immer": ">=9.0", + "react": ">=16.8" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + } + } } } } diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index b8a2a0e2a..2f777f227 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -10,10 +10,11 @@ "@unstoppabledomains/resolution": "^8.5.0", "date-fns": "^2.28.0", "emoji-picker-react": "^4.4.9", - "html-react-parser": "^1.4.13", - "gif-picker-react": "^1.1.0", "font-awesome": "^4.7.0", - "moment": "^2.29.4" + "gif-picker-react": "^1.1.0", + "html-react-parser": "^1.4.13", + "moment": "^2.29.4", + "react-twitter-embed": "^4.0.4" }, "peerDependencies": { "@pushprotocol/restapi": "^1.2.15", diff --git a/packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx b/packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx new file mode 100644 index 000000000..d81febbce --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx @@ -0,0 +1,319 @@ +import { useContext, useEffect, useState } from "react"; +import { Section, Span, Image } from "../../reusables"; +import moment from "moment"; +import styled from "styled-components"; +import { FileMessageContent } from "../../../types"; +import { FILE_ICON } from "../../../config"; +import { formatFileSize, getPfp, pCAIP10ToWallet, setPfp, shortenText } from "../../../helpers"; +import { checkTwitterUrl } from "../helpers/twitter"; +import { IMessagePayload, TwitterFeedReturnType } from "../exportedTypes"; +import { TwitterTweetEmbed } from "react-twitter-embed"; +import { ChatDataContext } from "../../../context"; +import { useChatData } from "../../../hooks"; +import { ThemeContext } from "../theme/ThemeProvider"; + +const SenderMessageAddress = ({ chat }: { chat: IMessagePayload }) => { + const { account } = useContext(ChatDataContext) + const theme = useContext(ThemeContext) + return ( + <> + {chat.fromCAIP10.split(":")[1] !== account && ( + {chat.fromDID.split(":")[1].slice(0, 6)}... + {chat.fromDID.split(":")[1].slice(-6)} + )} + + ) +} + +const SenderMessafeProfilePicture = ({ chat }: { chat: IMessagePayload }) => { + const { account, env } = useContext(ChatDataContext) + const [pfp, setPfp] = useState("") + const getUserPfp = async () => { + const pfp = await getPfp({ account: chat.fromCAIP10.split(":")[1], env: env }) + if (pfp) { + setPfp(pfp) + } + } + useEffect(() => { + getUserPfp() + }, [account, chat.fromCAIP10]) + return ( +
+ {chat.fromCAIP10.split(":")[1] !== account && ( +
+ {pfp && profile picture} +
+ )} +
+ ) +} + +const MessageCard = ({ + chat, + position, + isGroup, +}: { + chat: IMessagePayload; + position: number; + isGroup: boolean; +}) => { + const theme = useContext(ThemeContext) + const time = moment(chat.timestamp).format('hh:mm a'); + return ( +
+ {isGroup && + + } +
+ {isGroup && + + } +
+ {' '} +
+ {chat.messageContent.split('\n').map((str) => ( + + {str} + + ))} +
+ + {time} + +
+
+
+ ); +}; + +const FileCard = ({ + chat, + isGroup, +}: { + chat: IMessagePayload; + position: number; + isGroup: boolean; +}) => { + const fileContent: FileMessageContent = JSON.parse(chat.messageContent); + const name = fileContent.name; + + const content = fileContent.content as string; + const size = fileContent.size; + + return ( +
+ {isGroup && + + } +
+ {isGroup && + + } +
+ extension icon +
+ + {shortenText(name, 11)} + + + {formatFileSize(size)} + +
+ + +
+
+
+ ); +}; + +const ImageCard = ({ + chat, + position, + isGroup, +}: { + chat: IMessagePayload; + position: number; + isGroup: boolean; +}) => { + + return ( +
+ {isGroup && + + } +
+ {isGroup && ( + + )} +
+ +
+
+
+ ); +}; + +const GIFCard = ({ + chat, + position, + isGroup, +}: { + chat: IMessagePayload; + position: number; + isGroup: boolean; +}) => { + return ( +
+ {isGroup && + + } +
+ {isGroup && + + } +
+ +
+
+
+ ); +}; + +const TwitterCard = ({ chat, tweetId, isGroup, position }: { chat: IMessagePayload, tweetId: string, isGroup: boolean, position: number }) => { + return ( +
+ {isGroup && + + } +
+ {isGroup && + + } +
+ +
+
+
+ ) +} + +export const MessageBubble = ({ chat }: { chat: IMessagePayload }) => { + const { account } = useChatData(); + const position = pCAIP10ToWallet(chat.fromDID).toLowerCase() !== account?.toLowerCase() ? 0 : 1; + const { tweetId, messageType }: TwitterFeedReturnType = checkTwitterUrl({ message: chat?.messageContent }); + const [isGroup, setIsGroup] = useState(false); + useEffect(() => { + if (chat.toDID.split(':')[0] === 'eip155') { + if (isGroup) { + setIsGroup(false); + } + } else { + if (!isGroup) { + setIsGroup(true); + } + } + }, [chat.toDID, isGroup]) + + if (messageType === 'TwitterFeedLink') { + chat.messageType = 'TwitterFeedLink'; + } + + if (chat.messageType === 'GIF') { + return + } + if (chat.messageType === 'Image') { + return ; + } + if (chat.messageType === 'File') { + return ; + } + if (chat.messageType === 'TwitterFeedLink') { + return ; + } + return ; +} + + +const FileDownloadIcon = styled.i` + color: #575757; +`; + +const FileDownloadIconAnchor = styled.a` + font-size: 20px; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/MessageBubble/index.ts b/packages/uiweb/src/lib/components/chat/MessageBubble/index.ts new file mode 100644 index 000000000..fd86462dc --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageBubble/index.ts @@ -0,0 +1 @@ +export { MessageBubble } from './MessageBubble'; diff --git a/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx b/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx new file mode 100644 index 000000000..389ed105f --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx @@ -0,0 +1,190 @@ +import React, { useContext, useEffect, useRef, useState } from 'react'; +import { ChatDataContext } from '../../../context'; +import { IMessageListProps } from '../exportedTypes'; +import { chatLimit } from '../../../config'; +import { IMessageIPFS } from '@pushprotocol/restapi'; +import useFetchHistoryMessages from '../../../hooks/chat/useFetchHistoryMessages'; +import styled from 'styled-components'; +import { Section, Span, Spinner } from '../../reusables'; +import moment from 'moment'; +import { MessageBubble } from '../MessageBubble'; +import { appendUniqueMessages, dateToFromNowDaily, pCAIP10ToWallet } from '../../../helpers'; +import { useChatData, usePushChatSocket } from '../../../hooks'; +import { Messagetype } from '../../../types'; +import { ThemeContext } from '../theme/ThemeProvider'; + + + + +export const MessageList: React.FC = ( + options: IMessageListProps +) => { + const { conversationHash, limit = chatLimit } = options || {}; + const { pgpPrivateKey, account } = useChatData(); + const [messages, setMessages] = useState(); + const { historyMessages, loading } = useFetchHistoryMessages(); + const listInnerRef = useRef(null); + const bottomRef = useRef(null); + const { messagesSinceLastConnection } = usePushChatSocket(); + const theme = useContext(ThemeContext); + const dates = new Set(); + + useEffect(() => { + if ( + Object.keys(messagesSinceLastConnection || {}).length + ) { + if (!Object.keys(messages || {}).length) { + setMessages({ + messages: messagesSinceLastConnection, + lastThreadHash: messages!.lastThreadHash, + }); + } else { + const newMessageList = appendUniqueMessages(messages as Messagetype,[messagesSinceLastConnection],false); + setMessages( { + + messages: newMessageList, + lastThreadHash: messages!.lastThreadHash, + + }); + } + } + }, [messagesSinceLastConnection]); + + useEffect(() => { + if (conversationHash) { + (async function () { + await getMessagesCall(); + })(); + } + }, [conversationHash, pgpPrivateKey, account]); + + useEffect(() => { + scrollToBottom(null); + }, [conversationHash]); + + useEffect(() => { + if ( + conversationHash && + Object.keys(messages || {}).length && + messages?.messages.length && + messages?.messages.length <= limit + ) { + scrollToBottom(null); + } + }, [messages]); + + const scrollToBottom = (behavior?: string | null) => { + bottomRef?.current?.scrollIntoView( + !behavior ? true : { behavior: 'smooth' } + ); + }; + + const onScroll = async () => { + if (listInnerRef.current) { + const { scrollTop } = listInnerRef.current; + if (scrollTop === 0) { + const content = listInnerRef.current; + const curScrollPos = content.scrollTop; + const oldScroll = content.scrollHeight - content.clientHeight; + + await getMessagesCall(); + + const newScroll = content.scrollHeight - content.clientHeight; + content.scrollTop = curScrollPos + (newScroll - oldScroll); + } + } + }; + + const getMessagesCall = async () => { + let threadHash = null; + if (!messages) { + threadHash = conversationHash; + } else { + threadHash = messages?.lastThreadHash; + } + if (threadHash) { + const chatHistory = await historyMessages({ + limit: limit, + threadHash, + }); + if (chatHistory?.length) { + if (Object.keys(messages || {}) && messages?.messages.length) { + const newMessageList = appendUniqueMessages(messages,chatHistory,true); + setMessages({ + messages: newMessageList, + lastThreadHash: chatHistory[0].link, + }); + } else { + setMessages({ + messages: chatHistory, + lastThreadHash: chatHistory[0].link, + }); + } + } + } + }; + + + type RenderDataType = { + chat: IMessageIPFS; + dateNum: string; + }; + + const renderDate = ({ chat, dateNum }: RenderDataType) => { + const timestampDate = dateToFromNowDaily(chat.timestamp as number); + dates.add(dateNum); + return ( + + {timestampDate} + + ); + }; + + return ( +
onScroll()} + > + {loading ? : ''} + + + {messages?.messages.map((chat: IMessageIPFS, index: number) => { + const dateNum = moment(chat.timestamp).format('L'); + const position = + pCAIP10ToWallet(chat.fromDID).toLowerCase() !== + account?.toLowerCase() + ? 0 + : 1; + return ( + <> + {dates.has(dateNum) ? null : renderDate({ chat, dateNum })} +
+ +
+ + ); + })} +
+ +
+ ); +}; + +//styles +const MessageListCard = styled(Section)``; + +//pagination scroll issue left +//socket diff --git a/packages/uiweb/src/lib/components/chat/MessageList/index.ts b/packages/uiweb/src/lib/components/chat/MessageList/index.ts new file mode 100644 index 000000000..80a558955 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageList/index.ts @@ -0,0 +1 @@ +export {MessageList} from './MessageList'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/exportedTypes.ts b/packages/uiweb/src/lib/components/chat/exportedTypes.ts new file mode 100644 index 000000000..97f4b5c47 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/exportedTypes.ts @@ -0,0 +1,21 @@ +import type { IMessageIPFS } from '@pushprotocol/restapi'; + +export interface IMessageListProps { + conversationHash: string; + limit?: number; + } + +export interface TwitterFeedReturnType { + tweetId: string; + messageType: string; +} + +export type IMessagePayload = IMessageIPFS; + +export const CHAT_THEME_OPTIONS = { + LIGHT: 'light', + DARK: 'dark', + +} as const; + +export type ChatThemeOptions = (typeof CHAT_THEME_OPTIONS)[keyof typeof CHAT_THEME_OPTIONS]; diff --git a/packages/uiweb/src/lib/components/chat/helpers/helper.ts b/packages/uiweb/src/lib/components/chat/helpers/helper.ts new file mode 100644 index 000000000..2f6aff6a6 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/helper.ts @@ -0,0 +1,2 @@ +import { IMessagePayload } from "../exportedTypes"; + diff --git a/packages/uiweb/src/lib/components/chat/helpers/twitter.ts b/packages/uiweb/src/lib/components/chat/helpers/twitter.ts new file mode 100644 index 000000000..966e04037 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/twitter.ts @@ -0,0 +1,30 @@ +import { TwitterFeedReturnType } from '../exportedTypes'; + +interface TwitterFeedProps { + message: string; +} + +export const checkTwitterUrl = ({ message }: TwitterFeedProps): TwitterFeedReturnType => { + let tweetId = ""; + let messageType = ""; + + const URL_REGEX = /(ftp|http|https):\/\/(\w+:{0,1}\w*@)?(\S+)(:[0-9]+)?(\/)?([\w#!:.?+=&%@!-]+)/; + const messageContent = message?.split(" "); + + for (let i = 0; i < messageContent.length; i++) { + if (URL_REGEX.test(messageContent[i]) && messageContent[i].toLowerCase().includes("twitter")) { + // Extracting tweetId + const wordArray = messageContent[i].split("?")[0].split("/"); // split url at '?' and take first element and split at '/' + if (wordArray?.length >= 6) { + tweetId = wordArray[wordArray?.length - 1]; + messageType = "TwitterFeedLink"; + break; + } else { + messageType = "Text"; + break; + } + } + } + + return { tweetId, messageType }; +}; diff --git a/packages/uiweb/src/lib/components/chat/index.ts b/packages/uiweb/src/lib/components/chat/index.ts new file mode 100644 index 000000000..207007be6 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/index.ts @@ -0,0 +1,3 @@ +export { MessageBubble } from './MessageBubble'; +export * from './MessageList'; +export * from './exportedTypes'; diff --git a/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx b/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx new file mode 100644 index 000000000..f1f745e9b --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx @@ -0,0 +1,20 @@ +/** + * @file ThemeProvider.tsx: This acts as the custom theme provider for the entire app. + */ +import { createContext } from 'react'; + +import { IChatTheme, lightTheme } from './index'; + +/** + * @param theme optional: light or dark theme. defaults to light + * @param customTheme optional: custom colors/theme + * @param children children to be wrapped with ThemeProvider + */ +export interface IThemeProviderProps { + theme?: 'light' | 'dark'; + // themeOverride?: Partial; + children: any; +} + + +export const ThemeContext = createContext(lightTheme); diff --git a/packages/uiweb/src/lib/components/chat/theme/index.ts b/packages/uiweb/src/lib/components/chat/theme/index.ts new file mode 100644 index 000000000..3b58a948e --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/theme/index.ts @@ -0,0 +1,54 @@ +/** + * @file theme file: all the predefined themes are defined here + */ +import { CHAT_THEME_OPTIONS } from "../exportedTypes"; + +export interface IChatTheme { + bgColorPrimary?: string; + bgColorSecondary?: string; + textColorPrimary?: string; + textColorSecondary?: string; + accentBgColor?:string; + accentTextColor?:string; + btnColorPrimary?: string; + border?: string; + borderRadius?: string; + iconColorPrimary?: string; + fontFamily?: string; + receiverBgColor?: string; + } + + export const lightTheme: IChatTheme = { + bgColorPrimary:'#fff', + receiverBgColor: "#fff", + bgColorSecondary:'linear-gradient(179.97deg, #EEF5FF 0.02%, #ECE9FA 123.25%)', + textColorPrimary:'#000', + textColorSecondary:'rgb(101, 119, 149)', + accentBgColor:'rgb(202, 89, 155)', + accentTextColor:'#fff', + btnColorPrimary:'rgb(202, 89, 155)', + border:'none', + borderRadius:'32px', + iconColorPrimary:'none' + }; + + export const darkTheme: IChatTheme = { + bgColorPrimary:'rgb(47, 49, 55)', + bgColorSecondary:'rgb(40, 42, 46)', + receiverBgColor: "#fff", + textColorPrimary:'#fff', + textColorSecondary:'rgb(182, 188, 214)', + accentBgColor:'rgb(202, 89, 155)', + accentTextColor:'#fff', + btnColorPrimary:'rgb(202, 89, 155)', + border:'none', + borderRadius:'32px', + iconColorPrimary:'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)' + }; + + + //function to return final theme object +export const getCustomChatTheme = (theme:string | undefined) => { + // return Object.assign({}, theme===CHAT_THEME_OPTIONS.DARK?darkTheme:lightTheme, themeOverride); + return theme===CHAT_THEME_OPTIONS.DARK?darkTheme:lightTheme; + } \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx index 535924540..afef6def9 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx @@ -5,7 +5,7 @@ import { MinimisedModalHeader } from './MinimisedModalHeader'; import { Modal } from './modal'; import type { ChatFeedsType} from '../../types'; import { PUSH_TABS } from '../../types'; -import { CHAT_SOCKET_TYPE } from '../../types'; +import { SOCKET_TYPE } from '../../types'; import { ChatMainStateContext, ChatAndNotificationPropsContext, @@ -13,21 +13,21 @@ import { ChatAndNotificationMainContext, } from '../../context'; import { Section } from '../reusables/sharedStyling'; -import useGetChatProfile from '../../hooks/chat/useGetChatProfile'; +import useGetChatProfile from '../../hooks/useGetChatProfile'; import { chatLimit, device, requestLimit } from '../../config'; -import useFetchRequests from '../../hooks/chat/useFetchRequests'; -import useFetchChats from '../../hooks/chat/useFetchChats'; +import useFetchRequests from '../../hooks/chatAndNotification/chat/useFetchRequests'; +import useFetchChats from '../../hooks/chatAndNotification/chat/useFetchChats'; import { getAddress, getDefaultFeedObject, getNewChatUser, walletToPCAIP10, } from '../../helpers'; -import useFetchUserSubscriptions from '../../hooks/notifications/useFetchUserSubscriptions'; +import useFetchUserSubscriptions from '../../hooks/chatAndNotification/notifications/useFetchUserSubscriptions'; import useChatNotificationSocket from '../../hooks/chatAndNotification/useChatNotificationSocket'; import type { ChatMainStateContextType } from '../../context/chatAndNotification/chat/chatMainStateContext'; import type { IFeeds } from '@pushprotocol/restapi'; -import useFetchChat from '../../hooks/chat/useFetchChat'; +import useFetchChat from '../../hooks/chatAndNotification/chat/useFetchChat'; //make changes for users who dont have decryptedPgpPvtKey @@ -69,7 +69,7 @@ export const ChatAndNotification = () => { const { fetchUserSubscriptions } = useFetchUserSubscriptions(); useChatNotificationSocket({}); - useChatNotificationSocket({ socketType: CHAT_SOCKET_TYPE.CHAT }); + useChatNotificationSocket({ socketType: SOCKET_TYPE.CHAT }); useEffect(() => { setChatsFeed({}); diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/MessageBox.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/MessageBox.tsx index 409fba9b3..958674b37 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/MessageBox.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/MessageBox.tsx @@ -6,7 +6,7 @@ import { import React, { useEffect, useRef, useContext } from 'react'; import { Image, Section, Span } from '../../../reusables/sharedStyling'; import styled from 'styled-components'; -import useFetchHistoryMessages from '../../../../hooks/chat/useFetchHistoryMessages'; +import useFetchHistoryMessages from '../../../../hooks/chatAndNotification/chat/useFetchHistoryMessages'; import type { IMessageIPFS } from '@pushprotocol/restapi'; import { Spinner } from '../../../reusables/Spinner'; import moment from 'moment'; @@ -16,7 +16,7 @@ import { shortenText, } from '../../../../helpers'; import { pCAIP10ToWallet } from '../../../../helpers'; -import useApproveChatRequest from '../../../../hooks/chat/useApproveChatRequest'; +import useApproveChatRequest from '../../../../hooks/chatAndNotification/chat/useApproveChatRequest'; import type { FileMessageContent } from '../../../../types'; import { Typebar } from './typebar/Typebar'; diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/typebar/Typebar.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/typebar/Typebar.tsx index d5b4e0af6..fac3c793b 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/typebar/Typebar.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/messageBox/typebar/Typebar.tsx @@ -6,12 +6,12 @@ import { EmojiIcon } from '../../../../../icons/Emoji'; import { SendIcon } from '../../../../../icons/Send'; import { GifIcon } from '../../../../../icons/Gif'; import { AttachmentIcon } from '../../../../../icons/Attachment'; -import usePushSendMessage from '../../../../../hooks/chat/usePushSendMessage'; +import usePushSendMessage from '../../../../../hooks/chatAndNotification/chat/usePushSendMessage'; import { ChatAndNotificationMainContext, ChatMainStateContext, } from '../../../../../context'; -import useFetchRequests from '../../../../../hooks/chat/useFetchRequests'; +import useFetchRequests from '../../../../../hooks/chatAndNotification/chat/useFetchRequests'; import { Spinner } from '../../../../reusables/Spinner'; import type { EmojiClickData } from 'emoji-picker-react'; import EmojiPicker from 'emoji-picker-react'; diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/Sidebar.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/Sidebar.tsx index 4e090d9fb..445008219 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/Sidebar.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/Sidebar.tsx @@ -16,7 +16,7 @@ import { NotificationMainStateContext, ChatAndNotificationMainContext, } from '../../../../context'; -import useFetchChats from '../../../../hooks/chat/useFetchChats'; +import useFetchChats from '../../../../hooks/chatAndNotification/chat/useFetchChats'; import { Section, Span, Div } from '../../../reusables/sharedStyling'; import { ChatsFeedList } from './chatSidebar/ChatsFeedList'; import type { ChatMainStateContextType } from '../../../../context/chatAndNotification/chat/chatMainStateContext'; @@ -33,11 +33,11 @@ import { } from '../../../../helpers'; import { SpamIconSvg } from '../../../../icons/Spam'; import { InboxNotificationFeedList } from './notificationSidebar/InboxNotificationFeedList'; -import useGetChatProfile from '../../../../hooks/chat/useGetChatProfile'; +import useGetChatProfile from '../../../../hooks/useGetChatProfile'; import { NotificationFeedList } from './notificationSidebar/NotificationFeedList'; import { SidebarPlaceholder } from './SidebarPlaceholder'; import type { ChatAndNotificationMainContextType } from '../../../../context/chatAndNotification/chatAndNotificationMainContext'; -import useFetchChat from '../../../../hooks/chat/useFetchChat'; +import useFetchChat from '../../../../hooks/chatAndNotification/chat/useFetchChat'; import type { IFeeds } from '@pushprotocol/restapi'; export type TabPropType = { diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx index 68e1679cc..affcf369d 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/ChatsFeedList.tsx @@ -1,4 +1,4 @@ -import useFetchChats from '../../../../../hooks/chat/useFetchChats'; +import useFetchChats from '../../../../../hooks/chatAndNotification/chat/useFetchChats'; import React, { useEffect, useState, useContext, useRef } from 'react'; import styled from 'styled-components'; diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx index f337fdde2..8b8652b63 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/chatSidebar/RequestsFeedList.tsx @@ -1,4 +1,4 @@ -import useFetchRequests from '../../../../../hooks/chat/useFetchRequests'; +import useFetchRequests from '../../../../../hooks/chatAndNotification/chat/useFetchRequests'; import React, { useEffect, useState, useContext, useRef } from 'react'; import styled from 'styled-components'; import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../../../../context'; diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx index 7a24fc805..d59802a83 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/InboxNotificationFeedList.tsx @@ -11,7 +11,7 @@ import { Spinner } from '../../../../reusables/Spinner'; import { useIsInViewport } from '../../../../../hooks'; import { NotificationFeedList } from './NotificationFeedList'; -import useFetchNotification from '../../../../../hooks/notifications/useFetchNotification'; +import useFetchNotification from '../../../../../hooks/chatAndNotification/notifications/useFetchNotification'; import type { NotificationFeedsType, ParsedNotificationType} from '../../../../../types'; import { diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/NotificationFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/NotificationFeedList.tsx index 740a8fd8b..401267c97 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/NotificationFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/NotificationFeedList.tsx @@ -4,7 +4,7 @@ import type { chainNameType, INotificationItemTheme} from '../../../../notificat import { notificationLightTheme } from '../../../../notification'; import { NotificationItem } from '../../../../notification'; import { ChatAndNotificationPropsContext, NotificationMainStateContext } from '../../../../../context'; -import useOnSubscribeToChannel from '../../../../../hooks/notifications/useOnSubscribeToChannel'; +import useOnSubscribeToChannel from '../../../../../hooks/chatAndNotification/notifications/useOnSubscribeToChannel'; import { Div } from '../../../../reusables'; type NotificationFeedListPropType = { diff --git a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx index de6c554fa..fb1131d6e 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/modal/sidebar/notificationSidebar/SpamNotificationFeedList.tsx @@ -13,7 +13,7 @@ import { useIsInViewport } from '../../../../../hooks'; import { NotificationFeedList } from './NotificationFeedList'; import { notificationLimit } from '../../../../../config'; import type { NotificationFeedsType } from '../../../../../types'; -import useFetchNotification from '../../../../../hooks/notifications/useFetchNotification'; +import useFetchNotification from '../../../../../hooks/chatAndNotification/notifications/useFetchNotification'; export const SpamNotificationFeedList = () => { const { spamNotifsFeed, setSpamNotifsFeed,finishedFetchingSpam,setFinishedFetchingSpam } = useContext( diff --git a/packages/uiweb/src/lib/components/index.ts b/packages/uiweb/src/lib/components/index.ts index a91afffe8..f73274b34 100644 --- a/packages/uiweb/src/lib/components/index.ts +++ b/packages/uiweb/src/lib/components/index.ts @@ -4,3 +4,4 @@ export * from './subscribemodal'; export * from './space'; export * from './supportChat'; export * from './chatAndNotification'; +export * from './chat'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/context/chatContext.ts b/packages/uiweb/src/lib/context/chatContext.ts new file mode 100644 index 000000000..330936e67 --- /dev/null +++ b/packages/uiweb/src/lib/context/chatContext.ts @@ -0,0 +1,52 @@ +import { Env,IMessageIPFS, IUser } from "@pushprotocol/restapi"; +import { Constants } from "../config"; +import { createContext } from "react"; + + +export interface IChatDataContextValues { + account: string | null; + setAccount: React.Dispatch>; + pgpPrivateKey: string | null; + setPgpPrivateKey: React.Dispatch>; + env: Env; + setEnv: React.Dispatch>; + pushChatSocket: any; + setPushChatSocket: React.Dispatch>; + isPushChatSocketConnected: boolean; + setIsPushChatSocketConnected: React.Dispatch>; + connectedProfile: IUser | undefined; + setConnectedProfile: (connectedProfile: IUser) => void; +} + +export const initialChatDataContextValues: IChatDataContextValues = { + account: null, + setAccount: () => { + /**/ + }, + pgpPrivateKey: '', + setPgpPrivateKey: () => { + /**/ + }, + env: Constants.ENV.DEV, + setEnv: () => { + /**/ + }, + pushChatSocket: null, + setPushChatSocket: () => { + /** */ + }, + isPushChatSocketConnected: false, + setIsPushChatSocketConnected: () => { + /** */ + }, + connectedProfile: undefined, + setConnectedProfile: () => { + /** */ + } + +} + + +export const ChatDataContext = createContext( + initialChatDataContextValues + ); \ No newline at end of file diff --git a/packages/uiweb/src/lib/context/index.ts b/packages/uiweb/src/lib/context/index.ts index 35b23b387..49bf48467 100644 --- a/packages/uiweb/src/lib/context/index.ts +++ b/packages/uiweb/src/lib/context/index.ts @@ -1,5 +1,6 @@ import { SpaceDataContext } from "./spacesContext"; +import { ChatDataContext } from "./chatContext"; import SupportChatPropsContext from "./supportChat/supportChatPropsContext"; import SupportChatMainStateContext from "./supportChat/supportChatMainStateContext"; import ChatMainStateContextProvider, { ChatMainStateContext } from "./chatAndNotification/chat/chatMainStateContext"; @@ -10,6 +11,7 @@ import ChatAndNotificationMainContextProvider, { ChatAndNotificationMainContext export { SupportChatPropsContext, SpaceDataContext, + ChatDataContext, SupportChatMainStateContext, ChatMainStateContextProvider, ChatAndNotificationPropsContext, diff --git a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx new file mode 100644 index 000000000..e12d02dff --- /dev/null +++ b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx @@ -0,0 +1,81 @@ +import { useState, ReactNode, useEffect } from 'react'; +import { Constants, ENV } from '../config'; +import { + ChatDataContext, + IChatDataContextValues, +} from '../context/chatContext'; +import { ThemeContext } from '../components/chat/theme/ThemeProvider'; +import useGetChatProfile from '../hooks/useGetChatProfile'; +import { IUser } from '@pushprotocol/restapi'; +import { IChatTheme, getCustomChatTheme } from '../components/chat/theme'; +import { ChatThemeOptions } from '../components'; + +export interface IChatUIProviderProps { + children: ReactNode; + theme?: ChatThemeOptions; + themeOverride?: Partial; + account?: string | null; + pgpPrivateKey?: string | null; + env?: ENV; +} + +export const ChatUIProvider = ({ + children, + account = null, + theme, + pgpPrivateKey = null, + env = Constants.ENV.PROD, +}: IChatUIProviderProps) => { + const [accountVal, setAccountVal] = useState(account); + const [pushChatSocket, setPushChatSocket] = useState(null); + const [pgpPrivateKeyVal, setPgpPrivateKeyVal] = + useState(pgpPrivateKey); + const [envVal, setEnvVal] = useState(env); + const {fetchChatProfile} = useGetChatProfile(); + const [connectedProfile,setConnectedProfile]=useState(undefined); + + const [isPushChatSocketConnected, setIsPushChatSocketConnected] = + useState(false); + +useEffect(()=>{ + setAccountVal(account) + setPgpPrivateKeyVal(pgpPrivateKey) +},[pgpPrivateKey]) + +useEffect(() => { + (async () => { + let user; + if (account) { + user = await fetchChatProfile({ profileId: account }); + + if (user) setConnectedProfile(user); + } + })(); + }, [account]); + + const value: IChatDataContextValues = { + account: accountVal, + setAccount: setAccountVal, + pgpPrivateKey: pgpPrivateKeyVal, + setPgpPrivateKey: setPgpPrivateKeyVal, + env: envVal, + setEnv: setEnvVal, + pushChatSocket, + setPushChatSocket, + isPushChatSocketConnected, + setIsPushChatSocketConnected, + connectedProfile, + setConnectedProfile + }; + + + const PROVIDER_THEME = getCustomChatTheme(theme); + + return ( + + + {children} + + + ); +}; diff --git a/packages/uiweb/src/lib/dataProviders/index.ts b/packages/uiweb/src/lib/dataProviders/index.ts index bf7f090a8..c59db8bc5 100644 --- a/packages/uiweb/src/lib/dataProviders/index.ts +++ b/packages/uiweb/src/lib/dataProviders/index.ts @@ -1 +1,2 @@ -export * from "./SpaceDataProvider"; \ No newline at end of file +export * from "./SpaceDataProvider"; +export * from "./ChatDataProvider"; \ No newline at end of file diff --git a/packages/uiweb/src/lib/helpers/chat/chat.ts b/packages/uiweb/src/lib/helpers/chat/chat.ts index 24577d3fe..8990916c9 100644 --- a/packages/uiweb/src/lib/helpers/chat/chat.ts +++ b/packages/uiweb/src/lib/helpers/chat/chat.ts @@ -1,10 +1,10 @@ import * as PushAPI from '@pushprotocol/restapi'; import type { ENV } from '../../config'; import { Constants } from '../../config'; -import type { AccountEnvOptionsType, IMessageIPFS } from '../../types'; +import type { AccountEnvOptionsType, IMessageIPFS, Messagetype } from '../../types'; import { ChatFeedsType } from '../../types'; import type { Env, IConnectedUser, IFeeds, IUser } from '@pushprotocol/restapi'; -import { walletToPCAIP10 } from '../address'; +import { isPCAIP, pCAIP10ToWallet, walletToPCAIP10 } from '../address'; import { getData } from './localStorage'; type HandleOnChatIconClickProps = { @@ -182,3 +182,33 @@ export const checkIfUnread = (chatId:string,chat:IFeeds):boolean => { return false; } + +export const getChatId = ({ + msg, + account, +}: { + msg: IMessageIPFS; + account: string; +}) => { + if (pCAIP10ToWallet(msg.fromDID).toLowerCase() === account.toLowerCase()) { + return msg.toDID; + } + return !isPCAIP(msg.toDID) ? msg.toDID : msg.fromDID; +}; + +export const appendUniqueMessages = (parentList:Messagetype,newlist:IMessageIPFS[],infront:boolean) =>{ + const uniqueMap: { [timestamp: number]: IMessageIPFS } = {}; + const appendedArray = infront?[...newlist, ...parentList.messages]:[ ...parentList.messages,...newlist]; + const newMessageList = Object.values( + appendedArray.reduce( + (uniqueMap, message) => { + if (message.timestamp && !uniqueMap[message.timestamp]) { + uniqueMap[message.timestamp] = message; + } + return uniqueMap; + }, + uniqueMap + ) + ); + return newMessageList +} \ No newline at end of file diff --git a/packages/uiweb/src/lib/helpers/chat/localStorage.ts b/packages/uiweb/src/lib/helpers/chat/localStorage.ts index 2750a0cf7..4d7dac903 100644 --- a/packages/uiweb/src/lib/helpers/chat/localStorage.ts +++ b/packages/uiweb/src/lib/helpers/chat/localStorage.ts @@ -1,11 +1,12 @@ -import type { IFeeds} from '@pushprotocol/restapi'; +import type { IFeeds } from '@pushprotocol/restapi'; import { IMessageIPFS } from '@pushprotocol/restapi'; import { ChatFeedsType, LocalStorageKeys } from '../../types'; - +import * as PUSHAPI from '@pushprotocol/restapi'; +import { ENV } from '../../config'; type SetDataType = { - chatId:string, - value:IFeeds; + chatId: string; + value: IFeeds; }; //store only if there isnt a chat @@ -13,13 +14,50 @@ export const setData = ({ chatId, value }: SetDataType): void => { localStorage.setItem(chatId, JSON.stringify(value)); }; +//add return type +export const getData = (key: string): IFeeds | null => { + const chatJson = localStorage.getItem(key); + const chat = chatJson ? JSON.parse(chatJson) : null; + return chat; +}; + +export const getPfp = async ({ + account, + env, +}: { + account: string; + env: ENV; +}) => { + const fetchData = async () => { + try { + const response = await PUSHAPI.user.get({ + account: account, + env: env, + }); + const pfp = response.profile.picture ? response.profile.picture : ''; + setPfp({ account, value: pfp }); + return pfp; + } catch (err: Error | any) { + console.log(err.message); + return ''; + } + }; + const pfp = localStorage.getItem(account); - -//add return type -export const getData = (key: string):IFeeds | null => { - const chatJson=localStorage.getItem(key); - const chat = chatJson?JSON.parse(chatJson):null; - return chat; + if (pfp === null) { + return fetchData(); + } else { + return pfp; + } }; +export const setPfp = ({ + account, + value, +}: { + account: string; + value: string; +}) => { + localStorage.setItem(account, value); +}; diff --git a/packages/uiweb/src/lib/hooks/chat/index.ts b/packages/uiweb/src/lib/hooks/chat/index.ts index a11caf610..93b5dafbe 100644 --- a/packages/uiweb/src/lib/hooks/chat/index.ts +++ b/packages/uiweb/src/lib/hooks/chat/index.ts @@ -1,9 +1,4 @@ -export * from './useFetchChats'; -export * from './useFetchRequests'; export * from './useFetchHistoryMessages'; -export * from './useFetchConversationHash'; -export * from './useApproveChatRequest'; -export * from './useFetchChat'; -export * from './usePushSendMessage'; -export * from './useIsInViewport'; -export * from './useGetChatProfile'; \ No newline at end of file +export * from './useChatData'; + +export * from './usePushChatSocket'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/chat/useChatData.ts b/packages/uiweb/src/lib/hooks/chat/useChatData.ts new file mode 100644 index 000000000..6ecbbaa14 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useChatData.ts @@ -0,0 +1,11 @@ +import { useContext } from "react"; +import { ChatDataContext } from "../../context"; +import { IChatDataContextValues } from "../../context/chatContext"; + +export const useChatData = (): IChatDataContextValues => { + const context = useContext(ChatDataContext); + if (!context) { + throw new Error('useSpaceData must be used within a ChatDataProvider'); + } + return context; +} \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts b/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts index 998bfef64..bddf1e64c 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts @@ -1,11 +1,9 @@ import * as PushAPI from '@pushprotocol/restapi'; import type { IMessageIPFS } from '@pushprotocol/restapi'; -import { Env } from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { Constants } from '../../config'; -import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../context'; -import type { ChatMainStateContextType } from '../../context/chatAndNotification/chat/chatMainStateContext'; +import { ChatDataContext } from '../../context'; + @@ -19,10 +17,9 @@ const useFetchHistoryMessages = () => { const [error, setError] = useState(); const [loading, setLoading] = useState(false); - const { chats,setChat,selectedChatId} = - useContext(ChatMainStateContext); - const { account, env,decryptedPgpPvtKey } = - useContext(ChatAndNotificationPropsContext); + + const { account, env,pgpPrivateKey } = + useContext(ChatDataContext); const historyMessages = useCallback(async ({threadHash,limit = 10,}:HistoryMessagesParams) => { @@ -31,40 +28,24 @@ const useFetchHistoryMessages const chatHistory:IMessageIPFS[] = await PushAPI.chat.history({ threadhash: threadHash, account: account, - toDecrypt: decryptedPgpPvtKey ? true : false, - pgpPrivateKey: String(decryptedPgpPvtKey), + toDecrypt: pgpPrivateKey ? true : false, + pgpPrivateKey: String(pgpPrivateKey), limit: limit, env: env }); chatHistory.reverse(); - if (chats.get(selectedChatId as string)) { - const uniqueMap: { [timestamp: number]: IMessageIPFS } = {}; - const messages = Object.values( - [...chatHistory, ...chats.get(selectedChatId as string)!.messages].reduce((uniqueMap, message) => { - if (message.timestamp && !uniqueMap[message.timestamp]) { - uniqueMap[message.timestamp] = message; - } - return uniqueMap; - }, uniqueMap) - ); - setChat(selectedChatId as string, { - messages: messages, - lastThreadHash: chatHistory[0].link - }); - } else { - setChat(selectedChatId as string, { messages: chatHistory, lastThreadHash: chatHistory[0].link }); - } + return chatHistory; } catch (error: Error | any) { setLoading(false); setError(error.message); console.log(error); + return; } finally { setLoading(false); } - }, [chats]); + }, [pgpPrivateKey,account,env]); return { historyMessages, error, loading }; }; -export default useFetchHistoryMessages -; +export default useFetchHistoryMessages; diff --git a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts new file mode 100644 index 000000000..81e173358 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts @@ -0,0 +1,134 @@ +import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; +import { useCallback, useEffect, useState } from 'react'; +import { ENV } from '../../config'; +import * as PushAPI from '@pushprotocol/restapi'; +import type { IMessageIPFS } from '@pushprotocol/restapi'; +import { isAccountsEqual } from '../../components/space/helpers/account'; +import { useChatData } from './useChatData'; +import { SOCKET_TYPE } from '../../types'; +import { getChatId } from '../../helpers'; + + +export type PushChatSocketHookOptions = { + account?: string | null; + env?: ENV; +}; + +export const usePushChatSocket = () => { + const { + account, + pgpPrivateKey, + pushChatSocket, + setPushChatSocket, + setIsPushChatSocketConnected, + isPushChatSocketConnected, + connectedProfile, + env + } = useChatData(); + + const [messagesSinceLastConnection,setMessagesSinceLastConnection] = useState({}); + const addSocketEvents = useCallback(() => { + console.log('addSocketEvents'); + pushChatSocket?.on(EVENTS.CONNECT, () => { + setIsPushChatSocketConnected(true); + }); + + pushChatSocket?.on(EVENTS.DISCONNECT, (reason: string) => { + setIsPushChatSocketConnected(false); + }); + + + pushChatSocket?.on( + EVENTS.CHAT_RECEIVED_MESSAGE, + async (chat: any) => { + if (!connectedProfile || !pgpPrivateKey) { + return; + } + // const chatId = getChatId({ msg: chat, account:account! }).toLowerCase(); + if ( + chat.messageCategory === 'Request' && + chat.messageContent === null && + chat.messageType === null + ) { + return; + } + + const response = await PushAPI.chat.decryptConversation({ + messages: [chat], + connectedUser: connectedProfile, + pgpPrivateKey: pgpPrivateKey, + env: env, + }); + if (response && response.length) { + setMessagesSinceLastConnection(response[0]); + } + } + ); + + + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [ + pushChatSocket, + account, + pgpPrivateKey, + messagesSinceLastConnection, + env, + + ]); + + const removeSocketEvents = useCallback(() => { + pushChatSocket?.off(EVENTS.CONNECT); + pushChatSocket?.off(EVENTS.DISCONNECT); + pushChatSocket?.off(EVENTS.CHAT_GROUPS); + pushChatSocket?.off(EVENTS.CHAT_RECEIVED_MESSAGE); + }, [pushChatSocket]); + + useEffect(() => { + if (pushChatSocket) { + addSocketEvents(); + } + + return () => { + if (pushChatSocket) { + removeSocketEvents(); + } + }; + }, [pushChatSocket]); + + /** + * Whenever the required params to create a connection object change + * - disconnect the old connection + * - create a new connection object + */ + useEffect(() => { + if (account) { + if (pushChatSocket && pushChatSocket.connected) { + // console.log('=================>>> disconnection in the hook'); + // pushChatSocket?.disconnect(); + } + else { + const main = async () => { + const connectionObject = createSocketConnection({ + user: account, + env, + socketType: SOCKET_TYPE.CHAT, + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + }); + console.warn('new connection object: ', connectionObject); + + setPushChatSocket(connectionObject); + }; + main().catch((err) => console.error(err)); + } + + } + + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [account, env]); + + return { + pushChatSocket, + isPushChatSocketConnected, + messagesSinceLastConnection + }; +}; diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/chat/index.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/index.ts new file mode 100644 index 000000000..49cf9937a --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/index.ts @@ -0,0 +1,8 @@ +export * from './useFetchChats'; +export * from './useFetchRequests'; +export * from './useFetchHistoryMessages'; +export * from './useFetchConversationHash'; +export * from './useApproveChatRequest'; +export * from './useFetchChat'; +export * from './usePushSendMessage'; +export * from './useIsInViewport'; diff --git a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useApproveChatRequest.ts similarity index 94% rename from packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/useApproveChatRequest.ts index 703c9e73b..93755a3f5 100644 --- a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useApproveChatRequest.ts @@ -1,6 +1,6 @@ import * as PushAPI from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { ChatAndNotificationPropsContext } from '../../context'; +import { ChatAndNotificationPropsContext } from '../../../context'; interface ApproveChatParams { senderAddress: string; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchChat.ts similarity index 91% rename from packages/uiweb/src/lib/hooks/chat/useFetchChat.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchChat.ts index 7357e6289..2e0ea21f4 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchChat.ts @@ -1,8 +1,8 @@ import * as PushAPI from '@pushprotocol/restapi'; import { Env } from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { Constants } from '../../config'; -import { ChatAndNotificationPropsContext } from '../../context'; +import { Constants } from '../../../config'; +import { ChatAndNotificationPropsContext } from '../../../context'; interface fetchChat { diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchChats.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchChats.ts similarity index 87% rename from packages/uiweb/src/lib/hooks/chat/useFetchChats.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchChats.ts index fa2fb44da..51805ca41 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchChats.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchChats.ts @@ -1,11 +1,11 @@ import type { Env, IFeeds } from '@pushprotocol/restapi'; import * as PushAPI from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { Constants } from '../../config'; -import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../context'; -import { getData, setData } from '../../helpers/chat/localStorage'; -import type { ChatFeedsType} from '../../types'; -import { LOCAL_STORAGE_KEYS } from '../../types'; +import { Constants } from '../../../config'; +import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../../context'; +import { getData, setData } from '../../../helpers/chat/localStorage'; +import type { ChatFeedsType} from '../../../types'; +import { LOCAL_STORAGE_KEYS } from '../../../types'; interface fetchChats { page: number; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchConversationHash.ts similarity index 90% rename from packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchConversationHash.ts index e32610ae9..03e21cba4 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchConversationHash.ts @@ -1,8 +1,8 @@ import * as PushAPI from '@pushprotocol/restapi'; import { Env } from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { Constants } from '../../config'; -import { ChatAndNotificationPropsContext } from '../../context'; +import { Constants } from '../../../config'; +import { ChatAndNotificationPropsContext } from '../../../context'; interface conversationHashParams { conversationId: string; diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts new file mode 100644 index 000000000..a5394d73d --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts @@ -0,0 +1,70 @@ + +import * as PushAPI from '@pushprotocol/restapi'; +import type { IMessageIPFS } from '@pushprotocol/restapi'; +import { Env } from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; +import { Constants } from '../../../config'; +import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../../context'; +import type { ChatMainStateContextType } from '../../../context/chatAndNotification/chat/chatMainStateContext'; + + + + interface HistoryMessagesParams { + threadHash: string; + limit?: number; + } + + +const useFetchHistoryMessages + = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const { chats,setChat,selectedChatId} = + useContext(ChatMainStateContext); + const { account, env,decryptedPgpPvtKey } = + useContext(ChatAndNotificationPropsContext); + + const historyMessages = useCallback(async ({threadHash,limit = 10,}:HistoryMessagesParams) => { + + setLoading(true); + try { + const chatHistory:IMessageIPFS[] = await PushAPI.chat.history({ + threadhash: threadHash, + account: account, + toDecrypt: decryptedPgpPvtKey ? true : false, + pgpPrivateKey: String(decryptedPgpPvtKey), + limit: limit, + env: env + }); + chatHistory.reverse(); + if (chats.get(selectedChatId as string)) { + const uniqueMap: { [timestamp: number]: IMessageIPFS } = {}; + const messages = Object.values( + [...chatHistory, ...chats.get(selectedChatId as string)!.messages].reduce((uniqueMap, message) => { + if (message.timestamp && !uniqueMap[message.timestamp]) { + uniqueMap[message.timestamp] = message; + } + return uniqueMap; + }, uniqueMap) + ); + setChat(selectedChatId as string, { + messages: messages, + lastThreadHash: chatHistory[0].link + }); + } else { + setChat(selectedChatId as string, { messages: chatHistory, lastThreadHash: chatHistory[0].link }); + } + } catch (error: Error | any) { + setLoading(false); + setError(error.message); + console.log(error); + } finally { + setLoading(false); + } + }, [chats]); + + return { historyMessages, error, loading }; +}; + +export default useFetchHistoryMessages +; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchRequests.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchRequests.ts similarity index 87% rename from packages/uiweb/src/lib/hooks/chat/useFetchRequests.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchRequests.ts index 40fb3aec7..b5972ab12 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchRequests.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchRequests.ts @@ -2,10 +2,10 @@ import type { Env, IFeeds } from '@pushprotocol/restapi'; import * as PushAPI from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import type { ChatFeedsType} from '../..'; -import { Constants } from '../..'; -import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../context'; -import type { ChatMainStateContextType } from '../../context/chatAndNotification/chat/chatMainStateContext'; +import type { ChatFeedsType} from '../../../'; +import { Constants } from '../../../'; +import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../../context'; +import type { ChatMainStateContextType } from '../../../context/chatAndNotification/chat/chatMainStateContext'; interface fetchRequests { diff --git a/packages/uiweb/src/lib/hooks/chat/useIsInViewport.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useIsInViewport.ts similarity index 100% rename from packages/uiweb/src/lib/hooks/chat/useIsInViewport.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/useIsInViewport.ts diff --git a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/usePushSendMessage.ts similarity index 94% rename from packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/chat/usePushSendMessage.ts index 9208a46c8..646601d41 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/usePushSendMessage.ts @@ -1,9 +1,9 @@ import * as PushAPI from '@pushprotocol/restapi'; import { Env, IFeeds } from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { Constants } from '../../config'; -import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../context'; -import type { ChatMainStateContextType } from '../../context/chatAndNotification/chat/chatMainStateContext'; +import { Constants } from '../../../config'; +import { ChatMainStateContext, ChatAndNotificationPropsContext } from '../../../context'; +import type { ChatMainStateContextType } from '../../../context/chatAndNotification/chat/chatMainStateContext'; import useFetchChat from './useFetchChat'; interface SendMessageParams { diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/index.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/index.ts index 5f7ad156a..55901993e 100644 --- a/packages/uiweb/src/lib/hooks/chatAndNotification/index.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/index.ts @@ -1 +1,3 @@ -export * from './useChatNotificationSocket'; \ No newline at end of file +export * from './useChatNotificationSocket'; +export * from './chat'; +export * from './notifications'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/notifications/index.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/index.ts similarity index 100% rename from packages/uiweb/src/lib/hooks/notifications/index.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/notifications/index.ts diff --git a/packages/uiweb/src/lib/hooks/notifications/useFetchNotification.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useFetchNotification.ts similarity index 87% rename from packages/uiweb/src/lib/hooks/notifications/useFetchNotification.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useFetchNotification.ts index 7a0dab907..49208c4e9 100644 --- a/packages/uiweb/src/lib/hooks/notifications/useFetchNotification.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useFetchNotification.ts @@ -1,9 +1,9 @@ import * as PushAPI from '@pushprotocol/restapi'; import type { ParsedResponseType} from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { ChatAndNotificationPropsContext } from '../../context'; -import { ParsedNotificationType } from '../../types'; -import { convertReponseToParsedArray } from '../../helpers/notification'; +import { ChatAndNotificationPropsContext } from '../../../context'; +import { ParsedNotificationType } from '../../../types'; +import { convertReponseToParsedArray } from '../../../helpers/notification'; interface fetchNotification { diff --git a/packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useFetchUserSubscriptions.ts similarity index 89% rename from packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useFetchUserSubscriptions.ts index 1c81fc7d6..7796362b5 100644 --- a/packages/uiweb/src/lib/hooks/notifications/useFetchUserSubscriptions.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useFetchUserSubscriptions.ts @@ -4,9 +4,9 @@ import { useCallback, useContext, useState } from 'react'; import { ChatAndNotificationPropsContext, NotificationMainStateContext, -} from '../../context'; -import { ParsedNotificationType } from '../../types'; -import { convertAddressToAddrCaip } from '../../helpers/notification'; +} from '../../../context'; +import { ParsedNotificationType } from '../../../types'; +import { convertAddressToAddrCaip } from '../../../helpers/notification'; const useFetchUserSubscriptions = () => { const [error, setError] = useState(); diff --git a/packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useOnSubscribeToChannel.ts similarity index 94% rename from packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts rename to packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useOnSubscribeToChannel.ts index 8f7e87729..1784893cb 100644 --- a/packages/uiweb/src/lib/hooks/notifications/useOnSubscribeToChannel.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/notifications/useOnSubscribeToChannel.ts @@ -1,8 +1,8 @@ import * as PushAPI from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; -import { ChatAndNotificationPropsContext, NotificationMainStateContext } from '../../context'; +import { ChatAndNotificationPropsContext, NotificationMainStateContext } from '../../../context'; -import { convertAddressToAddrCaip } from '../../helpers/notification'; +import { convertAddressToAddrCaip } from '../../../helpers/notification'; interface onSubscribeToChannel { channelAddress: string; diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts index f3d8e61a0..921043f0d 100644 --- a/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts @@ -1,4 +1,4 @@ -import type { IFeeds, IMessageIPFS } from '@pushprotocol/restapi'; +import type { IFeeds } from '@pushprotocol/restapi'; import * as PushAPI from '@pushprotocol/restapi'; import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; import { useCallback, useContext, useEffect, useState } from 'react'; @@ -10,20 +10,20 @@ import { import type { ChatMainStateContextType } from '../../context/chatAndNotification/chat/chatMainStateContext'; import { checkIfIntent, - getData, + getChatId, isPCAIP, - pCAIP10ToWallet, + setData, } from '../../helpers'; import { convertAddressToAddrCaip, convertReponseToParsedArray, } from '../../helpers/notification'; -import type { ChatSocketType } from '../../types'; -import { CHAT_SOCKET_TYPE } from '../../types'; +import type { SocketType } from '../../types'; +import { SOCKET_TYPE } from '../../types'; -import useFetchChat from '../chat/useFetchChat'; -import useGetChatProfile from '../chat/useGetChatProfile'; +import useFetchChat from './chat/useFetchChat'; +import useGetChatProfile from '../useGetChatProfile'; interface PushChatNotificationSocket { pushChatNotificationSocket: any; @@ -34,24 +34,11 @@ interface PushChatNotificationSocket { } export type pushChatNotificationSocketType = { - socketType?: ChatSocketType; -}; - -const getChatId = ({ - msg, - account, -}: { - msg: IMessageIPFS; - account: string; -}) => { - if (pCAIP10ToWallet(msg.fromDID).toLowerCase() === account.toLowerCase()) { - return msg.toDID; - } - return !isPCAIP(msg.toDID) ? msg.toDID : msg.fromDID; + socketType?: SocketType; }; const useChatNotificationSocket = ({ - socketType = CHAT_SOCKET_TYPE.NOTIFICATION, + socketType = SOCKET_TYPE.NOTIFICATION, }: pushChatNotificationSocketType): PushChatNotificationSocket => { const [isSDKSocketConnected, setIsSDKSocketConnected] = useState(false); @@ -248,7 +235,7 @@ const useChatNotificationSocket = ({ // this is auto-connect on instantiation const connectionObject = createSocketConnection({ user: - socketType === CHAT_SOCKET_TYPE.CHAT + socketType === SOCKET_TYPE.CHAT ? account : convertAddressToAddrCaip(account, chainId), socketType, diff --git a/packages/uiweb/src/lib/hooks/exportedHooks.ts b/packages/uiweb/src/lib/hooks/exportedHooks.ts new file mode 100644 index 000000000..37ce84e9d --- /dev/null +++ b/packages/uiweb/src/lib/hooks/exportedHooks.ts @@ -0,0 +1,2 @@ +export * from "./chat/usePushChatSocket"; + diff --git a/packages/uiweb/src/lib/hooks/index.ts b/packages/uiweb/src/lib/hooks/index.ts index 8ebc61937..35a59c29f 100644 --- a/packages/uiweb/src/lib/hooks/index.ts +++ b/packages/uiweb/src/lib/hooks/index.ts @@ -1,10 +1,10 @@ export * from './useClickAway'; export * from './useChatScroll'; export * from "./space"; -export * from './chat'; export * from './useSDKSocket'; export * from './useResolveWeb3Name'; -export * from './notifications'; +export * from './chat'; export * from './chatAndNotification'; export * from './useDivOffsetWidth'; export * from './useDeviceWidthCheck'; +export * from './useGetChatProfile'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/chat/useGetChatProfile.ts b/packages/uiweb/src/lib/hooks/useGetChatProfile.ts similarity index 91% rename from packages/uiweb/src/lib/hooks/chat/useGetChatProfile.ts rename to packages/uiweb/src/lib/hooks/useGetChatProfile.ts index 189507d7a..6bfb1e5e5 100644 --- a/packages/uiweb/src/lib/hooks/chat/useGetChatProfile.ts +++ b/packages/uiweb/src/lib/hooks/useGetChatProfile.ts @@ -1,6 +1,6 @@ import * as PushAPI from '@pushprotocol/restapi'; import { useCallback, useContext } from 'react'; -import { ChatAndNotificationPropsContext } from '../../context'; +import { ChatAndNotificationPropsContext } from '../context'; export interface GetProfileParams { profileId: string; diff --git a/packages/uiweb/src/lib/index.ts b/packages/uiweb/src/lib/index.ts index b81e6f07f..fcf85641b 100644 --- a/packages/uiweb/src/lib/index.ts +++ b/packages/uiweb/src/lib/index.ts @@ -2,3 +2,5 @@ export * from './components' export * from './config'; export * from './dataProviders'; export * from './types'; + +export * from './hooks/exportedHooks'; diff --git a/packages/uiweb/src/lib/types/index.ts b/packages/uiweb/src/lib/types/index.ts index 5a48d32f5..51a5d97e9 100644 --- a/packages/uiweb/src/lib/types/index.ts +++ b/packages/uiweb/src/lib/types/index.ts @@ -84,7 +84,7 @@ export const PUSH_TABS = { APP_NOTIFICATIONS: 'APP_NOTIFICATIONS' } as const; -export const CHAT_SOCKET_TYPE = { +export const SOCKET_TYPE = { CHAT: 'chat', NOTIFICATION: 'notification' } as const; @@ -110,11 +110,12 @@ export type SidebarPlaceholderKeys = (typeof SIDEBAR_PLACEHOLDER_KEYS)[keyof typ export type LocalStorageKeys = (typeof LOCAL_STORAGE_KEYS)[keyof typeof LOCAL_STORAGE_KEYS]; export type PushTabs = (typeof PUSH_TABS)[keyof typeof PUSH_TABS]; export type PushSubTabs = (typeof PUSH_SUB_TABS)[keyof typeof PUSH_SUB_TABS]; -export type ChatSocketType = (typeof CHAT_SOCKET_TYPE)[keyof typeof CHAT_SOCKET_TYPE]; +export type SocketType = (typeof SOCKET_TYPE)[keyof typeof SOCKET_TYPE]; export interface FileMessageContent { content: string name: string type: string size: number -} \ No newline at end of file +} +export type Messagetype = { messages: IMessageIPFS[]; lastThreadHash: string | null }; diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index b5896656b..0e38365e7 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -2,61 +2,16 @@ # yarn lockfile v1 -"@babel/code-frame@^7.0.0": - version "7.21.4" - resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.21.4.tgz#d0fa9e4413aca81f2b23b9442797bda1826edb39" - integrity sha512-LYvhNKfwWSPpocw8GI7gpK2nq3HSDuEPC/uSYaALSJu9xjsalaaYFOq0Pwt5KmVqwEbZlDu81aLXwBOmD/Fv9g== - dependencies: - "@babel/highlight" "^7.18.6" - -"@babel/helper-string-parser@^7.21.5": +"@babel/runtime@^7.13.10", "@babel/runtime@^7.21.0": version "7.21.5" - resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.21.5.tgz#2b3eea65443c6bdc31c22d037c65f6d323b6b2bd" - integrity sha512-5pTUx3hAJaZIdW99sJ6ZUUgWq/Y+Hja7TowEnLNMm1VivRgZQL3vpBY3qUACVsvw+yQU6+YgfBVmcbLaZtrA1w== - -"@babel/helper-validator-identifier@^7.18.6", "@babel/helper-validator-identifier@^7.19.1": - version "7.19.1" - resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.19.1.tgz#7eea834cf32901ffdc1a7ee555e2f9c27e249ca2" - integrity sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w== - -"@babel/highlight@^7.18.6": - version "7.18.6" - resolved "https://registry.yarnpkg.com/@babel/highlight/-/highlight-7.18.6.tgz#81158601e93e2563795adcbfbdf5d64be3f2ecdf" - integrity sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g== - dependencies: - "@babel/helper-validator-identifier" "^7.18.6" - chalk "^2.0.0" - js-tokens "^4.0.0" - -"@babel/parser@^7.1.0", "@babel/parser@^7.20.7": - version "7.22.4" - resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.22.4.tgz#a770e98fd785c231af9d93f6459d36770993fb32" - integrity sha512-VLLsx06XkEYqBtE5YGPwfSGwfrjnyPP5oiGty3S8pQLFDFLaS8VwWSIxkTXpcvr5zeYLE6+MBNl2npl/YnfofA== - -"@babel/runtime@^7.13.10": - version "7.22.6" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.6.tgz#57d64b9ae3cff1d67eb067ae117dac087f5bd438" - integrity sha512-wDb5pWm4WDdF6LFUde3Jl8WzPA+3ZbxYqkC6xAXuD3irdEHN1k0NfTRrJD8ZD378SJ61miMLCqIOXYhd8x+AJQ== + resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.21.5.tgz" + integrity sha512-8jI69toZqqcsnqGGqwGS4Qb1VwLOEp4hz+CXPywcvjs60u3B4Pom/U/7rm4W8tMOYEB+E9wgD0mW1l3r8qlI9Q== dependencies: regenerator-runtime "^0.13.11" -"@babel/types@^7.0.0", "@babel/types@^7.20.7": - version "7.22.4" - resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.22.4.tgz#56a2653ae7e7591365dabf20b76295410684c071" - integrity sha512-Tx9x3UBHTTsMSW85WB2kphxYQVvrZ/t1FxD88IpSgIjiUJlCm9z+xWIDwyo1vffTwSqteqyznB8ZE9vYYk16zA== - dependencies: - "@babel/helper-string-parser" "^7.21.5" - "@babel/helper-validator-identifier" "^7.19.1" - to-fast-properties "^2.0.0" - -"@emotion/use-insertion-effect-with-fallbacks@^1.0.0": - version "1.0.1" - resolved "https://registry.yarnpkg.com/@emotion/use-insertion-effect-with-fallbacks/-/use-insertion-effect-with-fallbacks-1.0.1.tgz#08de79f54eb3406f9daaf77c76e35313da963963" - integrity sha512-jT/qyKZ9rzLErtrjGgdkMBn2OP8wl0G3sQlBb3YPryvKHsjvINUhVaPFfP+fpBcOkmrVOVEEHQFJ7nbj2TH2gw== - "@ethersproject/abi@^5.0.1": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/abi/-/abi-5.7.0.tgz#b3f3e045bbbeed1af3947335c247ad625a44e449" + resolved "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz" integrity sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA== dependencies: "@ethersproject/address" "^5.7.0" @@ -71,7 +26,7 @@ "@ethersproject/abstract-provider@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz#b0a8550f88b6bf9d51f90e4795d48294630cb9ef" + resolved "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz" integrity sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw== dependencies: "@ethersproject/bignumber" "^5.7.0" @@ -84,7 +39,7 @@ "@ethersproject/abstract-signer@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz#13f4f32117868452191a4649723cb086d2b596b2" + resolved "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz" integrity sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ== dependencies: "@ethersproject/abstract-provider" "^5.7.0" @@ -95,7 +50,7 @@ "@ethersproject/address@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/address/-/address-5.7.0.tgz#19b56c4d74a3b0a46bfdbb6cfcc0a153fc697f37" + resolved "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz" integrity sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA== dependencies: "@ethersproject/bignumber" "^5.7.0" @@ -106,14 +61,14 @@ "@ethersproject/base64@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/base64/-/base64-5.7.0.tgz#ac4ee92aa36c1628173e221d0d01f53692059e1c" + resolved "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz" integrity sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ== dependencies: "@ethersproject/bytes" "^5.7.0" "@ethersproject/bignumber@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/bignumber/-/bignumber-5.7.0.tgz#e2f03837f268ba655ffba03a57853e18a18dc9c2" + resolved "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz" integrity sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw== dependencies: "@ethersproject/bytes" "^5.7.0" @@ -122,21 +77,21 @@ "@ethersproject/bytes@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/bytes/-/bytes-5.7.0.tgz#a00f6ea8d7e7534d6d87f47188af1148d71f155d" + resolved "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz" integrity sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A== dependencies: "@ethersproject/logger" "^5.7.0" "@ethersproject/constants@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/constants/-/constants-5.7.0.tgz#df80a9705a7e08984161f09014ea012d1c75295e" + resolved "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz" integrity sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA== dependencies: "@ethersproject/bignumber" "^5.7.0" "@ethersproject/hash@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/hash/-/hash-5.7.0.tgz#eb7aca84a588508369562e16e514b539ba5240a7" + resolved "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz" integrity sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g== dependencies: "@ethersproject/abstract-signer" "^5.7.0" @@ -151,7 +106,7 @@ "@ethersproject/keccak256@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/keccak256/-/keccak256-5.7.0.tgz#3186350c6e1cd6aba7940384ec7d6d9db01f335a" + resolved "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz" integrity sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg== dependencies: "@ethersproject/bytes" "^5.7.0" @@ -159,26 +114,26 @@ "@ethersproject/logger@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/logger/-/logger-5.7.0.tgz#6ce9ae168e74fecf287be17062b590852c311892" + resolved "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz" integrity sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig== "@ethersproject/networks@^5.7.0": version "5.7.1" - resolved "https://registry.yarnpkg.com/@ethersproject/networks/-/networks-5.7.1.tgz#118e1a981d757d45ccea6bb58d9fd3d9db14ead6" + resolved "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz" integrity sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ== dependencies: "@ethersproject/logger" "^5.7.0" "@ethersproject/properties@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/properties/-/properties-5.7.0.tgz#a6e12cb0439b878aaf470f1902a176033067ed30" + resolved "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz" integrity sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw== dependencies: "@ethersproject/logger" "^5.7.0" "@ethersproject/rlp@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/rlp/-/rlp-5.7.0.tgz#de39e4d5918b9d74d46de93af80b7685a9c21304" + resolved "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz" integrity sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w== dependencies: "@ethersproject/bytes" "^5.7.0" @@ -186,7 +141,7 @@ "@ethersproject/signing-key@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/signing-key/-/signing-key-5.7.0.tgz#06b2df39411b00bc57c7c09b01d1e41cf1b16ab3" + resolved "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz" integrity sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q== dependencies: "@ethersproject/bytes" "^5.7.0" @@ -198,7 +153,7 @@ "@ethersproject/strings@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/strings/-/strings-5.7.0.tgz#54c9d2a7c57ae8f1205c88a9d3a56471e14d5ed2" + resolved "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz" integrity sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg== dependencies: "@ethersproject/bytes" "^5.7.0" @@ -207,7 +162,7 @@ "@ethersproject/transactions@^5.7.0": version "5.7.0" - resolved "https://registry.yarnpkg.com/@ethersproject/transactions/-/transactions-5.7.0.tgz#91318fc24063e057885a6af13fdb703e1f993d3b" + resolved "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz" integrity sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ== dependencies: "@ethersproject/address" "^5.7.0" @@ -222,7 +177,7 @@ "@ethersproject/web@^5.7.0": version "5.7.1" - resolved "https://registry.yarnpkg.com/@ethersproject/web/-/web-5.7.1.tgz#de1f285b373149bee5928f4eb7bcb87ee5fbb4ae" + resolved "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz" integrity sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w== dependencies: "@ethersproject/base64" "^5.7.0" @@ -231,71 +186,74 @@ "@ethersproject/properties" "^5.7.0" "@ethersproject/strings" "^5.7.0" -"@floating-ui/core@^1.3.1": - version "1.3.1" - resolved "https://registry.yarnpkg.com/@floating-ui/core/-/core-1.3.1.tgz#4d795b649cc3b1cbb760d191c80dcb4353c9a366" - integrity sha512-Bu+AMaXNjrpjh41znzHqaz3r2Nr8hHuHZT6V2LBKMhyMl0FgKA62PNYbqnfgmzOhoWZj70Zecisbo4H1rotP5g== +"@floating-ui/core@^1.4.1": + version "1.4.1" + resolved "https://registry.npmjs.org/@floating-ui/core/-/core-1.4.1.tgz" + integrity sha512-jk3WqquEJRlcyu7997NtR5PibI+y5bi+LS3hPmguVClypenMsCY3CBa3LAQnozRCtCrYWSEtAdiskpamuJRFOQ== + dependencies: + "@floating-ui/utils" "^0.1.1" "@floating-ui/dom@^1.3.0": - version "1.4.4" - resolved "https://registry.yarnpkg.com/@floating-ui/dom/-/dom-1.4.4.tgz#cf859dde33995a4e7b6ded16c98cb73b2ebfffd0" - integrity sha512-21hhDEPOiWkGp0Ys4Wi6Neriah7HweToKra626CIK712B5m9qkdz54OP9gVldUg+URnBTpv/j/bi/skmGdstXQ== + version "1.5.1" + resolved "https://registry.npmjs.org/@floating-ui/dom/-/dom-1.5.1.tgz" + integrity sha512-KwvVcPSXg6mQygvA1TjbN/gh///36kKtllIF8SUm0qpFj8+rvYrpvlYdL1JoA71SHpDqgSSdGOSoQ0Mp3uY5aw== dependencies: - "@floating-ui/core" "^1.3.1" + "@floating-ui/core" "^1.4.1" + "@floating-ui/utils" "^0.1.1" "@floating-ui/react-dom@^2.0.0": version "2.0.1" - resolved "https://registry.yarnpkg.com/@floating-ui/react-dom/-/react-dom-2.0.1.tgz#7972a4fc488a8c746cded3cfe603b6057c308a91" + resolved "https://registry.npmjs.org/@floating-ui/react-dom/-/react-dom-2.0.1.tgz" integrity sha512-rZtAmSht4Lry6gdhAJDrCp/6rKN7++JnL1/Anbr/DdeyYXQPxvg/ivrbYvJulbRf4vL8b212suwMM2lxbv+RQA== dependencies: "@floating-ui/dom" "^1.3.0" -"@juggle/resize-observer@^3.3.1": - version "3.4.0" - resolved "https://registry.yarnpkg.com/@juggle/resize-observer/-/resize-observer-3.4.0.tgz#08d6c5e20cf7e4cc02fd181c4b0c225cd31dbb60" - integrity sha512-dfLbk+PwWvFzSxwk3n5ySL0hfBog779o8h68wK/7/APo/7cgyWp5jcXockbxdk5kFRkbeXWm4Fbi9FrdN381sA== - -"@livepeer/core-react@^1.6.0": - version "1.6.0" - resolved "https://registry.yarnpkg.com/@livepeer/core-react/-/core-react-1.6.0.tgz#2a29789bd8acb551d81496cdc85376f165652971" - integrity sha512-6lsrWJ/iJSF9bL3y8O+gkvRJ17tT6g9z3l1/E7pf30tIlELjwFb4KklK/k3SFtuYYskkx8v5DvU2LaOd2yhQYA== - dependencies: - "@livepeer/core" "^1.6.0" - "@tanstack/query-async-storage-persister" "4.22.4" - "@tanstack/query-core" "4.22.4" - "@tanstack/react-query" "4.22.4" - "@tanstack/react-query-persist-client" "4.22.4" +"@floating-ui/utils@^0.1.1": + version "0.1.1" + resolved "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.1.1.tgz" + integrity sha512-m0G6wlnhm/AX0H12IOWtK8gASEMffnX08RtKkCgTdHb9JpHKGloI7icFfLg9ZmQeavcvR0PKmzxClyuFPSjKWw== + +"@livepeer/core-react@^1.8.0": + version "1.8.0" + resolved "https://registry.npmjs.org/@livepeer/core-react/-/core-react-1.8.0.tgz" + integrity sha512-DRciHEJgpALO2a9gHAy75g9VpaU6yszALP/gatO3W/+x9/o6MSR5PRhFg5eMDJA8o1ua39ZlaDu0/irLHIeE8g== + dependencies: + "@livepeer/core" "^1.8.0" + "@tanstack/query-async-storage-persister" "4.29.23" + "@tanstack/query-core" "4.29.23" + "@tanstack/react-query" "4.29.23" + "@tanstack/react-query-persist-client" "4.29.23" use-sync-external-store "^1.2.0" - zustand "^4.3.2" + zustand "^4.3.9" -"@livepeer/core@^1.6.0": - version "1.6.0" - resolved "https://registry.yarnpkg.com/@livepeer/core/-/core-1.6.0.tgz#1be05fc92b21f0cdebf28dd7243de6d8d0b8753c" - integrity sha512-MhyrtsXFrndnWn16GViavVG9UNjGroavw1FttgfstQ1IPWxrP2HEEvX52zATXF0JX/xfH5MCsfLNcVC9MF399g== +"@livepeer/core@^1.8.0": + version "1.8.0" + resolved "https://registry.npmjs.org/@livepeer/core/-/core-1.8.0.tgz" + integrity sha512-Sr+DplfGfhpv2Arh53tTTL9DyPEzlVAzy+eXd8+PMIlXLVOHTgGfDgpfpaeSCB8v8WlJtrgX50vFdSWyUyxi3g== dependencies: - cross-fetch "^3.1.5" + cross-fetch "^4.0.0" ms "^3.0.0-canary.1" multiformats "9.9.0" - tus-js-client "^3.0.1" - zustand "^4.3.2" + tus-js-client "^3.1.0" + zustand "^4.3.9" "@livepeer/react@^2.6.0": - version "2.6.0" - resolved "https://registry.yarnpkg.com/@livepeer/react/-/react-2.6.0.tgz#6ddff6d1c9e8f4dccff76c95ece238bc77642e5b" - integrity sha512-CH5hpONn4eiL6Qqf3neVzduvMbEkYa9DP1wliEGTpq/rAb8kfdrKGVOeEKkx7GoIIdHNPf0GIwFIggiqu/l8yw== + version "2.8.0" + resolved "https://registry.npmjs.org/@livepeer/react/-/react-2.8.0.tgz" + integrity sha512-ttQ6ggndZaGUboMHZxHS5NMMTBjZdn+SbXroMFo+Z+jiAB5TQCklYQXgsYazTE4GxtGePOLU0LndoJ0viDAJEw== dependencies: - "@livepeer/core-react" "^1.6.0" + "@livepeer/core-react" "^1.8.0" "@radix-ui/react-dialog" "^1.0.4" "@radix-ui/react-popover" "^1.0.6" "@radix-ui/react-select" "^1.2.2" "@stitches/react" "^1.2.8" - core-js "^3.27.2" - livepeer "2.6.0" - zustand "^4.3.2" + core-js "^3.31.1" + livepeer "2.8.0" + zustand "^4.3.9" "@pushprotocol/socket@^0.5.0": version "0.5.0" - resolved "https://registry.yarnpkg.com/@pushprotocol/socket/-/socket-0.5.0.tgz#ef5dfef1891dec9436e23b02d80e496e53ea4fe6" + resolved "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz" integrity sha512-b6hzyUIMunmf2hLeTqTtJFvDG1Ngm+Rho00Z0mod+3khSOKy1Kwgpcpmj9bISLgr0ymeFqMYqNPj9+X89EAMZA== dependencies: socket.io-client "^4.5.2" @@ -303,21 +261,21 @@ "@radix-ui/number@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/number/-/number-1.0.1.tgz#644161a3557f46ed38a042acf4a770e826021674" + resolved "https://registry.npmjs.org/@radix-ui/number/-/number-1.0.1.tgz" integrity sha512-T5gIdVO2mmPW3NNhjNgEP3cqMXjXL9UbO0BzWcXfvdBs+BohbQxvd/K5hSVKmn9/lbTdsQVKbUcP5WLCwvUbBg== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/primitive@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/primitive/-/primitive-1.0.1.tgz#e46f9958b35d10e9f6dc71c497305c22e3e55dbd" + resolved "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.0.1.tgz" integrity sha512-yQ8oGX2GVsEYMWGxcovu1uGWPCxV5BFfeeYxqPmuAzUyLT9qmaMXSAhXpb0WrspIeqYzdJpkh2vHModJPgRIaw== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-arrow@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-arrow/-/react-arrow-1.0.3.tgz#c24f7968996ed934d57fe6cde5d6ec7266e1d25d" + resolved "https://registry.npmjs.org/@radix-ui/react-arrow/-/react-arrow-1.0.3.tgz" integrity sha512-wSP+pHsB/jQRaL6voubsQ/ZlrGBHHrOjmBnr19hxYgtS0WvAFwZhK2WP/YY5yF9uKECCEEDGxuLxq1NBK51wFA== dependencies: "@babel/runtime" "^7.13.10" @@ -325,7 +283,7 @@ "@radix-ui/react-collection@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-collection/-/react-collection-1.0.3.tgz#9595a66e09026187524a36c6e7e9c7d286469159" + resolved "https://registry.npmjs.org/@radix-ui/react-collection/-/react-collection-1.0.3.tgz" integrity sha512-3SzW+0PW7yBBoQlT8wNcGtaxaD0XSu0uLUFgrtHY08Acx05TaHaOmVLR73c0j/cqpDy53KBMO7s0dx2wmOIDIA== dependencies: "@babel/runtime" "^7.13.10" @@ -336,21 +294,21 @@ "@radix-ui/react-compose-refs@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.1.tgz#7ed868b66946aa6030e580b1ffca386dd4d21989" + resolved "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.1.tgz" integrity sha512-fDSBgd44FKHa1FRMU59qBMPFcl2PZE+2nmqunj+BWFyYYjnhIDWL2ItDs3rrbJDQOtzt5nIebLCQc4QRfz6LJw== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-context@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-context/-/react-context-1.0.1.tgz#fe46e67c96b240de59187dcb7a1a50ce3e2ec00c" + resolved "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.0.1.tgz" integrity sha512-ebbrdFoYTcuZ0v4wG5tedGnp9tzcV8awzsxYph7gXUyvnNLuTIcCk1q17JEbnVhXAKG9oX3KtchwiMIAYp9NLg== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-dialog@^1.0.4": version "1.0.4" - resolved "https://registry.yarnpkg.com/@radix-ui/react-dialog/-/react-dialog-1.0.4.tgz#06bce6c16bb93eb36d7a8589e665a20f4c1c52c1" + resolved "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.0.4.tgz" integrity sha512-hJtRy/jPULGQZceSAP2Re6/4NpKo8im6V8P2hUqZsdFiSL8l35kYsw3qbRI6Ay5mQd2+wlLqje770eq+RJ3yZg== dependencies: "@babel/runtime" "^7.13.10" @@ -371,14 +329,14 @@ "@radix-ui/react-direction@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-direction/-/react-direction-1.0.1.tgz#9cb61bf2ccf568f3421422d182637b7f47596c9b" + resolved "https://registry.npmjs.org/@radix-ui/react-direction/-/react-direction-1.0.1.tgz" integrity sha512-RXcvnXgyvYvBEOhCBuddKecVkoMiI10Jcm5cTI7abJRAHYfFxeu+FBQs/DvdxSYucxR5mna0dNsL6QFlds5TMA== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-dismissable-layer@1.0.4": version "1.0.4" - resolved "https://registry.yarnpkg.com/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.0.4.tgz#883a48f5f938fa679427aa17fcba70c5494c6978" + resolved "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.0.4.tgz" integrity sha512-7UpBa/RKMoHJYjie1gkF1DlK8l1fdU/VKDpoS3rCCo8YBJR294GwcEHyxHw72yvphJ7ld0AXEcSLAzY2F/WyCg== dependencies: "@babel/runtime" "^7.13.10" @@ -390,14 +348,14 @@ "@radix-ui/react-focus-guards@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-focus-guards/-/react-focus-guards-1.0.1.tgz#1ea7e32092216b946397866199d892f71f7f98ad" + resolved "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.0.1.tgz" integrity sha512-Rect2dWbQ8waGzhMavsIbmSVCgYxkXLxxR3ZvCX79JOglzdEy4JXMb98lq4hPxUbLr77nP0UOGf4rcMU+s1pUA== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-focus-scope@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-focus-scope/-/react-focus-scope-1.0.3.tgz#9c2e8d4ed1189a1d419ee61edd5c1828726472f9" + resolved "https://registry.npmjs.org/@radix-ui/react-focus-scope/-/react-focus-scope-1.0.3.tgz" integrity sha512-upXdPfqI4islj2CslyfUBNlaJCPybbqRHAi1KER7Isel9Q2AtSJ0zRBZv8mWQiFXD2nyAJ4BhC3yXgZ6kMBSrQ== dependencies: "@babel/runtime" "^7.13.10" @@ -407,7 +365,7 @@ "@radix-ui/react-id@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-id/-/react-id-1.0.1.tgz#73cdc181f650e4df24f0b6a5b7aa426b912c88c0" + resolved "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.0.1.tgz" integrity sha512-tI7sT/kqYp8p96yGWY1OAnLHrqDgzHefRBKQ2YAkBS5ja7QLcZ9Z/uY7bEjPUatf8RomoXM8/1sMj1IJaE5UzQ== dependencies: "@babel/runtime" "^7.13.10" @@ -415,7 +373,7 @@ "@radix-ui/react-popover@^1.0.6": version "1.0.6" - resolved "https://registry.yarnpkg.com/@radix-ui/react-popover/-/react-popover-1.0.6.tgz#19bb81e7450482c625b8cd05bf4dcd1d2cd91a8b" + resolved "https://registry.npmjs.org/@radix-ui/react-popover/-/react-popover-1.0.6.tgz" integrity sha512-cZ4defGpkZ0qTRtlIBzJLSzL6ht7ofhhW4i1+pkemjV1IKXm0wgCRnee154qlV6r9Ttunmh2TNZhMfV2bavUyA== dependencies: "@babel/runtime" "^7.13.10" @@ -437,7 +395,7 @@ "@radix-ui/react-popper@1.1.2": version "1.1.2" - resolved "https://registry.yarnpkg.com/@radix-ui/react-popper/-/react-popper-1.1.2.tgz#4c0b96fcd188dc1f334e02dba2d538973ad842e9" + resolved "https://registry.npmjs.org/@radix-ui/react-popper/-/react-popper-1.1.2.tgz" integrity sha512-1CnGGfFi/bbqtJZZ0P/NQY20xdG3E0LALJaLUEoKwPLwl6PPPfbeiCqMVQnhoFRAxjJj4RpBRJzDmUgsex2tSg== dependencies: "@babel/runtime" "^7.13.10" @@ -454,7 +412,7 @@ "@radix-ui/react-portal@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-portal/-/react-portal-1.0.3.tgz#ffb961244c8ed1b46f039e6c215a6c4d9989bda1" + resolved "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.0.3.tgz" integrity sha512-xLYZeHrWoPmA5mEKEfZZevoVRK/Q43GfzRXkWV6qawIWWK8t6ifIiLQdd7rmQ4Vk1bmI21XhqF9BN3jWf+phpA== dependencies: "@babel/runtime" "^7.13.10" @@ -462,7 +420,7 @@ "@radix-ui/react-presence@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-presence/-/react-presence-1.0.1.tgz#491990ba913b8e2a5db1b06b203cb24b5cdef9ba" + resolved "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.0.1.tgz" integrity sha512-UXLW4UAbIY5ZjcvzjfRFo5gxva8QirC9hF7wRE4U5gz+TP0DbRk+//qyuAQ1McDxBt1xNMBTaciFGvEmJvAZCg== dependencies: "@babel/runtime" "^7.13.10" @@ -471,7 +429,7 @@ "@radix-ui/react-primitive@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-primitive/-/react-primitive-1.0.3.tgz#d49ea0f3f0b2fe3ab1cb5667eb03e8b843b914d0" + resolved "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-1.0.3.tgz" integrity sha512-yi58uVyoAcK/Nq1inRY56ZSjKypBNKTa/1mcL8qdl6oJeEaDbOldlzrGn7P6Q3Id5d+SYNGc5AJgc4vGhjs5+g== dependencies: "@babel/runtime" "^7.13.10" @@ -479,7 +437,7 @@ "@radix-ui/react-select@^1.2.2": version "1.2.2" - resolved "https://registry.yarnpkg.com/@radix-ui/react-select/-/react-select-1.2.2.tgz#caa981fa0d672cf3c1b2a5240135524e69b32181" + resolved "https://registry.npmjs.org/@radix-ui/react-select/-/react-select-1.2.2.tgz" integrity sha512-zI7McXr8fNaSrUY9mZe4x/HC0jTLY9fWNhO1oLWYMQGDXuV4UCivIGTxwioSzO0ZCYX9iSLyWmAh/1TOmX3Cnw== dependencies: "@babel/runtime" "^7.13.10" @@ -507,7 +465,7 @@ "@radix-ui/react-slot@1.0.2": version "1.0.2" - resolved "https://registry.yarnpkg.com/@radix-ui/react-slot/-/react-slot-1.0.2.tgz#a9ff4423eade67f501ffb32ec22064bc9d3099ab" + resolved "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.0.2.tgz" integrity sha512-YeTpuq4deV+6DusvVUW4ivBgnkHwECUu0BiN43L5UCDFgdhsRUWAghhTF5MbvNTPzmiFOx90asDSUjWuCNapwg== dependencies: "@babel/runtime" "^7.13.10" @@ -515,14 +473,14 @@ "@radix-ui/react-use-callback-ref@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.1.tgz#f4bb1f27f2023c984e6534317ebc411fc181107a" + resolved "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.1.tgz" integrity sha512-D94LjX4Sp0xJFVaoQOd3OO9k7tpBYNOXdVhkltUbGv2Qb9OXdrg/CpsjlZv7ia14Sylv398LswWBVVu5nqKzAQ== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-use-controllable-state@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.0.1.tgz#ecd2ced34e6330caf89a82854aa2f77e07440286" + resolved "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.0.1.tgz" integrity sha512-Svl5GY5FQeN758fWKrjM6Qb7asvXeiZltlT4U2gVfl8Gx5UAv2sMR0LWo8yhsIZh2oQ0eFdZ59aoOOMV7b47VA== dependencies: "@babel/runtime" "^7.13.10" @@ -530,7 +488,7 @@ "@radix-ui/react-use-escape-keydown@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.0.3.tgz#217b840c250541609c66f67ed7bab2b733620755" + resolved "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.0.3.tgz" integrity sha512-vyL82j40hcFicA+M4Ex7hVkB9vHgSse1ZWomAqV2Je3RleKGO5iM8KMOEtfoSB0PnIelMd2lATjTGMYqN5ylTg== dependencies: "@babel/runtime" "^7.13.10" @@ -538,21 +496,21 @@ "@radix-ui/react-use-layout-effect@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.0.1.tgz#be8c7bc809b0c8934acf6657b577daf948a75399" + resolved "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.0.1.tgz" integrity sha512-v/5RegiJWYdoCvMnITBkNNx6bCj20fiaJnWtRkU18yITptraXjffz5Qbn05uOiQnOvi+dbkznkoaMltz1GnszQ== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-use-previous@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-previous/-/react-use-previous-1.0.1.tgz#b595c087b07317a4f143696c6a01de43b0d0ec66" + resolved "https://registry.npmjs.org/@radix-ui/react-use-previous/-/react-use-previous-1.0.1.tgz" integrity sha512-cV5La9DPwiQ7S0gf/0qiD6YgNqM5Fk97Kdrlc5yBcrF3jyEZQwm7vYFqMo4IfeHgJXsRaMvLABFtd0OVEmZhDw== dependencies: "@babel/runtime" "^7.13.10" "@radix-ui/react-use-rect@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-rect/-/react-use-rect-1.0.1.tgz#fde50b3bb9fd08f4a1cd204572e5943c244fcec2" + resolved "https://registry.npmjs.org/@radix-ui/react-use-rect/-/react-use-rect-1.0.1.tgz" integrity sha512-Cq5DLuSiuYVKNU8orzJMbl15TXilTnJKUCltMVQg53BQOF1/C5toAaGrowkgksdBQ9H+SRL23g0HDmg9tvmxXw== dependencies: "@babel/runtime" "^7.13.10" @@ -560,7 +518,7 @@ "@radix-ui/react-use-size@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/react-use-size/-/react-use-size-1.0.1.tgz#1c5f5fea940a7d7ade77694bb98116fb49f870b2" + resolved "https://registry.npmjs.org/@radix-ui/react-use-size/-/react-use-size-1.0.1.tgz" integrity sha512-ibay+VqrgcaI6veAojjofPATwledXiSmX+C0KrBk/xgpX9rBzPV3OsfwlhQdUOFbh+LKQorLYT+xTXW9V8yd0g== dependencies: "@babel/runtime" "^7.13.10" @@ -568,7 +526,7 @@ "@radix-ui/react-visually-hidden@1.0.3": version "1.0.3" - resolved "https://registry.yarnpkg.com/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.0.3.tgz#51aed9dd0fe5abcad7dee2a234ad36106a6984ac" + resolved "https://registry.npmjs.org/@radix-ui/react-visually-hidden/-/react-visually-hidden-1.0.3.tgz" integrity sha512-D4w41yN5YRKtu464TLnByKzMDG/JlMPHtfZgQAu9v6mNakUqGUI9vUrfQKz8NK41VMm/xbZbh76NUTVtIYqOMA== dependencies: "@babel/runtime" "^7.13.10" @@ -576,339 +534,63 @@ "@radix-ui/rect@1.0.1": version "1.0.1" - resolved "https://registry.yarnpkg.com/@radix-ui/rect/-/rect-1.0.1.tgz#bf8e7d947671996da2e30f4904ece343bc4a883f" + resolved "https://registry.npmjs.org/@radix-ui/rect/-/rect-1.0.1.tgz" integrity sha512-fyrgCaedtvMg9NK3en0pnOYJdtfwxUcNolezkNPUsoX57X8oQk+NkqcvzHXD2uKNij6GXmWU9NDru2IWjrO4BQ== dependencies: "@babel/runtime" "^7.13.10" "@socket.io/component-emitter@~3.1.0": version "3.1.0" - resolved "https://registry.yarnpkg.com/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz#96116f2a912e0c02817345b3c10751069920d553" + resolved "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz" integrity sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg== "@stitches/core@^1.2.8": version "1.2.8" - resolved "https://registry.yarnpkg.com/@stitches/core/-/core-1.2.8.tgz#dce3b8fdc764fbc6dbea30c83b73bfb52cf96173" + resolved "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz" integrity sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg== "@stitches/react@^1.2.8": version "1.2.8" - resolved "https://registry.yarnpkg.com/@stitches/react/-/react-1.2.8.tgz#954f8008be8d9c65c4e58efa0937f32388ce3a38" + resolved "https://registry.npmjs.org/@stitches/react/-/react-1.2.8.tgz" integrity sha512-9g9dWI4gsSVe8bNLlb+lMkBYsnIKCZTmvqvDG+Avnn69XfmHZKiaMrx7cgTaddq7aTPPmXiTsbFcUy0xgI4+wA== -"@storybook/addon-styling@^1.0.8": - version "1.0.8" - resolved "https://registry.yarnpkg.com/@storybook/addon-styling/-/addon-styling-1.0.8.tgz#3533c4c5322b286575c235adcec246e39dcdf913" - integrity sha512-Ubi75gHNFO60Sjti2n/i3f0utERNOYcpsRkWHdzV+C26kUemLG+2riKHUt8zVbNskyJxA0EZxh84HYItRe4coA== - dependencies: - "@storybook/api" "^7.0.2" - "@storybook/components" "^7.0.2" - "@storybook/core-events" "^7.0.2" - "@storybook/manager-api" "^7.0.2" - "@storybook/node-logger" "^7.0.7" - "@storybook/preview-api" "^7.0.2" - "@storybook/theming" "^7.0.2" - "@storybook/types" "^7.0.2" - css-loader "^6.7.3" - less-loader "^11.1.0" - postcss-loader "^7.2.4" - resolve-url-loader "^5.0.0" - sass-loader "^13.2.2" - style-loader "^3.3.2" - -"@storybook/api@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/api/-/api-7.0.18.tgz#6304f7f5160b404b61e4080da0a952074258cf1f" - integrity sha512-gikVJBR2z7LdepljmbvbsrYgywQm3jNEEEmjG0OwYDeYNjWPuoQSffT+LoyouaaCK90d1osJLl3062OkwlIG8g== - dependencies: - "@storybook/client-logger" "7.0.18" - "@storybook/manager-api" "7.0.18" - -"@storybook/channel-postmessage@7.0.18": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/channel-postmessage/-/channel-postmessage-7.0.18.tgz#deb843705aec24bd23e717a14678fdb1f7cce8ae" - integrity sha512-rpwBH5ANdPnugS6+7xG9qHSoS+aPSEnBxDKsONWFubfMTTXQuFkf/793rBbxGkoINdqh8kSdKOM2rIty6e9cmQ== - dependencies: - "@storybook/channels" "7.0.18" - "@storybook/client-logger" "7.0.18" - "@storybook/core-events" "7.0.18" - "@storybook/global" "^5.0.0" - qs "^6.10.0" - telejson "^7.0.3" - -"@storybook/channels@7.0.18": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/channels/-/channels-7.0.18.tgz#0b5053ad6237ad7f619f1e17448d588de90ac235" - integrity sha512-rkA7ea0M3+dWS+71iHJdiZ5R2QuIdiVg0CgyLJHDagc1qej7pEVNhMWtppeq+X5Pwp9nkz8ZTQ7aCjTf6th0/A== - -"@storybook/client-logger@7.0.18": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/client-logger/-/client-logger-7.0.18.tgz#396858b53d0aa9485f173083ea27b7c1c48fa2dd" - integrity sha512-uKgFdVedYoRDZBVrE1IBdWNHDFln1IxWEeI+7ZiNSQwREG9swHpU5Fa8DceclM/oLjJRuzG1jFzv+XZY8894+Q== - dependencies: - "@storybook/global" "^5.0.0" - -"@storybook/components@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/components/-/components-7.0.18.tgz#74ab115342e576b7644c83667a9daef5758fc3c8" - integrity sha512-Jn1CbF9UAKt8BVaZtuhmthpcZ02VMaCFXR0ISfDXCpiMKnylmpP0+WfXcoKLzz6yS+EW8EW5S9+Qq8xgQY8H7A== - dependencies: - "@storybook/client-logger" "7.0.18" - "@storybook/csf" "^0.1.0" - "@storybook/global" "^5.0.0" - "@storybook/theming" "7.0.18" - "@storybook/types" "7.0.18" - memoizerific "^1.11.3" - use-resize-observer "^9.1.0" - util-deprecate "^1.0.2" - -"@storybook/core-events@7.0.18", "@storybook/core-events@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/core-events/-/core-events-7.0.18.tgz#429e0b092c645bd283adb4836ac0a945e813f085" - integrity sha512-7gxHBQDezdKOeq/u1LL80Bwjfcwsv7XOS3yWQElcgqp+gLaYB6OwwgtkCB2yV6a6l4nep9IdPWE8G3TxIzn9xw== - -"@storybook/csf@^0.1.0": - version "0.1.0" - resolved "https://registry.yarnpkg.com/@storybook/csf/-/csf-0.1.0.tgz#62315bf9704f3aa4e0d4d909b9033833774ddfbe" - integrity sha512-uk+jMXCZ8t38jSTHk2o5btI+aV2Ksbvl6DoOv3r6VaCM1KZqeuMwtwywIQdflkA8/6q/dKT8z8L+g8hC4GC3VQ== - dependencies: - type-fest "^2.19.0" - -"@storybook/global@^5.0.0": - version "5.0.0" - resolved "https://registry.yarnpkg.com/@storybook/global/-/global-5.0.0.tgz#b793d34b94f572c1d7d9e0f44fac4e0dbc9572ed" - integrity sha512-FcOqPAXACP0I3oJ/ws6/rrPT9WGhu915Cg8D02a9YxLo0DE9zI+a9A5gRGvmQ09fiWPukqI8ZAEoQEdWUKMQdQ== - -"@storybook/manager-api@7.0.18", "@storybook/manager-api@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/manager-api/-/manager-api-7.0.18.tgz#9e0e011df04271b0ed7216a22f9c965e3b7ac4b9" - integrity sha512-anQkm09twL96YkKGXHa+LI0+yMaY6Jxs1lRaetHdMlIqN4VHBHhizHaMgtGfH6xCTuO3WdrKTN7cZii5RH7PBQ== - dependencies: - "@storybook/channels" "7.0.18" - "@storybook/client-logger" "7.0.18" - "@storybook/core-events" "7.0.18" - "@storybook/csf" "^0.1.0" - "@storybook/global" "^5.0.0" - "@storybook/router" "7.0.18" - "@storybook/theming" "7.0.18" - "@storybook/types" "7.0.18" - dequal "^2.0.2" - lodash "^4.17.21" - memoizerific "^1.11.3" - semver "^7.3.7" - store2 "^2.14.2" - telejson "^7.0.3" - ts-dedent "^2.0.0" - -"@storybook/node-logger@^7.0.7": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/node-logger/-/node-logger-7.0.18.tgz#efed2e8b79964e7d999b64b0e99fa79f9356904e" - integrity sha512-cIeKEBvELtoVP/5UeQ01GJWZ7wM69/9Q+R5uOtNQBlwWFcCD6AVFWMRqq7ObMvdJG/okhXSF+sDetb+BF3zvdw== - dependencies: - "@types/npmlog" "^4.1.2" - chalk "^4.1.0" - npmlog "^5.0.1" - pretty-hrtime "^1.0.3" - -"@storybook/preview-api@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/preview-api/-/preview-api-7.0.18.tgz#ef012f984a2c0b9395b1b75b4f6e25643912c67d" - integrity sha512-xxtC0gPGMn/DbwvS4ZuJaBwfFNsjUCf0yLYHFrNe6fxncbvcLZ550RuyUwYuIRfsiKrlgfa3QmmCa4JM/JesHQ== - dependencies: - "@storybook/channel-postmessage" "7.0.18" - "@storybook/channels" "7.0.18" - "@storybook/client-logger" "7.0.18" - "@storybook/core-events" "7.0.18" - "@storybook/csf" "^0.1.0" - "@storybook/global" "^5.0.0" - "@storybook/types" "7.0.18" - "@types/qs" "^6.9.5" - dequal "^2.0.2" - lodash "^4.17.21" - memoizerific "^1.11.3" - qs "^6.10.0" - synchronous-promise "^2.0.15" - ts-dedent "^2.0.0" - util-deprecate "^1.0.2" - -"@storybook/router@7.0.18": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/router/-/router-7.0.18.tgz#c82146a6d4894c6d3d55b80a447010bebf192804" - integrity sha512-Mue4s/BnKgdYcsiW9yuvW3qL9k3AgYn5HIhnkBExAteyiUGdAca4IJFhArmGgFktgeLc4ecBQ7sgaCljApnbgg== - dependencies: - "@storybook/client-logger" "7.0.18" - memoizerific "^1.11.3" - qs "^6.10.0" - -"@storybook/theming@7.0.18", "@storybook/theming@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/theming/-/theming-7.0.18.tgz#566f5f42c9324b734f8aa9be4d16221278054734" - integrity sha512-P1gMKa/mKQHIMq0sxBIwTzAcF6v/6hrc62YmkuV62vXu+8zNV2YWbRwywqm3Q6faZEadmb/bL9+z8whaKhCL/g== - dependencies: - "@emotion/use-insertion-effect-with-fallbacks" "^1.0.0" - "@storybook/client-logger" "7.0.18" - "@storybook/global" "^5.0.0" - memoizerific "^1.11.3" - -"@storybook/types@7.0.18", "@storybook/types@^7.0.2": - version "7.0.18" - resolved "https://registry.yarnpkg.com/@storybook/types/-/types-7.0.18.tgz#9418da288db3a1258996aab17fd49ca4eb810b7a" - integrity sha512-qPop2CbvmX42/BX29YT9jIzW2TlMcMjAE+KCpcKLBiD1oT5DJ1fhMzpe6RW9HkMegkBxjWx54iamN4oHM/pwcQ== - dependencies: - "@storybook/channels" "7.0.18" - "@types/babel__core" "^7.0.0" - "@types/express" "^4.7.0" - file-system-cache "^2.0.0" - -"@tanstack/query-async-storage-persister@4.22.4": - version "4.22.4" - resolved "https://registry.yarnpkg.com/@tanstack/query-async-storage-persister/-/query-async-storage-persister-4.22.4.tgz#60f846dbb2b0bad6911b29ff77ba6272e610283c" - integrity sha512-8DWEt+bmxyjp12aqGnYhpgroOZgvgzvs+mMqBIyZVET4eWQNKAuQSFXTlkztmq9/sxbvTnp+xu7KRZExyurZPA== - dependencies: - "@tanstack/query-persist-client-core" "4.22.4" - -"@tanstack/query-core@4.22.4": - version "4.22.4" - resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-4.22.4.tgz#aca622d2f8800a147ece5520d956a076ab92f0ea" - integrity sha512-t79CMwlbBnj+yL82tEcmRN93bL4U3pae2ota4t5NN2z3cIeWw74pzdWrKRwOfTvLcd+b30tC+ciDlfYOKFPGUw== - -"@tanstack/query-persist-client-core@4.22.4": - version "4.22.4" - resolved "https://registry.yarnpkg.com/@tanstack/query-persist-client-core/-/query-persist-client-core-4.22.4.tgz#a8ed136a8234b9cbd12ae3df857425330c6200db" - integrity sha512-F5rCLczSw8RjFlwWASD3oRR7D4oyG90QbBFaOqBCjGbvE3bcD+m/E4GGCp1qfACoLuH4KtxhdwdOFfE+e0TRZQ== - -"@tanstack/react-query-persist-client@4.22.4": - version "4.22.4" - resolved "https://registry.yarnpkg.com/@tanstack/react-query-persist-client/-/react-query-persist-client-4.22.4.tgz#8e4fad6f70ca922ef9e7be58c5bd14b010cff780" - integrity sha512-vnRD28T0BLsbDRlantC6W34eLCbjSoZEkYL4t2QYRyuEcmUya2Ddbn+DN+RfZHqxoMiSJNfMdmRXsMPpNHZ1QA== - dependencies: - "@tanstack/query-persist-client-core" "4.22.4" - -"@tanstack/react-query@4.22.4": - version "4.22.4" - resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-4.22.4.tgz#851581c645f1c9cfcd394448fedd980a39bbc3fe" - integrity sha512-e5j5Z88XUQGeEPMyz5XF1V0mMf6Da+6URXiTpZfUb9nuHs2nlNoA+EoIvnhccE5b9YT6Yg7kARhn2L7u94M/4A== - dependencies: - "@tanstack/query-core" "4.22.4" - use-sync-external-store "^1.2.0" - -"@types/babel__core@^7.0.0": - version "7.20.1" - resolved "https://registry.yarnpkg.com/@types/babel__core/-/babel__core-7.20.1.tgz#916ecea274b0c776fec721e333e55762d3a9614b" - integrity sha512-aACu/U/omhdk15O4Nfb+fHgH/z3QsfQzpnvRZhYhThms83ZnAOZz7zZAWO7mn2yyNQaA4xTO8GLK3uqFU4bYYw== +"@tanstack/query-async-storage-persister@4.29.23": + version "4.29.23" + resolved "https://registry.npmjs.org/@tanstack/query-async-storage-persister/-/query-async-storage-persister-4.29.23.tgz" + integrity sha512-TlUCpJTwqzHyniiSCyyqe2Dw/oq5iKc7U5nQLLT3qFKUSFUa8Y7SzaNiCGm6WxOr0e3zlDze+Dh4uHx7s7CGTw== dependencies: - "@babel/parser" "^7.20.7" - "@babel/types" "^7.20.7" - "@types/babel__generator" "*" - "@types/babel__template" "*" - "@types/babel__traverse" "*" + "@tanstack/query-persist-client-core" "4.29.23" -"@types/babel__generator@*": - version "7.6.4" - resolved "https://registry.yarnpkg.com/@types/babel__generator/-/babel__generator-7.6.4.tgz#1f20ce4c5b1990b37900b63f050182d28c2439b7" - integrity sha512-tFkciB9j2K755yrTALxD44McOrk+gfpIpvC3sxHjRawj6PfnQxrse4Clq5y/Rq+G3mrBurMax/lG8Qn2t9mSsg== - dependencies: - "@babel/types" "^7.0.0" +"@tanstack/query-core@4.29.23": + version "4.29.23" + resolved "https://registry.npmjs.org/@tanstack/query-core/-/query-core-4.29.23.tgz" + integrity sha512-4BMHPrkfYmLP+NvqbbkV7Mk1nnphu+bNmxhhuB0+EMjKA7VfyFCfiyiTf55RRDgLaevyb9LrFK16lHW2owF52w== -"@types/babel__template@*": - version "7.4.1" - resolved "https://registry.yarnpkg.com/@types/babel__template/-/babel__template-7.4.1.tgz#3d1a48fd9d6c0edfd56f2ff578daed48f36c8969" - integrity sha512-azBFKemX6kMg5Io+/rdGT0dkGreboUVR0Cdm3fz9QJWpaQGJRQXl7C+6hOTCZcMll7KFyEQpgbYI2lHdsS4U7g== +"@tanstack/query-persist-client-core@4.29.23": + version "4.29.23" + resolved "https://registry.npmjs.org/@tanstack/query-persist-client-core/-/query-persist-client-core-4.29.23.tgz" + integrity sha512-u0P6y4DPeXeHEZnj0LEnhcgqX8x7iV7xbUDuoRPItUYsPn+anyLjXG3d3622+wLP3XKdevff0PhXkA7j9ZOWKg== dependencies: - "@babel/parser" "^7.1.0" - "@babel/types" "^7.0.0" + "@tanstack/query-core" "4.29.23" -"@types/babel__traverse@*": - version "7.20.0" - resolved "https://registry.yarnpkg.com/@types/babel__traverse/-/babel__traverse-7.20.0.tgz#4709d34d3eba3e1dad1950d40e80c6b5e0b81fc9" - integrity sha512-TBOjqAGf0hmaqRwpii5LLkJLg7c6OMm4nHLmpsUxwk9bBHtoTC6dAHdVWdGv4TBxj2CZOZY8Xfq8WmfoVi7n4Q== +"@tanstack/react-query-persist-client@4.29.23": + version "4.29.23" + resolved "https://registry.npmjs.org/@tanstack/react-query-persist-client/-/react-query-persist-client-4.29.23.tgz" + integrity sha512-P23y5CMGfSM943pJoQjjOdQXSHH/ohjAl8vhQp+40M4Nz3lDq2d39flGRpajyh4dl4C5s0R8V6Iii7kkIQo8Jg== dependencies: - "@babel/types" "^7.20.7" + "@tanstack/query-persist-client-core" "4.29.23" -"@types/body-parser@*": - version "1.19.2" - resolved "https://registry.yarnpkg.com/@types/body-parser/-/body-parser-1.19.2.tgz#aea2059e28b7658639081347ac4fab3de166e6f0" - integrity sha512-ALYone6pm6QmwZoAgeyNksccT9Q4AWZQ6PvfwR37GT6r6FWUPguq6sUmNGSMV2Wr761oQoBxwGGa6DR5o1DC9g== +"@tanstack/react-query@4.29.23": + version "4.29.23" + resolved "https://registry.npmjs.org/@tanstack/react-query/-/react-query-4.29.23.tgz" + integrity sha512-u59dPBJHeyeRDSrHN3M8FT65yZDT0uPlaFDFd4K2wmDreHguRlk9t578X+cp1Cj+4oksQCE+wv09A5ZH7Odx6g== dependencies: - "@types/connect" "*" - "@types/node" "*" - -"@types/connect@*": - version "3.4.35" - resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.35.tgz#5fcf6ae445e4021d1fc2219a4873cc73a3bb2ad1" - integrity sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ== - dependencies: - "@types/node" "*" - -"@types/express-serve-static-core@^4.17.33": - version "4.17.35" - resolved "https://registry.yarnpkg.com/@types/express-serve-static-core/-/express-serve-static-core-4.17.35.tgz#c95dd4424f0d32e525d23812aa8ab8e4d3906c4f" - integrity sha512-wALWQwrgiB2AWTT91CB62b6Yt0sNHpznUXeZEcnPU3DRdlDIz74x8Qg1UUYKSVFi+va5vKOLYRBI1bRKiLLKIg== - dependencies: - "@types/node" "*" - "@types/qs" "*" - "@types/range-parser" "*" - "@types/send" "*" - -"@types/express@^4.7.0": - version "4.17.17" - resolved "https://registry.yarnpkg.com/@types/express/-/express-4.17.17.tgz#01d5437f6ef9cfa8668e616e13c2f2ac9a491ae4" - integrity sha512-Q4FmmuLGBG58btUnfS1c1r/NQdlp3DMfGDGig8WhfpA2YRUtEkxAjkZb0yvplJGYdF1fsQ81iMDcH24sSCNC/Q== - dependencies: - "@types/body-parser" "*" - "@types/express-serve-static-core" "^4.17.33" - "@types/qs" "*" - "@types/serve-static" "*" - -"@types/mime@*": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@types/mime/-/mime-3.0.1.tgz#5f8f2bca0a5863cb69bc0b0acd88c96cb1d4ae10" - integrity sha512-Y4XFY5VJAuw0FgAqPNd6NNoV44jbq9Bz2L7Rh/J6jLTiHBSBJa9fxqQIvkIld4GsoDOcCbvzOUAbLPsSKKg+uA== - -"@types/mime@^1": - version "1.3.2" - resolved "https://registry.yarnpkg.com/@types/mime/-/mime-1.3.2.tgz#93e25bf9ee75fe0fd80b594bc4feb0e862111b5a" - integrity sha512-YATxVxgRqNH6nHEIsvg6k2Boc1JHI9ZbH5iWFFv/MTkchz3b1ieGDa5T0a9RznNdI0KhVbdbWSN+KWWrQZRxTw== - -"@types/node@*": - version "20.2.5" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.2.5.tgz#26d295f3570323b2837d322180dfbf1ba156fefb" - integrity sha512-JJulVEQXmiY9Px5axXHeYGLSjhkZEnD+MDPDGbCbIAbMslkKwmygtZFy1X6s/075Yo94sf8GuSlFfPzysQrWZQ== - -"@types/npmlog@^4.1.2": - version "4.1.4" - resolved "https://registry.yarnpkg.com/@types/npmlog/-/npmlog-4.1.4.tgz#30eb872153c7ead3e8688c476054ddca004115f6" - integrity sha512-WKG4gTr8przEZBiJ5r3s8ZIAoMXNbOgQ+j/d5O4X3x6kZJRLNvyUJuUK/KoG3+8BaOHPhp2m7WC6JKKeovDSzQ== - -"@types/qs@*", "@types/qs@^6.9.5": - version "6.9.7" - resolved "https://registry.yarnpkg.com/@types/qs/-/qs-6.9.7.tgz#63bb7d067db107cc1e457c303bc25d511febf6cb" - integrity sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw== - -"@types/range-parser@*": - version "1.2.4" - resolved "https://registry.yarnpkg.com/@types/range-parser/-/range-parser-1.2.4.tgz#cd667bcfdd025213aafb7ca5915a932590acdcdc" - integrity sha512-EEhsLsD6UsDM1yFhAvy0Cjr6VwmpMWqFBCb9w07wVugF7w9nfajxLuVmngTIpgS6svCnm6Vaw+MZhoDCKnOfsw== - -"@types/send@*": - version "0.17.1" - resolved "https://registry.yarnpkg.com/@types/send/-/send-0.17.1.tgz#ed4932b8a2a805f1fe362a70f4e62d0ac994e301" - integrity sha512-Cwo8LE/0rnvX7kIIa3QHCkcuF21c05Ayb0ZfxPiv0W8VRiZiNW/WuRupHKpqqGVGf7SUA44QSOUKaEd9lIrd/Q== - dependencies: - "@types/mime" "^1" - "@types/node" "*" - -"@types/serve-static@*": - version "1.15.1" - resolved "https://registry.yarnpkg.com/@types/serve-static/-/serve-static-1.15.1.tgz#86b1753f0be4f9a1bee68d459fcda5be4ea52b5d" - integrity sha512-NUo5XNiAdULrJENtJXZZ3fHtfMolzZwczzBbnAeBbqBwG+LaG6YaJtuwzwGSQZ2wsCrxjEhNNjAkKigy3n8teQ== - dependencies: - "@types/mime" "*" - "@types/node" "*" + "@tanstack/query-core" "4.29.23" + use-sync-external-store "^1.2.0" "@unstoppabledomains/resolution@^8.5.0": version "8.5.0" - resolved "https://registry.yarnpkg.com/@unstoppabledomains/resolution/-/resolution-8.5.0.tgz#7f65146fb3bc69bfae8699c4ed1c61f3d6f0096c" + resolved "https://registry.npmjs.org/@unstoppabledomains/resolution/-/resolution-8.5.0.tgz" integrity sha512-csqExbiK8F5mRKoHlDZjGuIEuvi63O8PSyhUcGhnTi76Il5fCREAGNVdTiRxagPPYoxCO+Xmf6kThwtmiws1Ow== dependencies: "@ethersproject/abi" "^5.0.1" @@ -917,292 +599,97 @@ crypto-js "^4.1.1" elliptic "^6.5.4" -adjust-sourcemap-loader@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/adjust-sourcemap-loader/-/adjust-sourcemap-loader-4.0.0.tgz#fc4a0fd080f7d10471f30a7320f25560ade28c99" - integrity sha512-OXwN5b9pCUXNQHJpwwD2qP40byEmSgzj8B4ydSN0uMNYWiFmJ6x6KwUllMmfk8Rwu/HJDFR7U8ubsWBoN0Xp0A== - dependencies: - loader-utils "^2.0.0" - regex-parser "^2.2.11" - -ansi-regex@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" - integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== - -ansi-styles@^3.2.1: - version "3.2.1" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" - integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== - dependencies: - color-convert "^1.9.0" - -ansi-styles@^4.1.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" - integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== - dependencies: - color-convert "^2.0.1" - -"aproba@^1.0.3 || ^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/aproba/-/aproba-2.0.0.tgz#52520b8ae5b569215b354efc0caa3fe1e45a8adc" - integrity sha512-lYe4Gx7QT+MKGbDsA+Z+he/Wtef0BiwDOlK/XkBrdfsh9J/jPPXbX0tE9x9cl27Tmu5gg3QUbUrQYa/y+KOHPQ== - -are-we-there-yet@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/are-we-there-yet/-/are-we-there-yet-2.0.0.tgz#372e0e7bd279d8e94c653aaa1f67200884bf3e1c" - integrity sha512-Ci/qENmwHnsYo9xKIcUJN5LeDKdJ6R1Z1j9V/J5wyq8nh/mYPEpIKJbBZXtZjG04HiK7zV/p6Vs9952MrMeUIw== - dependencies: - delegates "^1.0.0" - readable-stream "^3.6.0" - -argparse@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/argparse/-/argparse-2.0.1.tgz#246f50f3ca78a3240f6c997e8a9bd1eac49e4b38" - integrity sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q== - aria-hidden@^1.1.1: version "1.2.3" - resolved "https://registry.yarnpkg.com/aria-hidden/-/aria-hidden-1.2.3.tgz#14aeb7fb692bbb72d69bebfa47279c1fd725e954" + resolved "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.3.tgz" integrity sha512-xcLxITLe2HYa1cnYnwCjkOO1PqUHQpozB8x9AR0OgWN2woOBi5kSDVxKfd0b7sb1hw5qFeJhXm9H1nu3xSfLeQ== dependencies: tslib "^2.0.0" -async-limiter@~1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/async-limiter/-/async-limiter-1.0.1.tgz#dd379e94f0db8310b08291f9d64c3209766617fd" - integrity sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ== - -big.js@^5.2.2: - version "5.2.2" - resolved "https://registry.yarnpkg.com/big.js/-/big.js-5.2.2.tgz#65f0af382f578bcdc742bd9c281e9cb2d7768328" - integrity sha512-vyL2OymJxmarO8gxMr0mhChsO9QGwhynfuu4+MHTAW6czfq9humCB7rKpUjDd9YUiDPU4mzpyupFSvOClAwbmQ== - -bindings@^1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" - integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== - dependencies: - file-uri-to-path "1.0.0" - bn.js@^4.11.9, bn.js@^4.4.0: version "4.12.0" - resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" + resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== bn.js@^5.2.1: version "5.2.1" - resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-5.2.1.tgz#0bc527a6a0d18d0aa8d5b0538ce4a77dccfa7b70" + resolved "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== brorand@^1.1.0: version "1.1.0" - resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" + resolved "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== buffer-from@^1.1.2: version "1.1.2" - resolved "https://registry.yarnpkg.com/buffer-from/-/buffer-from-1.1.2.tgz#2b146a6fd72e80b4f55d255f35ed59a3a9a41bd5" + resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== -call-bind@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" - integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== - dependencies: - function-bind "^1.1.1" - get-intrinsic "^1.0.2" - -callsites@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/callsites/-/callsites-3.1.0.tgz#b3630abd8943432f54b3f0519238e33cd7df2f73" - integrity sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ== - -chalk@^2.0.0: - version "2.4.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.2.tgz#cd42541677a54333cf541a49108c1432b44c9424" - integrity sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ== - dependencies: - ansi-styles "^3.2.1" - escape-string-regexp "^1.0.5" - supports-color "^5.3.0" - -chalk@^4.1.0: - version "4.1.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" - integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== - dependencies: - ansi-styles "^4.1.0" - supports-color "^7.1.0" - clsx@^1.2.1: version "1.2.1" - resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.2.1.tgz#0ddc4a20a549b59c93a4116bb26f5294ca17dc12" + resolved "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== -color-convert@^1.9.0: - version "1.9.3" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" - integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== - dependencies: - color-name "1.1.3" - -color-convert@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" - integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== - dependencies: - color-name "~1.1.4" - -color-name@1.1.3: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" - integrity sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw== - -color-name@~1.1.4: - version "1.1.4" - resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" - integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== - -color-support@^1.1.2: - version "1.1.3" - resolved "https://registry.yarnpkg.com/color-support/-/color-support-1.1.3.tgz#93834379a1cc9a0c61f82f52f0d04322251bd5a2" - integrity sha512-qiBjkpbMLO/HL68y+lh4q0/O1MZFj2RX6X/KmMa3+gJD3z+WwI1ZzDHysvqHGS3mP6mznPckpXmw1nI9cJjyRg== - combine-errors@^3.0.3: version "3.0.3" - resolved "https://registry.yarnpkg.com/combine-errors/-/combine-errors-3.0.3.tgz#f4df6740083e5703a3181110c2b10551f003da86" + resolved "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz" integrity sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q== dependencies: custom-error-instance "2.1.1" lodash.uniqby "4.5.0" -console-control-strings@^1.0.0, console-control-strings@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/console-control-strings/-/console-control-strings-1.1.0.tgz#3d7cf4464db6446ea644bf4b39507f9851008e8e" - integrity sha512-ty/fTekppD2fIwRvnZAVdeOiGd1c7YXEixbgJTNzqcxJWKQnjJ/V1bNEEE6hygpM3WjwHFUVK6HTjWSzV4a8sQ== - -convert-source-map@^1.7.0: - version "1.9.0" - resolved "https://registry.yarnpkg.com/convert-source-map/-/convert-source-map-1.9.0.tgz#7faae62353fb4213366d0ca98358d22e8368b05f" - integrity sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A== - -core-js@^3.27.2: - version "3.31.1" - resolved "https://registry.yarnpkg.com/core-js/-/core-js-3.31.1.tgz#f2b0eea9be9da0def2c5fece71064a7e5d687653" - integrity sha512-2sKLtfq1eFST7l7v62zaqXacPc7uG8ZAya8ogijLhTtaKNcpzpB4TMoTw2Si+8GYKRwFPMMtUT0263QFWFfqyQ== - -core-util-is@~1.0.0: - version "1.0.3" - resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.3.tgz#a6042d3634c2b27e9328f837b965fac83808db85" - integrity sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ== - -cosmiconfig@^8.1.3: - version "8.1.3" - resolved "https://registry.yarnpkg.com/cosmiconfig/-/cosmiconfig-8.1.3.tgz#0e614a118fcc2d9e5afc2f87d53cd09931015689" - integrity sha512-/UkO2JKI18b5jVMJUp0lvKFMpa/Gye+ZgZjKD+DGEN9y7NRcf/nK1A0sp67ONmKtnDCNMS44E6jrk0Yc3bDuUw== - dependencies: - import-fresh "^3.2.1" - js-yaml "^4.1.0" - parse-json "^5.0.0" - path-type "^4.0.0" +core-js@^3.31.1: + version "3.32.0" + resolved "https://registry.npmjs.org/core-js/-/core-js-3.32.0.tgz" + integrity sha512-rd4rYZNlF3WuoYuRIDEmbR/ga9CeuWX9U05umAvgrrZoHY4Z++cp/xwPQMvUpBB4Ag6J8KfD80G0zwCyaSxDww== cross-fetch@^3.1.4: - version "3.1.5" - resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-3.1.5.tgz#e1389f44d9e7ba767907f7af8454787952ab534f" - integrity sha512-lvb1SBsI0Z7GDwmuid+mU3kWVBwTVUbe7S0H52yaaAdQOXq2YktTCZdlAcNKFzE6QtRz0snpw9bNiPeOIkkQvw== - dependencies: - node-fetch "2.6.7" - -cross-fetch@^3.1.5: version "3.1.8" - resolved "https://registry.yarnpkg.com/cross-fetch/-/cross-fetch-3.1.8.tgz#0327eba65fd68a7d119f8fb2bf9334a1a7956f82" + resolved "https://registry.npmjs.org/cross-fetch/-/cross-fetch-3.1.8.tgz" integrity sha512-cvA+JwZoU0Xq+h6WkMvAUqPEYy92Obet6UdKLfW60qn99ftItKjB5T+BkyWOFWe2pUyfQ+IJHmpOTznqk1M6Kg== dependencies: node-fetch "^2.6.12" +cross-fetch@^4.0.0: + version "4.0.0" + resolved "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz" + integrity sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g== + dependencies: + node-fetch "^2.6.12" + crypto-js@^4.1.1: version "4.1.1" - resolved "https://registry.yarnpkg.com/crypto-js/-/crypto-js-4.1.1.tgz#9e485bcf03521041bd85844786b83fb7619736cf" + resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== -css-loader@^6.7.3: - version "6.8.1" - resolved "https://registry.yarnpkg.com/css-loader/-/css-loader-6.8.1.tgz#0f8f52699f60f5e679eab4ec0fcd68b8e8a50a88" - integrity sha512-xDAXtEVGlD0gJ07iclwWVkLoZOpEvAWaSyf6W18S2pOC//K8+qUDIx8IIT3D+HjnmkJPQeesOPv5aiUaJsCM2g== - dependencies: - icss-utils "^5.1.0" - postcss "^8.4.21" - postcss-modules-extract-imports "^3.0.0" - postcss-modules-local-by-default "^4.0.3" - postcss-modules-scope "^3.0.0" - postcss-modules-values "^4.0.0" - postcss-value-parser "^4.2.0" - semver "^7.3.8" - -cssesc@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" - integrity sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg== - custom-error-instance@2.1.1: version "2.1.1" - resolved "https://registry.yarnpkg.com/custom-error-instance/-/custom-error-instance-2.1.1.tgz#3cf6391487a6629a6247eb0ca0ce00081b7e361a" + resolved "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz" integrity sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg== date-fns@^2.28.0: - version "2.29.3" - resolved "https://registry.yarnpkg.com/date-fns/-/date-fns-2.29.3.tgz#27402d2fc67eb442b511b70bbdf98e6411cd68a8" - integrity sha512-dDCnyH2WnnKusqvZZ6+jA1O51Ibt8ZMRNkDZdyAyK4YfbDwa/cEmuztzG5pk6hqlp9aSBPYcjOlktquahGwGeA== - -deasync@^0.1.9: - version "0.1.28" - resolved "https://registry.yarnpkg.com/deasync/-/deasync-0.1.28.tgz#9b447b79b3f822432f0ab6a8614c0062808b5ad2" - integrity sha512-QqLF6inIDwiATrfROIyQtwOQxjZuek13WRYZ7donU5wJPLoP67MnYxA6QtqdvdBy2mMqv5m3UefBVdJjvevOYg== - dependencies: - bindings "^1.5.0" - node-addon-api "^1.7.1" - -debug@^2.6.1: - version "2.6.9" - resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" - integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== + version "2.30.0" + resolved "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz" + integrity sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw== dependencies: - ms "2.0.0" - -debug@^3.1.0: - version "3.2.7" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" - integrity sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ== - dependencies: - ms "^2.1.1" + "@babel/runtime" "^7.21.0" debug@~4.3.1, debug@~4.3.2: version "4.3.4" - resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" + resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== dependencies: ms "2.1.2" -delegates@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/delegates/-/delegates-1.0.0.tgz#84c6e159b81904fdca59a0ef44cd870d31250f9a" - integrity sha512-bd2L678uiWATM6m5Z1VzNCErI3jiGzt6HGY8OVICs40JQq/HALfbyNJmp0UDakEY4pMMaN0Ly5om/B1VI/+xfQ== - -dequal@^2.0.2: - version "2.0.3" - resolved "https://registry.yarnpkg.com/dequal/-/dequal-2.0.3.tgz#2644214f1997d39ed0ee0ece72335490a7ac67be" - integrity sha512-0je+qPKHEMohvfRTCEo3CrPG6cAzAYgmzKyxRiYSSDkS6eGJdyVJm7WaYA5ECaAD9wLB2T4EEeymA5aFVcYXCA== - detect-node-es@^1.1.0: version "1.1.0" - resolved "https://registry.yarnpkg.com/detect-node-es/-/detect-node-es-1.1.0.tgz#163acdf643330caa0b4cd7c21e7ee7755d6fa493" + resolved "https://registry.npmjs.org/detect-node-es/-/detect-node-es-1.1.0.tgz" integrity sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ== dom-serializer@^1.0.1: version "1.4.1" - resolved "https://registry.yarnpkg.com/dom-serializer/-/dom-serializer-1.4.1.tgz#de5d41b1aea290215dc45a6dae8adcf1d32e2d30" + resolved "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz" integrity sha512-VHwB3KfrcOOkelEG2ZOfxqLZdfkil8PtJi4P8N2MMXucZq2yLp75ClViUlOVwyoHEDjYU433Aq+5zWP61+RGag== dependencies: domelementtype "^2.0.1" @@ -1211,19 +698,19 @@ dom-serializer@^1.0.1: domelementtype@^2.0.1, domelementtype@^2.2.0: version "2.3.0" - resolved "https://registry.yarnpkg.com/domelementtype/-/domelementtype-2.3.0.tgz#5c45e8e869952626331d7aab326d01daf65d589d" + resolved "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz" integrity sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw== domhandler@4.3.1, domhandler@^4.2.0, domhandler@^4.2.2: version "4.3.1" - resolved "https://registry.yarnpkg.com/domhandler/-/domhandler-4.3.1.tgz#8d792033416f59d68bc03a5aa7b018c1ca89279c" + resolved "https://registry.npmjs.org/domhandler/-/domhandler-4.3.1.tgz" integrity sha512-GrwoxYN+uWlzO8uhUXRl0P+kHE4GtVPfYzVLcUxPL7KNdHKj66vvlhiweIHqYYXWlw+T8iLMp42Lm67ghw4WMQ== dependencies: domelementtype "^2.2.0" domutils@^2.8.0: version "2.8.0" - resolved "https://registry.yarnpkg.com/domutils/-/domutils-2.8.0.tgz#4437def5db6e2d1f5d6ee859bd95ca7d02048135" + resolved "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz" integrity sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A== dependencies: dom-serializer "^1.0.1" @@ -1232,7 +719,7 @@ domutils@^2.8.0: elliptic@6.5.4, elliptic@^6.5.4: version "6.5.4" - resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.4.tgz#da37cebd31e79a1367e941b592ed1fbebd58abbb" + resolved "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz" integrity sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ== dependencies: bn.js "^4.11.9" @@ -1244,25 +731,15 @@ elliptic@6.5.4, elliptic@^6.5.4: minimalistic-crypto-utils "^1.0.1" emoji-picker-react@^4.4.9: - version "4.4.9" - resolved "https://registry.yarnpkg.com/emoji-picker-react/-/emoji-picker-react-4.4.9.tgz#564fc387ae2ce8c8086a12a9231d6fd9567d0ae5" - integrity sha512-ef9MfzSJy5xrzihLLv0e1zZmiNtcekubctTBQVfIpvKfsfu4iLBBzcHCmOC2IaUVBCZuUw+GM24BAPj1MdCQXQ== + version "4.4.10" + resolved "https://registry.npmjs.org/emoji-picker-react/-/emoji-picker-react-4.4.10.tgz" + integrity sha512-/5o57w8BKiCHklyqfYCeUlm00R9tdm2ZmJd0p6Q3/Ul7E7eMh+/FduuRFn3UVQCl5F6i4kOdREMz7EJ7YI1vMg== dependencies: clsx "^1.2.1" -emoji-regex@^8.0.0: - version "8.0.0" - resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" - integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== - -emojis-list@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/emojis-list/-/emojis-list-3.0.0.tgz#5570662046ad29e2e916e71aae260abdff4f6a78" - integrity sha512-/kyM18EfinwXZbno9FyUGeFh87KC8HRQBQGildHZbEuRyWFOmv1U10o9BBp8XVZDVNNuQKyIGIu5ZYAAXJ0V2Q== - engine.io-client@~6.4.0: version "6.4.0" - resolved "https://registry.yarnpkg.com/engine.io-client/-/engine.io-client-6.4.0.tgz#88cd3082609ca86d7d3c12f0e746d12db4f47c91" + resolved "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.4.0.tgz" integrity sha512-GyKPDyoEha+XZ7iEqam49vz6auPnNJ9ZBfy89f+rMMas8AuiMWOZ9PVzu8xb9ZC6rafUqiGHSCfu22ih66E+1g== dependencies: "@socket.io/component-emitter" "~3.1.0" @@ -1273,153 +750,55 @@ engine.io-client@~6.4.0: engine.io-parser@~5.0.3: version "5.0.6" - resolved "https://registry.yarnpkg.com/engine.io-parser/-/engine.io-parser-5.0.6.tgz#7811244af173e157295dec9b2718dfe42a64ef45" + resolved "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.0.6.tgz" integrity sha512-tjuoZDMAdEhVnSFleYPCtdL2GXwVTGtNjoeJd9IhIG3C1xs9uwxqRNEu5WpnDZCaozwVlK/nuQhpodhXSIMaxw== entities@^2.0.0: version "2.2.0" - resolved "https://registry.yarnpkg.com/entities/-/entities-2.2.0.tgz#098dc90ebb83d8dffa089d55256b351d34c4da55" + resolved "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz" integrity sha512-p92if5Nz619I0w+akJrLZH0MX0Pb5DX39XOwQTtXSdQQOaYH03S1uIQp4mhOZtAXrxq4ViO67YTiLBo2638o9A== entities@^3.0.1: version "3.0.1" - resolved "https://registry.yarnpkg.com/entities/-/entities-3.0.1.tgz#2b887ca62585e96db3903482d336c1006c3001d4" + resolved "https://registry.npmjs.org/entities/-/entities-3.0.1.tgz" integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== -error-ex@^1.3.1: - version "1.3.2" - resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" - integrity sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g== - dependencies: - is-arrayish "^0.2.1" - -escape-string-regexp@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz#1b61c0562190a8dff6ae3bb2cf0200ca130b86d4" - integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== - -file-system-cache@^2.0.0: - version "2.3.0" - resolved "https://registry.yarnpkg.com/file-system-cache/-/file-system-cache-2.3.0.tgz#201feaf4c8cd97b9d0d608e96861bb6005f46fe6" - integrity sha512-l4DMNdsIPsVnKrgEXbJwDJsA5mB8rGwHYERMgqQx/xAUtChPJMre1bXBzDEqqVbWv9AIbFezXMxeEkZDSrXUOQ== - dependencies: - fs-extra "11.1.1" - ramda "0.29.0" - -file-uri-to-path@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" - integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== - font-awesome@^4.7.0: version "4.7.0" - resolved "https://registry.yarnpkg.com/font-awesome/-/font-awesome-4.7.0.tgz#8fa8cf0411a1a31afd07b06d2902bb9fc815a133" + resolved "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz" integrity sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg== -fs-extra@11.1.1: - version "11.1.1" - resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-11.1.1.tgz#da69f7c39f3b002378b0954bb6ae7efdc0876e2d" - integrity sha512-MGIE4HOvQCeUCzmlHs0vXpih4ysz4wg9qiSAu6cd42lVwPbTM1TjV7RusoyQqMmk/95gdQZX72u+YW+c3eEpFQ== - dependencies: - graceful-fs "^4.2.0" - jsonfile "^6.0.1" - universalify "^2.0.0" - -function-bind@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== - -gauge@^3.0.0: - version "3.0.2" - resolved "https://registry.yarnpkg.com/gauge/-/gauge-3.0.2.tgz#03bf4441c044383908bcfa0656ad91803259b395" - integrity sha512-+5J6MS/5XksCuXq++uFRsnUd7Ovu1XenbeuIuNRJxYWjgQbPuFhT14lAvsWfqfAmnwluf1OwMjz39HjfLPci0Q== - dependencies: - aproba "^1.0.3 || ^2.0.0" - color-support "^1.1.2" - console-control-strings "^1.0.0" - has-unicode "^2.0.1" - object-assign "^4.1.1" - signal-exit "^3.0.0" - string-width "^4.2.3" - strip-ansi "^6.0.1" - wide-align "^1.1.2" - -get-intrinsic@^1.0.2: - version "1.2.1" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" - integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== - dependencies: - function-bind "^1.1.1" - has "^1.0.3" - has-proto "^1.0.1" - has-symbols "^1.0.3" - get-nonce@^1.0.0: version "1.0.1" - resolved "https://registry.yarnpkg.com/get-nonce/-/get-nonce-1.0.1.tgz#fdf3f0278073820d2ce9426c18f07481b1e0cdf3" + resolved "https://registry.npmjs.org/get-nonce/-/get-nonce-1.0.1.tgz" integrity sha512-FJhYRoDaiatfEkUK8HKlicmu/3SGFD51q3itKDGoSTysQJBnfOcxU5GxnhE1E6soB76MbT0MBtnKJuXyAx+96Q== gif-picker-react@^1.1.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/gif-picker-react/-/gif-picker-react-1.2.0.tgz#bbedd040b5433b5de00d447d1a68f08de1e17715" - integrity sha512-zNVjRR5nx9hqxuRzu9HPrHik9UIDMu82DwWVpKjEiWSiKODMiMFV3SNiuZ4tYjiUfohuRENUJzOAitJ7ZQnaTA== - dependencies: - "@storybook/addon-styling" "^1.0.8" + version "1.3.0" + resolved "https://registry.npmjs.org/gif-picker-react/-/gif-picker-react-1.3.0.tgz" + integrity sha512-IYDmx9iEouC84JCrOt/HSaiRgHD8o7/catZCspUVpNEXoIunq7CF65JcmyTyoPkVJZcQz0ofjU5Gp5C2bqwOlQ== -graceful-fs@^4.1.6, graceful-fs@^4.2.0, graceful-fs@^4.2.4: +graceful-fs@^4.2.4: version "4.2.11" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" + resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== -has-flag@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-3.0.0.tgz#b5d454dc2199ae225699f3467e5a07f3b955bafd" - integrity sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw== - -has-flag@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" - integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== - -has-proto@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" - integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== - -has-symbols@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" - integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== - -has-unicode@^2.0.1: - version "2.0.1" - resolved "https://registry.yarnpkg.com/has-unicode/-/has-unicode-2.0.1.tgz#e0e6fe6a28cf51138855e086d1691e771de2a8b9" - integrity sha512-8Rf9Y83NBReMnx0gFzA8JImQACstCYWUplepDa9xprwwtmgEZUF0h/i5xSA625zB/I37EtrswSST6OXxwaaIJQ== - -has@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" - integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== - dependencies: - function-bind "^1.1.1" - hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: version "1.1.7" - resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" + resolved "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" integrity sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA== dependencies: inherits "^2.0.3" minimalistic-assert "^1.0.1" -hls.js@^1.4.0: - version "1.4.8" - resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.4.8.tgz#6fedcb5224d7361e4f38046ffd45286d8a645df8" - integrity sha512-wYL7W49M6oKv0+P4RW50YkJaxDzgnHMMrN+YoLpow07hVgaedAdX9HfKkehTb04UEfeJhNSef5ucICYPsHOfqg== +hls.js@^1.4.9: + version "1.4.10" + resolved "https://registry.npmjs.org/hls.js/-/hls.js-1.4.10.tgz" + integrity sha512-wAVSj4Fm2MqOHy5+BlYnlKxXvJlv5IuZHjlzHu18QmjRzSDFQiUDWdHs5+NsFMQrgKEBwuWDcyvaMC9dUzJ5Uw== hmac-drbg@^1.0.1: version "1.0.1" - resolved "https://registry.yarnpkg.com/hmac-drbg/-/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1" + resolved "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz" integrity sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg== dependencies: hash.js "^1.0.3" @@ -1428,7 +807,7 @@ hmac-drbg@^1.0.1: html-dom-parser@1.2.0: version "1.2.0" - resolved "https://registry.yarnpkg.com/html-dom-parser/-/html-dom-parser-1.2.0.tgz#8f689b835982ffbf245eda99730e92b8462c111e" + resolved "https://registry.npmjs.org/html-dom-parser/-/html-dom-parser-1.2.0.tgz" integrity sha512-2HIpFMvvffsXHFUFjso0M9LqM+1Lm22BF+Df2ba+7QHJXjk63pWChEnI6YG27eaWqUdfnh5/Vy+OXrNTtepRsg== dependencies: domhandler "4.3.1" @@ -1436,7 +815,7 @@ html-dom-parser@1.2.0: html-react-parser@^1.4.13: version "1.4.14" - resolved "https://registry.yarnpkg.com/html-react-parser/-/html-react-parser-1.4.14.tgz#577b7a90be0c61eebbbc488d914ad08398c79ef5" + resolved "https://registry.npmjs.org/html-react-parser/-/html-react-parser-1.4.14.tgz" integrity sha512-pxhNWGie8Y+DGDpSh8cTa0k3g8PsDcwlfolA+XxYo1AGDeB6e2rdlyv4ptU9bOTiZ2i3fID+6kyqs86MN0FYZQ== dependencies: domhandler "4.3.1" @@ -1446,7 +825,7 @@ html-react-parser@^1.4.13: htmlparser2@7.2.0: version "7.2.0" - resolved "https://registry.yarnpkg.com/htmlparser2/-/htmlparser2-7.2.0.tgz#8817cdea38bbc324392a90b1990908e81a65f5a5" + resolved "https://registry.npmjs.org/htmlparser2/-/htmlparser2-7.2.0.tgz" integrity sha512-H7MImA4MS6cw7nbyURtLPO1Tms7C5H602LRETv95z1MxO/7CP7rDVROehUYeYBUYEON94NXXDEPmZuq+hX4sog== dependencies: domelementtype "^2.0.1" @@ -1454,159 +833,72 @@ htmlparser2@7.2.0: domutils "^2.8.0" entities "^3.0.1" -icss-utils@^5.0.0, icss-utils@^5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/icss-utils/-/icss-utils-5.1.0.tgz#c6be6858abd013d768e98366ae47e25d5887b1ae" - integrity sha512-soFhflCVWLfRNOPU3iv5Z9VUdT44xFRbzjLsEzSr5AQmgqPMTHdU3PMT1Cf1ssx8fLNJDA1juftYl+PUcv3MqA== - -import-fresh@^3.2.1: - version "3.3.0" - resolved "https://registry.yarnpkg.com/import-fresh/-/import-fresh-3.3.0.tgz#37162c25fcb9ebaa2e6e53d5b4d88ce17d9e0c2b" - integrity sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw== - dependencies: - parent-module "^1.0.0" - resolve-from "^4.0.0" - -inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.3: +inherits@^2.0.3, inherits@^2.0.4: version "2.0.4" - resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" + resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== inline-style-parser@0.1.1: version "0.1.1" - resolved "https://registry.yarnpkg.com/inline-style-parser/-/inline-style-parser-0.1.1.tgz#ec8a3b429274e9c0a1f1c4ffa9453a7fef72cea1" + resolved "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.1.1.tgz" integrity sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q== invariant@^2.2.4: version "2.2.4" - resolved "https://registry.yarnpkg.com/invariant/-/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" + resolved "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz" integrity sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA== dependencies: loose-envify "^1.0.0" -is-arrayish@^0.2.1: - version "0.2.1" - resolved "https://registry.yarnpkg.com/is-arrayish/-/is-arrayish-0.2.1.tgz#77c99840527aa8ecb1a8ba697b80645a7a926a9d" - integrity sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg== - -is-fullwidth-code-point@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" - integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== - is-stream@^2.0.0: version "2.0.1" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" + resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== -isarray@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" - integrity sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ== - -jiti@^1.18.2: - version "1.18.2" - resolved "https://registry.yarnpkg.com/jiti/-/jiti-1.18.2.tgz#80c3ef3d486ebf2450d9335122b32d121f2a83cd" - integrity sha512-QAdOptna2NYiSSpv0O/BwoHBSmz4YhpzJHyi+fnMRTXFjp7B8i/YG5Z8IfusxB1ufjcD2Sre1F3R+nX3fvy7gg== - js-base64@^3.7.2: version "3.7.5" - resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.5.tgz#21e24cf6b886f76d6f5f165bfcd69cc55b9e3fca" + resolved "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz" integrity sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA== js-sha3@0.8.0: version "0.8.0" - resolved "https://registry.yarnpkg.com/js-sha3/-/js-sha3-0.8.0.tgz#b9b7a5da73afad7dedd0f8c463954cbde6818840" + resolved "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz" integrity sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q== -"js-tokens@^3.0.0 || ^4.0.0", js-tokens@^4.0.0: +"js-tokens@^3.0.0 || ^4.0.0": version "4.0.0" - resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-4.0.0.tgz#19203fb59991df98e3a287050d4647cdeaf32499" + resolved "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== -js-yaml@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/js-yaml/-/js-yaml-4.1.0.tgz#c1fb65f8f5017901cdd2c951864ba18458a10602" - integrity sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA== - dependencies: - argparse "^2.0.1" - -json-parse-even-better-errors@^2.3.0: - version "2.3.1" - resolved "https://registry.yarnpkg.com/json-parse-even-better-errors/-/json-parse-even-better-errors-2.3.1.tgz#7c47805a94319928e05777405dc12e1f7a4ee02d" - integrity sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w== - -json5@^2.1.2: - version "2.2.3" - resolved "https://registry.yarnpkg.com/json5/-/json5-2.2.3.tgz#78cd6f1a19bdc12b73db5ad0c61efd66c1e29283" - integrity sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg== - -jsonfile@^6.0.1: - version "6.1.0" - resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-6.1.0.tgz#bc55b2634793c679ec6403094eb13698a6ec0aae" - integrity sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ== - dependencies: - universalify "^2.0.0" - optionalDependencies: - graceful-fs "^4.1.6" - -klona@^2.0.6: - version "2.0.6" - resolved "https://registry.yarnpkg.com/klona/-/klona-2.0.6.tgz#85bffbf819c03b2f53270412420a4555ef882e22" - integrity sha512-dhG34DXATL5hSxJbIexCft8FChFXtmskoZYnoPWjXQuebWYCNkVeV3KkGegCK9CP1oswI/vQibS2GY7Em/sJJA== - -less-loader@^11.1.0: - version "11.1.1" - resolved "https://registry.yarnpkg.com/less-loader/-/less-loader-11.1.1.tgz#f1ba2bac94afe2a9c37baa3aa3f17efcfd56a5d5" - integrity sha512-sxfYqC6nYpZMF57gMmtlgbNwtH++zOCqqRnOlrvmgtNTQEyX7jFb1GlMXOpHb1+B8KZugOK72onl1SEkEgWH2g== - dependencies: - klona "^2.0.6" - v "^0.3.0" - -lines-and-columns@^1.1.6: - version "1.2.4" - resolved "https://registry.yarnpkg.com/lines-and-columns/-/lines-and-columns-1.2.4.tgz#eca284f75d2965079309dc0ad9255abb2ebc1632" - integrity sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg== - -livepeer@2.6.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/livepeer/-/livepeer-2.6.0.tgz#b2c1011436ec801390e8b77d1322087c83171c6b" - integrity sha512-tURkBvJQi0nyS5WlFHhKyRGx0qKqGt/DbKSzhUwJ9fAzT3GAlipujgKVOc3wnNWIj76LQrCp7onUmsrrkFRGkQ== +livepeer@2.8.0: + version "2.8.0" + resolved "https://registry.npmjs.org/livepeer/-/livepeer-2.8.0.tgz" + integrity sha512-ZYw/bew356VZ1MZE6T7NBV6xgQ6yukqutb/GiSk9Yz+vjJvxy2npu4sEhgZ1pkHFVVczcGVwjZidWWaZ+oMwGg== dependencies: - "@livepeer/core" "^1.6.0" + "@livepeer/core" "^1.8.0" "@stitches/core" "^1.2.8" - core-js "^3.27.2" - cross-fetch "^3.1.5" - hls.js "^1.4.0" + core-js "^3.31.1" + cross-fetch "^4.0.0" + hls.js "^1.4.9" ms "^3.0.0-canary.1" - multiformats "9.9.0" - tus-js-client "^3.0.1" - zustand "^4.3.2" - -loader-utils@^2.0.0: - version "2.0.4" - resolved "https://registry.yarnpkg.com/loader-utils/-/loader-utils-2.0.4.tgz#8b5cb38b5c34a9a018ee1fc0e6a066d1dfcc528c" - integrity sha512-xXqpXoINfFhgua9xiqD8fPFHgkoq1mmmpE92WlDbm9rNRd/EbRb+Gqf908T2DMfuHjjJlksiK2RbHVOdD/MqSw== - dependencies: - big.js "^5.2.2" - emojis-list "^3.0.0" - json5 "^2.1.2" + tus-js-client "^3.1.0" + zustand "^4.3.9" lodash._baseiteratee@~4.7.0: version "4.7.0" - resolved "https://registry.yarnpkg.com/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz#34a9b5543572727c3db2e78edae3c0e9e66bd102" + resolved "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz" integrity sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ== dependencies: lodash._stringtopath "~4.8.0" lodash._basetostring@~4.12.0: version "4.12.0" - resolved "https://registry.yarnpkg.com/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz#9327c9dc5158866b7fa4b9d42f4638e5766dd9df" + resolved "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz" integrity sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw== lodash._baseuniq@~4.6.0: version "4.6.0" - resolved "https://registry.yarnpkg.com/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz#0ebb44e456814af7905c6212fa2c9b2d51b841e8" + resolved "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz" integrity sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A== dependencies: lodash._createset "~4.0.0" @@ -1614,292 +906,100 @@ lodash._baseuniq@~4.6.0: lodash._createset@~4.0.0: version "4.0.3" - resolved "https://registry.yarnpkg.com/lodash._createset/-/lodash._createset-4.0.3.tgz#0f4659fbb09d75194fa9e2b88a6644d363c9fe26" + resolved "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz" integrity sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA== lodash._root@~3.0.0: version "3.0.1" - resolved "https://registry.yarnpkg.com/lodash._root/-/lodash._root-3.0.1.tgz#fba1c4524c19ee9a5f8136b4609f017cf4ded692" + resolved "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz" integrity sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ== lodash._stringtopath@~4.8.0: version "4.8.0" - resolved "https://registry.yarnpkg.com/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz#941bcf0e64266e5fc1d66fed0a6959544c576824" + resolved "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz" integrity sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ== dependencies: lodash._basetostring "~4.12.0" lodash.throttle@^4.1.1: version "4.1.1" - resolved "https://registry.yarnpkg.com/lodash.throttle/-/lodash.throttle-4.1.1.tgz#c23e91b710242ac70c37f1e1cda9274cc39bf2f4" + resolved "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz" integrity sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ== lodash.uniqby@4.5.0: version "4.5.0" - resolved "https://registry.yarnpkg.com/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz#a3a17bbf62eeb6240f491846e97c1c4e2a5e1e21" + resolved "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz" integrity sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ== dependencies: lodash._baseiteratee "~4.7.0" lodash._baseuniq "~4.6.0" -lodash@^4.17.21: - version "4.17.21" - resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" - integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== - loose-envify@^1.0.0: version "1.4.0" - resolved "https://registry.yarnpkg.com/loose-envify/-/loose-envify-1.4.0.tgz#71ee51fa7be4caec1a63839f7e682d8132d30caf" + resolved "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz" integrity sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q== dependencies: js-tokens "^3.0.0 || ^4.0.0" -lru-cache@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" - integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== - dependencies: - yallist "^4.0.0" - -map-or-similar@^1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/map-or-similar/-/map-or-similar-1.5.0.tgz#6de2653174adfb5d9edc33c69d3e92a1b76faf08" - integrity sha512-0aF7ZmVon1igznGI4VS30yugpduQW3y3GkcgGJOp7d8x8QrizhigUxjI/m2UojsXXto+jLAH3KSz+xOJTiORjg== - -memoizerific@^1.11.3: - version "1.11.3" - resolved "https://registry.yarnpkg.com/memoizerific/-/memoizerific-1.11.3.tgz#7c87a4646444c32d75438570905f2dbd1b1a805a" - integrity sha512-/EuHYwAPdLtXwAwSZkh/Gutery6pD2KYd44oQLhAvQp/50mpyduZh8Q7PYHXTCJ+wuXxt7oij2LXyIJOOYFPog== - dependencies: - map-or-similar "^1.5.0" - minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" - resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" + resolved "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" integrity sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A== minimalistic-crypto-utils@^1.0.1: version "1.0.1" - resolved "https://registry.yarnpkg.com/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz#f6c00c1c0b082246e5c4d99dfb8c7c083b2b582a" + resolved "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz" integrity sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg== moment@^2.29.4: version "2.29.4" - resolved "https://registry.yarnpkg.com/moment/-/moment-2.29.4.tgz#3dbe052889fe7c1b2ed966fcb3a77328964ef108" + resolved "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz" integrity sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w== -ms@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" - integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A== - ms@2.1.2: version "2.1.2" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" + resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -ms@^2.1.1: - version "2.1.3" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" - integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== - ms@^3.0.0-canary.1: version "3.0.0-canary.1" - resolved "https://registry.yarnpkg.com/ms/-/ms-3.0.0-canary.1.tgz#c7b34fbce381492fd0b345d1cf56e14d67b77b80" + resolved "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz" integrity sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g== multiformats@9.9.0: version "9.9.0" - resolved "https://registry.yarnpkg.com/multiformats/-/multiformats-9.9.0.tgz#c68354e7d21037a8f1f8833c8ccd68618e8f1d37" + resolved "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz" integrity sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg== -nanoid@^3.3.6: - version "3.3.6" - resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.6.tgz#443380c856d6e9f9824267d960b4236ad583ea4c" - integrity sha512-BGcqMMJuToF7i1rt+2PWSNVnWIkGCU78jBG3RxO/bZlnZPK2Cmi2QaffxGO/2RvWi9sL+FAiRiXMgsyxQ1DIDA== - -neo-async@^2.6.2: - version "2.6.2" - resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.2.tgz#b4aafb93e3aeb2d8174ca53cf163ab7d7308305f" - integrity sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw== - -node-addon-api@^1.7.1: - version "1.7.2" - resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-1.7.2.tgz#3df30b95720b53c24e59948b49532b662444f54d" - integrity sha512-ibPK3iA+vaY1eEjESkQkM0BbCqFOaZMiXRTtdB0u7b4djtY6JnsjvPdUHVMg6xQt3B8fpTTWHI9A+ADjM9frzg== - -node-fetch@2.6.7: - version "2.6.7" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.7.tgz#24de9fba827e3b4ae44dc8b20256a379160052ad" - integrity sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ== - dependencies: - whatwg-url "^5.0.0" - node-fetch@^2.6.12: version "2.6.12" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.12.tgz#02eb8e22074018e3d5a83016649d04df0e348fba" + resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz" integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== dependencies: whatwg-url "^5.0.0" -npmlog@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-5.0.1.tgz#f06678e80e29419ad67ab964e0fa69959c1eb8b0" - integrity sha512-AqZtDUWOMKs1G/8lwylVjrdYgqA4d9nu8hc+0gzRxlDb1I10+FHBGMXs6aiQHFdCUUlqH99MUMuLfzWDNDtfxw== - dependencies: - are-we-there-yet "^2.0.0" - console-control-strings "^1.1.0" - gauge "^3.0.0" - set-blocking "^2.0.0" - -object-assign@^4.1.1: - version "4.1.1" - resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" - integrity sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg== - -object-inspect@^1.9.0: - version "1.12.3" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" - integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== - -parent-module@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" - integrity sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g== - dependencies: - callsites "^3.0.0" - -parse-json@^5.0.0: - version "5.2.0" - resolved "https://registry.yarnpkg.com/parse-json/-/parse-json-5.2.0.tgz#c76fc66dee54231c962b22bcc8a72cf2f99753cd" - integrity sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg== - dependencies: - "@babel/code-frame" "^7.0.0" - error-ex "^1.3.1" - json-parse-even-better-errors "^2.3.0" - lines-and-columns "^1.1.6" - -path-type@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" - integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== - -picocolors@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/picocolors/-/picocolors-1.0.0.tgz#cb5bdc74ff3f51892236eaf79d68bc44564ab81c" - integrity sha512-1fygroTLlHu66zi26VoTDv8yRgm0Fccecssto+MhsZ0D/DGW2sm8E8AjW7NU5VVTRt5GxbeZ5qBuJr+HyLYkjQ== - -postcss-loader@^7.2.4: - version "7.3.2" - resolved "https://registry.yarnpkg.com/postcss-loader/-/postcss-loader-7.3.2.tgz#ac3344ad1f14bb65df135744b7efae4dbdad4301" - integrity sha512-c7qDlXErX6n0VT+LUsW+nwefVtTu3ORtVvK8EXuUIDcxo+b/euYqpuHlJAvePb0Af5e8uMjR/13e0lTuYifaig== - dependencies: - cosmiconfig "^8.1.3" - jiti "^1.18.2" - klona "^2.0.6" - semver "^7.3.8" - -postcss-modules-extract-imports@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/postcss-modules-extract-imports/-/postcss-modules-extract-imports-3.0.0.tgz#cda1f047c0ae80c97dbe28c3e76a43b88025741d" - integrity sha512-bdHleFnP3kZ4NYDhuGlVK+CMrQ/pqUm8bx/oGL93K6gVwiclvX5x0n76fYMKuIGKzlABOy13zsvqjb0f92TEXw== - -postcss-modules-local-by-default@^4.0.3: - version "4.0.3" - resolved "https://registry.yarnpkg.com/postcss-modules-local-by-default/-/postcss-modules-local-by-default-4.0.3.tgz#b08eb4f083050708998ba2c6061b50c2870ca524" - integrity sha512-2/u2zraspoACtrbFRnTijMiQtb4GW4BvatjaG/bCjYQo8kLTdevCUlwuBHx2sCnSyrI3x3qj4ZK1j5LQBgzmwA== - dependencies: - icss-utils "^5.0.0" - postcss-selector-parser "^6.0.2" - postcss-value-parser "^4.1.0" - -postcss-modules-scope@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/postcss-modules-scope/-/postcss-modules-scope-3.0.0.tgz#9ef3151456d3bbfa120ca44898dfca6f2fa01f06" - integrity sha512-hncihwFA2yPath8oZ15PZqvWGkWf+XUfQgUGamS4LqoP1anQLOsOJw0vr7J7IwLpoY9fatA2qiGUGmuZL0Iqlg== - dependencies: - postcss-selector-parser "^6.0.4" - -postcss-modules-values@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/postcss-modules-values/-/postcss-modules-values-4.0.0.tgz#d7c5e7e68c3bb3c9b27cbf48ca0bb3ffb4602c9c" - integrity sha512-RDxHkAiEGI78gS2ofyvCsu7iycRv7oqw5xMWn9iMoR0N/7mf9D50ecQqUo5BZ9Zh2vH4bCUR/ktCqbB9m8vJjQ== - dependencies: - icss-utils "^5.0.0" - -postcss-selector-parser@^6.0.2, postcss-selector-parser@^6.0.4: - version "6.0.13" - resolved "https://registry.yarnpkg.com/postcss-selector-parser/-/postcss-selector-parser-6.0.13.tgz#d05d8d76b1e8e173257ef9d60b706a8e5e99bf1b" - integrity sha512-EaV1Gl4mUEV4ddhDnv/xtj7sxwrwxdetHdWUGnT4VJQf+4d05v6lHYZr8N573k5Z0BViss7BDhfWtKS3+sfAqQ== - dependencies: - cssesc "^3.0.0" - util-deprecate "^1.0.2" - -postcss-value-parser@^4.1.0, postcss-value-parser@^4.2.0: - version "4.2.0" - resolved "https://registry.yarnpkg.com/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz#723c09920836ba6d3e5af019f92bc0971c02e514" - integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ== - -postcss@^8.2.14, postcss@^8.4.21: - version "8.4.24" - resolved "https://registry.yarnpkg.com/postcss/-/postcss-8.4.24.tgz#f714dba9b2284be3cc07dbd2fc57ee4dc972d2df" - integrity sha512-M0RzbcI0sO/XJNucsGjvWU9ERWxb/ytp1w6dKtxTKgixdtQDq4rmx/g8W1hnaheq9jgwL/oyEdH5Bc4WwJKMqg== - dependencies: - nanoid "^3.3.6" - picocolors "^1.0.0" - source-map-js "^1.0.2" - -pretty-hrtime@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/pretty-hrtime/-/pretty-hrtime-1.0.3.tgz#b7e3ea42435a4c9b2759d99e0f201eb195802ee1" - integrity sha512-66hKPCr+72mlfiSjlEB1+45IjXSqvVAIy6mocupoww4tBFE9R9IhwwUGoI4G++Tc9Aq+2rxOt0RFU6gPcrte0A== - -process-nextick-args@~2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" - integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== - proper-lockfile@^4.1.2: version "4.1.2" - resolved "https://registry.yarnpkg.com/proper-lockfile/-/proper-lockfile-4.1.2.tgz#c8b9de2af6b2f1601067f98e01ac66baa223141f" + resolved "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz" integrity sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA== dependencies: graceful-fs "^4.2.4" retry "^0.12.0" signal-exit "^3.0.2" -qs@^6.10.0: - version "6.11.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" - integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== - dependencies: - side-channel "^1.0.4" - querystringify@^2.1.1: version "2.2.0" - resolved "https://registry.yarnpkg.com/querystringify/-/querystringify-2.2.0.tgz#3345941b4153cb9d082d8eee4cda2016a9aef7f6" + resolved "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz" integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== -ramda@0.29.0: - version "0.29.0" - resolved "https://registry.yarnpkg.com/ramda/-/ramda-0.29.0.tgz#fbbb67a740a754c8a4cbb41e2a6e0eb8507f55fb" - integrity sha512-BBea6L67bYLtdbOqfp8f58fPMqEwx0doL+pAi8TZyp2YWz8R9G8z9x75CZI8W+ftqhFHCpEX2cRnUUXK130iKA== - -randombytes@^2.0.3: - version "2.1.0" - resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" - integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== - dependencies: - safe-buffer "^5.1.0" - react-property@2.0.0: version "2.0.0" - resolved "https://registry.yarnpkg.com/react-property/-/react-property-2.0.0.tgz#2156ba9d85fa4741faf1918b38efc1eae3c6a136" + resolved "https://registry.npmjs.org/react-property/-/react-property-2.0.0.tgz" integrity sha512-kzmNjIgU32mO4mmH5+iUyrqlpFQhF8K2k7eZ4fdLSOPFrD1XgEuSBv9LDEgxRXTMBqMd8ppT0x6TIzqE5pdGdw== react-remove-scroll-bar@^2.3.3: version "2.3.4" - resolved "https://registry.yarnpkg.com/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz#53e272d7a5cb8242990c7f144c44d8bd8ab5afd9" + resolved "https://registry.npmjs.org/react-remove-scroll-bar/-/react-remove-scroll-bar-2.3.4.tgz" integrity sha512-63C4YQBUt0m6ALadE9XV56hV8BgJWDmmTPY758iIJjfQKt2nYwoUrPk0LXRXcB/yIj82T1/Ixfdpdk68LwIB0A== dependencies: react-style-singleton "^2.2.1" @@ -1907,7 +1007,7 @@ react-remove-scroll-bar@^2.3.3: react-remove-scroll@2.5.5: version "2.5.5" - resolved "https://registry.yarnpkg.com/react-remove-scroll/-/react-remove-scroll-2.5.5.tgz#1e31a1260df08887a8a0e46d09271b52b3a37e77" + resolved "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.5.5.tgz" integrity sha512-ImKhrzJJsyXJfBZ4bzu8Bwpka14c/fQt0k+cyFp/PBhTfyDnU5hjOtM4AG/0AMyy8oKzOTR0lDgJIM7pYXI0kw== dependencies: react-remove-scroll-bar "^2.3.3" @@ -1918,130 +1018,48 @@ react-remove-scroll@2.5.5: react-style-singleton@^2.2.1: version "2.2.1" - resolved "https://registry.yarnpkg.com/react-style-singleton/-/react-style-singleton-2.2.1.tgz#f99e420492b2d8f34d38308ff660b60d0b1205b4" + resolved "https://registry.npmjs.org/react-style-singleton/-/react-style-singleton-2.2.1.tgz" integrity sha512-ZWj0fHEMyWkHzKYUr2Bs/4zU6XLmq9HsgBURm7g5pAVfyn49DgUiNgY2d4lXRlYSiCif9YBGpQleewkcqddc7g== dependencies: get-nonce "^1.0.0" invariant "^2.2.4" tslib "^2.0.0" -readable-stream@^2.0.5: - version "2.3.8" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.8.tgz#91125e8042bba1b9887f49345f6277027ce8be9b" - integrity sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA== - 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" - -readable-stream@^3.6.0: - version "3.6.2" - resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" - integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== +react-twitter-embed@^4.0.4: + version "4.0.4" + resolved "https://registry.npmjs.org/react-twitter-embed/-/react-twitter-embed-4.0.4.tgz" + integrity sha512-2JIL7qF+U62zRzpsh6SZDXNI3hRNVYf5vOZ1WRcMvwKouw+xC00PuFaD0aEp2wlyGaZ+f4x2VvX+uDadFQ3HVA== dependencies: - inherits "^2.0.3" - string_decoder "^1.1.1" - util-deprecate "^1.0.1" + scriptjs "^2.5.9" regenerator-runtime@^0.13.11: version "0.13.11" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz#f6dca3e7ceec20590d07ada785636a90cdca17f9" + resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== -regex-parser@^2.2.11: - version "2.2.11" - resolved "https://registry.yarnpkg.com/regex-parser/-/regex-parser-2.2.11.tgz#3b37ec9049e19479806e878cabe7c1ca83ccfe58" - integrity sha512-jbD/FT0+9MBU2XAZluI7w2OBs1RBi6p9M83nkoZayQXXU9e8Robt69FcZc7wU4eJD/YFTjn1JdCk3rbMJajz8Q== - requires-port@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/requires-port/-/requires-port-1.0.0.tgz#925d2601d39ac485e091cf0da5c6e694dc3dcaff" + resolved "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz" integrity sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ== -resolve-from@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-4.0.0.tgz#4abcd852ad32dd7baabfe9b40e00a36db5f392e6" - integrity sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g== - -resolve-url-loader@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/resolve-url-loader/-/resolve-url-loader-5.0.0.tgz#ee3142fb1f1e0d9db9524d539cfa166e9314f795" - integrity sha512-uZtduh8/8srhBoMx//5bwqjQ+rfYOUq8zC9NrMUGtjBiGTtFJM42s58/36+hTqeqINcnYe08Nj3LkK9lW4N8Xg== - dependencies: - adjust-sourcemap-loader "^4.0.0" - convert-source-map "^1.7.0" - loader-utils "^2.0.0" - postcss "^8.2.14" - source-map "0.6.1" - retry@^0.12.0: version "0.12.0" - resolved "https://registry.yarnpkg.com/retry/-/retry-0.12.0.tgz#1b42a6266a21f07421d1b0b54b7dc167b01c013b" + resolved "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz" integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== -safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@~5.2.0: - version "5.2.1" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" - integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== - -safe-buffer@~5.1.0, safe-buffer@~5.1.1: - version "5.1.2" - resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.1.2.tgz#991ec69d296e0313747d59bdfd2b745c35f8828d" - integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== - -sass-loader@^13.2.2: - version "13.3.1" - resolved "https://registry.yarnpkg.com/sass-loader/-/sass-loader-13.3.1.tgz#32ee5791434b9b4dbd1adcce76fcb4cea49cc12c" - integrity sha512-cBTxmgyVA1nXPvIK4brjJMXOMJ2v2YrQEuHqLw3LylGb3gsR6jAvdjHMcy/+JGTmmIF9SauTrLLR7bsWDMWqgg== - dependencies: - klona "^2.0.6" - neo-async "^2.6.2" - -semver@^7.3.7, semver@^7.3.8: - version "7.5.1" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.1.tgz#c90c4d631cf74720e46b21c1d37ea07edfab91ec" - integrity sha512-Wvss5ivl8TMRZXXESstBA4uR5iXgEN/VC5/sOcuXdVLzcdkz4HWetIoRfG5gb5X+ij/G9rw9YoGn3QoQ8OCSpw== - dependencies: - lru-cache "^6.0.0" - -set-blocking@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" - integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== - -side-channel@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" - integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== - dependencies: - call-bind "^1.0.0" - get-intrinsic "^1.0.2" - object-inspect "^1.9.0" +scriptjs@^2.5.9: + version "2.5.9" + resolved "https://registry.npmjs.org/scriptjs/-/scriptjs-2.5.9.tgz" + integrity sha512-qGVDoreyYiP1pkQnbnFAUIS5AjenNwwQBdl7zeos9etl+hYKWahjRTfzAZZYBv5xNHx7vNKCmaLDQZ6Fr2AEXg== -signal-exit@^3.0.0, signal-exit@^3.0.2: +signal-exit@^3.0.2: version "3.0.7" - resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.7.tgz#a9a1767f8af84155114eaabd73f99273c8f59ad9" + resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" integrity sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ== -simple-websocket@^5.0.0: - version "5.1.1" - resolved "https://registry.yarnpkg.com/simple-websocket/-/simple-websocket-5.1.1.tgz#ad46492f95b80405b95dfe2a43d4586e8a571646" - integrity sha512-1yCq3y3XtzENKnCT5ycsV2f45PlQoIQOKeSlOMQ43Z2rKkIxLsJz3dZRRccHJE/rdbMozLUl/SRisdLchX2TrQ== - dependencies: - debug "^3.1.0" - inherits "^2.0.1" - randombytes "^2.0.3" - readable-stream "^2.0.5" - safe-buffer "^5.0.1" - ws "^3.3.1" - socket.io-client@^4.5.2: version "4.6.1" - resolved "https://registry.yarnpkg.com/socket.io-client/-/socket.io-client-4.6.1.tgz#80d97d5eb0feca448a0fb6d69a7b222d3d547eab" + resolved "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.6.1.tgz" integrity sha512-5UswCV6hpaRsNg5kkEHVcbBIXEYoVbMQaHJBXJCyEQ+CiFPV1NIOY0XOFWG4XR4GZcB8Kn6AsRs/9cy9TbqVMQ== dependencies: "@socket.io/component-emitter" "~3.1.0" @@ -2051,131 +1069,40 @@ socket.io-client@^4.5.2: socket.io-parser@~4.2.1: version "4.2.2" - resolved "https://registry.yarnpkg.com/socket.io-parser/-/socket.io-parser-4.2.2.tgz#1dd384019e25b7a3d374877f492ab34f2ad0d206" + resolved "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.2.tgz" integrity sha512-DJtziuKypFkMMHCm2uIshOYC7QaylbtzQwiMYDuCKy3OPkjLzu4B2vAhTlqipRHHzrI0NJeBAizTK7X+6m1jVw== dependencies: "@socket.io/component-emitter" "~3.1.0" debug "~4.3.1" -source-map-js@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/source-map-js/-/source-map-js-1.0.2.tgz#adbc361d9c62df380125e7f161f71c826f1e490c" - integrity sha512-R0XvVJ9WusLiqTCEiGCmICCMplcCkIwwR11mOSD9CR5u+IXYdiseeEuXCVAjS54zqwkLcPNnmU4OeJ6tUrWhDw== - -source-map@0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/source-map/-/source-map-0.6.1.tgz#74722af32e9614e9c287a8d0bbde48b5e2f1a263" - integrity sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g== - -store2@^2.14.2: - version "2.14.2" - resolved "https://registry.yarnpkg.com/store2/-/store2-2.14.2.tgz#56138d200f9fe5f582ad63bc2704dbc0e4a45068" - integrity sha512-siT1RiqlfQnGqgT/YzXVUNsom9S0H1OX+dpdGN1xkyYATo4I6sep5NmsRD/40s3IIOvlCq6akxkqG82urIZW1w== - -"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.2.3: - version "4.2.3" - resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" - integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== - dependencies: - emoji-regex "^8.0.0" - is-fullwidth-code-point "^3.0.0" - strip-ansi "^6.0.1" - -string_decoder@^1.1.1: - version "1.3.0" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" - integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== - dependencies: - safe-buffer "~5.2.0" - -string_decoder@~1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.1.1.tgz#9cf1611ba62685d7030ae9e4ba34149c3af03fc8" - integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== - dependencies: - safe-buffer "~5.1.0" - -strip-ansi@^6.0.1: - version "6.0.1" - resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" - integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== - dependencies: - ansi-regex "^5.0.1" - -style-loader@^3.3.2: - version "3.3.3" - resolved "https://registry.yarnpkg.com/style-loader/-/style-loader-3.3.3.tgz#bba8daac19930169c0c9c96706749a597ae3acff" - integrity sha512-53BiGLXAcll9maCYtZi2RCQZKa8NQQai5C4horqKyRmHj9H7QmcUyucrH+4KW/gBQbXM2AsB0axoEcFZPlfPcw== - style-to-js@1.1.1: version "1.1.1" - resolved "https://registry.yarnpkg.com/style-to-js/-/style-to-js-1.1.1.tgz#417786986cda61d4525c80aed9d1123a6a7af9b8" + resolved "https://registry.npmjs.org/style-to-js/-/style-to-js-1.1.1.tgz" integrity sha512-RJ18Z9t2B02sYhZtfWKQq5uplVctgvjTfLWT7+Eb1zjUjIrWzX5SdlkwLGQozrqarTmEzJJ/YmdNJCUNI47elg== dependencies: style-to-object "0.3.0" style-to-object@0.3.0: version "0.3.0" - resolved "https://registry.yarnpkg.com/style-to-object/-/style-to-object-0.3.0.tgz#b1b790d205991cc783801967214979ee19a76e46" + resolved "https://registry.npmjs.org/style-to-object/-/style-to-object-0.3.0.tgz" integrity sha512-CzFnRRXhzWIdItT3OmF8SQfWyahHhjq3HwcMNCNLn+N7klOOqPjMeG/4JSu77D7ypZdGvSzvkrbyeTMizz2VrA== dependencies: inline-style-parser "0.1.1" -supports-color@^5.3.0: - version "5.5.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f" - integrity sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow== - dependencies: - has-flag "^3.0.0" - -supports-color@^7.1.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" - integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== - dependencies: - has-flag "^4.0.0" - -synchronous-promise@^2.0.15: - version "2.0.17" - resolved "https://registry.yarnpkg.com/synchronous-promise/-/synchronous-promise-2.0.17.tgz#38901319632f946c982152586f2caf8ddc25c032" - integrity sha512-AsS729u2RHUfEra9xJrE39peJcc2stq2+poBXX8bcM08Y6g9j/i/PUzwNQqkaJde7Ntg1TO7bSREbR5sdosQ+g== - -telejson@^7.0.3: - version "7.1.0" - resolved "https://registry.yarnpkg.com/telejson/-/telejson-7.1.0.tgz#1ef7a0dd57eeb52cde933126f61bcc296c170f52" - integrity sha512-jFJO4P5gPebZAERPkJsqMAQ0IMA1Hi0AoSfxpnUaV6j6R2SZqlpkbS20U6dEUtA3RUYt2Ak/mTlkQzHH9Rv/hA== - dependencies: - memoizerific "^1.11.3" - -to-fast-properties@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/to-fast-properties/-/to-fast-properties-2.0.0.tgz#dc5e698cbd079265bc73e0377681a4e4e83f616e" - integrity sha512-/OaKK0xYrs3DmxRYqL/yDc+FxFUVYhDlXMhRmv3z915w2HF1tnN1omB354j8VUGO/hbRzyD6Y3sA7v7GS/ceog== - tr46@~0.0.3: version "0.0.3" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" + resolved "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz" integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== -ts-dedent@^2.0.0: - version "2.2.0" - resolved "https://registry.yarnpkg.com/ts-dedent/-/ts-dedent-2.2.0.tgz#39e4bd297cd036292ae2394eb3412be63f563bb5" - integrity sha512-q5W7tVM71e2xjHZTlgfTDoPF/SmqKG5hddq9SzR49CH2hayqRKJtQ4mtRlSxKaJlR/+9rEM+mnBHf7I2/BQcpQ== - -tslib@^2.0.0, tslib@^2.1.0: - version "2.6.0" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.0.tgz#b295854684dbda164e181d259a22cd779dcd7bc3" - integrity sha512-7At1WUettjcSRHXCyYtTselblcHl9PJFFVKiCAy/bY97+BPZXSQ2wbq0P9s8tK2G7dFQfNnlJnPAiArVBVBsfA== - -tslib@^2.3.0: +tslib@^2.0.0, tslib@^2.1.0, tslib@^2.3.0: version "2.5.0" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.5.0.tgz#42bfed86f5787aeb41d031866c8f402429e0fddf" + resolved "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz" integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg== -tus-js-client@^3.0.1: - version "3.1.0" - resolved "https://registry.yarnpkg.com/tus-js-client/-/tus-js-client-3.1.0.tgz#20af57d06c23823fbe108ccb3a3dcb7503968cb4" - integrity sha512-Hfpc8ho4C9Lhs/OflPUA/nHUHZJUrKD5upoPBq7dYJJ9DQhWocsjJU2RZYfN16Y5n19j9dFDszwCvVZ5sfcogw== +tus-js-client@^3.1.0: + version "3.1.1" + resolved "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz" + integrity sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A== dependencies: buffer-from "^1.1.2" combine-errors "^3.0.3" @@ -2185,24 +1112,9 @@ tus-js-client@^3.0.1: proper-lockfile "^4.1.2" url-parse "^1.5.7" -type-fest@^2.19.0: - version "2.19.0" - resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-2.19.0.tgz#88068015bb33036a598b952e55e9311a60fd3a9b" - integrity sha512-RAH822pAdBgcNMAfWnCBU3CFZcfZ/i1eZjwFU/dsLKumyuuP3niueg2UAukXYF0E2AAoc82ZSSf9J0WQBinzHA== - -ultron@~1.1.0: - version "1.1.1" - resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.1.tgz#9fe1536a10a664a65266a1e3ccf85fd36302bc9c" - integrity sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og== - -universalify@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/universalify/-/universalify-2.0.0.tgz#75a4984efedc4b08975c5aeb73f530d02df25717" - integrity sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ== - url-parse@^1.5.7: version "1.5.10" - resolved "https://registry.yarnpkg.com/url-parse/-/url-parse-1.5.10.tgz#9d3c2f736c1d75dd3bd2be507dcc111f1e2ea9c1" + resolved "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz" integrity sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ== dependencies: querystringify "^2.1.1" @@ -2210,21 +1122,14 @@ url-parse@^1.5.7: use-callback-ref@^1.3.0: version "1.3.0" - resolved "https://registry.yarnpkg.com/use-callback-ref/-/use-callback-ref-1.3.0.tgz#772199899b9c9a50526fedc4993fc7fa1f7e32d5" + resolved "https://registry.npmjs.org/use-callback-ref/-/use-callback-ref-1.3.0.tgz" integrity sha512-3FT9PRuRdbB9HfXhEq35u4oZkvpJ5kuYbpqhCfmiZyReuRgpnhDlbr2ZEnnuS0RrJAPn6l23xjFg9kpDM+Ms7w== dependencies: tslib "^2.0.0" -use-resize-observer@^9.1.0: - version "9.1.0" - resolved "https://registry.yarnpkg.com/use-resize-observer/-/use-resize-observer-9.1.0.tgz#14735235cf3268569c1ea468f8a90c5789fc5c6c" - integrity sha512-R25VqO9Wb3asSD4eqtcxk8sJalvIOYBqS8MNZlpDSQ4l4xMQxC/J7Id9HoTqPq8FwULIn0PVW+OAqF2dyYbjow== - dependencies: - "@juggle/resize-observer" "^3.3.1" - use-sidecar@^1.1.2: version "1.1.2" - resolved "https://registry.yarnpkg.com/use-sidecar/-/use-sidecar-1.1.2.tgz#2f43126ba2d7d7e117aa5855e5d8f0276dfe73c2" + resolved "https://registry.npmjs.org/use-sidecar/-/use-sidecar-1.1.2.tgz" integrity sha512-epTbsLuzZ7lPClpz2TyryBfztm7m+28DlEv2ZCQ3MDr5ssiwyOwGH/e5F9CkfWjJ1t4clvI58yF822/GUkjjhw== dependencies: detect-node-es "^1.1.0" @@ -2232,71 +1137,35 @@ use-sidecar@^1.1.2: use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: version "1.2.0" - resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz#7dbefd6ef3fe4e767a0cf5d7287aacfb5846928a" + resolved "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz" integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== -util-deprecate@^1.0.1, util-deprecate@^1.0.2, util-deprecate@~1.0.1: - version "1.0.2" - resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" - integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== - -v@^0.3.0: - version "0.3.0" - resolved "https://registry.yarnpkg.com/v/-/v-0.3.0.tgz#475af8a6196f66e4da8b3375d5e9ee7db76f681f" - integrity sha512-9grXbMw2B4ScMvE9iL2tre9Qfy46zWDNjSptgFCraHfgqRQMhPlWkFHKvUOKjBFvOAxeRTiaY6SySPLXFBt2oQ== - dependencies: - debug "^2.6.1" - simple-websocket "^5.0.0" - optionalDependencies: - deasync "^0.1.9" - webidl-conversions@^3.0.0: version "3.0.1" - resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" + resolved "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz" integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== whatwg-url@^5.0.0: version "5.0.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" + resolved "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz" integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== dependencies: tr46 "~0.0.3" webidl-conversions "^3.0.0" -wide-align@^1.1.2: - version "1.1.5" - resolved "https://registry.yarnpkg.com/wide-align/-/wide-align-1.1.5.tgz#df1d4c206854369ecf3c9a4898f1b23fbd9d15d3" - integrity sha512-eDMORYaPNZ4sQIuuYPDHdQvf4gyCF9rEEV/yPxGfwPkRodwEgiMUUXTx/dex+Me0wxx53S+NgUHaP7y3MGlDmg== - dependencies: - string-width "^1.0.2 || 2 || 3 || 4" - -ws@^3.3.1: - version "3.3.3" - resolved "https://registry.yarnpkg.com/ws/-/ws-3.3.3.tgz#f1cf84fe2d5e901ebce94efaece785f187a228f2" - integrity sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA== - dependencies: - async-limiter "~1.0.0" - safe-buffer "~5.1.0" - ultron "~1.1.0" - ws@~8.11.0: version "8.11.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.11.0.tgz#6a0d36b8edfd9f96d8b25683db2f8d7de6e8e143" + resolved "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz" integrity sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg== xmlhttprequest-ssl@~2.0.0: version "2.0.0" - resolved "https://registry.yarnpkg.com/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz#91360c86b914e67f44dce769180027c0da618c67" + resolved "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz" integrity sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A== -yallist@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" - integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== - -zustand@^4.3.2: - version "4.3.9" - resolved "https://registry.yarnpkg.com/zustand/-/zustand-4.3.9.tgz#a7d4332bbd75dfd25c6848180b3df1407217f2ad" - integrity sha512-Tat5r8jOMG1Vcsj8uldMyqYKC5IZvQif8zetmLHs9WoZlntTHmIoNM8TpLRY31ExncuUvUOXehd0kvahkuHjDw== +zustand@^4.3.9: + version "4.4.0" + resolved "https://registry.npmjs.org/zustand/-/zustand-4.4.0.tgz" + integrity sha512-2dq6wq4dSxbiPTamGar0NlIG/av0wpyWZJGeQYtUOLegIUvhM2Bf86ekPlmgpUtS5uR7HyetSiktYrGsdsyZgQ== dependencies: use-sync-external-store "1.2.0" From 8ecf5d92cc1b5c25562ba0d6d1ae1137877a5be7 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 9 Aug 2023 11:05:37 +0530 Subject: [PATCH 184/298] fix: add alpha support to UI web --- packages/uiweb/project.json | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/packages/uiweb/project.json b/packages/uiweb/project.json index d5f327b5f..aec4d41f0 100644 --- a/packages/uiweb/project.json +++ b/packages/uiweb/project.json @@ -48,6 +48,16 @@ "postTargets": ["uiweb:build", "uiweb:ci-publish"] } }, + "ci-version-beta": { + "executor": "@jscutlery/semver:version", + "options": { + "preset": "angular", + "commitMessageFormat": "ci(${projectName}): 🎉 cut beta release to ${projectName}-v${version}", + "postTargets": ["uiweb:build", "uiweb:ci-publish"], + "version": "prerelease", + "preid": "alpha" + } + }, "ci-publish": { "executor": "@nrwl/workspace:run-commands", "options": { From 9a6eab175d548469919364b36b5bada5bc555cdb Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 9 Aug 2023 11:20:01 +0530 Subject: [PATCH 185/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 21 +++++++++++++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 182d1e341..59cb82a9b 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,27 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-0.0.1-alpha.0) (2023-08-09) + + +### Bug Fixes + +* add alpha support to UI web ([8ecf5d9](https://github.com/ethereum-push-notification-service/push-sdk/commit/8ecf5d92cc1b5c25562ba0d6d1ae1137877a5be7)) +* fixed bugs ([#566](https://github.com/ethereum-push-notification-service/push-sdk/issues/566)) ([481d8fc](https://github.com/ethereum-push-notification-service/push-sdk/commit/481d8fcd7c40325654ba490640daabc38ee2f96e)) +* fixed build issues ([#550](https://github.com/ethereum-push-notification-service/push-sdk/issues/550)) ([0ce6e18](https://github.com/ethereum-push-notification-service/push-sdk/commit/0ce6e18a82901478fe3157788c716e5224f14bdb)) +* fixed issue with build uiweb ([#541](https://github.com/ethereum-push-notification-service/push-sdk/issues/541)) ([3e00f81](https://github.com/ethereum-push-notification-service/push-sdk/commit/3e00f81af99de5bee468c3320062aec243708798)) +* merged main ([c5533f8](https://github.com/ethereum-push-notification-service/push-sdk/commit/c5533f8dce7b88cb1f14aa72f83579a8e01dcf36)) +* signer compatibility with viem ([3df201c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3df201c7474b88d270d6e868bc516f223539e74c)) +* signer compatibility with viem and ethers ([1edea43](https://github.com/ethereum-push-notification-service/push-sdk/commit/1edea431ccf7f19cc0430deb2ce7a5c61390d99f)) + + +### Features + +* add video sdk methods ([#395](https://github.com/ethereum-push-notification-service/push-sdk/issues/395)) ([4b9dd69](https://github.com/ethereum-push-notification-service/push-sdk/commit/4b9dd691ac1fde6a91be0478b20780f6755fbb4f)), closes [#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295) [#309](https://github.com/ethereum-push-notification-service/push-sdk/issues/309) [#357](https://github.com/ethereum-push-notification-service/push-sdk/issues/357) [#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295) +* chat widget component ([#386](https://github.com/ethereum-push-notification-service/push-sdk/issues/386)) ([93a8fd8](https://github.com/ethereum-push-notification-service/push-sdk/commit/93a8fd8b41831ab61931336044a8f66cb9453edd)), closes [#460](https://github.com/ethereum-push-notification-service/push-sdk/issues/460) + + + ## [1.1.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.3...uiweb-1.1.4) (2023-07-20) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 2f777f227..9e52107ad 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.4", + "version": "0.0.1-alpha.0", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 79cd37464936ae2991df94fe733e42eb50a21a58 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 9 Aug 2023 16:44:12 +0530 Subject: [PATCH 186/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 8f9a24fd2..f1e522e0e 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.5...restapi-1.4.6) (2023-08-09) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([75fbda5](https://github.com/ethereum-push-notification-service/push-sdk/commit/75fbda5fdaf152f40758cb62ebc2dca4890f0340)) +* **sdk-frontend:** comment out spaces UI to remove build issues ([#618](https://github.com/ethereum-push-notification-service/push-sdk/issues/618)) ([769c20d](https://github.com/ethereum-push-notification-service/push-sdk/commit/769c20d5eb42b758277e57699793b8e76deeab94)) + + + ## [1.4.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.4...restapi-1.4.5) (2023-08-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 631835798..76ea33b9d 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.5", + "version": "1.4.6", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 0142fb70a3ddbb700f941d64afb773b22f275f3f Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 10 Aug 2023 05:34:14 +0530 Subject: [PATCH 187/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 10 ++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 7555e7b21..6378f41a9 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.8...uiweb-1.1.9) (2023-08-10) + + +### Bug Fixes + +* hide few spaces features ([#622](https://github.com/ethereum-push-notification-service/push-sdk/issues/622)) ([0e2556c](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e2556c6bbe3438cd30851ffdd9764b027f42f6e)) +* Merge branch 'main' into deployment ([843cd01](https://github.com/ethereum-push-notification-service/push-sdk/commit/843cd0169a270bbab69922021edf312616de3802)) + + + ## [1.1.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.7...uiweb-1.1.8) (2023-08-04) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 85147ea15..da845c0af 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.8", + "version": "1.1.9", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From dd97e3ddcc98bfc8ce34ae563a38eaf4b6d3228b Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Thu, 10 Aug 2023 12:57:46 +0530 Subject: [PATCH 188/298] Feat/chat components (#625) * feat: created architechture * fix: added context values (#594) * Chat dataprovider (#596) * feat: data provider for chat component * fix: replaced react.usestate to usestate * fix: added props as the initial state and changed state name * fix: reverted chat context changes and renamed values * fix: added test page for chat ui components (#597) * added chatbubble component (#602) * feat: added chatbubble component * fix: made the messageBubble's width to fit-content --------- Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> * fix: added theme * Group chat bubble (#604) * feat: moved test component to testui folder & replaced dummy data with sdk response * feat: added twitter card and address for group chat received msg * feat: made the messageaddress reusable, added account from context * fix: removed unnecessary div and unused props and console logs * feat: adding pfp in text bubbles * fix: replaced hook with function and added pfp to messagebubble * fix: fixed image alignment * fix: changed border-radius of msg bubble and changed function name * fix: fixed theme and decryptedPrivateKey name (#616) * fix: fixed theme and decryptedPrivateKey name * fix: fixed bug * fix: fixed theme reviews * Message list (#615) * fix: message list comp * fix: message list comp * fix: added pagination * fix: added pagination * fix: pagination * fix: create useChatData hook * fix: fixed minor bug * fix: socket issues fixed * fix: added theme in msgbubble (#620) * fix: added theme in msgbubble * fix: fixed import --------- Co-authored-by: Monalisha Mishra * fix: exported the theme (#623) * fix: exported the theme * fix: fixed issues --------- Co-authored-by: Monalisha Mishra --------- Co-authored-by: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Co-authored-by: KlausMikhaelson --- .../sdk-frontend-react/src/app/app.tsx | 4 +- .../chat/MessageBubble/MessageBubble.tsx | 4 +- .../chat/MessageList/MessageList.tsx | 38 ++++++-- .../src/lib/components/chat/exportedTypes.ts | 1 + .../uiweb/src/lib/components/chat/index.ts | 1 + .../components/chat/theme/ThemeProvider.tsx | 10 +- .../src/lib/components/chat/theme/index.ts | 95 +++++++++---------- .../lib/dataProviders/ChatDataProvider.tsx | 7 +- 8 files changed, 89 insertions(+), 71 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index a025e4f7f..b6ea55f10 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -78,7 +78,7 @@ import { import ChatUITest from './ChatUITest/ChatUITest'; import MessageListTest from './ChatUITest/MessageListTest'; import { MessageBubbles } from './ChatUITest/MessageBubbles'; -import { ChatThemeOptions } from '@pushprotocol/uiweb'; +import { lightChatTheme } from '@pushprotocol/uiweb'; window.Buffer = window.Buffer || Buffer; @@ -303,7 +303,7 @@ export function App() { - + {' '}
diff --git a/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx b/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx index 389ed105f..d85ba01da 100644 --- a/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx @@ -12,9 +12,18 @@ import { appendUniqueMessages, dateToFromNowDaily, pCAIP10ToWallet } from '../.. import { useChatData, usePushChatSocket } from '../../../hooks'; import { Messagetype } from '../../../types'; import { ThemeContext } from '../theme/ThemeProvider'; +import { IChatTheme } from '../theme'; +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; + + } export const MessageList: React.FC = ( options: IMessageListProps @@ -36,7 +45,7 @@ export const MessageList: React.FC = ( if (!Object.keys(messages || {}).length) { setMessages({ messages: messagesSinceLastConnection, - lastThreadHash: messages!.lastThreadHash, + lastThreadHash: messagesSinceLastConnection.lastThreadHash, }); } else { const newMessageList = appendUniqueMessages(messages as Messagetype,[messagesSinceLastConnection],false); @@ -47,6 +56,7 @@ export const MessageList: React.FC = ( }); } + scrollToBottom(null); } }, [messagesSinceLastConnection]); @@ -145,18 +155,21 @@ export const MessageList: React.FC = ( ); }; - return ( -
onScroll()} > {loading ? : ''} - = ( ); })}
- -
+
+ ); }; //styles -const MessageListCard = styled(Section)``; +const MessageListCard = styled(Section)` +&::-webkit-scrollbar-thumb { + background: ${(props) => props.theme.accentBgColor}; + border-radius: 10px; + } + + &::-webkit-scrollbar { + width: 5px; + } -//pagination scroll issue left -//socket +`; diff --git a/packages/uiweb/src/lib/components/chat/exportedTypes.ts b/packages/uiweb/src/lib/components/chat/exportedTypes.ts index 97f4b5c47..a0a0dbcf1 100644 --- a/packages/uiweb/src/lib/components/chat/exportedTypes.ts +++ b/packages/uiweb/src/lib/components/chat/exportedTypes.ts @@ -19,3 +19,4 @@ export const CHAT_THEME_OPTIONS = { } as const; export type ChatThemeOptions = (typeof CHAT_THEME_OPTIONS)[keyof typeof CHAT_THEME_OPTIONS]; +export {IChatTheme} from './theme'; diff --git a/packages/uiweb/src/lib/components/chat/index.ts b/packages/uiweb/src/lib/components/chat/index.ts index 207007be6..95973691a 100644 --- a/packages/uiweb/src/lib/components/chat/index.ts +++ b/packages/uiweb/src/lib/components/chat/index.ts @@ -1,3 +1,4 @@ export { MessageBubble } from './MessageBubble'; export * from './MessageList'; export * from './exportedTypes'; +export * from './theme'; diff --git a/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx b/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx index f1f745e9b..5b5134b48 100644 --- a/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx +++ b/packages/uiweb/src/lib/components/chat/theme/ThemeProvider.tsx @@ -3,18 +3,16 @@ */ import { createContext } from 'react'; -import { IChatTheme, lightTheme } from './index'; - +import { IChatTheme, lightChatTheme } from './index'; +export { lightChatTheme, darkChatTheme } from './index'; /** * @param theme optional: light or dark theme. defaults to light * @param customTheme optional: custom colors/theme * @param children children to be wrapped with ThemeProvider */ export interface IThemeProviderProps { - theme?: 'light' | 'dark'; - // themeOverride?: Partial; + theme?: IChatTheme; children: any; } - -export const ThemeContext = createContext(lightTheme); +export const ThemeContext = createContext(lightChatTheme); diff --git a/packages/uiweb/src/lib/components/chat/theme/index.ts b/packages/uiweb/src/lib/components/chat/theme/index.ts index 3b58a948e..9a198030a 100644 --- a/packages/uiweb/src/lib/components/chat/theme/index.ts +++ b/packages/uiweb/src/lib/components/chat/theme/index.ts @@ -1,54 +1,53 @@ /** * @file theme file: all the predefined themes are defined here */ -import { CHAT_THEME_OPTIONS } from "../exportedTypes"; +import { CHAT_THEME_OPTIONS } from '../exportedTypes'; export interface IChatTheme { - bgColorPrimary?: string; - bgColorSecondary?: string; - textColorPrimary?: string; - textColorSecondary?: string; - accentBgColor?:string; - accentTextColor?:string; - btnColorPrimary?: string; - border?: string; - borderRadius?: string; - iconColorPrimary?: string; - fontFamily?: string; - receiverBgColor?: string; - } - - export const lightTheme: IChatTheme = { - bgColorPrimary:'#fff', - receiverBgColor: "#fff", - bgColorSecondary:'linear-gradient(179.97deg, #EEF5FF 0.02%, #ECE9FA 123.25%)', - textColorPrimary:'#000', - textColorSecondary:'rgb(101, 119, 149)', - accentBgColor:'rgb(202, 89, 155)', - accentTextColor:'#fff', - btnColorPrimary:'rgb(202, 89, 155)', - border:'none', - borderRadius:'32px', - iconColorPrimary:'none' - }; - - export const darkTheme: IChatTheme = { - bgColorPrimary:'rgb(47, 49, 55)', - bgColorSecondary:'rgb(40, 42, 46)', - receiverBgColor: "#fff", - textColorPrimary:'#fff', - textColorSecondary:'rgb(182, 188, 214)', - accentBgColor:'rgb(202, 89, 155)', - accentTextColor:'#fff', - btnColorPrimary:'rgb(202, 89, 155)', - border:'none', - borderRadius:'32px', - iconColorPrimary:'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)' - }; - + bgColorPrimary?: string; + bgColorSecondary?: string; + textColorPrimary?: string; + textColorSecondary?: string; + accentBgColor?: string; + accentTextColor?: string; + btnColorPrimary?: string; + chatBubbleAccentBgColor?:string; + border?: string; + borderRadius?: string; + iconColorPrimary?: string; + fontFamily?: string; + chatBubblePrimaryBgColor?: string; +} + +export const lightChatTheme: IChatTheme = { + bgColorPrimary: '#fff', + chatBubblePrimaryBgColor: '#fff', + bgColorSecondary: + 'linear-gradient(179.97deg, #EEF5FF 0.02%, #ECE9FA 123.25%)', + textColorPrimary: '#000', + textColorSecondary: 'rgb(101, 119, 149)', + chatBubbleAccentBgColor: 'rgb(202, 89, 155)', + accentBgColor: 'rgb(202, 89, 155)', + accentTextColor: '#fff', + btnColorPrimary: 'rgb(202, 89, 155)', + border: 'none', + borderRadius: '32px', + iconColorPrimary: 'none', +}; + +export const darkChatTheme: IChatTheme = { + chatBubblePrimaryBgColor: 'fff', + bgColorPrimary: 'rgb(47, 49, 55)', + bgColorSecondary: 'rgb(40, 42, 46)', + textColorPrimary: '#fff', + textColorSecondary: 'rgb(182, 188, 214)', + chatBubbleAccentBgColor: 'rgb(202, 89, 155)', + accentBgColor: 'rgb(202, 89, 155)', + accentTextColor: '#fff', + btnColorPrimary: 'rgb(202, 89, 155)', + border: 'none', + borderRadius: '32px', + iconColorPrimary: + 'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)', +}; - //function to return final theme object -export const getCustomChatTheme = (theme:string | undefined) => { - // return Object.assign({}, theme===CHAT_THEME_OPTIONS.DARK?darkTheme:lightTheme, themeOverride); - return theme===CHAT_THEME_OPTIONS.DARK?darkTheme:lightTheme; - } \ No newline at end of file diff --git a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx index e12d02dff..e099818fe 100644 --- a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx +++ b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx @@ -7,13 +7,12 @@ import { import { ThemeContext } from '../components/chat/theme/ThemeProvider'; import useGetChatProfile from '../hooks/useGetChatProfile'; import { IUser } from '@pushprotocol/restapi'; -import { IChatTheme, getCustomChatTheme } from '../components/chat/theme'; +import { IChatTheme, lightChatTheme } from '../components/chat/theme'; import { ChatThemeOptions } from '../components'; export interface IChatUIProviderProps { children: ReactNode; - theme?: ChatThemeOptions; - themeOverride?: Partial; + theme?: IChatTheme; account?: string | null; pgpPrivateKey?: string | null; env?: ENV; @@ -69,7 +68,7 @@ useEffect(() => { }; - const PROVIDER_THEME = getCustomChatTheme(theme); + const PROVIDER_THEME = Object.assign({}, lightChatTheme, theme); return ( From b74a40df83d13bf1ea69f37c073f238a6663b87e Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 10 Aug 2023 13:00:18 +0530 Subject: [PATCH 189/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 4 ++++ packages/uiweb/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 59cb82a9b..387d51119 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.0...uiweb-0.0.1-alpha.1) (2023-08-10) + + + ## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-0.0.1-alpha.0) (2023-08-09) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 9e52107ad..974a0d1d4 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.0", + "version": "0.0.1-alpha.1", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 04c7de2523573678b4bb49be61a5dfad6dbaa3d3 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 10 Aug 2023 14:07:24 +0530 Subject: [PATCH 190/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index f1e522e0e..428428337 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.6...restapi-1.4.7) (2023-08-10) + + +### Bug Fixes + +* allow to create empty groups just with group creator. ([#607](https://github.com/ethereum-push-notification-service/push-sdk/issues/607)) ([7d14e24](https://github.com/ethereum-push-notification-service/push-sdk/commit/7d14e248626422cf079e4b99dbdfa3ce6cd796da)) +* CreateUserPropsWithProfile ([#612](https://github.com/ethereum-push-notification-service/push-sdk/issues/612)) ([32125b5](https://github.com/ethereum-push-notification-service/push-sdk/commit/32125b5408b45e8a51ba9a16acc1250fc56decae)) +* deprecation notice ([#581](https://github.com/ethereum-push-notification-service/push-sdk/issues/581)) ([6cd4b1e](https://github.com/ethereum-push-notification-service/push-sdk/commit/6cd4b1ea8626849a5f78588a21ac66db2bd293df)) + + + ## [1.4.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.5...restapi-1.4.6) (2023-08-09) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 76ea33b9d..c8b14a62c 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.6", + "version": "1.4.7", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From a50488c91347f309d4671dfdfde397a01443fa92 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 10 Aug 2023 14:26:07 +0530 Subject: [PATCH 191/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 428428337..b318349d7 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.7...restapi-1.4.8) (2023-08-10) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([e504703](https://github.com/ethereum-push-notification-service/push-sdk/commit/e5047039c6ec668c0a2ad5950d7a5ba227c4f50a)) + + + ## [1.4.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.6...restapi-1.4.7) (2023-08-10) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c8b14a62c..c47cd3dfc 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.7", + "version": "1.4.8", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ae25b693c54f328ec6983b071d1e5ecb9d35f1f9 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 10 Aug 2023 14:35:02 +0530 Subject: [PATCH 192/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.10?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 4 ++++ packages/uiweb/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 6378f41a9..eb30e71a6 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.9...uiweb-1.1.10) (2023-08-10) + + + ## [1.1.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.8...uiweb-1.1.9) (2023-08-10) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index da845c0af..1542f18cd 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.9", + "version": "1.1.10", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 4f690df9a08c7b7ec055ad80d8f880d8d29b773c Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 11 Aug 2023 15:41:56 +0530 Subject: [PATCH 193/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index b318349d7..4d10e69cb 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.8...restapi-1.4.9) (2023-08-11) + + +### Bug Fixes + +* added Reaction MessageType ([#633](https://github.com/ethereum-push-notification-service/push-sdk/issues/633)) ([2856ece](https://github.com/ethereum-push-notification-service/push-sdk/commit/2856ece83e0a42335ff7e5e2f8db83d2aa7fd007)) +* Merge branch 'main' into deployment ([cd9f1e0](https://github.com/ethereum-push-notification-service/push-sdk/commit/cd9f1e0dfb6fc7aa6ff3648d17509fe43aa824f6)) + + + ## [1.4.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.7...restapi-1.4.8) (2023-08-10) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c47cd3dfc..241e2296f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.8", + "version": "1.4.9", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 31a453e8501b74b04ad1eb25d79a96021ec1194a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 15 Aug 2023 14:37:33 +0530 Subject: [PATCH 194/298] 632 group access control sdk changes (#640) * fix: group access control changes * fix: get group access SDK fix * fix: removed unnecessary param * Update README.md * Update README.md * Update README.md --- .../src/app/ChatTest/ChatTest.tsx | 3 + .../src/app/ChatTest/CreateGroupTest.tsx | 19 + .../src/app/ChatTest/GetGroupAccessTest.tsx | 86 +++ .../src/app/ChatTest/UpdateGroupTest.tsx | 18 + .../sdk-frontend-react/src/app/app.tsx | 129 +++-- packages/restapi/README.md | 541 ++++++++++++++++-- packages/restapi/src/lib/chat/createGroup.ts | 13 +- .../restapi/src/lib/chat/getGroupAccess.ts | 48 ++ .../src/lib/chat/helpers/payloadHelper.ts | 11 +- packages/restapi/src/lib/chat/index.ts | 1 + packages/restapi/src/lib/chat/updateGroup.ts | 7 +- packages/restapi/src/lib/types/index.ts | 38 ++ 12 files changed, 822 insertions(+), 92 deletions(-) create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupAccessTest.tsx create mode 100644 packages/restapi/src/lib/chat/getGroupAccess.ts diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx index f861ca6e4..ac4b452b8 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx @@ -68,6 +68,9 @@ const ChatTest = () => { CHAT.GETGROUP + + CHAT.GETGROUPACCESS + CHAT.ADDMEMBERSTOGROUP diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx index 1970855f3..4f273a383 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx @@ -10,6 +10,7 @@ import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; import { walletToPCAIP10 } from '../helpers'; import ChatTest from './ChatTest'; +import { Rules } from '@pushprotocol/restapi'; const CreateGroupTest = () => { const { account: acc, library } = useContext(Web3Context); @@ -26,6 +27,8 @@ const CreateGroupTest = () => { const [contractAddressERC20, setContractAddressERC20] = useState(); const [numberOfERC20, setNumberOfERC20] = useState(); const [meta, setMeta] = useState(); + const [rules, setRules] = useState(); + const [account, setAccount] = useState(acc); const [sendResponse, setSendResponse] = useState(''); @@ -74,6 +77,10 @@ const CreateGroupTest = () => { setMeta((e.target as HTMLInputElement).value); }; + const updateRules = (e: React.SyntheticEvent) => { + setRules((e.target as HTMLInputElement).value); + }; + const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; @@ -99,6 +106,7 @@ const CreateGroupTest = () => { signer: librarySigner, env, meta: meta, + rules: rules ? JSON.parse(rules) as Rules : undefined }); setSendResponse(response); @@ -238,6 +246,17 @@ const CreateGroupTest = () => { /> + + + + + + create group diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupAccessTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupAccessTest.tsx new file mode 100644 index 000000000..3da02346b --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupAccessTest.tsx @@ -0,0 +1,86 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; + +const GetGroupAccessTest = () => { + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [chatId, setChatId] = useState(''); + const [did, setDid] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + + const updateChatId = (e: React.SyntheticEvent) => { + setChatId((e.target as HTMLInputElement).value); + }; + + const updateDid = (e: React.SyntheticEvent) => { + setDid((e.target as HTMLInputElement).value); + }; + + const testGetGroupAccess = async () => { + try { + setLoading(true); + + const response = await PushAPI.chat.getGroupAccess({ + chatId: chatId, + did: did, + env, + }); + setSendResponse(response); + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+

Get Group Access Test Page

+ + + +
+ + get group access + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetGroupAccessTest; diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/UpdateGroupTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/UpdateGroupTest.tsx index ee3185149..fd787144d 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatTest/UpdateGroupTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/UpdateGroupTest.tsx @@ -10,6 +10,7 @@ import { Web3Context, EnvContext } from '../context'; import * as PushAPI from '@pushprotocol/restapi'; import { walletToPCAIP10 } from '../helpers'; import ChatTest from './ChatTest'; +import { Rules } from '@pushprotocol/restapi'; const UpdateGroupTest = () => { const { account: acc, library } = useContext(Web3Context); @@ -23,6 +24,7 @@ const UpdateGroupTest = () => { const [admins, setAdmins] = useState(''); const [account, setAccount] = useState(acc); const [sendResponse, setSendResponse] = useState(''); + const [rules, setRules] = useState(); const updateChatId = (e: React.SyntheticEvent) => { setChatId((e.target as HTMLInputElement).value); @@ -47,6 +49,10 @@ const UpdateGroupTest = () => { setAdmins((e.target as HTMLInputElement).value); }; + const updateRules = (e: React.SyntheticEvent) => { + setRules((e.target as HTMLInputElement).value); + }; + const updateAccount = (e: React.SyntheticEvent) => { setAccount((e.target as HTMLInputElement).value); }; @@ -64,6 +70,7 @@ const UpdateGroupTest = () => { account: isCAIP ? walletToPCAIP10(account) : account, signer: librarySigner, env, + rules: rules ? JSON.parse(rules) as Rules : undefined }); setSendResponse(response); @@ -143,6 +150,17 @@ const UpdateGroupTest = () => { style={{ width: 400, height: 30 }} />
+ + + + + + } /> - {/* spaces method routes */} - } - /> - } - /> - } /> - } - /> - } - /> - } /> - } /> - } - /> - } - /> - } - /> - } - /> - } /> - } - /> - } - /> + {/* chat method routes */} + } /> + } + /> + } /> + } + /> + } + /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } /> + } + /> + } + /> + } + /> + } + /> + } /> + + {/* spaces method routes */} + } /> + } /> + } /> + } + /> + } + /> + } /> + } /> + } + /> + } + /> + } + /> + } + /> + } /> + } + /> + } + /> + {/* spaces ui components routes */} } /> diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 066bd3be5..99027472e 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -3287,10 +3287,58 @@ const response = await PushAPI.chat.createGroup({ members: ['0x9e60c47edF21fa5e5Af33347680B3971F2FfD464','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], groupImage: <group image link> , admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], - contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", - numberOfERC20: 20, - contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", - numberOfNFTTokens: 2, + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + }, isPublic: true, account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', env: 'staging', @@ -3308,13 +3356,79 @@ Allowed Options (params with _ are mandatory) | members* | Array | - | wallet addresses of all members except admins and groupCreator | | admins* | Array | - | wallet addresses of all admins except members and groupCreator | | isPublic* | boolean | - | true for public group, false for private group | -| contractAddressERC20 | string | null | ERC20 Contract Address | -| numberOfERC20 | int | 0 | Minimum number of tokens required to join the group | -| contractAddressNFT | string | null | NFT Contract Address | -| numberOfNFTTokens | int | 0 | Minimum number of nfts required to join the group | +| contractAddressERC20 (deprecated) | string | null | ERC20 Contract Address | +| numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | +| contractAddressNFT (deprecated) | string | null | NFT Contract Address | +| numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | +| rules | Rules | - | conditions for group and chatting access (see format below) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| +## **Rules format** +```typescript +export enum ConditionType { + PUSH = 'PUSH', + GUILD = 'GUILD', +} + +export type Data = { + address?: string; + comparison?: string; + amount?: number; + decimals?: number; + guildId?: string; + roleId?: string; +}; + +export type ConditionBase = { + type: ConditionType; + category?: string; + subcategory?: string; + data: Data; + access?: boolean; +}; + +export type Condition = ConditionBase & { + any?: ConditionBase[]; + all?: ConditionBase[]; +}; + +export interface Rules { + groupAccess?: { + conditions: Array; + }; + chattingAccess?: { + conditions: Array; + }; +} +``` + +## Rules Object Description + +The rules object consists of two main sections: `groupAccess` and `chattingAccess`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. + +### Conditions + +Conditions can be either an "any" or "all" logic structure. If a condition has an "any" property, it means that only one of the nested conditions needs to be met. If a condition has an "all" property, it means that all the nested conditions must be satisfied. + +### Types + +There are two main types of conditions: `PUSH` and `GUILD`. + +#### PUSH Conditions + +PUSH conditions may relate to: + +- **ERC721**: Needs an address and an amount, and can only have the `nft_owner` subcategory. +- **ERC20**: Needs an address, an amount, and a decimals value. It can only have the `token_holder` subcategory. + +#### GUILD Conditions + +GUILD conditions require both guild ID and role ID. + + + +
Expected response (create group) @@ -3423,7 +3537,59 @@ Allowed Options (params with _ are mandatory) groupDescription: 'This is the oficial group for Push Protocol', isPublic: true, groupCreator: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', - chatId: '0364908cbaef95a5a3124c394ada868177c158a4d677cedd6fd1e42db1852386' + chatId: '0364908cbaef95a5a3124c394ada868177c158a4d677cedd6fd1e42db1852386', + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + } } @@ -3479,10 +3645,58 @@ const response = await PushAPI.chat.updateGroup({ members: ['0x2e60c47edF21fa5e5A333347680B3971F1FfD456','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], groupImage: <group image link> , admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], - contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", - numberOfERC20: 20, - contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", - numberOfNFTTokens: 2, + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + }, account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', env: 'staging', pgpPrivateKey: pgpDecryptedPvtKey, //decrypted private key @@ -3499,10 +3713,11 @@ Allowed Options (params with _ are mandatory) | groupImage* | string | - | group image link | | members* | Array | - | wallet addresses of all members except admins and groupCreator | | admins* | Array | - | wallet addresses of all admins except members and groupCreator | -| contractAddressERC20 | string | null | ERC20 Contract Address | -| numberOfERC20 | int | 0 | Minimum number of tokens required to join the group | -| contractAddressNFT | string | null | NFT Contract Address | -| numberOfNFTTokens | int | 0 | Minimum number of nfts required to join the group | +| contractAddressERC20 (deprecated) | string | null | ERC20 Contract Address | +| numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | +| contractAddressNFT (deprecated) | string | null | NFT Contract Address | +| numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | +| rules | Rules | - | conditions for group and chatting access (see format below) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -3629,7 +3844,59 @@ Allowed Options (params with _ are mandatory) groupDescription: 'This is the oficial group for Push Protocol', isPublic: true, groupCreator: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', - chatId: '870cbb20f0b116d5e461a154dc723dc1485976e97f61a673259698aa7f48371c' + chatId: '870cbb20f0b116d5e461a154dc723dc1485976e97f61a673259698aa7f48371c', + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + } } ``` @@ -4277,10 +4544,58 @@ const response = await PushAPI.space.create({ listeners: ['0x9e60c47edF21fa5e5Af33347680B3971F2FfD464','0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], spaceImage: <space image link> , speakers: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], - contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", - numberOfERC20: 20, - contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", - numberOfNFTTokens: 2, + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + }, isPublic: true, account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', env: 'staging', @@ -4302,10 +4617,11 @@ Allowed Options (params with _ are mandatory) | isPublic* | boolean | - | true for public space, false for private space | | scheduleAt\* | Date | - | Date time when the space is scheduled to start | | scheduleEnd | Date | - | Date time when the space is scheduled to end | -| contractAddressERC20 | string | null | ERC20 Contract Address | -| numberOfERC20 | int | 0 | Minimum number of tokens required to join the space | -| contractAddressNFT | string | null | NFT Contract Address | -| numberOfNFTTokens | int | 0 | Minimum number of nfts required to join the space | +| contractAddressERC20 (deprecated) | string | null | ERC20 Contract Address | +| numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | +| contractAddressNFT (deprecated) | string | null | NFT Contract Address | +| numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | +| rules | Rules | - | conditions for space and chatting access (see format above) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -4387,7 +4703,59 @@ Allowed Options (params with _ are mandatory) spaceId: 'spaces:e0553610da88dacac70b406d1222a6881c0bde2c5129e58b526b5ae729d82116', scheduleAt: '2023-07-15T14:48:00.000Z', scheduleEnd: '2023-07-15T15:48:00.000Z', - status: 'PENDING' + status: 'PENDING', + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + }, } @@ -4449,10 +4817,58 @@ const response = await PushAPI.space.update({ scheduleAt: '2023-07-15T14:48:00.000Z', scheduleEnd: '2023-07-15T15:48:00.000Z', status: PushAPI.ChatStatus.PENDING, - contractAddressERC20: "0x8Afa8FDf9fB545C8412499E8532C958086608b30", - numberOfERC20: 20, - contractAddressNFT: "0x42af3147f17239341477113484752D5D3dda997B", - numberOfNFTTokens: 2, + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + }, account: '0xD993eb61B8843439A23741C0A3b5138763aE11a4', env: 'staging', pgpPrivateKey: pgpDecryptedPvtKey, //decrypted private key @@ -4472,10 +4888,11 @@ Allowed Options (params with _ are mandatory) | speakers* | Array | - | wallet addresses of all speakers except listeners and spaceCreator | | scheduleAt* | Date | - | Date time when the space is scheduled to start | | scheduleEnd | Date | - | Date time when the space is scheduled to end | -| contractAddressERC20 | string | null | ERC20 Contract Address | -| numberOfERC20 | int | 0 | Minimum number of tokens required to join the group | -| contractAddressNFT | string | null | NFT Contract Address | -| numberOfNFTTokens | int | 0 | Minimum number of nfts required to join the group | +| contractAddressERC20 (deprecated) | string | null | ERC20 Contract Address | +| numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the space | +| contractAddressNFT (deprecated) | string | null | NFT Contract Address | +| numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the space | +| rules | Rules | - | conditions for space and chatting access (see format above) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -4567,7 +4984,59 @@ Allowed Options (params with _ are mandatory) spaceId: 'spaces:108f766a5053e2b985d0843e806f741da5ad754d128aff0710e526eebc127afc', scheduleAt: '2023-07-15T14:48:00.000Z', scheduleEnd: '2023-07-15T15:48:00.000Z', - status: 'PENDING' + status: 'PENDING', + rules: { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + }, + 'chattingAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + } + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + } + } + ] + } + ] + } + } } ``` diff --git a/packages/restapi/src/lib/chat/createGroup.ts b/packages/restapi/src/lib/chat/createGroup.ts index 0eca88732..74af26339 100644 --- a/packages/restapi/src/lib/chat/createGroup.ts +++ b/packages/restapi/src/lib/chat/createGroup.ts @@ -1,7 +1,7 @@ import axios from 'axios'; import { getAPIBaseUrls } from '../helpers'; import Constants from '../constants'; -import { EnvOptionsType, GroupDTO, SignerType } from '../types'; +import { EnvOptionsType, GroupDTO, SignerType, Rules } from '../types'; import { ICreateGroupRequestPayload, createGroupPayload, @@ -29,9 +29,10 @@ export interface ChatCreateGroupType extends EnvOptionsType { numberOfERC20?: number; pgpPrivateKey?: string | null; meta?: string; - groupType? : string | null, - scheduleAt ?: Date | null; + groupType?: string | null; + scheduleAt?: Date | null; scheduleEnd?: Date | null; + rules?: Rules | null; } export const createGroup = async ( @@ -55,7 +56,8 @@ export const createGroup = async ( meta, groupType, scheduleAt, - scheduleEnd + scheduleEnd, + rules } = options || {}; try { @@ -132,7 +134,8 @@ export const createGroup = async ( meta, groupType, scheduleAt, - scheduleEnd + scheduleEnd, + rules ); return axios diff --git a/packages/restapi/src/lib/chat/getGroupAccess.ts b/packages/restapi/src/lib/chat/getGroupAccess.ts new file mode 100644 index 000000000..83603a17f --- /dev/null +++ b/packages/restapi/src/lib/chat/getGroupAccess.ts @@ -0,0 +1,48 @@ +import axios from 'axios'; +import { getAPIBaseUrls } from '../helpers'; +import Constants, { ENV } from '../constants'; + +/** + * GET /v1/chat/groups/:chatId/access/:did + */ + +export interface GetGroupAccessType { + chatId: string; + did: string; // Decentralized Identifier + env?: ENV; +} + +export const getGroupAccess = async ( + options: GetGroupAccessType +): Promise => { + // Replace "any" with the actual response type + const { chatId, did, env = Constants.ENV.PROD } = options || {}; + try { + if (chatId == null || chatId.length === 0) { + throw new Error(`chatId cannot be null or empty`); + } + if (did == null || did.length === 0) { + throw new Error(`did cannot be null or empty`); + } + + const API_BASE_URL = getAPIBaseUrls(env); + const requestUrl = `${API_BASE_URL}/v1/chat/groups/${chatId}/access/${did}`; + return axios + .get(requestUrl) + .then((response) => { + return response.data; + }) + .catch((err) => { + if (err?.response?.data) throw new Error(err?.response?.data); + throw new Error(err); + }); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${getGroupAccess.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${getGroupAccess.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index ab3a02a4e..f99dbcecb 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -1,5 +1,5 @@ import { isValidETHAddress, walletToPCAIP10 } from '../../helpers'; -import { IConnectedUser, GroupDTO, SpaceDTO, ChatStatus } from '../../types'; +import { IConnectedUser, GroupDTO, SpaceDTO, ChatStatus, Rules } from '../../types'; import { getEncryptedRequest } from './crypto'; import { ENV, MessageType } from '../../constants'; import * as AES from './aes'; @@ -58,6 +58,7 @@ export interface ICreateGroupRequestPayload { groupCreator: string; verificationProof: string; meta?: string; + rules?: Rules | null; } export interface IUpdateGroupRequestPayload { @@ -178,7 +179,8 @@ export const createGroupPayload = ( meta?: string, groupType?: string | null, scheduleAt?: Date | null, - scheduleEnd?: Date | null + scheduleEnd?: Date | null, + rules?: Rules | null, ): ICreateGroupRequestPayload => { const body = { groupName: groupName, @@ -197,6 +199,7 @@ export const createGroupPayload = ( groupType: groupType, scheduleAt: scheduleAt, scheduleEnd: scheduleEnd, + rules: rules }; return body; }; @@ -244,7 +247,8 @@ export const updateGroupPayload = ( scheduleAt?: Date | null, scheduleEnd?: Date | null, status?: ChatStatus | null, - meta?: string | null + meta?: string | null, + rules? : Rules | null ): IUpdateGroupRequestPayload => { const body = { groupName: groupName, @@ -258,6 +262,7 @@ export const updateGroupPayload = ( scheduleEnd: scheduleEnd, status: status, ...(meta !== undefined && { meta: meta }), + ...(rules !== undefined && { rules: rules }), }; return body; }; diff --git a/packages/restapi/src/lib/chat/index.ts b/packages/restapi/src/lib/chat/index.ts index 0a5c3fdbd..d49d0ab6b 100644 --- a/packages/restapi/src/lib/chat/index.ts +++ b/packages/restapi/src/lib/chat/index.ts @@ -18,3 +18,4 @@ export * from './addMembers'; export * from './addAdmins'; export * from './removeMembers'; export * from './removeAdmins'; +export * from './getGroupAccess'; diff --git a/packages/restapi/src/lib/chat/updateGroup.ts b/packages/restapi/src/lib/chat/updateGroup.ts index f0ab01645..41cd7ffd1 100644 --- a/packages/restapi/src/lib/chat/updateGroup.ts +++ b/packages/restapi/src/lib/chat/updateGroup.ts @@ -1,7 +1,7 @@ import axios from 'axios'; import { getAPIBaseUrls } from '../helpers'; import Constants from '../constants'; -import { ChatStatus, EnvOptionsType, GroupDTO, SignerType } from '../types'; +import { ChatStatus, EnvOptionsType, GroupDTO, Rules, SignerType } from '../types'; import { IUpdateGroupRequestPayload, updateGroupPayload, @@ -31,6 +31,7 @@ export interface ChatUpdateGroupType extends EnvOptionsType { // If passed as null will update to null // If passed as string will update to that value meta?: string | null; + rules?: Rules | null; } /** @@ -54,6 +55,7 @@ export const updateGroup = async ( scheduleEnd, status, meta, + rules } = options || {}; try { if (account == null && signer == null) { @@ -108,7 +110,8 @@ export const updateGroup = async ( scheduleAt, scheduleEnd, status, - meta + meta, + rules ); return axios diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 809b95ae0..08831b13c 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -308,6 +308,42 @@ export enum ChatStatus { PENDING = 'PENDING', ENDED = 'ENDED', } + +export enum ConditionType { + PUSH = 'PUSH', + GUILD = 'GUILD', +} + +export type Data = { + address?: string; + amount?: number; + decimals?: number; + guildId?: string; + roleId?: string; +}; + +export type ConditionBase = { + type: ConditionType; + category?: string; + subcategory?: string; + data: Data; + access?: boolean; +}; + +export type Condition = ConditionBase & { + any?: ConditionBase[]; + all?: ConditionBase[]; +}; + +export interface Rules { + groupAccess?: { + conditions: Array; + }; + chattingAccess?: { + conditions: Array; + }; +} + export interface GroupDTO { members: { wallet: string; @@ -336,6 +372,7 @@ export interface GroupDTO { scheduleEnd?: Date | null; groupType?: string; status?: ChatStatus | null; + rules?: Rules | null; } export interface SpaceDTO { @@ -366,6 +403,7 @@ export interface SpaceDTO { scheduleEnd?: Date | null; status: ChatStatus | null; inviteeDetails?: { [key: string]: SPACE_INVITE_ROLES }; + rules?: Rules | null; } export interface Peer { From d338a224a5a39bd891ec5adacdcefa80657c1a82 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 15 Aug 2023 14:48:28 +0530 Subject: [PATCH 195/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.30?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 17 +++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 18 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d1fc77947..5a9ac534e 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,23 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.30](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.29...restapi-0.0.1-alpha.30) (2023-08-15) + + +### Bug Fixes + +* added Reaction MessageType ([#633](https://github.com/ethereum-push-notification-service/push-sdk/issues/633)) ([2856ece](https://github.com/ethereum-push-notification-service/push-sdk/commit/2856ece83e0a42335ff7e5e2f8db83d2aa7fd007)) +* allow to create empty groups just with group creator. ([#607](https://github.com/ethereum-push-notification-service/push-sdk/issues/607)) ([7d14e24](https://github.com/ethereum-push-notification-service/push-sdk/commit/7d14e248626422cf079e4b99dbdfa3ce6cd796da)) +* CreateUserPropsWithProfile ([#612](https://github.com/ethereum-push-notification-service/push-sdk/issues/612)) ([32125b5](https://github.com/ethereum-push-notification-service/push-sdk/commit/32125b5408b45e8a51ba9a16acc1250fc56decae)) +* deprecation notice ([#581](https://github.com/ethereum-push-notification-service/push-sdk/issues/581)) ([6cd4b1e](https://github.com/ethereum-push-notification-service/push-sdk/commit/6cd4b1ea8626849a5f78588a21ac66db2bd293df)) +* fixed subscribe and unsubscribe ([3f908a0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f908a02ce7faee703340e17f6441f3ebe88fd58)) +* Merge branch 'alpha' into alpha-deployment ([984a80f](https://github.com/ethereum-push-notification-service/push-sdk/commit/984a80f178abc220a0243a5fce00413d4dd0aadb)) +* merge main ([f338fd4](https://github.com/ethereum-push-notification-service/push-sdk/commit/f338fd49707933c65bdcc7736cdd08d6784625ba)) +* **merged:** merged ([bb71789](https://github.com/ethereum-push-notification-service/push-sdk/commit/bb717897cec1e7d46d86be05b1d29ca9103272c5)) +* **sdk-frontend:** comment out spaces UI to remove build issues ([#618](https://github.com/ethereum-push-notification-service/push-sdk/issues/618)) ([769c20d](https://github.com/ethereum-push-notification-service/push-sdk/commit/769c20d5eb42b758277e57699793b8e76deeab94)) + + + ## [0.0.1-alpha.29](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.28...restapi-0.0.1-alpha.29) (2023-08-02) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index fa1612829..f24e59bc2 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.29", + "version": "0.0.1-alpha.30", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 1bde1e2b90b365da223992640b7ebd84d7041b2d Mon Sep 17 00:00:00 2001 From: Aman Gupta Date: Wed, 16 Aug 2023 13:31:05 +0530 Subject: [PATCH 196/298] Reduce profile creation signature to 2 (#639) * fix: reduced signatures * fix: fixed examples --- .../sdk-backend-node/src/chat/chat.ts | 15 ++- .../sdk-backend-node/src/chat/nftChat.ts | 9 +- .../restapi/src/lib/chat/helpers/service.ts | 14 ++- .../restapi/src/lib/chat/helpers/signature.ts | 6 +- packages/restapi/src/lib/helpers/crypto.ts | 116 +++++++++++------- packages/restapi/src/lib/user/getUser.ts | 8 +- .../restapi/src/lib/user/getUsersBatch.ts | 8 +- .../src/lib/user/profile.updateUser.ts | 8 +- .../tests/lib/chat/updateGroup.test.ts | 2 +- 9 files changed, 118 insertions(+), 68 deletions(-) diff --git a/packages/examples/sdk-backend-node/src/chat/chat.ts b/packages/examples/sdk-backend-node/src/chat/chat.ts index 31b4bb6d8..3b594ec1c 100644 --- a/packages/examples/sdk-backend-node/src/chat/chat.ts +++ b/packages/examples/sdk-backend-node/src/chat/chat.ts @@ -97,7 +97,7 @@ export const runChatUseCases = async (): Promise => { await PushAPI_chat_video_call_notification(TargetChatId); console.log('PushAPI.chat.createGroup'); - const chatId = await PushAPI_chat_createGroup(); + const { chatId, name } = await PushAPI_chat_createGroup(); console.log('PushAPI.chat.conversationHash'); await PushAPI_chat_conversationHash(); @@ -112,7 +112,7 @@ export const runChatUseCases = async (): Promise => { await PushAPI_chat_updateGroup(chatId); console.log('PushAPI.chat.getGroupByName'); - await PushAPI_chat_getGroupByName(); + await PushAPI_chat_getGroupByName(name); console.log('PushAPI.chat.getGroup'); await PushAPI_chat_getGroup(chatId); @@ -400,7 +400,7 @@ async function PushAPI_chat_approve(silent = !showAPIResponse) { // Push Chat - PushAPI.chat.createGroup async function PushAPI_chat_createGroup( silent = !showAPIResponse -): Promise { +): Promise<{ chatId: string; name: string }> { // Fetch user const user = await PushAPI.user.get({ account: `eip155:${signerAddress}`, @@ -433,7 +433,7 @@ async function PushAPI_chat_createGroup( if (!silent) { console.log(response); } - return response.chatId; + return { chatId: response.chatId, name: response.groupName }; } // Push Chat - PushAPI.chat.updateGroup @@ -483,9 +483,12 @@ async function PushAPI_chat_updateGroup( } // Push Chat - PushAPI.chat.getGroupByName -async function PushAPI_chat_getGroupByName(silent = !showAPIResponse) { +async function PushAPI_chat_getGroupByName( + name: string, + silent = !showAPIResponse +) { const response = await PushAPI.chat.getGroupByName({ - groupName: 'Push Group Chat 3', + groupName: name, env: env as ENV, }); diff --git a/packages/examples/sdk-backend-node/src/chat/nftChat.ts b/packages/examples/sdk-backend-node/src/chat/nftChat.ts index 2e926d519..4f780434f 100644 --- a/packages/examples/sdk-backend-node/src/chat/nftChat.ts +++ b/packages/examples/sdk-backend-node/src/chat/nftChat.ts @@ -95,7 +95,7 @@ export const runNFTChatUseCases = async (): Promise => { await PushAPI_nft_chat_updateGroup(chatId); console.log('PushAPI.chat.getGroupByName'); - await PushAPI_nft_chat_getGroupByName(); + await PushAPI_nft_chat_getGroupByName(updatedNftGroupName); console.log('PushAPI.chat.getGroup'); await PushAPI_nft_chat_getGroup(chatId); @@ -509,9 +509,12 @@ async function PushAPI_nft_chat_updateGroup( } // Push Chat - PushAPI.chat.getGroupByName -async function PushAPI_nft_chat_getGroupByName(silent = !showAPIResponse) { +async function PushAPI_nft_chat_getGroupByName( + name: string, + silent = !showAPIResponse +) { const response = await PushAPI.chat.getGroupByName({ - groupName: 'Push Group Chat 3', + groupName: name, env: env as ENV, }); diff --git a/packages/restapi/src/lib/chat/helpers/service.ts b/packages/restapi/src/lib/chat/helpers/service.ts index b08f0cc22..c0f016319 100644 --- a/packages/restapi/src/lib/chat/helpers/service.ts +++ b/packages/restapi/src/lib/chat/helpers/service.ts @@ -5,7 +5,7 @@ import { getAPIBaseUrls, getQueryParams, isValidCAIP10NFTAddress, - verifyPGPPublicKey, + verifyProfileKeys, walletToPCAIP10, } from '../../helpers'; import { @@ -63,10 +63,12 @@ export const createUserService = async (options: CreateUserOptionsType) => { .post(requestUrl, body) .then(async (response) => { if (response.data) - response.data.publicKey = await verifyPGPPublicKey( + response.data.publicKey = await verifyProfileKeys( response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did + response.data.did, + response.data.wallets, + response.data.verificationProof ); return populateDeprecatedUser(response.data); }) @@ -106,10 +108,12 @@ export const authUpdateUserService = async (options: CreateUserOptionsType) => { .put(requestUrl, body) .then(async (response) => { if (response.data) - response.data.publicKey = verifyPGPPublicKey( + response.data.publicKey = await verifyProfileKeys( response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did + response.data.did, + response.data.wallets, + response.data.verificationProof ); return populateDeprecatedUser(response.data); }) diff --git a/packages/restapi/src/lib/chat/helpers/signature.ts b/packages/restapi/src/lib/chat/helpers/signature.ts index 665e846ad..acc9f2fa2 100644 --- a/packages/restapi/src/lib/chat/helpers/signature.ts +++ b/packages/restapi/src/lib/chat/helpers/signature.ts @@ -90,12 +90,14 @@ export const verifyProfileSignature = async ( ): Promise => { const SIG_TYPE_V2 = 'eip712v2'; const SIG_TYPE_V3 = 'eip191'; + const SIG_TYPE_V4 = 'eip191v2'; let chainId: number | null = null; let signature: string; const sigType = verificationProof.split(':')[0]; - if ( - (sigType !== SIG_TYPE_V2 && sigType !== SIG_TYPE_V3) || + (sigType !== SIG_TYPE_V2 && + sigType !== SIG_TYPE_V3 && + sigType !== SIG_TYPE_V4) || verificationProof.split(':').length > 3 ) { return false; diff --git a/packages/restapi/src/lib/helpers/crypto.ts b/packages/restapi/src/lib/helpers/crypto.ts index e843753e0..9c5a2778d 100644 --- a/packages/restapi/src/lib/helpers/crypto.ts +++ b/packages/restapi/src/lib/helpers/crypto.ts @@ -448,26 +448,24 @@ export const preparePGPPublicKey = async ( chatPublicKey = publicKey; break; } - case Constants.ENC_TYPE_V3: { - const createProfileMessage = - 'Create Push Profile \n' + generateHash(publicKey); - const { verificationProof } = await getEip191Signature( - wallet, - createProfileMessage - ); - chatPublicKey = JSON.stringify({ - key: publicKey, - signature: verificationProof, - }); - break; - } + case Constants.ENC_TYPE_V3: case Constants.ENC_TYPE_V4: { - const createProfileMessage = - 'Create Push Profile \n' + generateHash(publicKey); - const { verificationProof } = await getEip191Signature( - wallet, - createProfileMessage - ); + const verificationProof = 'DEPRECATED'; + + /** + * @deprecated + * PUSH CHAT PROFILE CREATION DOES NOT SIGN PGP PUBLIC KEY + * VERIFICATION PROOF SIGNATURE SHOULD BE USED FOR VERIFICATION OF PUSH PROFILE KEYS + */ + + // const createProfileMessage = + // 'Create Push Profile \n' + generateHash(publicKey); + // const { verificationProof } = await getEip191Signature( + // wallet, + // createProfileMessage + // ); + + // TODO - Change JSON Structure to string ie equivalent to ENC_TYPE_V1 ( would be done after PUSH Node changes ) chatPublicKey = JSON.stringify({ key: publicKey, signature: verificationProof, @@ -480,35 +478,69 @@ export const preparePGPPublicKey = async ( return chatPublicKey; }; -export const verifyPGPPublicKey = async ( +/** + * Checks the Push Profile keys using verificationProof + * @param encryptedPrivateKey + * @param publicKey + * @param did + * @param caip10 + * @param verificationProof + * @returns PGP Public Key + */ +export const verifyProfileKeys = async ( encryptedPrivateKey: string, publicKey: string, - did: string + did: string, + caip10: string, + verificationProof: string ): Promise => { + let parsedPublicKey: string; try { - if (publicKey !== '' && publicKey.includes('signature')) { - const { key, signature: verificationProof } = JSON.parse(publicKey); - publicKey = key; - let signedData: string; - if (verificationProof.includes('eip712')) - signedData = 'Create Push Chat Profile \n' + generateHash(key); - else signedData = 'Create Push Profile \n' + generateHash(key); - if ( - await verifyProfileSignature( - verificationProof, - signedData, - isValidCAIP10NFTAddress(did) - ? pCAIP10ToWallet(JSON.parse(encryptedPrivateKey).owner) - : pCAIP10ToWallet(did) - ) - ) - return publicKey; - else throw new Error('Cannot Verify this publicKey Owner!!!'); + parsedPublicKey = JSON.parse(publicKey).key; + if (parsedPublicKey === undefined) { + throw new Error('Invalid Public Key'); + } + } catch (err) { + parsedPublicKey = publicKey; + } + + try { + if (publicKey && publicKey.length > 0 && verificationProof) { + const data = { + caip10, + did, + publicKey, + encryptedPrivateKey, + }; + + if (isValidCAIP10NFTAddress(did)) { + const keyToRemove = 'owner'; + const parsedEncryptedPrivateKey = JSON.parse(encryptedPrivateKey); + if (keyToRemove in parsedEncryptedPrivateKey) { + delete parsedEncryptedPrivateKey[keyToRemove]; + } + data.encryptedPrivateKey = JSON.stringify(parsedEncryptedPrivateKey); + } + + const signedData = generateHash(data); + + const isValidSig: boolean = await verifyProfileSignature( + verificationProof, + signedData, + isValidCAIP10NFTAddress(did) + ? pCAIP10ToWallet(JSON.parse(encryptedPrivateKey).owner) + : pCAIP10ToWallet(did) + ); + if (isValidSig) { + return parsedPublicKey; + } else { + throw new Error('Invalid Signature'); + } } - return publicKey; + return parsedPublicKey; } catch (err) { - console.warn('Cannot Verify this publicKey Owner!!!'); - return publicKey; + console.warn(`Cannot Verify keys for DID : ${did} !!!`); + return parsedPublicKey; } }; diff --git a/packages/restapi/src/lib/user/getUser.ts b/packages/restapi/src/lib/user/getUser.ts index fa5bf052d..6bf22e8f6 100644 --- a/packages/restapi/src/lib/user/getUser.ts +++ b/packages/restapi/src/lib/user/getUser.ts @@ -1,7 +1,7 @@ import axios from 'axios'; import { AccountEnvOptionsType, IUser } from '../types'; import { isValidETHAddress, walletToPCAIP10 } from '../helpers/address'; -import { getAPIBaseUrls, verifyPGPPublicKey } from '../helpers'; +import { getAPIBaseUrls, verifyProfileKeys } from '../helpers'; import Constants from '../constants'; import { populateDeprecatedUser } from '../utils/populateIUser'; @@ -17,10 +17,12 @@ export const get = async (options: AccountEnvOptionsType): Promise => { .get(requestUrl) .then(async (response) => { if (response.data) { - response.data.publicKey = await verifyPGPPublicKey( + response.data.publicKey = await verifyProfileKeys( response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did + response.data.did, + response.data.wallets, + response.data.verificationProof ); } return populateDeprecatedUser(response.data); diff --git a/packages/restapi/src/lib/user/getUsersBatch.ts b/packages/restapi/src/lib/user/getUsersBatch.ts index eebcda782..3a15699db 100644 --- a/packages/restapi/src/lib/user/getUsersBatch.ts +++ b/packages/restapi/src/lib/user/getUsersBatch.ts @@ -1,7 +1,7 @@ import axios from 'axios'; import { IUser } from '../types'; import { isValidETHAddress, walletToPCAIP10 } from '../helpers/address'; -import { getAPIBaseUrls, verifyPGPPublicKey } from '../helpers'; +import { getAPIBaseUrls, verifyProfileKeys } from '../helpers'; import Constants, { ENV } from '../constants'; import { populateDeprecatedUser } from '../utils/populateIUser'; @@ -36,10 +36,12 @@ export const getBatch = async (options: GetBatchType): Promise => { .post(requestUrl, requestBody) .then((response) => { response.data.users.forEach(async (user: any, index: number) => { - response.data.users[index].publicKey = await verifyPGPPublicKey( + response.data.users[index].publicKey = await verifyProfileKeys( user.encryptedPrivateKey, user.publicKey, - user.did + user.did, + user.caip10, + user.verificationProof ); response.data.users[index] = populateDeprecatedUser( diff --git a/packages/restapi/src/lib/user/profile.updateUser.ts b/packages/restapi/src/lib/user/profile.updateUser.ts index 175452e19..545a55098 100644 --- a/packages/restapi/src/lib/user/profile.updateUser.ts +++ b/packages/restapi/src/lib/user/profile.updateUser.ts @@ -5,7 +5,7 @@ import Constants, { ENV } from '../constants'; import { getAPIBaseUrls, isValidETHAddress, - verifyPGPPublicKey, + verifyProfileKeys, } from '../helpers'; import { IUser, ProgressHookType, ProgressHookTypeFunction } from '../types'; import { get } from './getUser'; @@ -99,10 +99,12 @@ export const profileUpdate = async ( progressHook?.(PROGRESSHOOK['PUSH-PROFILE-UPDATE-01'] as ProgressHookType); const response = await axios.put(apiEndpoint, body); if (response.data) - response.data.publicKey = await verifyPGPPublicKey( + response.data.publicKey = await verifyProfileKeys( response.data.encryptedPrivateKey, response.data.publicKey, - response.data.did + response.data.did, + response.data.wallets, + response.data.verificationProof ); // Report Progress diff --git a/packages/restapi/tests/lib/chat/updateGroup.test.ts b/packages/restapi/tests/lib/chat/updateGroup.test.ts index a9bfa7b60..c89b06a46 100644 --- a/packages/restapi/tests/lib/chat/updateGroup.test.ts +++ b/packages/restapi/tests/lib/chat/updateGroup.test.ts @@ -133,7 +133,7 @@ describe('Update Group', () => { const admins: string[] = []; const members = [ account2, - // 'eip155:0xDB0Bb1C25e36a5Ec9d199688bB01eADa4e70225E', + 'eip155:0xDB0Bb1C25e36a5Ec9d199688bB01eADa4e70225E', ]; // creator - account const group = await createGroup({ From a9d3b6319362f546ab363b0f4897abc736809415 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 16 Aug 2023 13:44:10 +0530 Subject: [PATCH 197/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.31?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 5a9ac534e..a0d799a82 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.31](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.30...restapi-0.0.1-alpha.31) (2023-08-16) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([a4c170e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a4c170edd7766c843412bd83f6ef7e5a9ab70247)) + + + ## [0.0.1-alpha.30](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.29...restapi-0.0.1-alpha.30) (2023-08-15) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index f24e59bc2..84c0fa941 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.30", + "version": "0.0.1-alpha.31", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 7c02c3adef593b59bde6c8dd4d23b760e99a5416 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 17 Aug 2023 01:09:18 +0530 Subject: [PATCH 198/298] fix: Read me fixes --- packages/restapi/README.md | 37 +++++++++++++++---------- packages/restapi/src/lib/types/index.ts | 2 +- 2 files changed, 24 insertions(+), 15 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 99027472e..ef12b4afe 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -3313,7 +3313,7 @@ const response = await PushAPI.chat.createGroup({ } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -3360,7 +3360,7 @@ Allowed Options (params with _ are mandatory) | numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | | contractAddressNFT (deprecated) | string | null | NFT Contract Address | | numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | -| rules | Rules | - | conditions for group and chatting access (see format below) | +| rules | Rules | - | conditions for group and chat access (see format below) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -3397,7 +3397,7 @@ export interface Rules { groupAccess?: { conditions: Array; }; - chattingAccess?: { + chatAccess?: { conditions: Array; }; } @@ -3405,7 +3405,7 @@ export interface Rules { ## Rules Object Description -The rules object consists of two main sections: `groupAccess` and `chattingAccess`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. +The rules object consists of two main sections: `groupAccess` and `chatAccess`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. ### Conditions @@ -3564,7 +3564,7 @@ GUILD conditions require both guild ID and role ID. } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -3671,7 +3671,7 @@ const response = await PushAPI.chat.updateGroup({ } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -3717,7 +3717,7 @@ Allowed Options (params with _ are mandatory) | numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | | contractAddressNFT (deprecated) | string | null | NFT Contract Address | | numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | -| rules | Rules | - | conditions for group and chatting access (see format below) | +| rules | Rules | - | conditions for group and chat access (see format below) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -3871,7 +3871,7 @@ Allowed Options (params with _ are mandatory) } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -4570,7 +4570,7 @@ const response = await PushAPI.space.create({ } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -4621,7 +4621,7 @@ Allowed Options (params with _ are mandatory) | numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | | contractAddressNFT (deprecated) | string | null | NFT Contract Address | | numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | -| rules | Rules | - | conditions for space and chatting access (see format above) | +| rules | Rules | - | conditions for space and chat access (see format above) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -4730,7 +4730,7 @@ Allowed Options (params with _ are mandatory) } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -4843,7 +4843,7 @@ const response = await PushAPI.space.update({ } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ @@ -4892,7 +4892,7 @@ Allowed Options (params with _ are mandatory) | numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the space | | contractAddressNFT (deprecated) | string | null | NFT Contract Address | | numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the space | -| rules | Rules | - | conditions for space and chatting access (see format above) | +| rules | Rules | - | conditions for space and chat access (see format above) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| @@ -5006,12 +5006,21 @@ Allowed Options (params with _ are mandatory) 'guildId': '13468', 'roleId': '19924' } + }, + { + 'type': 'PUSH', + 'category': 'ERC721', + 'subcategory': 'nft_owner', + 'data': { + 'address': 'eip155:5:0x42af3147f17239341477113484752D5D3dda997B', + 'amount': 1 + } } ] } ] }, - 'chattingAccess': { + 'chatAccess': { 'conditions': [ { 'all': [ diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 08831b13c..1ccc0c666 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -339,7 +339,7 @@ export interface Rules { groupAccess?: { conditions: Array; }; - chattingAccess?: { + chatAccess?: { conditions: Array; }; } From 2181074811549a0c70aea189bc82a1acf1944ba1 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 17 Aug 2023 06:04:35 +0530 Subject: [PATCH 199/298] fix: Space rules --- .../src/lib/chat/helpers/payloadHelper.ts | 16 +++++++++++++++- packages/restapi/src/lib/space/create.ts | 9 +++++++-- packages/restapi/src/lib/types/index.ts | 9 ++++++++- 3 files changed, 30 insertions(+), 4 deletions(-) diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index f99dbcecb..c29fffc24 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -1,5 +1,5 @@ import { isValidETHAddress, walletToPCAIP10 } from '../../helpers'; -import { IConnectedUser, GroupDTO, SpaceDTO, ChatStatus, Rules } from '../../types'; +import { IConnectedUser, GroupDTO, SpaceDTO, ChatStatus, Rules, SpaceRules } from '../../types'; import { getEncryptedRequest } from './crypto'; import { ENV, MessageType } from '../../constants'; import * as AES from './aes'; @@ -233,9 +233,23 @@ export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { scheduleEnd: groupDto.scheduleEnd, status: groupDto.status ?? null, }; + + if (groupDto.rules) { + spaceDto.rules = { + spaceAccess: groupDto.rules.groupAccess, + }; + } + return spaceDto; }; +export const convertSpaceRulesToRules = (spaceRules: SpaceRules): Rules => { + return { + groupAccess: spaceRules.spaceAccess, + chatAccess: undefined, + }; +} + export const updateGroupPayload = ( groupName: string, groupImage: string | null, diff --git a/packages/restapi/src/lib/space/create.ts b/packages/restapi/src/lib/space/create.ts index 3a76b5d22..c05f01011 100644 --- a/packages/restapi/src/lib/space/create.ts +++ b/packages/restapi/src/lib/space/create.ts @@ -1,6 +1,6 @@ import Constants from '../constants'; -import { EnvOptionsType, SignerType, SpaceDTO } from '../types'; -import { groupDtoToSpaceDto } from './../chat/helpers'; +import { EnvOptionsType, SignerType, SpaceDTO, SpaceRules } from '../types'; +import { convertSpaceRulesToRules, groupDtoToSpaceDto } from './../chat/helpers'; import { createGroup } from '../chat/createGroup'; export interface ChatCreateSpaceType extends EnvOptionsType { @@ -19,6 +19,7 @@ export interface ChatCreateSpaceType extends EnvOptionsType { meta?: string; scheduleAt: Date; scheduleEnd?: Date | null; + rules?: SpaceRules | null; } export async function create(options: ChatCreateSpaceType): Promise { @@ -39,8 +40,11 @@ export async function create(options: ChatCreateSpaceType): Promise { meta, scheduleAt, scheduleEnd, + rules, } = options || {}; + const groupRules = rules ? convertSpaceRulesToRules(rules) : null; + try { const group = await createGroup({ signer, @@ -60,6 +64,7 @@ export async function create(options: ChatCreateSpaceType): Promise { groupType: 'spaces', scheduleAt: scheduleAt, scheduleEnd: scheduleEnd, + rules: groupRules, }); return groupDtoToSpaceDto(group); diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 1ccc0c666..80ca96229 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -344,6 +344,13 @@ export interface Rules { }; } +export interface SpaceRules { + spaceAccess?: { + conditions: Array; + }; +} + + export interface GroupDTO { members: { wallet: string; @@ -403,7 +410,7 @@ export interface SpaceDTO { scheduleEnd?: Date | null; status: ChatStatus | null; inviteeDetails?: { [key: string]: SPACE_INVITE_ROLES }; - rules?: Rules | null; + rules?: SpaceRules | null; } export interface Peer { From 98fd9210e0e7136f5625e96adf7eb26be7294892 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 17 Aug 2023 06:36:43 +0530 Subject: [PATCH 200/298] Update README.md --- packages/restapi/README.md | 131 ++++++++++++++----------------------- 1 file changed, 50 insertions(+), 81 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index ef12b4afe..6f7935aa0 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -3302,6 +3302,15 @@ const response = await PushAPI.chat.createGroup({ 'decimals': 18 } }, + { + 'type': 'PUSH', + 'category': 'ERC721', + 'subcategory': 'nft_owner', + 'data': { + 'address': 'eip155:5:0x42af3147f17239341477113484752D5D3dda997B', + 'amount': 1 + } + }, { 'type': 'GUILD', 'data': { @@ -3373,7 +3382,6 @@ export enum ConditionType { export type Data = { address?: string; - comparison?: string; amount?: number; decimals?: number; guildId?: string; @@ -4545,7 +4553,7 @@ const response = await PushAPI.space.create({ spaceImage: <space image link> , speakers: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], rules: { - 'groupAccess': { + 'spaceAccess': { 'conditions': [ { 'any': [ @@ -4569,31 +4577,6 @@ const response = await PushAPI.space.create({ ] } ] - }, - 'chatAccess': { - 'conditions': [ - { - 'all': [ - { - 'type': 'PUSH', - 'category': 'ERC20', - 'subcategory': 'token_holder', - 'data': { - 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', - 'amount': 1000, - 'decimals': 18 - } - }, - { - 'type': 'GUILD', - 'data': { - 'guildId': '13468', - 'roleId': '19924' - } - } - ] - } - ] } }, isPublic: true, @@ -4621,10 +4604,46 @@ Allowed Options (params with _ are mandatory) | numberOfERC20 (deprecated) | int | 0 | Minimum number of tokens required to join the group | | contractAddressNFT (deprecated) | string | null | NFT Contract Address | | numberOfNFTTokens (deprecated) | int | 0 | Minimum number of nfts required to join the group | -| rules | Rules | - | conditions for space and chat access (see format above) | +| rules | Rules | - | conditions for space access (see format below) | | pgpPrivateKey | string | null | mandatory for users having pgp keys| | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + +## **Rules format** +```typescript +export enum ConditionType { + PUSH = 'PUSH', + GUILD = 'GUILD', +} + +export type Data = { + address?: string; + amount?: number; + decimals?: number; + guildId?: string; + roleId?: string; +}; + +export type ConditionBase = { + type: ConditionType; + category?: string; + subcategory?: string; + data: Data; + access?: boolean; +}; + +export type Condition = ConditionBase & { + any?: ConditionBase[]; + all?: ConditionBase[]; +}; + +export interface Rules { + spaceAccess?: { + conditions: Array; + }; +} +``` +
Expected response (create space) @@ -4705,7 +4724,7 @@ Allowed Options (params with _ are mandatory) scheduleEnd: '2023-07-15T15:48:00.000Z', status: 'PENDING', rules: { - 'groupAccess': { + 'spaceAccess': { 'conditions': [ { 'any': [ @@ -4729,33 +4748,8 @@ Allowed Options (params with _ are mandatory) ] } ] - }, - 'chatAccess': { - 'conditions': [ - { - 'all': [ - { - 'type': 'PUSH', - 'category': 'ERC20', - 'subcategory': 'token_holder', - 'data': { - 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', - 'amount': 1000, - 'decimals': 18 - } - }, - { - 'type': 'GUILD', - 'data': { - 'guildId': '13468', - 'roleId': '19924' - } - } - ] - } - ] } - }, + } } @@ -4986,7 +4980,7 @@ Allowed Options (params with _ are mandatory) scheduleEnd: '2023-07-15T15:48:00.000Z', status: 'PENDING', rules: { - 'groupAccess': { + 'spaceAccess': { 'conditions': [ { 'any': [ @@ -5019,31 +5013,6 @@ Allowed Options (params with _ are mandatory) ] } ] - }, - 'chatAccess': { - 'conditions': [ - { - 'all': [ - { - 'type': 'PUSH', - 'category': 'ERC20', - 'subcategory': 'token_holder', - 'data': { - 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', - 'amount': 1000, - 'decimals': 18 - } - }, - { - 'type': 'GUILD', - 'data': { - 'guildId': '13468', - 'roleId': '19924' - } - } - ] - } - ] } } } From b5919ebd895ae01ca0b7ea7e73238b7929e56db2 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 17 Aug 2023 06:54:09 +0530 Subject: [PATCH 201/298] Update README.md --- packages/restapi/README.md | 104 ++++++++++++++++++++++++++++++++++++- 1 file changed, 102 insertions(+), 2 deletions(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 6f7935aa0..46d511e72 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -58,6 +58,7 @@ This package gives access to Push Protocol (Push Nodes) APIs. Visit [Developer D - [To approve a chat request](#to-approve-a-chat-request) - [To create a group](#to-create-a-group) - [To create a token gated group](#to-create-a-token-gated-group) + - [To check user access of a token gated group](#to-check-user-access-of-a-token-gated-group) - [To update group details](#to-update-group-details) - [To update token gated group details](#to-update-token-gated-group-details) - [To get group details by group name](#to-get-group-details-by-group-name) @@ -3435,8 +3436,6 @@ PUSH conditions may relate to: GUILD conditions require both guild ID and role ID. - -
Expected response (create group) @@ -3607,6 +3606,107 @@ GUILD conditions require both guild ID and role ID. --- +### **To check user access of a token gated group** + +```typescript + +// actual api +const response = await PushAPI.chat.getGroupAccess({ + chatId:'8f7be0068a677df166c2e5b8a9030fe8a4341807150339e588853c0049df3106', + did: '0x9e60c47edF21fa5e5Af33347680B3971F2FfD464' + env: 'staging', +}); +``` + +Allowed Options (params with _ are mandatory) +| Param | Type | Default | Remarks | +|----------|---------|---------|--------------------------------------------| +| chatId | string | - | group address | +| did | string | - | user address | +| env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + + +
+ Expected response (group access) + +```typescript +// PushAPI_chat_getGroupAccess | Response - 200 OK +{ + 'groupAccess': true, + 'chatAccess': false, + 'rules': { + 'groupAccess': { + 'conditions': [ + { + 'any': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + }, + 'access': false + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + }, + 'access': true + }, + { + 'type': 'PUSH', + 'category': 'ERC721', + 'subcategory': 'nft_owner', + 'data': { + 'address': 'eip155:5:0x42af3147f17239341477113484752D5D3dda997B', + 'amount': 1 + }, + 'access': true + } + ] + } + ] + }, + 'chatAccess': { + 'conditions': [ + { + 'all': [ + { + 'type': 'PUSH', + 'category': 'ERC20', + 'subcategory': 'token_holder', + 'data': { + 'address': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + 'amount': 1000, + 'decimals': 18 + }, + 'access': false + }, + { + 'type': 'GUILD', + 'data': { + 'guildId': '13468', + 'roleId': '19924' + }, + 'access': true + } + ] + } + ] + } + } +} + +``` +
+ +--- + ### **To update group details** Note - updateGroup is an idompotent call From dd708cadfe0b7f78fcbdcb3a942b6d5274668a1a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 17 Aug 2023 06:57:02 +0530 Subject: [PATCH 202/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.32?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index a0d799a82..d0329d1d9 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.32](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.31...restapi-0.0.1-alpha.32) (2023-08-17) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([8dd925c](https://github.com/ethereum-push-notification-service/push-sdk/commit/8dd925cd5e0a134e07735b5a3ef7382f4b1909de)) +* Read me fixes ([7c02c3a](https://github.com/ethereum-push-notification-service/push-sdk/commit/7c02c3adef593b59bde6c8dd4d23b760e99a5416)) +* Space rules ([2181074](https://github.com/ethereum-push-notification-service/push-sdk/commit/2181074811549a0c70aea189bc82a1acf1944ba1)) + + + ## [0.0.1-alpha.31](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.30...restapi-0.0.1-alpha.31) (2023-08-16) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 84c0fa941..091754214 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.31", + "version": "0.0.1-alpha.32", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 66bce15964885cbb76a21539d450913504143236 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 18 Aug 2023 09:45:22 +0530 Subject: [PATCH 203/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.10?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 4d10e69cb..ca8aa7773 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.9...restapi-1.4.10) (2023-08-18) + + +### Bug Fixes + +* add meta ([#643](https://github.com/ethereum-push-notification-service/push-sdk/issues/643)) ([06689e7](https://github.com/ethereum-push-notification-service/push-sdk/commit/06689e75b58dc93981302b7a5feff28f8486cb85)) +* added decryptedPGPPrivateKey in the returned response for client ([#650](https://github.com/ethereum-push-notification-service/push-sdk/issues/650)) ([16646b4](https://github.com/ethereum-push-notification-service/push-sdk/commit/16646b4e2f6792c2fb30c5e544012244e5b5a6fe)) + + + ## [1.4.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.8...restapi-1.4.9) (2023-08-11) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 241e2296f..bf297c806 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.9", + "version": "1.4.10", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ed10f3f8f3f1d50dd9bd93944aa5a34ed2246816 Mon Sep 17 00:00:00 2001 From: Nilesh Gupta Date: Fri, 18 Aug 2023 15:34:49 +0530 Subject: [PATCH 204/298] Feat/chat components (#658) * feat: created architechture * fix: added context values (#594) * Chat dataprovider (#596) * feat: data provider for chat component * fix: replaced react.usestate to usestate * fix: added props as the initial state and changed state name * fix: reverted chat context changes and renamed values * fix: added test page for chat ui components (#597) * added chatbubble component (#602) * feat: added chatbubble component * fix: made the messageBubble's width to fit-content --------- Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> * fix: added theme * Group chat bubble (#604) * feat: moved test component to testui folder & replaced dummy data with sdk response * feat: added twitter card and address for group chat received msg * feat: made the messageaddress reusable, added account from context * fix: removed unnecessary div and unused props and console logs * feat: adding pfp in text bubbles * fix: replaced hook with function and added pfp to messagebubble * fix: fixed image alignment * fix: changed border-radius of msg bubble and changed function name * fix: fixed theme and decryptedPrivateKey name (#616) * fix: fixed theme and decryptedPrivateKey name * fix: fixed bug * fix: fixed theme reviews * Message list (#615) * fix: message list comp * fix: message list comp * fix: added pagination * fix: added pagination * fix: pagination * fix: create useChatData hook * fix: fixed minor bug * fix: socket issues fixed * fix: added theme in msgbubble (#620) * fix: added theme in msgbubble * fix: fixed import --------- Co-authored-by: Monalisha Mishra * fix: exported the theme (#623) * fix: exported the theme * fix: fixed issues --------- Co-authored-by: Monalisha Mishra * Typebar component (#631) * feat: added typebar UI * feat: added functions to typebar * fix: added icon * fix: fixed theme issues --------- Co-authored-by: Monalisha Mishra * feat: added connectbutton * fix: fixed connectbtn ui and remove disconnect and fixed error on disconnect * fix: fixed create account getting called twice * Profile Header Component (#636) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * Message container (#635) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * fix: updated svg to react component * fix: changed svg to tsx component * fix: fixed review changes (#646) * fix: fixed review changes * fix: resolved issues --------- Co-authored-by: Nilesh Gupta * Profile Header -> Chat Profile fixes (#647) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * fix: notifs * fix: correct theme colors * fix: renaming profileHeader * fix: qa fixes * fix: loader * refactor: resolved issues * fix: edit types --------- Co-authored-by: Nilesh Gupta * fix: resolved package not added issue * Fix: modal issue in group info && alert remove members (#653) * fix: modal * fix: update changes * refactor: resolved issue --------- Co-authored-by: Nilesh Gupta * fix: QA fixes (#654) --------- Co-authored-by: Monalisha Mishra Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Co-authored-by: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Co-authored-by: KlausMikhaelson Co-authored-by: Kolade --- .../src/app/ChatUITest/ChatProfile.tsx | 15 + .../src/app/ChatUITest/ChatUITest.tsx | 8 +- ...{MessageBubbles.tsx => ChatViewBubble.tsx} | 36 +- .../src/app/ChatUITest/ChatViewComponent.tsx | 30 + .../src/app/ChatUITest/ChatViewListTest.tsx | 39 ++ .../src/app/ChatUITest/MessageListTest.tsx | 50 -- .../sdk-frontend-react/src/app/app.tsx | 176 ++--- packages/restapi/CHANGELOG.md | 1 + packages/uiweb/CHANGELOG.md | 38 ++ packages/uiweb/package-lock.json | 17 +- packages/uiweb/package.json | 3 + .../chat/ChatProfile/AddWalletContent.tsx | 380 +++++++++++ .../chat/ChatProfile/ChatProfile.tsx | 241 +++++++ .../components/chat/ChatProfile/DropDown.tsx | 205 ++++++ .../chat/ChatProfile/GroupInfoModal.tsx | 635 ++++++++++++++++++ .../chat/ChatProfile/MemberListContainer.tsx | 191 ++++++ .../chat/ChatProfile/ProfileCard.tsx | 158 +++++ .../lib/components/chat/ChatProfile/index.tsx | 1 + .../ChatViewBubble.tsx} | 10 +- .../components/chat/ChatViewBubble/index.ts | 1 + .../ChatViewComponent/ChatViewComponent.tsx | 86 +++ .../chat/ChatViewComponent/index.ts | 1 + .../ChatViewList/ApproveRequestBubble.tsx | 119 ++++ .../chat/ChatViewList/ChatViewList.tsx | 351 ++++++++++ .../chat/ChatViewList/MessageEncryption.tsx | 55 ++ .../lib/components/chat/ChatViewList/index.ts | 1 + .../chat/ConnectButton/ConnectButton.tsx | 174 +++++ .../components/chat/ConnectButton/index.ts | 1 + .../components/chat/MessageBubble/index.ts | 1 - .../chat/MessageInput/MessageInput.tsx | 340 ++++++++++ .../lib/components/chat/MessageInput/index.ts | 1 + .../chat/MessageList/MessageList.tsx | 210 ------ .../lib/components/chat/MessageList/index.ts | 1 - .../src/lib/components/chat/exportedTypes.ts | 148 +++- .../src/lib/components/chat/helpers/Modal.tsx | 99 +++ .../lib/components/chat/helpers/NewToast.tsx | 228 +++++++ .../src/lib/components/chat/helpers/Toast.tsx | 190 ++++++ .../src/lib/components/chat/helpers/helper.ts | 106 ++- .../src/lib/components/chat/helpers/index.ts | 1 + .../components/chat/helpers/useMediaQuery.ts | 43 ++ .../uiweb/src/lib/components/chat/index.ts | 7 +- .../src/lib/components/chat/theme/index.ts | 85 ++- .../ChatAndNotification.tsx | 2 +- .../components/reusables/sharedStyling.tsx | 6 +- .../supportChat/spinner/Spinner.tsx | 5 +- packages/uiweb/src/lib/context/chatContext.ts | 2 +- .../lib/dataProviders/ChatDataProvider.tsx | 28 +- packages/uiweb/src/lib/helpers/address.ts | 32 +- packages/uiweb/src/lib/helpers/chat/chat.ts | 45 +- packages/uiweb/src/lib/helpers/chat/search.ts | 2 +- packages/uiweb/src/lib/helpers/chat/time.ts | 2 +- packages/uiweb/src/lib/hooks/chat/index.ts | 9 +- .../lib/hooks/chat/useApproveChatRequest.ts | 41 ++ .../src/lib/hooks/chat/useChatProfile.ts | 32 + .../uiweb/src/lib/hooks/chat/useFetchChat.ts | 46 ++ .../hooks/chat/useFetchConversationHash.ts | 38 ++ .../lib/hooks/chat/useFetchHistoryMessages.ts | 6 +- .../uiweb/src/lib/hooks/chat/useGetGroup.ts | 51 ++ .../src/lib/hooks/chat/useGetGroupByID.ts | 37 + .../src/lib/hooks/chat/usePushChatSocket.ts | 112 +-- .../src/lib/hooks/chat/usePushSendMessage.ts | 50 ++ .../chat/useFetchHistoryMessages.ts | 1 + .../useChatNotificationSocket.ts | 2 +- .../uiweb/src/lib/hooks/useGetChatProfile.ts | 7 +- packages/uiweb/src/lib/icons/Accept.svg | 3 - packages/uiweb/src/lib/icons/Adddark.tsx | 12 + packages/uiweb/src/lib/icons/Attachment.tsx | 10 +- packages/uiweb/src/lib/icons/BRBIcon.svg | 54 ++ .../uiweb/src/lib/icons/CaretDownGrey.tsx | 9 + packages/uiweb/src/lib/icons/CheckCircle.tsx | 6 +- packages/uiweb/src/lib/icons/Emoji.tsx | 20 +- packages/uiweb/src/lib/icons/Encryption.tsx | 8 +- packages/uiweb/src/lib/icons/Gif.tsx | 8 +- packages/uiweb/src/lib/icons/Lock.png | Bin 0 -> 819 bytes packages/uiweb/src/lib/icons/LockSlash.png | Bin 0 -> 1366 bytes packages/uiweb/src/lib/icons/MoreDark.tsx | 12 + packages/uiweb/src/lib/icons/MoreLight.tsx | 11 + packages/uiweb/src/lib/icons/NoEncryption.tsx | 8 +- packages/uiweb/src/lib/icons/Public-Chat.svg | 3 + packages/uiweb/src/lib/icons/SearchIcon.tsx | 10 + packages/uiweb/src/lib/icons/SendCompIcon.tsx | 13 + packages/uiweb/src/lib/icons/Tick.tsx | 15 + packages/uiweb/src/lib/icons/Token-Gated.svg | 3 + .../uiweb/src/lib/icons/VerticalEllipsis.svg | 3 + packages/uiweb/src/lib/icons/addadmin.svg | 3 + packages/uiweb/src/lib/icons/adddark.svg | 5 + packages/uiweb/src/lib/icons/addicon.svg | 4 + packages/uiweb/src/lib/icons/addlight.svg | 5 + packages/uiweb/src/lib/icons/close.svg | 4 + packages/uiweb/src/lib/icons/dismissadmin.svg | 5 + packages/uiweb/src/lib/icons/greyImage.png | Bin 0 -> 144 bytes packages/uiweb/src/lib/icons/info.svg | 5 + packages/uiweb/src/lib/icons/infodark.svg | 5 + packages/uiweb/src/lib/icons/more.svg | 5 + packages/uiweb/src/lib/icons/moredark.svg | 5 + packages/uiweb/src/lib/icons/remove.svg | 4 + packages/uiweb/src/lib/icons/search.svg | 4 + packages/uiweb/src/lib/icons/tick.svg | 3 + .../uiweb/src/lib/icons/videoCallIcon.svg | 3 + packages/uiweb/src/lib/types/index.ts | 18 + packages/uiweb/yarn.lock | 14 +- 101 files changed, 4852 insertions(+), 487 deletions(-) create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatProfile.tsx rename packages/examples/sdk-frontend-react/src/app/ChatUITest/{MessageBubbles.tsx => ChatViewBubble.tsx} (58%) create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx delete mode 100644 packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/DropDown.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/MemberListContainer.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/ProfileCard.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatProfile/index.tsx rename packages/uiweb/src/lib/components/chat/{MessageBubble/MessageBubble.tsx => ChatViewBubble/ChatViewBubble.tsx} (97%) create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewBubble/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewComponent/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ChatViewList/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx create mode 100644 packages/uiweb/src/lib/components/chat/ConnectButton/index.ts delete mode 100644 packages/uiweb/src/lib/components/chat/MessageBubble/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx create mode 100644 packages/uiweb/src/lib/components/chat/MessageInput/index.ts delete mode 100644 packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx delete mode 100644 packages/uiweb/src/lib/components/chat/MessageList/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/helpers/Modal.tsx create mode 100644 packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx create mode 100644 packages/uiweb/src/lib/components/chat/helpers/Toast.tsx create mode 100644 packages/uiweb/src/lib/components/chat/helpers/index.ts create mode 100644 packages/uiweb/src/lib/components/chat/helpers/useMediaQuery.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/useChatProfile.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/useFetchChat.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/useGetGroup.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/useGetGroupByID.ts create mode 100644 packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts delete mode 100644 packages/uiweb/src/lib/icons/Accept.svg create mode 100644 packages/uiweb/src/lib/icons/Adddark.tsx create mode 100644 packages/uiweb/src/lib/icons/BRBIcon.svg create mode 100644 packages/uiweb/src/lib/icons/CaretDownGrey.tsx create mode 100644 packages/uiweb/src/lib/icons/Lock.png create mode 100644 packages/uiweb/src/lib/icons/LockSlash.png create mode 100644 packages/uiweb/src/lib/icons/MoreDark.tsx create mode 100644 packages/uiweb/src/lib/icons/MoreLight.tsx create mode 100644 packages/uiweb/src/lib/icons/Public-Chat.svg create mode 100644 packages/uiweb/src/lib/icons/SearchIcon.tsx create mode 100644 packages/uiweb/src/lib/icons/SendCompIcon.tsx create mode 100644 packages/uiweb/src/lib/icons/Tick.tsx create mode 100644 packages/uiweb/src/lib/icons/Token-Gated.svg create mode 100644 packages/uiweb/src/lib/icons/VerticalEllipsis.svg create mode 100644 packages/uiweb/src/lib/icons/addadmin.svg create mode 100644 packages/uiweb/src/lib/icons/adddark.svg create mode 100644 packages/uiweb/src/lib/icons/addicon.svg create mode 100644 packages/uiweb/src/lib/icons/addlight.svg create mode 100644 packages/uiweb/src/lib/icons/close.svg create mode 100644 packages/uiweb/src/lib/icons/dismissadmin.svg create mode 100644 packages/uiweb/src/lib/icons/greyImage.png create mode 100644 packages/uiweb/src/lib/icons/info.svg create mode 100644 packages/uiweb/src/lib/icons/infodark.svg create mode 100644 packages/uiweb/src/lib/icons/more.svg create mode 100644 packages/uiweb/src/lib/icons/moredark.svg create mode 100644 packages/uiweb/src/lib/icons/remove.svg create mode 100644 packages/uiweb/src/lib/icons/search.svg create mode 100644 packages/uiweb/src/lib/icons/tick.svg create mode 100644 packages/uiweb/src/lib/icons/videoCallIcon.svg diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatProfile.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatProfile.tsx new file mode 100644 index 000000000..b889f7daf --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatProfile.tsx @@ -0,0 +1,15 @@ +import { ChatProfile } from "@pushprotocol/uiweb"; + +export const ChatProfileTest = () => { + + return ( +
+ +
+ ) +} diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx index 936f67a76..7dd92f1ff 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx @@ -26,11 +26,17 @@ const ChatUITest = () => {
+ + CHAT PROFILE + CHAT BUBBLE - MESSAGE LIST + CHAT VIEW LIST + + + CHAT VIEW COMPONENT
diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx similarity index 58% rename from packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx rename to packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx index d3f70a954..d9d184845 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageBubbles.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx @@ -1,16 +1,16 @@ -import { MessageBubble } from "@pushprotocol/uiweb"; +import { ChatViewBubble } from "@pushprotocol/uiweb"; import { useEffect, useContext, useState } from "react"; import { EnvContext, Web3Context } from "../context"; import * as PUSHAPI from "@pushprotocol/restapi" import { ENV } from "@pushprotocol/uiweb"; import { IMessagePayload } from "@pushprotocol/uiweb"; -export const MessageBubbles = () => { +export const ChatViewBubbles = () => { const { env } = useContext(EnvContext); const { library, account } = useContext(Web3Context) const [message, setMessage] = useState([]) - const [ conversationHash , setConversationHash] = useState(''); + const [conversationHash, setConversationHash] = useState(''); const librarySigner = library.getSigner() @@ -26,22 +26,22 @@ export const MessageBubbles = () => { const ConversationHash = await PUSHAPI.chat.conversationHash({ account: `eip155:${account}`, - conversationId: '24b029b8e07e60291bf9d8c0c48ff993fa1e0a99105459f7404c425c92e91bac', + conversationId: '831b1d93f36fa2fce6c3d8c7c41c53335c82ad13cbe05478579af235f10716dc', env: env }); setConversationHash(ConversationHash.threadHash); - if(ConversationHash?.threadHash){ - const chatHistory = await PUSHAPI.chat.history({ - threadhash: conversationHash, - account: account, - limit: 10, - toDecrypt: true, - pgpPrivateKey: pgpPrivateKey ? pgpPrivateKey : undefined, - env: env - }) - setMessage(chatHistory) - console.log(chatHistory) - } + if (ConversationHash?.threadHash) { + const chatHistory = await PUSHAPI.chat.history({ + threadhash: conversationHash, + account: account, + limit: 10, + toDecrypt: true, + pgpPrivateKey: pgpPrivateKey ? pgpPrivateKey : undefined, + env: env + }) + setMessage(chatHistory) + console.log(chatHistory) + } } useEffect(() => { @@ -49,9 +49,9 @@ export const MessageBubbles = () => { }, []) return ( -
+
{message.map((msg) => ( - + ))}
) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx new file mode 100644 index 000000000..bf1273fa6 --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -0,0 +1,30 @@ +import styled from 'styled-components'; + +import { Section } from '../components/StyledComponents'; + +import { ChatViewComponent } from '@pushprotocol/uiweb'; + + +const ChatViewComponentTest = () => { + + + + return ( +
+

Chat UI Test page

+ + {/* */} + + + + +
+ ); +}; + +export default ChatViewComponentTest; + + +const ChatViewComponentCard = styled(Section)` +height:60vh; +`; \ No newline at end of file diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx new file mode 100644 index 000000000..28eec588d --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx @@ -0,0 +1,39 @@ +import { useContext, useEffect, useState } from 'react'; +import styled from 'styled-components'; +import * as PUSHAPI from '@pushprotocol/restapi'; +import { Link } from 'react-router-dom'; +import { Section } from '../components/StyledComponents'; +import { ChatViewList } from '@pushprotocol/uiweb'; +import { EnvContext, Web3Context } from '../context'; +import { usePushChatSocket } from '@pushprotocol/uiweb'; +import { MessageInput } from '@pushprotocol/uiweb'; + +const ChatViewListTest = () => { + const { account, pgpPrivateKey } = useContext(Web3Context) + + const { env } = useContext(EnvContext); + + + usePushChatSocket(); + return ( +
+

Chat UI Test page

+ + {/* */} + + + + + + +
+ ); +}; + +export default ChatViewListTest; + + +const ChatViewListCard = styled(Section)` +height:40vh; +background:black; +`; \ No newline at end of file diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx deleted file mode 100644 index 27cf0844c..000000000 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/MessageListTest.tsx +++ /dev/null @@ -1,50 +0,0 @@ -import { useContext, useEffect, useState } from 'react'; -import styled from 'styled-components'; -import * as PUSHAPI from '@pushprotocol/restapi'; -import { Link } from 'react-router-dom'; -import { Section } from '../components/StyledComponents'; -import { MessageList } from '@pushprotocol/uiweb'; -import { EnvContext, Web3Context } from '../context'; -import { usePushChatSocket } from '@pushprotocol/uiweb'; - -const MessageListTest = () => { - const { account } = useContext(Web3Context) - - const { env } = useContext(EnvContext); - const [ conversationHash , setConversationHash] = useState(''); - - const fetchConversationHash = async() =>{ - const ConversationHash = await PUSHAPI.chat.conversationHash({ - account: `eip155:${account}`, - conversationId: '24b029b8e07e60291bf9d8c0c48ff993fa1e0a99105459f7404c425c92e91bac', - env: env - }); - setConversationHash(ConversationHash.threadHash); - } -console.log(conversationHash) - useEffect(()=>{ - fetchConversationHash(); - }) - - usePushChatSocket(); - return ( -
-

Chat UI Test page

- - {/* */} - - - - - - -
- ); -}; - -export default MessageListTest; - - -const MessageListCard = styled(Section)` -height:40vh; -`; \ No newline at end of file diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index 0acb0d4f5..a84f521dd 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -1,4 +1,4 @@ -import { useEffect, useMemo, useState } from 'react'; +import { useContext, useEffect, useMemo, useState } from 'react'; import styled from 'styled-components'; import { Route, Routes, Link } from 'react-router-dom'; import { useWeb3React } from '@web3-react/core'; @@ -74,10 +74,13 @@ import { ChatUIProvider, SpacesUI, SpacesUIProvider, + darkChatTheme, } from '@pushprotocol/uiweb'; import ChatUITest from './ChatUITest/ChatUITest'; -import MessageListTest from './ChatUITest/MessageListTest'; -import { MessageBubbles } from './ChatUITest/MessageBubbles'; +import { ChatProfileTest } from './ChatUITest/ChatProfile'; +import ChatViewListTest from './ChatUITest/ChatViewListTest'; +import { ChatViewBubbles } from './ChatUITest/ChatViewBubble'; +import ChatViewComponentTest from './ChatUITest/ChatViewComponent'; import { lightChatTheme } from '@pushprotocol/uiweb'; window.Buffer = window.Buffer || Buffer; @@ -209,8 +212,7 @@ const checkForWeb3Data = ({ export function App() { const { account, library, active, chainId } = useWeb3React(); - - const [env, setEnv] = useState(ENV.STAGING); + const [env, setEnv] = useState(ENV.PROD); const [isCAIP, setIsCAIP] = useState(false); const { SpaceWidgetComponent } = useSpaceComponents(); @@ -303,60 +305,60 @@ export function App() { - - - - - - NOTIFICATIONS - - - SECRET NOTIFICATION - - - CHANNELS - - - ALIAS - - - DELEGATIONS - - - PAYLOADS - - - SOCKET - - - EMBED - - - CHAT - - - CHAT UI - - - SPACE - - - SPACE UI - - - } - /> - } - /> - } - /> + + + + + + NOTIFICATIONS + + + SECRET NOTIFICATION + + + CHANNELS + + + ALIAS + + + DELEGATIONS + + + PAYLOADS + + + SOCKET + + + EMBED + + + CHAT + + + CHAT UI + + + SPACE + + + SPACE UI + + + } + /> + } + /> + } + /> } /> @@ -505,27 +507,35 @@ export function App() { /> - {/* spaces ui components routes */} - } /> - } /> - } /> - } - /> - } - /> + {/* spaces ui components routes */} + } /> + } /> + } /> + } + /> + } + /> - {/* chat ui components routes */} - } + {/* chat ui components routes */} + } /> - } + element={} + /> + } + /> + } /> {/* */} @@ -536,7 +546,17 @@ export function App() { - ) : null} + ) : + + + } /> + } + /> + + + } ); diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d1fc77947..31e752569 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,7 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.8...restapi-1.4.9) (2023-08-11) ## [0.0.1-alpha.29](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.28...restapi-0.0.1-alpha.29) (2023-08-02) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 59cb82a9b..4589c675c 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,11 +2,49 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.9...uiweb-1.1.10) (2023-08-10) + + + +## [1.1.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.8...uiweb-1.1.9) (2023-08-10) ## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-0.0.1-alpha.0) (2023-08-09) ### Bug Fixes +* hide few spaces features ([#622](https://github.com/ethereum-push-notification-service/push-sdk/issues/622)) ([0e2556c](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e2556c6bbe3438cd30851ffdd9764b027f42f6e)) +* Merge branch 'main' into deployment ([843cd01](https://github.com/ethereum-push-notification-service/push-sdk/commit/843cd0169a270bbab69922021edf312616de3802)) + + + +## [1.1.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.7...uiweb-1.1.8) (2023-08-04) + + +### Bug Fixes + +* merge main ([b9e4440](https://github.com/ethereum-push-notification-service/push-sdk/commit/b9e44408fa4c97720b12217486e8d13ef3caeb00)) + + + +## [1.1.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.6...uiweb-1.1.7) (2023-07-31) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([9755baf](https://github.com/ethereum-push-notification-service/push-sdk/commit/9755baf3d4bcd3ab3fd365fad9d8fb7623fda58f)) + + + +## [1.1.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.5...uiweb-1.1.6) (2023-07-28) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([e33017a](https://github.com/ethereum-push-notification-service/push-sdk/commit/e33017afb2d4e9361d5df47e0f7e726ecdffbc32)) + + + +## [1.1.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.4...uiweb-1.1.5) (2023-07-27) * add alpha support to UI web ([8ecf5d9](https://github.com/ethereum-push-notification-service/push-sdk/commit/8ecf5d92cc1b5c25562ba0d6d1ae1137877a5be7)) * fixed bugs ([#566](https://github.com/ethereum-push-notification-service/push-sdk/issues/566)) ([481d8fc](https://github.com/ethereum-push-notification-service/push-sdk/commit/481d8fcd7c40325654ba490640daabc38ee2f96e)) * fixed build issues ([#550](https://github.com/ethereum-push-notification-service/push-sdk/issues/550)) ([0ce6e18](https://github.com/ethereum-push-notification-service/push-sdk/commit/0ce6e18a82901478fe3157788c716e5224f14bdb)) diff --git a/packages/uiweb/package-lock.json b/packages/uiweb/package-lock.json index a204cad1a..898a92ce8 100644 --- a/packages/uiweb/package-lock.json +++ b/packages/uiweb/package-lock.json @@ -1,12 +1,12 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.4", + "version": "0.0.1-alpha.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@pushprotocol/uiweb", - "version": "1.1.4", + "version": "0.0.1-alpha.0", "dependencies": { "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", @@ -17,6 +17,7 @@ "gif-picker-react": "^1.1.0", "html-react-parser": "^1.4.13", "moment": "^2.29.4", + "react-toastify": "^9.1.3", "react-twitter-embed": "^4.0.4" }, "peerDependencies": { @@ -3380,6 +3381,18 @@ } } }, + "node_modules/react-toastify": { + "version": "9.1.3", + "resolved": "https://registry.npmjs.org/react-toastify/-/react-toastify-9.1.3.tgz", + "integrity": "sha512-fPfb8ghtn/XMxw3LkxQBk3IyagNpF/LIKjOBflbexr2AWxAH1MJgvnESwEwBn9liLFXgTKWgBSdZpw9m4OTHTg==", + "dependencies": { + "clsx": "^1.1.1" + }, + "peerDependencies": { + "react": ">=16", + "react-dom": ">=16" + } + }, "node_modules/react-twitter-embed": { "version": "4.0.4", "resolved": "https://registry.npmjs.org/react-twitter-embed/-/react-twitter-embed-4.0.4.tgz", diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 9e52107ad..7e3eea05b 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -8,12 +8,15 @@ "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", "@unstoppabledomains/resolution": "^8.5.0", + "@web3-react/injected-connector": "^6.0.7", "date-fns": "^2.28.0", "emoji-picker-react": "^4.4.9", "font-awesome": "^4.7.0", "gif-picker-react": "^1.1.0", "html-react-parser": "^1.4.13", "moment": "^2.29.4", + "react-icons": "^4.10.1", + "react-toastify": "^9.1.3", "react-twitter-embed": "^4.0.4" }, "peerDependencies": { diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx new file mode 100644 index 000000000..0ba4639b9 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx @@ -0,0 +1,380 @@ +import { useContext, useEffect, useState } from "react"; +import styled from "styled-components"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { useChatData } from "../../../hooks"; +import { displayDefaultUser, getAddress, walletToPCAIP10 } from "../../../helpers"; +import { IToast, ModalButtonProps, User } from "../exportedTypes"; +import * as PushAPI from '@pushprotocol/restapi'; +import { ethers } from "ethers"; +import { addWalletValidation } from "../helpers/helper"; +import ArrowGreyIcon from '../../../icons/CaretDownGrey.svg' +import ArrowLeftIcon from '../../../icons/ArrowLeft.svg'; +import CloseIcon from '../../../icons/close.svg'; +import { Spinner } from "../../supportChat/spinner/Spinner"; +import { MoreLightIcon } from '../../../icons/MoreLight'; +import { MoreDarkIcon } from '../../../icons/MoreDark'; +import { SearchIcon } from '../../../icons/SearchIcon'; +import { Section, Span, Image } from "../../reusables/sharedStyling"; +import { AddUserDarkIcon } from '../../../icons/Adddark'; +import { device } from "../../../config"; +import { MemberListContainer } from "./MemberListContainer"; +import useMediaQuery from "../helpers/useMediaQuery"; +import useToast from "../helpers/NewToast"; +import { MdCheckCircle, MdError } from "react-icons/md"; +import { Modal } from "../helpers/Modal"; + + + +export const AddWalletContent = ({ onSubmit, handlePrevious, onClose, memberList, handleMemberList, title, groupMembers, isLoading }: {onSubmit: ()=> void ,onClose: ()=> void, handlePrevious: ()=> void, memberList: any, handleMemberList: any, title: string, groupMembers: any, isLoading?: boolean }) => { + const theme = useContext(ThemeContext); + + const [searchedUser, setSearchedUser] = useState(''); + const [filteredUserData, setFilteredUserData] = useState(null); + const [isInValidAddress, setIsInvalidAddress] = useState(false); + const [isLoadingSearch, setIsLoadingSearch] = useState(false); + const { account, env } = useChatData(); + const isMobile = useMediaQuery(device.mobileL); + const groupInfoToast = useToast(); + + + useEffect(() => { + if (isInValidAddress) { + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Invalid Address', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } + }, [isInValidAddress]); + + const onChangeSearchBox = (e: any) => { + setSearchedUser(e.target.value); + }; + + const handleUserSearch = async (userSearchData: string): Promise => { + try{ + const caip10 = walletToPCAIP10(userSearchData); + let filteredData: User; + + if (userSearchData.length) { + filteredData = await PushAPI.user.get({ + account: caip10, + env: env + }); + + if (filteredData !== null) { + setFilteredUserData(filteredData); + } + // User is not in the protocol. Create new user + else { + if (ethers.utils.isAddress(userSearchData)) { + const displayUser = displayDefaultUser({ caip10 }); + setFilteredUserData(displayUser); + } else { + setIsInvalidAddress(true); + setFilteredUserData(null); + } + } + } else { + setFilteredUserData(null); + } + setIsLoadingSearch(false); + } + catch(error){ + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Unsuccessful search, Try again', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } + }; + + const handleSearch = async (e: any): Promise => { + setIsLoadingSearch(true); + setIsInvalidAddress(false); + e.preventDefault(); + if (!ethers.utils.isAddress(searchedUser)) { + let address: string; + try { + address = await getAddress(searchedUser, env) as string; + // if (!address) { + // address = await library.resolveName(searchedUser); + // } + // this ensures address are checksummed + address = ethers.utils.getAddress(address?.toLowerCase()); + if (address) { + handleUserSearch(address); + } else { + setIsInvalidAddress(true); + setFilteredUserData(null); + } + } catch (err) { + setIsInvalidAddress(true); + setFilteredUserData(null); + } finally { + setIsLoadingSearch(false); + } + } else { + handleUserSearch(searchedUser); + } + }; + + const clearInput = () => { + setSearchedUser(''); + setFilteredUserData(null); + setIsLoadingSearch(false); + }; + + const addMemberToList = (member: User) => { + let errorMessage = ''; + + errorMessage = addWalletValidation(member, memberList, groupMembers, account); + + if (errorMessage) { + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: errorMessage, + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } else { + handleMemberList((prev: any) => [...prev, { ...member, isAdmin: false }]); + } + + setFilteredUserData(''); + clearInput(); + }; + + const removeMemberFromList = (member: User) => { + const filteredMembers = memberList?.filter((user: any) => user.wallets !== member.wallets); + handleMemberList(filteredMembers); + }; + + return ( +
+
+ + handlePrevious()} cursor='pointer' /> + + Add Wallets + + onClose()} cursor='pointer' /> +
+ +
+ Add Wallets + + + {groupMembers + ? `0${memberList?.length + groupMembers?.length} / 09 Members` + : `0${memberList?.length} / 09 Members`} + +
+ +
+ + +
+ {searchedUser.length > 0 && ( + clearInput()} cursor='pointer' /> + )} + {searchedUser.length == 0 && !filteredUserData && +
+ +
+ } +
+
+
+ + {filteredUserData ? ( + + } + darkIcon={} + /> + + ) : isLoadingSearch ? ( +
+ +
+ ) : null} + + + {memberList?.map((member: any, index: any) => ( + } + darkIcon={} + /> + ))} + + +
+ onSubmit()} + isLoading={isLoading} + memberListCount={memberList?.length > 0} + theme={theme} + > + {!isLoading && groupMembers ? 'Add To Group' : ''} + {isLoading && } + +
+ +
+ ) +} + +const SearchBarContent = styled.form` + position: relative; + display: flex; + flex: 1; +`; + +const Input = styled.input` + box-sizing: border-box; + display: flex; + flex: 1; +// min-width: 445px; + height: 48px; + padding: 0px 50px 0px 16px; + margin: 10px 0px 0px; + border-radius: 99px; + border: 1px solid; + border-color: ${(props) => props.theme.modalSearchBarBorderColor}; + background: ${(props) => props.theme.modalSearchBarBackground}; + color: ${(props) => props.color || '#000'}; + &:focus { + outline: none; + background-image: linear-gradient( + ${(props) => props.theme.snapFocusBg}, + ${(props) => props.theme.snapFocusBg} + ), + linear-gradient( + to right, + rgba(182, 160, 245, 1), + rgba(244, 110, 246, 1), + rgba(255, 222, 211, 1), + rgba(255, 207, 197, 1) + ); + background-origin: border; + border: 1px solid transparent !important; + background-clip: padding-box, border-box; + } + &::placeholder { + color: #657795; + } + @media ${device.mobileL} { + min-width: 100%; + } +`; + +const MemberList = styled.div` + // justify-content: flex-start; + // padding: 0px 2px; + // margin: 0 0 34px 0; + flex: 1; + // background: red; + width: 100%; +`; + +const MultipleMemberList = styled.div` + // overflow-y: auto; + height: fit-content; + max-height: 216px; + padding: 0px 2px; + // overflow-x: hidden; + width: 100%; + + &::-webkit-scrollbar-track { + background-color: ${(props) => props.theme.scrollBg}; + } + + &::-webkit-scrollbar { + background-color: ${(props) => props.theme.scrollBg}; + width: 6px; + } + + @media (max-width: 768px) { + padding: 0px 0px 0px 0px; + max-height: 35vh; + + &::-webkit-scrollbar-track { + background-color: none; + border-radius: 9px; + } + + &::-webkit-scrollbar { + background-color: none; + width: 4px; + } + } + + &::-webkit-scrollbar-thumb { + border-radius: 10px; + background-image: -webkit-gradient( + linear, + left top, + left bottom, + color-stop(0.44, #cf1c84), + color-stop(0.72, #cf1c84), + color-stop(0.86, #cf1c84) + ); + } +`; + +const ModalConfirmButton = styled.button` + margin: 60px 0 0 0; + background: ${(props) => props.memberListCount ? '#CF1C84' : props.theme.groupButtonBackgroundColor}; + color: ${(props) => props.memberListCount ? '#fff' : props.theme.groupButtonTextColor}; + border: ${(props) => props.memberListCount ? 'none' : props.theme.modalConfirmButtonBorder}; + min-width: 50%; + box-sizing: border-box; + cursor: pointer; + border-radius: 15px; + padding: 16px; + font-size: 1.125rem; + font-weight: 500; + display: flex; + align-items: center; + justify-content: center; + box-shadow: none; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx new file mode 100644 index 000000000..4949a44b6 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx @@ -0,0 +1,241 @@ +// @typescript-eslint/no-non-null-asserted-optional-chain + +import { useContext, useEffect, useRef, useState } from "react"; +import { Image, Section, Span } from "../../reusables"; +import styled from "styled-components"; +import TokenGatedIcon from '../../../icons/Token-Gated.svg'; +import PublicChatIcon from '../../../icons/Public-Chat.svg'; +import VideoChatIcon from '../../../icons/VideoCallIcon.svg'; +import GreyImage from '../../../icons/greyImage.png'; +import InfoIcon from '../../../icons/infodark.svg'; +import VerticalEllipsisIcon from '../../../icons/VerticalEllipsis.svg'; +import type { IUser } from '@pushprotocol/restapi'; +import { useChatData, useClickAway, useDeviceWidthCheck } from "../../../hooks"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { IChatTheme } from "../theme"; +import { pCAIP10ToWallet, resolveEns, resolveNewEns, shortenText } from "../../../helpers"; +import useGetGroupByID from "../../../hooks/chat/useGetGroupByID"; +import useChatProfile from "../../../hooks/chat/useChatProfile"; +import { IGroup } from "../../../types"; +import { GroupInfoModal } from "./GroupInfoModal"; +import { isValidETHAddress } from "../helpers/helper"; +import { ethers } from "ethers"; +import { IChatProfile, IToast, OptionProps } from "../exportedTypes"; +import { InfuraAPIKey, allowedNetworks, device } from "../../../config"; +import Toast from "../helpers/Toast"; +import useMediaQuery from "../helpers/useMediaQuery"; +import { createBlockie } from "../../space/helpers/blockies"; +// import { NewToast } from "../helpers/NewToast"; +import { ToastContainer, toast } from 'react-toastify'; +import 'react-toastify/dist/ReactToastify.min.css'; + + + +const Options = ({ options, setOptions, isGroup, chatInfo, groupInfo, setGroupInfo,theme }: OptionProps) => { + const DropdownRef = useRef(null); + const [modal, setModal] = useState(false); + + useClickAway(DropdownRef, () => { + setOptions(false); + }); + + const ShowModal = () => { + setModal(true); + } + + if (groupInfo && isGroup){ + return ( +
+ + + {groupInfo?.isPublic && + ()} + + setOptions(true)}> + + + {options && + ( + + + + + Group Info + + + )} + + {modal && + ()} + +
+ ) + } else { + return null } + }; + + + + + +export const ChatProfile: React.FC = ({ chatId, style }: {chatId: string, style: "Info" | "Preview"}) => { + const theme = useContext(ThemeContext); + const { account, env } = useChatData(); + const { getGroupByID } = useGetGroupByID(); + const { fetchUserChatProfile } = useChatProfile(); + + const [isGroup, setIsGroup] = useState(false); + const [options, setOptions] = useState(false); + const [chatInfo, setChatInfo ] = useState(); + const [groupInfo, setGroupInfo ] = useState(); + const [ensName, setEnsName ] = useState(''); + const isMobile = useMediaQuery(device.tablet); + const l1ChainId = allowedNetworks[env].includes(1) ? 1 : 5; + const provider = new ethers.providers.InfuraProvider(l1ChainId, InfuraAPIKey); + + + + const fetchProfileData = async () => { + if(isValidETHAddress(chatId)){ + const ChatProfile = await fetchUserChatProfile({ profileId: chatId }); + setChatInfo(ChatProfile); + setGroupInfo(null); + setIsGroup(false); + } else { + const GroupProfile = await getGroupByID({ groupId : chatId}) + setGroupInfo(GroupProfile); + setChatInfo(null); + setIsGroup(true); + } + } + + const getName = async (chatId: string) => { + if(isValidETHAddress(chatId)){ + const result = await resolveNewEns(chatId, provider); + // if(result) + console.log(result); + setEnsName(result); + } + } + + + useEffect(()=> { + if(!chatId) return; + fetchProfileData(); + getName(chatId); + },[chatId, account, env]) + + if (chatId && style === 'Info') { + return ( + + {chatInfo || groupInfo ? ( + + ) : ()} + + + + {isGroup ? groupInfo?.groupName : ensName ? `${ensName} (${isMobile ? shortenText(chatInfo?.did?.split(':')[1] ?? '', 4, true) : chatId})`: chatInfo ? shortenText(chatInfo.did?.split(':')[1] ?? '', 6, true) : shortenText(chatId,6, true)} + + + + + + {/* {!isGroup && + + + + } */} + + + + + + ) + } else { + return null; + } +} + + +const Container = styled.div` + width: 100%; + background: ${(props) => props.theme.bgColorPrimary}; + border-radius: 32px; + display: flex; + flex-direction: row; + align-items: center; + padding: 6px; + box-sizing: border-box; + position: relative; +`; + +const ImageItem = styled.div` + position: relative; +`; + +const DummyImage = styled.div` + height: 48px; + width: 48px; + border-radius: 100%; + background: #ccc; +`; + +const DropDownBar = styled.div` + position: absolute; + top: 30px; + left: -130px; + display: block; + min-width: 140px; + color: rgb(101, 119, 149); + border: ${(props) => `1px solid ${props.theme.defaultBorder}`}; + background: ${(props) => props.theme.bgColorPrimary}; + z-index: 10; + border-radius: 16px; +`; + +const VideoChatSection = styled.div` + margin: 0 25px 0 auto; +`; + +const DropDownItem = styled(Span)` + display: flex; + flex-direction: row; + align-items: center; + gap: 8px; + padding: 10px 16px; + border-radius: 16px; + z-index: 3000000; + width: 100%; +`; + +const TextItem = styled(Span)` + white-space: nowrap; + overflow: hidden; +`; + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/DropDown.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/DropDown.tsx new file mode 100644 index 000000000..991c1e6c8 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/DropDown.tsx @@ -0,0 +1,205 @@ +// React + Web3 Essentials +import { useContext } from 'react'; + +// External Packages +import styled from 'styled-components'; +import { shortenText } from "../../../helpers"; + +// Internal Components +import { Image, Section, Span } from "../../reusables"; +import { ThemeContext } from "../theme/ThemeProvider"; + + +export type DropdownValueType = { + id: number|string, + value?: string, + title: string, + icon: string, + textColor?: string, + function: () => void, +} + +type DropdownProps = { + dropdownValues: any[]; + textColor?: string; + iconFilter?: string; + hoverBGColor?: string; +}; + + +// Create Dropdown +function Dropdown({ dropdownValues, textColor, iconFilter, hoverBGColor }: DropdownProps) { + const theme = useContext(ThemeContext); + + + const getTextColor = (dropdownValue:DropdownValueType) => { + return dropdownValue.textColor ? dropdownValue.textColor : textColor ? textColor : theme.snackbarBorderText; + } + + + const copyToClipboard = (address:string) => { + if (navigator && navigator.clipboard) { + navigator.clipboard.writeText(address); + } else { + const el = document.createElement('textarea'); + el.value = address; + document.body.appendChild(el); + el.select(); + document.execCommand('copy'); + document.body.removeChild(el); + } + }; + return ( + <> + {dropdownValues.map((dropdownValue) => + dropdownValue?.id === 'walletAddress' ? ( +
dropdownValue?.function()} + > + + {dropdownValue?.title} + + {shortenText(dropdownValue?.title,6)} + + + {dropdownValue?.invertedIcon && ( + icon { + copyToClipboard(dropdownValue?.value); + }} + /> + )} + {dropdownValue?.icon && ( + icon { + copyToClipboard(dropdownValue?.value); + }} + /> + )} +
+ ) : ( + dropdownValue?.function()}> + {dropdownValue?.invertedIcon && ( + icon + )} + {dropdownValue?.icon && ( + icon + )} + {!dropdownValue?.link && dropdownValue?.function && ( + + {dropdownValue.title} + + )} + {dropdownValue?.link && ( + + {dropdownValue.title} + + )} + + ) + )} + + ); +} + +// css styles +const SpanAddress = styled(Span)` + margin: 11px 22px 11px 2px; + font-weight: 400; + size: 14px; + text-transform: uppercase; + color: #fff; + spacing: 1px; + width: max-content; +`; + +const MobileAddress = styled(SpanAddress)` + @media (min-width: 993px) { + display: none; + } +`; + +const DesktopAddress = styled(SpanAddress)` + @media (max-width: 992px) { + display: none; + } +`; + +const DropdownItemContainer = styled(Section)<{hoverBGColor?: string}>` + width: 12.5rem; + justify-content: flex-start; + flex-wrap: nowrap; + margin: 1px 0; + padding: 2px 8px; + border-radius: 12px; + cursor: pointer; + text-align: left; + + &:hover { + background-color: ${(props) => props.hoverBGColor || 'none'}; + } +`; + + +const A = styled.a` + margin: 8px 10px; + font-weight: 400; + font-size: 16px; + width: max-content; + + background: ${(props) => props.color}; + z-index: 11; + &. hover { + background: transparent !important; + } +`; + +export default Dropdown; diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx new file mode 100644 index 000000000..c5a03ca8b --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx @@ -0,0 +1,635 @@ +import { useRef, useState } from "react"; +import styled from "styled-components"; +import { useChatData, useClickAway } from "../../../hooks"; +import { IGroup } from "../../../types"; +import { IChatTheme } from "../theme"; +import * as PushAPI from '@pushprotocol/restapi'; +import { IToast, ShadowedProps, UpdateGroupType } from "../exportedTypes"; +import { convertToWalletAddressList, getAdminList, getUpdatedAdminList, getUpdatedMemberList } from "../helpers/helper"; +import { DropdownValueType } from "./DropDown"; +import DismissAdmin from '../../../icons/dismissadmin.svg'; +import AddAdmin from '../../../icons/addadmin.svg'; +import Remove from '../../../icons/remove.svg'; +import { Section, Span, Image } from "../../reusables/sharedStyling"; +import CloseIcon from '../../../icons/close.svg'; +import { ProfileCard } from "./ProfileCard"; +import addIcon from '../../../icons/addicon.svg'; +import { pCAIP10ToWallet, shortenText } from "../../../helpers"; +import LockIcon from '../../../icons/Lock.png' +import LockSlashIcon from '../../../icons/LockSlash.png' +import { AddWalletContent } from './AddWalletContent' +import ArrowIcon from '../../../icons/CaretDown.svg' +import { Modal } from "../helpers/Modal"; +import { device } from "../../../config"; +import useMediaQuery from "../helpers/useMediaQuery"; +import useToast from "../helpers/NewToast"; +import { MdCheckCircle, MdError } from "react-icons/md"; + + + +const PendingMembers = ({ groupInfo, setShowPendingRequests, showPendingRequests, theme }: {groupInfo?: IGroup | null, setShowPendingRequests: React.Dispatch>, showPendingRequests: boolean, theme: IChatTheme }) => { + if(groupInfo){ + return ( + + setShowPendingRequests(!showPendingRequests)}> + Pending Requests + {groupInfo?.pendingMembers?.length} + + + {/* */} + + + {showPendingRequests && ( +
+ {groupInfo?.pendingMembers && groupInfo?.pendingMembers?.length > 0 && groupInfo?.pendingMembers.map((item) => ( + + + + + {shortenText(item?.wallet?.split(':')[1] ?? '', 6, true)} + + + + ))} +
+ )} +
+ ) + } else {return null } +} + +export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo }: { theme: IChatTheme, modal: boolean, setModal: React.Dispatch>, groupInfo: IGroup, setGroupInfo: React.Dispatch> }) => { + const { account, env, pgpPrivateKey } = useChatData(); + const [showAddMoreWalletModal, setShowAddMoreWalletModal] = useState(false); + const [showPendingRequests, setShowPendingRequests] = useState(false); + const [memberList, setMemberList] = useState([]); + const [isLoading, setIsLoading] = useState(false); + const [selectedMemberAddress, setSelectedMemberAddress] = useState(null); + + const handleClose = () => onClose(); + const dropdownRef = useRef(null); + useClickAway(dropdownRef, () => setSelectedMemberAddress(null)); + const groupInfoToast = useToast(); + + + const groupCreator = groupInfo?.groupCreator; + const membersExceptGroupCreator = groupInfo?.members?.filter((x) => x.wallet?.toLowerCase() !== groupCreator?.toLowerCase()); + const groupMembers = [...membersExceptGroupCreator, ...groupInfo.pendingMembers]; + + + const updateGroup = async (options:UpdateGroupType) => { + const { groupInfo, connectedUser,adminList,memberList } = options; + const updateResponse = await PushAPI.chat.updateGroup({ + chatId: groupInfo?.chatId, + groupName: groupInfo?.groupName, + groupDescription: groupInfo?.groupDescription ?? '', + groupImage: groupInfo?.groupImage, + members: memberList, + admins: adminList, + account: connectedUser?.wallets, + pgpPrivateKey: pgpPrivateKey, + env: env, + }); + let updatedCurrentChat = null; + if(typeof updateResponse !== 'string') + { + updatedCurrentChat = groupInfo; + updatedCurrentChat = updateResponse; + } + return {updateResponse,updatedCurrentChat}; + } + + const addMembers = async () => { + //Already Present Members and PendingMembers + const groupMemberList = convertToWalletAddressList([ + ...groupInfo.members, + ...groupInfo.pendingMembers, + ]); + + //Newly Added Members and alreadyPresent Members in the groupchat + const newMembersToAdd = memberList.map((member: any) => member.wallets); + const members = [...groupMemberList, ...newMembersToAdd]; + + //Admins wallet address from both members and pendingMembers + const adminList = getAdminList?.(groupInfo); + + + try { + setIsLoading(true); + const connectedUser = await PushAPI.user.get({ account: account as string, env }); + const { updateResponse, updatedCurrentChat } = await updateGroup({ + groupInfo, + connectedUser, + adminList, + memberList: members, + }); + + if (typeof updateResponse !== 'string') { + setSelectedMemberAddress(null); + setGroupInfo(updateResponse); + } else { + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: updateResponse, + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + setSelectedMemberAddress(null); + } + setIsLoading(false); + groupInfoToast.showMessageToast({ + toastTitle: 'Success', + toastMessage: 'Group Invitation sent', + toastType: 'SUCCESS', + getToastIcon: (size) => ( + + ), + }); + handleClose(); + } catch (error) { + setIsLoading(false); + console.log('Error', error); + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Please, try again', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } + }; + + + const makeGroupAdmin = async () => { + const groupMemberList = convertToWalletAddressList([ + ...groupInfo.members, + ...groupInfo.pendingMembers, + ]); + const newAdminList = getUpdatedAdminList(groupInfo, selectedMemberAddress, false); + try { + const connectedUser = await PushAPI.user.get({ account: account as string, env }); + const { updateResponse, updatedCurrentChat } = await updateGroup({ + groupInfo, + connectedUser, + adminList: newAdminList, + memberList: groupMemberList, + }); + if (typeof updateResponse !== 'string') { + setSelectedMemberAddress(null); + setGroupInfo(updateResponse); + + groupInfoToast.showMessageToast({ + toastTitle: 'Success', + toastMessage: 'Admin added successfully', + toastType: 'SUCCESS', + getToastIcon: (size) => ( + ), + }); + } else { + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: updateResponse, + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + setSelectedMemberAddress(null); + } + } catch (e) { + console.error('Error while adding admin', e); + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Error', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } + setSelectedMemberAddress(null); + }; + + const dismissGroupAdmin = async () => { + const groupMemberList = convertToWalletAddressList([ + ...groupInfo.members, + ...groupInfo.pendingMembers, + ]); + const newAdminList = getUpdatedAdminList(groupInfo, selectedMemberAddress, true); + try { + const connectedUser = await PushAPI.user.get({ account: account as string, env }); + const { updateResponse, updatedCurrentChat } = await updateGroup({ + groupInfo, + connectedUser, + adminList: newAdminList, + memberList: groupMemberList, + }); + if (typeof updateResponse !== 'string') { + setSelectedMemberAddress(null); + setGroupInfo(updateResponse); + + groupInfoToast.showMessageToast({ + toastTitle: 'Success', + toastMessage: 'Admin removed successfully', + toastType: 'SUCCESS', + getToastIcon: (size) => ( + ), + }); + + } else { + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: updateResponse, + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + setSelectedMemberAddress(null); + } + } catch (e) { + console.error('Error while dismissing admin', e); + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Please, try again', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } + setSelectedMemberAddress(null); + }; + + const removeMember = async () => { + const updatedMemberList = getUpdatedMemberList(groupInfo, selectedMemberAddress!); + const adminList = getUpdatedAdminList(groupInfo, selectedMemberAddress, true); + try { + const connectedUser = await PushAPI.user.get({ account: account as string, env }); + const { updateResponse, updatedCurrentChat } = await updateGroup({ + groupInfo, + connectedUser, + adminList, + memberList: updatedMemberList, + }); + + if (typeof updateResponse !== 'string') { + setSelectedMemberAddress(null); + setGroupInfo(updateResponse); + + groupInfoToast.showMessageToast({ + toastTitle: 'Success', + toastMessage: 'Removed Member successfully', + toastType: 'SUCCESS', + getToastIcon: (size) => ( + + ), + }); + } else { + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: updateResponse, + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + setSelectedMemberAddress(null); + } + } catch (error) { + console.error('Error in removing member', error); + groupInfoToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Please, try again', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }); + } + setSelectedMemberAddress(null); + }; + + // const messageUserDropdown: DropdownValueType = { + // id: 'message_user', + // title: 'Message user', + // icon: Message, + // function: () => messageUser(), + // }; + const removeAdminDropdown: DropdownValueType = { + id: 'dismiss_admin', + title: 'Dismiss as admin', + icon: DismissAdmin, + function: () => dismissGroupAdmin(), + }; + const addAdminDropdown: DropdownValueType = { + id: 'add_admin', + title: 'Make group admin', + icon: AddAdmin, + function: () => makeGroupAdmin(), + }; + const removeMemberDropdown: DropdownValueType = { + id: 'remove_member', + title: 'Remove', + icon: Remove, + function: () => removeMember(), + textColor: '#ED5858', + }; + + + + const isAccountOwnerAdmin = groupInfo?.members?.some( + (member) => pCAIP10ToWallet(member?.wallet)?.toLowerCase() === account?.toLowerCase() && member?.isAdmin + ); + + const handlePrevious = () => { + setShowAddMoreWalletModal(false); + }; + + const onClose = () => { + setModal(false); + } + + const isMobile = useMediaQuery(device.mobileL); + if(groupInfo){ + return( + + {!showAddMoreWalletModal && (
+
+ +
+ + Group Info + + onClose()} cursor='pointer' /> +
+ + + + +
+ {groupInfo?.groupName} + {groupInfo?.members?.length} Members +
+
+ + + Group Description + {groupInfo?.groupDescription} + + + + + +
+ {groupInfo?.isPublic ? 'Public' : 'Private'} + {groupInfo?.isPublic ? 'Chats are not encrypted' : 'Chats are encrypted'} +
+
+ + {isAccountOwnerAdmin && groupInfo?.members && groupInfo?.members?.length < 10 && ( + setShowAddMoreWalletModal(true)} + > + + + + Add more wallets + + )} + +
+ {groupInfo?.pendingMembers?.length > 0 && ( + + )} +
+ +
+ {groupInfo?.members && groupInfo?.members?.length > 0 && groupInfo?.members.map((item, index) => ( + + ))} +
+ +
)} + + + + {showAddMoreWalletModal && ( + + )} +
+ ) +} else { return null } + +} + +const ProfileDiv = styled.div<{minHeight?: number}>` + display: flex; + flex-direction: column; + justify-content: flex-start; + padding-right: 3px; + align-items: center; + min-width: 445px; + min-height: 72px; + max-height: 216px; + min-height: ${(props) => `${props.minHeight}px`}; + overflow-y: auto; + overflow-x: hidden; + &&::-webkit-scrollbar { + width: 4px; + } + &&::-webkit-scrollbar-thumb { + background: #cf1c84; + border-radius: 10px; + } + @media (max-width: 480px) { + min-width: 300px; + } +`; + +const GroupHeader = styled.div` + margin-top: 34px; + display: flex; + flex-direction: row; + width: 100%; + gap: 19px; +`; + +const GroupDescription = styled.div` + margin-top: 34px; + display: flex; + flex-direction: column; + width: 100%; + align-items: flex-start; + gap: 5px; +`; + + +const PublicEncrypted = styled.div` + margin-top: 20px; + display: flex; + flex-direction: row; + width: 100%; + gap: 19px; + align-items: center; + border: ${(props) => `1px solid ${props.theme.defaultBorder}`}; + border-radius: 16px; + padding: 16px; + box-sizing: border-box; +`; + +const GroupMembers = styled.div` + margin-top: 20px; + display: flex; + flex-direction: row; + width: 100%; + align-items: center; +`; + +const AdminItem = styled.div` + background: rgb(244, 220, 234); + color: rgb(213, 58, 148); + margin-left: auto; + font-size: 10px; + padding: 6px; + border-radius: 8px; +`; + +const AddWalletContainer = styled.div` + margin-top: 20px; + border: ${(props) => `1px solid ${props.theme.defaultBorder}`}; + border-radius: 16px; + width: 100%; + padding: 20px 16px; + box-sizing: border-box; + display: flex; + flex-direction: row; + justify-content: center; + cursor: pointer; + align-items: center; +`; + +const GroupPendingMembers = styled.div` + margin-top: 3px; + display: flex; + flex-direction: row; + width: 100%; + align-items: center; + background: ${(props) => props.theme.pendingCardBackground}; + padding: 10px 15px; + box-sizing: border-box; + + &:last-child { + border-radius: 0px 0px 16px 16px; + } +`; + + +const PendingRequestWrapper = styled.div` + width: 100%; + margin-top: 20px; + border: ${(props) => `1px solid ${props.theme.defaultBorder}`}; + border-radius: 16px; + padding: 0px 0px; + box-sizing: border-box; +`; + +const PendingSection = styled.div` + width: 100%; + display: flex; + flex-direction: row; + align-items: center; + flex: 1; + cursor: pointer; + padding: 15px 20px; + box-sizing: border-box; +`; + +const ArrowImage = styled(Image)` + margin-left: auto; + transform: ${(props) => props?.setPosition ? 'rotate(0)' : 'rotate(180deg)'}; +`; + + +const Badge = styled.div` + margin: 0 0 0 5px; + font-size: 13px; + background: rgb(207, 28, 132); + padding: 4px 8px; + border-radius: 7px; + color: white; + font-weight: 700; +`; diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/MemberListContainer.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/MemberListContainer.tsx new file mode 100644 index 000000000..c92529fef --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/MemberListContainer.tsx @@ -0,0 +1,191 @@ +import { useContext, useRef, useState } from "react"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { useClickAway } from "../../../hooks"; +import Dropdown, { DropdownValueType } from "./DropDown"; +import DismissAdmin from '../../../icons/dismissadmin.svg'; +import AddAdmin from '../../../icons/addadmin.svg'; +import Remove from '../../../icons/remove.svg'; +import styled from "styled-components"; +import { Section, Image, Span } from "../../reusables/sharedStyling"; +import { MemberListContainerType, WalletProfileContainerProps } from "../exportedTypes"; +import { findObject } from "../helpers/helper"; +import { device } from "../../../config"; +import { shortenText } from "../../../helpers"; + +export const MemberListContainer = ({ key, memberData, handleMembers, handleMemberList, lightIcon, darkIcon, memberList }: MemberListContainerType) => { + const theme = useContext(ThemeContext); + const [selectedWallet, setSelectedWallet] = useState(null); + const [dropdownHeight, setDropdownHeight] = useState(0); + const dropdownRef = useRef(null); + + + useClickAway(dropdownRef, () => setSelectedWallet(null)); + + const removeAdminDropdown: DropdownValueType = + { id: 'dismiss_admin', title: 'Dismiss as admin', icon: DismissAdmin, function: () => dismissGroupAdmin() } + + const addAdminDropdown: DropdownValueType = + { id: 'dismiss_admin', title: 'Make group admin', icon: AddAdmin, function: () => makeGroupAdmin() } + + const removeUserDropdown: DropdownValueType = + { id: 'remove_user', title: 'Remove', icon: Remove, function: () => removeUser() } + + const dismissGroupAdmin = () => { + const updatedMembers = memberList.map((member:any) => member?.wallets?.toLowerCase() == memberData?.wallets?.toLowerCase() ? ({ ...member, isAdmin: false }) : member) + handleMembers?.(updatedMembers) + setSelectedWallet(null) + } + + const makeGroupAdmin = () => { + const updatedMembers = memberList.map((member: any) => member?.wallets?.toLowerCase() == memberData?.wallets?.toLowerCase() ? ({ ...member, isAdmin: true }) : member) + handleMembers?.(updatedMembers) + setSelectedWallet(null) + } + + const removeUser = () => { + handleMemberList(memberData) + setSelectedWallet(null) + } + + + const handleHeight = (id: any) => { + const containerHeight = document.getElementById(id)?.getBoundingClientRect(); + setDropdownHeight(containerHeight?.top); + }; + + + return ( + + +
+ +
+ + {shortenText(memberData?.wallets?.split(':')[1], 8, true)} +
+ +
+ {memberData?.isAdmin && ( + + Admin + + )} +
{ + handleHeight(memberData?.wallets); + setSelectedWallet(null) + memberList + ? findObject(memberData, memberList, 'wallets') + ? setSelectedWallet(memberData?.wallets) + : handleMemberList(memberData) + : handleMemberList(memberData) + }} + > + {/* {theme === 'light' ? lightIcon : darkIcon} */} + {darkIcon} +
+
+ + {selectedWallet?.toLowerCase() == memberData?.wallets?.toLowerCase() && ( + 500 ? '30%' : "45%" }} ref={dropdownRef} theme={theme}> + + + )} + + + ) +} + + +const WalletProfileContainer = styled(Section)` + // position: relative; + // padding: 5px 16px; + // margin: 8px 0px; + // justify-content: space-between; + // // min-width: 450px; + // min-width: 100%; + // box-sizing: border-box; + // align-items: center; + // border-radius: 16px; + + // @media (max-width: 480px) { + // // min-width: 300px; + // } + + justify-content: space-between; + padding: 8px 16px; + border-radius: 16px; + position: relative; + box-sizing: border-box; + width: 100%; + // background-color: ${(props) => props.theme.snapFocusBg}; + max-height: 64px; + align-self: stretch; + display: flex; + height: auto; + z-index: auto; + flex: 1; + @media (max-width: 480px) { + max-width: 100%; + } + +`; + +const WalletProfile = styled(Section)` + justify-content: flex-start; +`; + +const DropdownContainer = styled.div` + // position: absolute; + // left: 48%; + // border-radius: 16px; + // padding: 14px 8px; + // background: ${(props) => props.theme.modalContentBackground}; + // border: 1px solid ${(props) => props.theme.modalBorderColor}; + // z-index: 400; + // @media ${device.mobileL} { + // left: 27%; + // } + // @media (min-width: 426px) and (max-width: 1150px) { + // left: 47%; + // } + position: absolute; + left: 48%; + top: 69%; + border-radius: 16px; + padding: 14px 8px; + z-index: 999999999999 !important; + display: flex; + flex-direction: column !important; + background: ${(props) => props.theme.modalContentBackground}; + border: 1px solid ${(props) => props.theme.modalBorderColor}; + + @media ${device.mobileL} { + left: 27%; + } + @media (min-width: 426px) and (max-width: 1150px) { + left: 48%; + } + @media (max-width: 480px){ + left: 25%; + } +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/ProfileCard.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/ProfileCard.tsx new file mode 100644 index 000000000..2ee09770f --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/ProfileCard.tsx @@ -0,0 +1,158 @@ +// React + Web3 Essentials +import React, { useContext ,useState } from 'react'; + +// External Packages +import styled from 'styled-components'; +import { ethers } from 'ethers'; + +// Internal Components +import { MoreLightIcon } from '../../../icons/MoreLight'; +import { MoreDarkIcon } from '../../../icons/MoreDark'; +import { shortenText } from "../../../helpers"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { useChatData, useClickAway} from "../../../hooks"; +import { Image, Section, Span } from "../../reusables"; +import Dropdown from './DropDown'; +import { pCAIP10ToWallet } from '../../../helpers'; +import { device } from "../../../config"; + + +type ProfileCardProps = { + key?: number | string, + member?: any, + dropdownValues?: any; + selectedMemberAddress?: any; + setSelectedMemberAddress?: any; + dropdownRef?: any; +} + +export const ProfileCard = ({ + key, + member, + dropdownValues, + selectedMemberAddress, + setSelectedMemberAddress, + dropdownRef, +}: ProfileCardProps) => { + const theme = useContext(ThemeContext); + const { account } = useChatData(); + + const [dropdownHeight, setDropdownHeight] = useState(0); + + const handleHeight = (id: any) => { + const containerHeight = document.getElementById(id)?.getBoundingClientRect(); + setDropdownHeight(containerHeight?.top); + }; + + return ( + +
+
+ +
+ + {shortenText(member?.wallet?.split(':')[1], 6, true)} + +
+
+ {member?.isAdmin && ( + + Admin + + )} + {pCAIP10ToWallet(member?.wallet)?.toLowerCase() !== account?.toLowerCase() && dropdownValues.length > 0 && ( +
{ + handleHeight(member.wallet); + setSelectedMemberAddress(member?.wallet) + }} + style={{ cursor: 'pointer' }} + > + {theme ? : } +
+ )} +
+ {selectedMemberAddress?.toLowerCase() == member?.wallet?.toLowerCase() && ( + 570 ? '30%' : '40%' }} + theme={theme} + ref={dropdownRef}> + + + )} +
+ ); +}; + +const ProfileCardItem = styled(Section)<{id: any, key: any, background: any}>` + justify-content: space-between; + padding: 8px 16px; + border-radius: 16px; + position: relative; + box-sizing: border-box; + width: 100%; + // background-color: ${(props) => props.theme.snapFocusBg}; + max-height: 64px; + align-self: stretch; + display: flex; + height: auto; + z-index: auto; + flex: 1; + @media (max-width: 480px) { + max-width: 100%; + } +`; + +const DropdownContainer = styled(Section)` + position: absolute; + left: 48%; + top: 69%; + border-radius: 16px; + padding: 14px 8px; + z-index: 999999999999 !important; + display: flex; + flex-direction: column !important; + background: ${(props) => props.theme.modalContentBackground}; + border: 1px solid ${(props) => props.theme.modalBorderColor}; + + @media ${device.mobileL} { + left: 27%; + } + @media (min-width: 426px) and (max-width: 1150px) { + left: 48%; + } + @media (max-width: 480px){ + left: 25%; + } +`; diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/index.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/index.tsx new file mode 100644 index 000000000..c84eff807 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/index.tsx @@ -0,0 +1 @@ +export { ChatProfile } from './ChatProfile' \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx similarity index 97% rename from packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx rename to packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx index 625957a10..9ad6ce257 100644 --- a/packages/uiweb/src/lib/components/chat/MessageBubble/MessageBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx @@ -273,8 +273,8 @@ const TwitterCard = ({ chat, tweetId, isGroup, position }: { chat: IMessagePaylo ) } -export const MessageBubble = ({ chat }: { chat: IMessagePayload }) => { - const { account } = useChatData(); +export const ChatViewBubble = ({ chat }: { chat: IMessagePayload }) => { + const { account, setAccount, pgpPrivateKey, setPgpPrivateKey, env, setEnv } = useChatData(); const position = pCAIP10ToWallet(chat.fromDID).toLowerCase() !== account?.toLowerCase() ? 0 : 1; const { tweetId, messageType }: TwitterFeedReturnType = checkTwitterUrl({ message: chat?.messageContent }); const [isGroup, setIsGroup] = useState(false); @@ -290,6 +290,12 @@ export const MessageBubble = ({ chat }: { chat: IMessagePayload }) => { } }, [chat.toDID, isGroup]) + // useEffect(() => { + // setAccount(""); + // setPgpPrivateKey(""); + // setEnv(env); + // }, [account, env, pgpPrivateKey]) + if (messageType === 'TwitterFeedLink') { chat.messageType = 'TwitterFeedLink'; } diff --git a/packages/uiweb/src/lib/components/chat/ChatViewBubble/index.ts b/packages/uiweb/src/lib/components/chat/ChatViewBubble/index.ts new file mode 100644 index 000000000..25dc326f2 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewBubble/index.ts @@ -0,0 +1 @@ +export { ChatViewBubble } from './ChatViewBubble'; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx new file mode 100644 index 000000000..846112317 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -0,0 +1,86 @@ +import React, { useContext} from 'react'; +import { IChatViewComponentProps } from '../exportedTypes'; + +import { Section, } from '../../reusables'; +import { ChatViewList } from '../ChatViewList'; +import { chatLimit } from '../../../config'; + +import { ThemeContext } from '../theme/ThemeProvider'; +import { useChatData } from '../../../hooks/chat/useChatData'; +import { MessageInput } from '../MessageInput'; +import { ChatProfile } from '../ChatProfile'; + + + +export const ChatViewComponent: React.FC = ( + options: IChatViewComponentProps +) => { + const { + chatId, + messageInput = true, + chatViewList = true, + chatProfile = true, + limit = chatLimit, + emoji = true, + file = true, + gif = true, + isConnected = true, + } = options || {}; + + const {env } = useChatData(); + + console.log(env); + + // const [conversationHash, setConversationHash] = useState(); + + const theme = useContext(ThemeContext); + + + + + + + + + + + return ( +
+ + {chatProfile && } +
+ + + {chatId && chatViewList && } + +
+ + {/* )} */} + + {messageInput && ( +
+ +
+ )} +
+ ); +}; + +//styles + diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/index.ts b/packages/uiweb/src/lib/components/chat/ChatViewComponent/index.ts new file mode 100644 index 000000000..25a649344 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/index.ts @@ -0,0 +1 @@ +export {ChatViewComponent} from './ChatViewComponent'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx new file mode 100644 index 000000000..afdc1724a --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx @@ -0,0 +1,119 @@ +import { IFeeds } from '@pushprotocol/restapi'; +import { ThemeContext } from '../theme/ThemeProvider'; +import { Dispatch, useContext } from 'react'; +import { Div, Section, Span, Spinner } from '../../reusables'; +import useApproveChatRequest from '../../../hooks/chat/useApproveChatRequest'; +import { useChatData } from '../../../hooks'; +import { TickSvg } from '../../../icons/Tick'; +import styled from 'styled-components'; +import { IChatTheme } from '../theme'; + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; +} +export interface IApproveRequestBubbleProps { + chatId: string; + chatFeed: IFeeds; + setChatFeed: Dispatch; +} + +export const ApproveRequestBubble = ({ + chatFeed, + chatId, + setChatFeed, +}: IApproveRequestBubbleProps) => { + const { account, pgpPrivateKey, env } = useChatData(); + + const ApproveRequestText = { + GROUP: `You were invited to the group ${chatFeed?.groupInformation?.groupName}. Please accept to continue messaging in this group.`, + W2W: ` Please accept to enable push chat from this wallet`, + }; + const theme = useContext(ThemeContext); + const { approveChatRequest, loading: approveLoading } = + useApproveChatRequest(); + + const handleApproveChatRequest = async () => { + try { + if (!pgpPrivateKey) { + return; + } + const response = await approveChatRequest({ + chatId, + }); + if (response) { + const updatedChatFeed = { ...(chatFeed as IFeeds) }; + updatedChatFeed.intent = response; + + setChatFeed(updatedChatFeed); + } + } catch (error_: Error | any) { + console.log(error_.message); + } + }; + return ( +
+ + {chatFeed?.groupInformation + ? ApproveRequestText.GROUP + : ApproveRequestText.W2W} + + + {/*
(!approveLoading ? handleApproveChatRequest() : null)} + > + {approveLoading ? : } +
*/} +
+ ); +}; + +//styles +const Button = styled.button` + border: none; + cursor: pointer; + border-radius: 8px; + background: ${(props) => props.theme.accentBgColor}; + border: none; + color: white; + width: 100%; + font-size: 16px; + font-weight: 600; + line-height: 24px; + max-height: 48px; + min-height: 48px; + padding: 0px 24px; + display: flex; + justify-content: center; + align-items: center; +`; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx new file mode 100644 index 000000000..220aef905 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -0,0 +1,351 @@ +import React, { useContext, useEffect, useRef, useState } from 'react'; +import { ChatDataContext } from '../../../context'; +import { IChatViewListProps } from '../exportedTypes'; +import { chatLimit } from '../../../config'; +import { IFeeds, IMessageIPFS } from '@pushprotocol/restapi'; +import useFetchHistoryMessages from '../../../hooks/chat/useFetchHistoryMessages'; +import styled from 'styled-components'; +import { Div, Section, Span, Spinner } from '../../reusables'; +import moment from 'moment'; +import { ChatViewBubble } from '../ChatViewBubble'; +import { + appendUniqueMessages, + checkIfIntent, + checkIfSameChat, + dateToFromNowDaily, + getDefaultFeedObject, + getNewChatUser, + pCAIP10ToWallet, +} from '../../../helpers'; +import { useChatData, usePushChatSocket } from '../../../hooks'; +import { Messagetype } from '../../../types'; +import { ThemeContext } from '../theme/ThemeProvider'; +import { IChatTheme } from '../theme'; +import useFetchConversationHash from '../../../hooks/chat/useFetchConversationHash'; + +import { EncryptionMessage } from './MessageEncryption'; +import useGetGroup from '../../../hooks/chat/useGetGroup'; +import useGetChatProfile from '../../../hooks/useGetChatProfile'; +import useFetchChat from '../../../hooks/chat/useFetchChat'; +import { ApproveRequestBubble } from './ApproveRequestBubble'; + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; +} +const ChatStatus = { + FIRST_CHAT: `This is your first conversation with recipient.\n Start the conversation by sending a message.`, + INVALID_CHAT: 'Invalid chatId', +}; + +export const ChatViewList: React.FC = ( + options: IChatViewListProps +) => { + const { chatId, limit = chatLimit } = options || {}; + const { pgpPrivateKey, account } = useChatData(); + const [chatFeed, setChatFeed] = useState({} as IFeeds); + const [chatStatusText, setChatStatusText] = useState(''); + const [messages, setMessages] = useState(); + const [ loading,setLoading] = useState(true); + const [conversationHash, setConversationHash] = useState(); + const { historyMessages, loading:messageLoading } = useFetchHistoryMessages(); + const listInnerRef = useRef(null); + const bottomRef = useRef(null); + const { fetchChat } = useFetchChat(); + const { fetchChatProfile } = useGetChatProfile(); + const { getGroup } = useGetGroup(); + + const { messagesSinceLastConnection, groupInformationSinceLastConnection } = + usePushChatSocket(); + const { fetchConversationHash } = useFetchConversationHash(); + const theme = useContext(ThemeContext); + const dates = new Set(); + const { env } = useChatData(); + + useEffect(() => { + setChatStatusText(''); + }, [chatId, account, env]); + + useEffect(() => { + setMessages(undefined); + setConversationHash(undefined); + }, [chatId, account, pgpPrivateKey, env]); + + useEffect(() => { + (async () => { + const chat = await fetchChat({ chatId }); + if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); + else { + let newChatFeed; + let group; + const result = await getNewChatUser({ + searchText: chatId, + fetchChatProfile, + env, + }); + if (result) { + newChatFeed = getDefaultFeedObject({ user: result }); + } else { + group = await getGroup({ searchText: chatId }); + if (group) { + newChatFeed = getDefaultFeedObject({ groupInformation: group }); + } + } + if (newChatFeed) { + if (!newChatFeed?.groupInformation) { + setChatStatusText(ChatStatus.FIRST_CHAT); + } + console.log(chatFeed) + setChatFeed(newChatFeed); + } else { + setChatStatusText(ChatStatus.INVALID_CHAT); + } + + } + setLoading(false); + })(); + }, [chatId, pgpPrivateKey, account, env]); + + useEffect(() => { + if (checkIfSameChat(messagesSinceLastConnection, account!, chatId)) { + if (!Object.keys(messages || {}).length) { + setMessages({ + messages: [messagesSinceLastConnection], + lastThreadHash: messagesSinceLastConnection.cid, + }); + setConversationHash(messagesSinceLastConnection.cid); + } else { + const newChatViewList = appendUniqueMessages( + messages as Messagetype, + [messagesSinceLastConnection], + false + ); + setMessages({ + messages: newChatViewList, + lastThreadHash: messages!.lastThreadHash, + }); + } + scrollToBottom(null); + } + }, [messagesSinceLastConnection]); + + useEffect(() => { + (async function () { + const hash = await fetchConversationHash({ conversationId: chatId }); + setConversationHash(hash?.threadHash); + })(); + }, [chatId, account, env, pgpPrivateKey]); + + useEffect(() => { + if (conversationHash) { + (async function () { + await getMessagesCall(); + })(); + } + }, [conversationHash, pgpPrivateKey, account, env]); + + useEffect(() => { + scrollToBottom(null); + }, [conversationHash]); + + useEffect(() => { + if ( + conversationHash && + Object.keys(messages || {}).length && + messages?.messages.length && + messages?.messages.length <= limit + ) { + scrollToBottom(null); + } + }, [messages]); + + useEffect(() => { + if ( + Object.keys(messagesSinceLastConnection || {}).length && + Object.keys(chatFeed || {}).length && + checkIfSameChat(messagesSinceLastConnection, account!, chatId) + ) { + const updatedChatFeed = chatFeed; + updatedChatFeed.msg = messagesSinceLastConnection; + + setChatStatusText(''); + setChatFeed(updatedChatFeed); + } + }, [messagesSinceLastConnection]); + + const scrollToBottom = (behavior?: string | null) => { + bottomRef?.current?.scrollIntoView( + !behavior ? true : { behavior: 'smooth' } + ); + }; + + useEffect(() => { + if (Object.keys(groupInformationSinceLastConnection || {}).length) { + if ( + chatFeed?.groupInformation?.chatId.toLowerCase() === + groupInformationSinceLastConnection.chatId.toLowerCase() + ) { + const updateChatFeed = chatFeed; + updateChatFeed.groupInformation = groupInformationSinceLastConnection; + setChatFeed(updateChatFeed); + } + } + }, [groupInformationSinceLastConnection]); + + const onScroll = async () => { + if (listInnerRef.current) { + const { scrollTop } = listInnerRef.current; + if (scrollTop === 0) { + const content = listInnerRef.current; + const curScrollPos = content.scrollTop; + const oldScroll = content.scrollHeight - content.clientHeight; + + await getMessagesCall(); + + const newScroll = content.scrollHeight - content.clientHeight; + content.scrollTop = curScrollPos + (newScroll - oldScroll); + } + } + }; + + const getMessagesCall = async () => { + let threadHash = null; + if (!messages) { + threadHash = conversationHash; + } else { + threadHash = messages?.lastThreadHash; + } + if (threadHash && account) { + const chatHistory = await historyMessages({ + limit: limit, + threadHash, + }); + if (chatHistory?.length) { + if (Object.keys(messages || {}) && messages?.messages.length) { + const newChatViewList = appendUniqueMessages( + messages, + chatHistory, + true + ); + setMessages({ + messages: newChatViewList, + lastThreadHash: chatHistory[0].link, + }); + } else { + setMessages({ + messages: chatHistory, + lastThreadHash: chatHistory[0].link, + }); + } + } + } + }; + + type RenderDataType = { + chat: IMessageIPFS; + dateNum: string; + }; + + const renderDate = ({ chat, dateNum }: RenderDataType) => { + const timestampDate = dateToFromNowDaily(chat.timestamp as number); + dates.add(dateNum); + return ( + + {timestampDate} + + ); + }; + return ( + onScroll()} + > + {loading ? : ''} + {!loading && + <> + {chatFeed && + (chatFeed.publicKey || + (chatFeed?.groupInformation && + !chatFeed?.groupInformation?.isPublic)) ? ( + + ) : ( + + )} + + {chatStatusText && ( +
+ + {chatStatusText} + +
+ )} + {messageLoading ? : ''} + + { + !messageLoading && + <> +
+ {messages?.messages && + messages?.messages?.map((chat: IMessageIPFS, index: number) => { + const dateNum = moment(chat.timestamp).format('L'); + const position = + pCAIP10ToWallet(chat.fromDID).toLowerCase() !== + account?.toLowerCase() + ? 0 + : 1; + return ( + <> + {dates.has(dateNum) ? null : renderDate({ chat, dateNum })} +
+ +
+ + ); + })} +
+
+ {chatFeed && checkIfIntent({ chat: chatFeed as IFeeds, account: account! }) && ( + + )} + + } + + } +
+ ); +}; + +//styles +const ChatViewListCard = styled(Section)` + &::-webkit-scrollbar-thumb { + background: ${(props) => props.theme.accentBgColor}; + border-radius: 10px; + } + + &::-webkit-scrollbar { + width: 5px; + } +`; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx new file mode 100644 index 000000000..d2519e6ed --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx @@ -0,0 +1,55 @@ +import styled from "styled-components"; +import { Div, Section, Span } from "../../reusables"; +import { useDeviceWidthCheck } from "../../../hooks"; +import { useContext } from "react"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { NoEncryptionIcon } from "../../../icons/NoEncryption"; +import { EncryptionIcon } from "../../../icons/Encryption"; + +const EncryptionMessageContent = { + ENCRYPTED: { + IconComponent: , + text: 'Messages are end-to-end encrypted. Only users in this chat can view or listen to them. Click to learn more.', + }, + NO_ENCRYPTED: { + IconComponent: , + text: `Messages are not encrypted`, + }, + }; + export const EncryptionMessage = ({ id }: { id: 'ENCRYPTED' | 'NO_ENCRYPTED' }) => { + console.log(id) + const theme = useContext(ThemeContext); + const isMobile = useDeviceWidthCheck(771); + return ( +
+ + {EncryptionMessageContent[id].IconComponent} + + + {EncryptionMessageContent[id].text} + + +
+ ); + }; + + //styles + const EncryptionMessageDiv = styled(Div)` + text-align: center; + svg { + vertical-align: middle; + } +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/index.ts b/packages/uiweb/src/lib/components/chat/ChatViewList/index.ts new file mode 100644 index 000000000..d91caff1c --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/index.ts @@ -0,0 +1 @@ +export {ChatViewList} from './ChatViewList'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx new file mode 100644 index 000000000..d196b00b7 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx @@ -0,0 +1,174 @@ +import React, { useContext, useEffect } from "react"; +import styled from "styled-components"; +import { InjectedConnector } from "@web3-react/injected-connector"; +import { useWeb3React } from "@web3-react/core"; +import { useChatData } from "../../../hooks"; +import * as PUSHAPI from "@pushprotocol/restapi" +import { Spinner } from "../../reusables"; +import { ThemeContext } from "../theme/ThemeProvider"; + +interface NwMappingType { + [key: number]: string; +} + + +const NETWORK_MAPPING: NwMappingType = { + 1: 'ETH_MAIN_NET', + 5: 'ETH_GOERLI', + 3: 'ETH_ROPSTEN', + 137: 'POLYGON_MAINNET', + 80001: 'POLYGON_MUMBAI', + 56: 'BSC_MAINNET', + 97: 'BSC_TESTNET', + 420: 'OPTIMISM_TESTNET', + 10: 'OPTIMISM_MAINNET', + 1442: 'POLYGON_ZK_EVM_TESTNET', + 1101: 'POLYGON_ZK_EVM_MAINNET', +}; + +const injected = new InjectedConnector({ + supportedChainIds: [1, 3, 4, 5, 42, 137, 80001, 56, 97, 10, 420, 1442, 1101], +}); + +const ConnectWrapper = styled.div` + display: flex; + align-items: center; + flex-direction: column; + margin: 20; + + & .account { + font-size: 1.2rem; + border: 1px solid green; + border-radius: 3px; + padding: 4px 7px; + font-weight: 500; + font-family: monospace; + } + + & .network { + margin: 5px 0; + } + `; + +const StyledButton = styled.button` + border: 0px; + outline: 0px; + padding: 24px 9px; + font-weight: 500; + margin: 10px; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 165px; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; + `; + +const Connect = styled(StyledButton)` + color: rgb(255, 255, 255); + background: #D53A94; + `; + +const Disconnect = styled(StyledButton)` +display: flex; +padding: 9px 24px; +justify-content: center; +align-items: center; +gap: 10px; +background: var(--general-use-creamy-pink, #D53A94); +color: var(--general-use-white, #ffffff); + `; + +export const ConnectButton = () => { + const { active, activate, library } = useWeb3React(); + const { pgpPrivateKey, account, env, setPgpPrivateKey } = useChatData(); + const theme = useContext(ThemeContext); + + useEffect(() => { + if (active && account && env && library) { + const librarySigner = library.getSigner(); + + const connectBtn = async () => { + const user = await PUSHAPI.user.get({ account: account, env: env }); + if (!user) { + await createProfile(); + } + if (user?.encryptedPrivateKey && !pgpPrivateKey) { + const decryptPgpKey = await PUSHAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account: account, + signer: librarySigner, + env: env, + }); + setPgpPrivateKey(decryptPgpKey); + } + }; + + connectBtn(); + } + }, [active, account, env, library]); + + const createProfile = async () => { + if (!account || !env || !library) return; + + const librarySigner = library.getSigner(); + + const user = await PUSHAPI.user.create({ + signer: librarySigner, + env: env, + }); + + const createdUser = await PUSHAPI.user.get({ + account: account, + env: env, + }); + + const pvtKey = await PUSHAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: createdUser.encryptedPrivateKey ? createdUser.encryptedPrivateKey : "", + signer: librarySigner, + env: env, + toUpgrade: true, + }); + + setPgpPrivateKey(pvtKey); + }; + + async function connect() { + try { + await activate(injected); + } catch (ex) { + console.log(ex); + } + } + + const connectWalletOnPageLoad = async () => { + if (!pgpPrivateKey && !account) { + try { + await activate(injected); + } catch (ex) { + console.log(ex); + } + } + }; + + useEffect(() => { + connectWalletOnPageLoad(); + }, [activate]); + + return ( + + {active ? ( + <> + + + + + ) : ( + Connect Wallet + )} + + ); +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.ts b/packages/uiweb/src/lib/components/chat/ConnectButton/index.ts new file mode 100644 index 000000000..d5457ba77 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.ts @@ -0,0 +1 @@ +export { ConnectButton } from './ConnectButton'; diff --git a/packages/uiweb/src/lib/components/chat/MessageBubble/index.ts b/packages/uiweb/src/lib/components/chat/MessageBubble/index.ts deleted file mode 100644 index fd86462dc..000000000 --- a/packages/uiweb/src/lib/components/chat/MessageBubble/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { MessageBubble } from './MessageBubble'; diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx new file mode 100644 index 000000000..a1305be48 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -0,0 +1,340 @@ +import { useChatData, useClickAway, useDeviceWidthCheck } from "../../../hooks"; +import type { FileMessageContent } from "../../../types"; +import type { ChatMainStateContextType } from "../../../context/chatAndNotification/chat/chatMainStateContext"; +import { ChangeEvent, useContext, useEffect, useRef, useState } from "react"; +import { GIFType, IChatTheme, MessageInputProps } from "../exportedTypes"; +import styled from "styled-components"; +import { PUBLIC_GOOGLE_TOKEN, device } from "../../../config"; +import { Section, Div, Span } from "../../reusables"; +import { EmojiIcon } from "../../../icons/Emoji"; +import EmojiPicker, { EmojiClickData } from "emoji-picker-react"; +import * as PUSHAPI from "@pushprotocol/restapi"; +import { GifIcon } from "../../../icons/Gif"; +import GifPicker from "gif-picker-react"; +import { AttachmentIcon } from "../../../icons/Attachment"; +import usePushSendMessage from "../../../hooks/chat/usePushSendMessage"; +import { SendCompIcon } from "../../../icons/SendCompIcon"; +import { Spinner } from "../../reusables"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { ConnectButton } from "../ConnectButton"; + + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; +} + +export const MessageInput: React.FC = ({ chatId, Emoji = true, GIF = true, File = true, isConnected = true }) => { + const [typedMessage, setTypedMessage] = useState(""); + const [showEmojis, setShowEmojis] = useState(false); + const [gifOpen, setGifOpen] = useState(false); + const [newChat, setNewChat] = useState(false); + const modalRef = useRef(null); + const fileUploadInputRef = useRef(null); + const [fileUploading, setFileUploading] = useState(false); + const onChangeTypedMessage = (val: string) => { + setTypedMessage(val.trim()); + }; + const theme = useContext(ThemeContext); + const isMobile = useDeviceWidthCheck(425); + const { sendMessage, loading } = usePushSendMessage(); + const { pgpPrivateKey, setPgpPrivateKey } = useChatData(); + + useClickAway(modalRef, () => { + setShowEmojis(false); + setGifOpen(false); + }); + const textAreaRef = useRef(null); + useEffect(() => { + if (textAreaRef?.current?.style) { + textAreaRef.current.style.height = 25 + 'px'; + const scrollHeight = textAreaRef.current?.scrollHeight; + textAreaRef.current.style.height = scrollHeight + 'px'; + } + }, [textAreaRef, typedMessage]) + + const addEmoji = (emojiData: EmojiClickData, event: MouseEvent): void => { + setTypedMessage(typedMessage + emojiData.emoji); + setShowEmojis(false); + } + + const handleUploadFile = () => { + if (fileUploadInputRef.current) { + fileUploadInputRef.current.click(); + } + } + + const uploadFile = async ( + e: ChangeEvent + ): Promise => { + if (!(e.target instanceof HTMLInputElement)) { + return; + } + if (!e.target.files) { + return; + } + if ( + e.target && + (e.target as HTMLInputElement).files && + ((e.target as HTMLInputElement).files as FileList).length + ) { + const file: File = e.target.files[0]; + if (file) { + try { + const TWO_MB = 1024 * 1024 * 2; + if (file.size > TWO_MB) { + console.log('Files larger than 2mb is now allowed'); + throw new Error('Files larger than 2mb is now allowed'); + } + setFileUploading(true); + const messageType = file.type.startsWith('image') ? 'Image' : 'File'; + const reader = new FileReader(); + let fileMessageContent: FileMessageContent; + reader.readAsDataURL(file); + reader.onloadend = async (e): Promise => { + fileMessageContent = { + content: e.target!.result as string, + name: file.name, + type: file.type, + size: file.size, + }; + + sendPushMessage(JSON.stringify(fileMessageContent), messageType); + }; + } catch (err) { + console.log(err); + } finally { + setFileUploading(false); + } + } + } + }; + + const sendPushMessage = async (content: string, type: string) => { + try { + await sendMessage({ + message: content, + chatId, + messageType: type as any, + }); + } catch (error) { + console.log(error); + } + } + + const sendTextMsg = async () => { + if (typedMessage.trim() !== '') { + await sendPushMessage(typedMessage as string, 'Text'); + setTypedMessage(''); + } + } + + // useEffect(() => { + // setPgpPrivateKey + // }, [pgpPrivateKey]) + + const sendGIF = async (emojiObject: GIFType) => { + sendPushMessage(emojiObject.url as string, 'GIF'); + setGifOpen(false); + } + + return ( + + {/* {isConnected && ( + + )} */} + + {!pgpPrivateKey && isConnected && ( + // align this button in right corner + +
+ + You need to connect your wallet to get started + + +
+ ) + } + {pgpPrivateKey && + <> +
+ {Emoji && +
setShowEmojis(!showEmojis)} + > + +
+ } + {showEmojis && ( +
+
+ )} + { + if (event.key === 'Enter' && !event.shiftKey) { + event.preventDefault(); + sendTextMsg(); + } + }} + placeholder="Type your message..." + onChange={(e) => onChangeTypedMessage(e.target.value)} + value={typedMessage} + ref={textAreaRef} + rows={1} + /> +
+ + {GIF && +
setGifOpen(!gifOpen)}> + +
+ } + {gifOpen && ( +
+ +
+ )} +
+ {!fileUploading && File && ( + <> +
setNewChat(true)} + > + +
+ uploadFile(e)} + /> + + )} +
+ {!(loading || fileUploading) && ( +
sendTextMsg()} + > + +
+ )} + + {(loading || fileUploading) && ( +
+ +
+ )} +
+ + } +
+
+ ) +} + +const Container = styled.div` + width: 100%; + overflow: hidden; +`; +const TypebarSection = styled(Section)` + gap: 10px; + @media ${device.mobileL} { + gap: 0px; + } +`; +const SendSection = styled(Section)` + gap: 11.5px; + @media ${device.mobileL} { + gap: 7.5px; + } +`; +const MultiLineInput = styled.textarea` + font-family: inherit; + font-weight: 400; + transform: translateY(3px); + font-size: 16px; + outline: none; + overflow-y: auto; + box-sizing: border-box; + background:${(props) => props.theme.bgColorPrimary}; + border: none; + color: ${(props) => props.theme.textColorSecondary}; + resize: none; + flex: 1; + padding-right: 5px; + align-self: end; + @media ${device.mobileL} { + font-size: 14px; + } + &&::-webkit-scrollbar { + width: 4px; + padding-right: 0px; + } + ::-webkit-scrollbar-thumb { + background: rgb(181 181 186); + border-radius: 10px; + height: 50px; + } + ::placeholder { + color: ${(props) => props.theme.textColorSecondary}; + transform: translateY(1px); + @media ${device.mobileL} { + font-size: 14px; + } + } + + min-height: 25px; + max-height: 80px; + word-break: break-word; +`; +const FileInput = styled.input` + display: none; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/index.ts b/packages/uiweb/src/lib/components/chat/MessageInput/index.ts new file mode 100644 index 000000000..b0ef7c589 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageInput/index.ts @@ -0,0 +1 @@ +export { MessageInput } from './MessageInput'; diff --git a/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx b/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx deleted file mode 100644 index d85ba01da..000000000 --- a/packages/uiweb/src/lib/components/chat/MessageList/MessageList.tsx +++ /dev/null @@ -1,210 +0,0 @@ -import React, { useContext, useEffect, useRef, useState } from 'react'; -import { ChatDataContext } from '../../../context'; -import { IMessageListProps } from '../exportedTypes'; -import { chatLimit } from '../../../config'; -import { IMessageIPFS } from '@pushprotocol/restapi'; -import useFetchHistoryMessages from '../../../hooks/chat/useFetchHistoryMessages'; -import styled from 'styled-components'; -import { Section, Span, Spinner } from '../../reusables'; -import moment from 'moment'; -import { MessageBubble } from '../MessageBubble'; -import { appendUniqueMessages, dateToFromNowDaily, pCAIP10ToWallet } from '../../../helpers'; -import { useChatData, usePushChatSocket } from '../../../hooks'; -import { Messagetype } from '../../../types'; -import { ThemeContext } from '../theme/ThemeProvider'; -import { IChatTheme } from '../theme'; - - - -/** - * @interface IThemeProps - * this interface is used for defining the props for styled components - */ -interface IThemeProps { - theme?: IChatTheme; - - } - -export const MessageList: React.FC = ( - options: IMessageListProps -) => { - const { conversationHash, limit = chatLimit } = options || {}; - const { pgpPrivateKey, account } = useChatData(); - const [messages, setMessages] = useState(); - const { historyMessages, loading } = useFetchHistoryMessages(); - const listInnerRef = useRef(null); - const bottomRef = useRef(null); - const { messagesSinceLastConnection } = usePushChatSocket(); - const theme = useContext(ThemeContext); - const dates = new Set(); - - useEffect(() => { - if ( - Object.keys(messagesSinceLastConnection || {}).length - ) { - if (!Object.keys(messages || {}).length) { - setMessages({ - messages: messagesSinceLastConnection, - lastThreadHash: messagesSinceLastConnection.lastThreadHash, - }); - } else { - const newMessageList = appendUniqueMessages(messages as Messagetype,[messagesSinceLastConnection],false); - setMessages( { - - messages: newMessageList, - lastThreadHash: messages!.lastThreadHash, - - }); - } - scrollToBottom(null); - } - }, [messagesSinceLastConnection]); - - useEffect(() => { - if (conversationHash) { - (async function () { - await getMessagesCall(); - })(); - } - }, [conversationHash, pgpPrivateKey, account]); - - useEffect(() => { - scrollToBottom(null); - }, [conversationHash]); - - useEffect(() => { - if ( - conversationHash && - Object.keys(messages || {}).length && - messages?.messages.length && - messages?.messages.length <= limit - ) { - scrollToBottom(null); - } - }, [messages]); - - const scrollToBottom = (behavior?: string | null) => { - bottomRef?.current?.scrollIntoView( - !behavior ? true : { behavior: 'smooth' } - ); - }; - - const onScroll = async () => { - if (listInnerRef.current) { - const { scrollTop } = listInnerRef.current; - if (scrollTop === 0) { - const content = listInnerRef.current; - const curScrollPos = content.scrollTop; - const oldScroll = content.scrollHeight - content.clientHeight; - - await getMessagesCall(); - - const newScroll = content.scrollHeight - content.clientHeight; - content.scrollTop = curScrollPos + (newScroll - oldScroll); - } - } - }; - - const getMessagesCall = async () => { - let threadHash = null; - if (!messages) { - threadHash = conversationHash; - } else { - threadHash = messages?.lastThreadHash; - } - if (threadHash) { - const chatHistory = await historyMessages({ - limit: limit, - threadHash, - }); - if (chatHistory?.length) { - if (Object.keys(messages || {}) && messages?.messages.length) { - const newMessageList = appendUniqueMessages(messages,chatHistory,true); - setMessages({ - messages: newMessageList, - lastThreadHash: chatHistory[0].link, - }); - } else { - setMessages({ - messages: chatHistory, - lastThreadHash: chatHistory[0].link, - }); - } - } - } - }; - - - type RenderDataType = { - chat: IMessageIPFS; - dateNum: string; - }; - - const renderDate = ({ chat, dateNum }: RenderDataType) => { - const timestampDate = dateToFromNowDaily(chat.timestamp as number); - dates.add(dateNum); - return ( - - {timestampDate} - - ); - }; - return ( - onScroll()} - > - {loading ? : ''} - -
- {messages?.messages.map((chat: IMessageIPFS, index: number) => { - const dateNum = moment(chat.timestamp).format('L'); - const position = - pCAIP10ToWallet(chat.fromDID).toLowerCase() !== - account?.toLowerCase() - ? 0 - : 1; - return ( - <> - {dates.has(dateNum) ? null : renderDate({ chat, dateNum })} -
- -
- - ); - })} -
-
-
- ); -}; - -//styles -const MessageListCard = styled(Section)` -&::-webkit-scrollbar-thumb { - background: ${(props) => props.theme.accentBgColor}; - border-radius: 10px; - } - - &::-webkit-scrollbar { - width: 5px; - } - -`; diff --git a/packages/uiweb/src/lib/components/chat/MessageList/index.ts b/packages/uiweb/src/lib/components/chat/MessageList/index.ts deleted file mode 100644 index 80a558955..000000000 --- a/packages/uiweb/src/lib/components/chat/MessageList/index.ts +++ /dev/null @@ -1 +0,0 @@ -export {MessageList} from './MessageList'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/exportedTypes.ts b/packages/uiweb/src/lib/components/chat/exportedTypes.ts index a0a0dbcf1..4da3d5691 100644 --- a/packages/uiweb/src/lib/components/chat/exportedTypes.ts +++ b/packages/uiweb/src/lib/components/chat/exportedTypes.ts @@ -1,22 +1,152 @@ -import type { IMessageIPFS } from '@pushprotocol/restapi'; +import type { IMessageIPFS } from '@pushprotocol/restapi'; +import { IChatTheme } from "./theme"; +import { IGroup } from '../../types' -export interface IMessageListProps { - conversationHash: string; - limit?: number; - } +export interface IChatViewListProps { + chatId: string; + limit?: number; +} + +export interface IChatViewComponentProps { + messageInput?: boolean; + chatViewList?: boolean; + chatProfile?: boolean; //name needs to change + chatId: string; //need confirmation on this + limit?: number; + emoji?: boolean; + gif?: boolean; + file?: boolean; + isConnected?: boolean; +} + +export interface IChatProfile { + chatId: string; + style: "Info" | "Preview"; +} export interface TwitterFeedReturnType { - tweetId: string; - messageType: string; + tweetId: string; + messageType: string; +} + +export interface IToast { + message: string; + status: string; } +export type OptionProps = { + options: boolean; + setOptions: React.Dispatch>; + isGroup: boolean; + chatInfo: any; + groupInfo: IGroup | null | undefined , + setGroupInfo: React.Dispatch>; + theme: IChatTheme; +} export type IMessagePayload = IMessageIPFS; export const CHAT_THEME_OPTIONS = { LIGHT: 'light', DARK: 'dark', - } as const; -export type ChatThemeOptions = (typeof CHAT_THEME_OPTIONS)[keyof typeof CHAT_THEME_OPTIONS]; +export type GIFType = { + url: string; + width: number; + height: number; +}; + +export interface MessageInputProps { + chatId: string; + Emoji?: boolean; + GIF?: boolean; + File?: boolean; + Image?: boolean; + isConnected?: boolean; +} + +export type UpdateGroupType = { + groupInfo: IGroup, + connectedUser: User, + adminList: Array, + memberList: Array, +} + +export type MemberListContainerType = { + key?: number; + memberData: User; + handleMemberList: (member: User) => void; + handleMembers?: (value: User[]) => void; + lightIcon: any; + darkIcon: any; + memberList?: any; +}; + +export interface WalletProfileContainerProps { + id?: any; + background?: any; + border?: any; + +}; + +export interface MessageIPFS { + fromCAIP10: string + toCAIP10: string + fromDID: string + toDID: string + messageType: string + messageContent: string + signature: string + sigType: string + link: string | null + timestamp?: number + encType: string + encryptedSecret: string +} + +export interface Feeds { + chatId?: string; + msg: MessageIPFS; + did: string; + wallets: string; + profilePicture: string | null; + publicKey: string | null; + about: string | null; + threadhash: string | null; + intent: string | null; + intentSentBy: string | null; + intentTimestamp: Date; + combinedDID: string; + cid?: string; + groupInformation?: IGroup +} + +export interface User { + did: string; + wallets: string; + profilePicture: string | null; + publicKey: string; + encryptedPrivateKey: string; + encryptionType: string; + signature: string; + sigType: string; + about: string | null; + name: string | null; + numMsg: number; + allowedNumMsg: number; + linkedListHash?: string | null; + isAdmin?:boolean; +} + +export interface ShadowedProps { + setPosition: boolean; +}; + +export interface ModalButtonProps { + memberListCount?: boolean; + theme?: IChatTheme; + isLoading?: boolean; +}; + + export {IChatTheme} from './theme'; diff --git a/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx b/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx new file mode 100644 index 000000000..c7cbef9b4 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx @@ -0,0 +1,99 @@ +/** + * @file Modal + * generic modal component for spaces UI + * does not handle any business logic, acts only as a container + */ +import { useRef, useContext } from 'react'; +import styled from 'styled-components' +import { ThemeContext } from '../theme/ThemeProvider'; +import { useClickAway } from '../../../hooks'; + +// import { ThemeContext } from '../theme/ThemeProvider'; + +// import { useClickAway } from '../../../hooks'; + +interface IModalProps { + width?: string; + clickawayClose?: () => void; + children: any; +} + +const ClickawayCloseModal = ({ children, clickawayClose, width }: IModalProps) => { + const modalRef = useRef(null); + const theme = useContext(ThemeContext) + + useClickAway(modalRef, () => { + if (clickawayClose) { + clickawayClose(); + } + }); + + return ( + + {children} + + ); +}; + +export const Modal = ({ clickawayClose, children, width }: IModalProps) => { + const theme = useContext(ThemeContext) + return ( + + {clickawayClose ? ( + {children} + ) : ( + + { children } + + )} + + ); +}; + +/* styling */ + +const ModalOverlay = styled.div` + position: fixed; + top: 0; + left: 0; + right: 0; + bottom: 0; + width: 100%; + height: 100%; + background-color: rgba(0, 0, 0, 0.4); /* Black with 40% opacity */ + display: flex; + color: ${props => props.theme.textColorPrimary ?? '#000'}; + justify-content: center; + align-items: center; + z-index: 2000; + + max-height: 100vh; + overflow-y: auto; + margin: auto !important; +`; + +const ModalParent = styled.div` + // position: absolute; + // top: 50%; + // left: 50%; + // transform: translate(-50%, -50%); + + display: flex; + flex-direction: column; + align-items: center; + padding: 24px 20px; + + background: ${(props => props.theme.bgColorPrimary)}; + border-radius: 12px; + + width: ${(props => props.width ? props.width : 'auto')}; + margin: auto !important; + + @media (max-width: 425px) { + min-width: 300px; + max-width: 300px; + } +`; diff --git a/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx b/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx new file mode 100644 index 000000000..3009b3054 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx @@ -0,0 +1,228 @@ +/* eslint-disable @typescript-eslint/no-inferrable-types */ +// // React + Web3 Essentials + +// // External Packages +import { Spinner } from '../../supportChat/spinner/Spinner'; +import { toast } from 'react-toastify'; +import styled, { ThemeProvider } from 'styled-components'; +import CloseIcon from '../../../icons/close.svg'; +import useMediaQuery from './useMediaQuery'; +import { useContext, useRef } from 'react'; +import { Image } from '../../reusables'; +import { device } from '../../../config'; +import { ThemeContext } from '../theme/ThemeProvider'; +import { MdOutlineClose } from 'react-icons/md'; +// import useMediaQuery from './useMediaQuery'; + + +// Types +type LoaderToastType = { msg: string; loaderColor: string; textColor: string }; + +const override: React.CSSProperties = { + // width: "fit-content", + height: '45px', +}; + + +const LoaderToast = ({ msg, loaderColor, textColor }: LoaderToastType) => ( + + + + {msg} + + +); + +const CloseButton = ({ closeToast }:{ closeToast: any }) => ( + +); + +export type ShowLoaderToastType = ({ loaderMessage }: { loaderMessage: string }) => React.ReactText; + +export type ShowMessageToastType = ({ + toastTitle, + toastMessage, + toastType, + getToastIcon, +}: { + toastTitle: string; + toastMessage: string; + toastType: 'SUCCESS' | 'ERROR'; + getToastIcon?: (size: number) => JSX.Element; +}) => void; + +const useToast = ( + autoClose: number = 3000, + position: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right' = 'top-right' +) => { + const toastId = useRef(null); + const theme = useContext(ThemeContext); + const isMobile = useMediaQuery(device.tablet); + + let isLoaderToastShown = false; + + const showLoaderToast: ShowLoaderToastType = ({ loaderMessage }) => { + isLoaderToastShown = true; + return (toastId.current = toast( + + + , + { + position, + autoClose: false, + hideProgressBar: true, + closeOnClick: true, + pauseOnHover: true, + draggable: true, + progress: undefined, + closeButton: false, + style: { + background: theme.mainBg, + border: `1px solid ${theme.toastBorderColor}`, + boxShadow: `8px 8px 8px ${theme.toastShadowColor}`, + borderRadius: '20px', + }, + } + )); + }; + + const showMessageToast: ShowMessageToastType = ({ toastTitle, toastMessage, toastType, getToastIcon }) => { + + const toastUI = ( + + {getToastIcon ? getToastIcon(30) : ''} + + + {toastTitle} + + + {toastMessage} + + + + ); + + const toastRenderParams = { + position, + hideProgressBar: true, + closeOnClick: true, + pauseOnHover: true, + draggable: true, + progress: undefined, + type: toast.TYPE.DEFAULT, + closeButton: CloseButton, + autoClose: autoClose, + style: { + background: toastType === 'SUCCESS' ? theme.toastSuccessBackground : theme.toastErrorBackground, + boxShadow: `10px 10px 10px ${theme.toastShadowColor}`, + borderRadius: '20px', + margin: isMobile ? '20px' : '0px', + }, + }; + + if (!isLoaderToastShown) { + // render a new toast + toastId.current = toast(toastUI, { + ...toastRenderParams, + }); + } + + // update the old toast + toast.update(toastId.current, { + render: toastUI, + ...toastRenderParams, + }); + }; + + return { + showLoaderToast, + showMessageToast, + }; +}; + +const LoaderNotification = styled.div` + display: flex; + flex-direction: row; + align-items: center; + justify-content: center; + margin: 1% 3%; +`; +const LoaderMessage = styled.div` + margin-left: 3%; + font-size: 1rem; + font-weight: 600; + line-height: 1.3rem; + letter-spacing: 0em; + text-align: left; +`; + +const Toast = styled.div` + display: flex; + flex-direction: row; + align-items: flex-start; + margin: 1.5% 1%; +`; +const ToastIcon = styled.div` + width: 15%; + margin-right: 4%; +`; +const ToastContent = styled.div` + display: flex; + flex-direction: column; + align-items: flex-start; +`; +const ToastTitle = styled.div` + font-weight: 500; + font-size: 1.125rem; + letter-spacing: -0.019em; + line-height: 1.4rem; + letter-spacing: 0em; + text-align: left; + margin-bottom: 1%; +`; +const ToastMessage = styled.div` + font-weight: 400; + font-size: 0.9375rem; + line-height: 1.3rem; + text-align: left; +`; + +const Button = styled.button` + cursor: pointer; + background: none; + margin: 0; + padding: 0; + width: 1.3rem; + height: 1.3rem; + border: none; +`; + +export default useToast; diff --git a/packages/uiweb/src/lib/components/chat/helpers/Toast.tsx b/packages/uiweb/src/lib/components/chat/helpers/Toast.tsx new file mode 100644 index 000000000..0411a0c6a --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/Toast.tsx @@ -0,0 +1,190 @@ +import { useState, useEffect, Fragment, useContext } from 'react'; +import styled, { keyframes } from 'styled-components'; +import { Image, Section } from '../../reusables'; +import CloseIcon from '../../../icons/close.svg'; +import { CheckCircleIcon } from '../../../icons/CheckCircle'; +import { ThemeContext } from '../theme/ThemeProvider'; +import { IChatTheme } from '../theme'; +import InfoIcon from '../../../icons/infodark.svg'; + + +type toastProps = { + toastMessage: string; + position?: string; + status: string; +} + +const Toast = ({ toastMessage, position, status }: toastProps) => { + const [message, setMessage] = useState(''); + const theme = useContext(ThemeContext); + + useEffect(() => { + setMessage(toastMessage); + + setTimeout(() => { + setMessage(''); + }, 5000); + }, [toastMessage]); + + const closeToast = () => { + setMessage(''); + } + if (message !== '') { + return ( + + + + + {status === 'success' ? : } + + +
+ {status === 'success' ? 'Success' : 'Error'} + + {toastMessage} + +
+ + +
+
+ ); + } else return null +} + + +const Container = styled.div` + position: fixed !important; + z-index: 999999; + width: 100vw; + top: 0; + left: 0; + height: 100vh; +`; + +const toastInRight = keyframes` + from { + transform: translateX(100%); + } + to { + transform: translateX(0); + } +`; + +const toastInLeft = keyframes` + from { + transform: translateX(-100%); + } + to { + transform: translateX(0); + } +`; + +const Notification = styled.div<{theme?: IChatTheme, status?: string}>` + background: ${(props) => props.status === 'success' ? props.theme.toastSuccessBackground : props.theme.toastErrorBackground}; + transition: .3s ease; + position: fixed; + pointer-events: auto; + overflow: hidden; + margin: 0 0 6px; + margin-bottom: 15px; + // width: 300px; + max-height: 100px; + border-radius: 16px; + box-shadow: 0 0 10px #999; + box-shadow: 10px 10px 10px ${(props) => props.theme.toastShadowColor}; + opacity: 1; + display: flex; + flex-direction: row; + gap: 10px; + + + &:hover { + box-shadow: 0 0 12px #fff; + opacity: 1; + cursor: pointer; + } + + &.toast { + height: fit-content; + width: fit-content; + padding: 20px 15px; + } + + &.top-right { + top: 20px; + right: 20px; + animation: ${toastInRight} .3s ease-in-out .3s both; + } + + &.bottom-right { + bottom: 20px; + right: 20px; + transition: transform .6s ease-in-out; + animation: ${toastInRight} .7s; + } + + &.top-left { + top: 20px; + left: 20px; + transition: transform .6s ease-in; + animation: ${toastInLeft} .7s; + } + + &.bottom-left { + bottom: 20px; + left: 20px; + transition: transform .6s ease-in; + animation: ${toastInLeft} .7s; + } +`; + + + +const NotificationImage = styled.div` +`; + +const NotificationTitle = styled.div` + font-weight: 700; + font-size: 16px; + text-align: left; + margin-top: 0; + margin-bottom: 5px; + min-width: 250px; + color: ${(props) => props.theme.textColorPrimary}; + +`; + +const NotificationMessage = styled.div` + margin: 0; + text-align: left; + white-space: nowrap; + color: ${(props) => props.theme.snackbarBorderText}; + + font-weight: 400; + font-size: 14px; +`; + +const Button = styled.div` + position: relative; + font-weight: 700; + color: #fff; + outline: none; + border: none; + text-shadow: 0 1px 0 #fff; + opacity: 1; + line-height: 1; + font-size: 16px; + padding: 0; + cursor: pointer; + background: 0 0; + border: 0; +`; + +export default Toast; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/helpers/helper.ts b/packages/uiweb/src/lib/components/chat/helpers/helper.ts index 2f6aff6a6..d4db16867 100644 --- a/packages/uiweb/src/lib/components/chat/helpers/helper.ts +++ b/packages/uiweb/src/lib/components/chat/helpers/helper.ts @@ -1,2 +1,106 @@ -import { IMessagePayload } from "../exportedTypes"; +import { IMessagePayload, User } from "../exportedTypes"; +import { ethers } from "ethers"; +import { IGroup } from "../../../types"; +import { walletToPCAIP10 } from "../../../helpers"; +export const getAdminList = (groupInformation: IGroup): Array => { + const adminsFromMembers = convertToWalletAddressList(groupInformation?.members.filter((admin) => admin.isAdmin == true)); + const adminsFromPendingMembers = convertToWalletAddressList(groupInformation?.pendingMembers.filter((admin) => admin.isAdmin == true)); + const adminList = [...adminsFromMembers,...adminsFromPendingMembers]; + return adminList + }; + +export const convertToWalletAddressList = ( + memberList: { wallet: string }[] + ): string[] => { + return memberList ? memberList.map((member) => member.wallet) : []; + } + +export const getUpdatedMemberList = (groupInfo: IGroup ,walletAddress:string): Array =>{ + const members = groupInfo?.members?.filter((i) => i.wallet?.toLowerCase() !== walletAddress?.toLowerCase()); + return convertToWalletAddressList([...members,...groupInfo.pendingMembers]); +} + +export const getUpdatedAdminList = (groupInfo: IGroup, walletAddress: string | null, toRemove: boolean): Array => { + const groupAdminList: any = getAdminList(groupInfo); + if (!toRemove) { + return [...groupAdminList, walletAddress]; + } else { + const newAdminList = groupAdminList.filter((wallet: any) => wallet !== walletAddress); + return newAdminList; + } + }; + +export const profilePicture = `data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg==`; + + +export const displayDefaultUser = ({ caip10 }: { caip10: string }): User => { + const userCreated: User = { + did: caip10, + wallets: caip10, + publicKey: 'temp', + profilePicture: profilePicture, + encryptedPrivateKey: 'temp', + encryptionType: 'temp', + signature: 'temp', + sigType: 'temp', + about: null, + name: null, + numMsg: 1, + allowedNumMsg: 100, + linkedListHash: null, + }; + return userCreated; + }; + +export const findObject = (data: any,parentArray: any[],property: string ): boolean => { + let isPresent = false; + if(data) { + parentArray.map((value) => { + if (value[property] == data[property]) { + isPresent = true; + } + }); + } + return isPresent; + } + +export const MemberAlreadyPresent = (member: any, groupMembers: any )=>{ + const memberCheck = groupMembers?.find((x: any)=>x.wallet?.toLowerCase() == member.wallets?.toLowerCase()); + if(memberCheck){ + return true; + } + return false; + } + +export const addWalletValidation = (member:User,memberList:any,groupMembers:any,account: any) =>{ + const checkIfMemberisAlreadyPresent = MemberAlreadyPresent(member, groupMembers); + + let errorMessage = ''; + + if (checkIfMemberisAlreadyPresent) { + errorMessage = "This Member is Already present in the group" + } + + if (memberList?.length + groupMembers?.length >= 9) { + errorMessage = 'No More Addresses can be added' + } + + if (memberList?.length >= 9) { + errorMessage = 'No More Addresses can be added' + } + + if (findObject(member, memberList, 'wallets')) { + errorMessage = 'Address is already added' + } + + if (member?.wallets?.toLowerCase() === walletToPCAIP10(account)?.toLowerCase()) { + errorMessage = 'Group Creator cannot be added as Member' + } + + return errorMessage; + } + +export function isValidETHAddress(address: string) { + return ethers.utils.isAddress(address); + } \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/helpers/index.ts b/packages/uiweb/src/lib/components/chat/helpers/index.ts new file mode 100644 index 000000000..eb150f0e9 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/index.ts @@ -0,0 +1 @@ +export * from './twitter'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/helpers/useMediaQuery.ts b/packages/uiweb/src/lib/components/chat/helpers/useMediaQuery.ts new file mode 100644 index 000000000..f5fa9d7d8 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/helpers/useMediaQuery.ts @@ -0,0 +1,43 @@ +import { useEffect, useState } from 'react'; + +function useMediaQuery(query: string): boolean { + const getMatches = (query: string): boolean => { + // Prevents SSR issues + if (typeof window !== 'undefined') { + return window.matchMedia(query).matches; + } + return false; + }; + + const [matches, setMatches] = useState(getMatches(query)); + + function handleChange() { + setMatches(getMatches(query)); + } + + useEffect(() => { + const matchMedia = window.matchMedia(query); + + // Triggered at the first client-side load and if query changes + handleChange(); + + // Listen matchMedia + if (matchMedia.addListener) { + matchMedia.addListener(handleChange); + } else { + matchMedia.addEventListener('change', handleChange); + } + + return () => { + if (matchMedia.removeListener) { + matchMedia.removeListener(handleChange); + } else { + matchMedia.removeEventListener('change', handleChange); + } + }; + }, [query]); + + return matches; +} + +export default useMediaQuery; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/index.ts b/packages/uiweb/src/lib/components/chat/index.ts index 95973691a..10531f89e 100644 --- a/packages/uiweb/src/lib/components/chat/index.ts +++ b/packages/uiweb/src/lib/components/chat/index.ts @@ -1,4 +1,7 @@ -export { MessageBubble } from './MessageBubble'; -export * from './MessageList'; +export { ChatViewBubble } from './ChatViewBubble'; +export * from './ChatViewList'; export * from './exportedTypes'; +export * from "./ChatProfile" +export * from './ChatViewComponent' +export * from "./MessageInput" export * from './theme'; diff --git a/packages/uiweb/src/lib/components/chat/theme/index.ts b/packages/uiweb/src/lib/components/chat/theme/index.ts index 9a198030a..34947cdb4 100644 --- a/packages/uiweb/src/lib/components/chat/theme/index.ts +++ b/packages/uiweb/src/lib/components/chat/theme/index.ts @@ -17,6 +17,32 @@ export interface IChatTheme { iconColorPrimary?: string; fontFamily?: string; chatBubblePrimaryBgColor?: string; + fileIconColor?: string; + dropdownBorderColor?: string; + modalPrimaryTextColor?: string; + modalSearchBarBorderColor?: string; + modalSearchBarBackground?: string; + snapFocusBg?: string; + groupButtonBackgroundColor?: string; + groupButtonTextColor?: string; + modalConfirmButtonBorder?: string; + groupSearchProfilBackground?: string, + modalInputBorderColor?: string, + snackbarBorderText?: string, + snackbarBorderIcon?: string, + modalContentBackground?: string, + modalProfileTextColor?: string, + toastSuccessBackground?: string; + toastErrorBackground?: string; + toastShadowColor?: string; + toastBorderColor?: string; + mainBg?: string; + modalBorderColor?: string; + modalDescriptionTextColor?: string; + modalIconColor?: string; + pendingCardBackground?: string, + modalHeadingColor?: string; + defaultBorder?: string; } export const lightChatTheme: IChatTheme = { @@ -31,12 +57,38 @@ export const lightChatTheme: IChatTheme = { accentTextColor: '#fff', btnColorPrimary: 'rgb(202, 89, 155)', border: 'none', - borderRadius: '32px', + borderRadius: '24px', iconColorPrimary: 'none', + fileIconColor: '#000', + dropdownBorderColor: '1px solid rgb(229, 232, 246)', + modalPrimaryTextColor: '#1E1E1E', + modalSearchBarBorderColor: '#BAC4D6', + modalSearchBarBackground: '#FFF', + snapFocusBg: '#F4F5FA', + groupButtonBackgroundColor: '#ADB0BE', + groupButtonTextColor: '#FFF', + modalConfirmButtonBorder: '1px solid #F4DCEA', + groupSearchProfilBackground: '#F4F5FA', + modalInputBorderColor: '#C2CBDB', + snackbarBorderText: '#000', + snackbarBorderIcon: 'none', + modalContentBackground: '#FFFFFF', + modalProfileTextColor: '#1E1E1E', + toastSuccessBackground: 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #F3FFF9 42.81%)', + toastErrorBackground: 'linear-gradient(90.15deg, #FF2070 -125.65%, #FF2D79 -125.63%, #FFF9FB 42.81%)', + toastShadowColor: '#ccc', + toastBorderColor: '#F4F3FF', + mainBg: '#fff', + modalBorderColor: '#E5E8F6', + modalDescriptionTextColor: '#575D73', + modalIconColor: '#657795', + pendingCardBackground: 'rgba(173, 176, 190, 0.12)', + modalHeadingColor: '#333333', + defaultBorder: '#E5E8F6', }; export const darkChatTheme: IChatTheme = { - chatBubblePrimaryBgColor: 'fff', + chatBubblePrimaryBgColor: '#fff', bgColorPrimary: 'rgb(47, 49, 55)', bgColorSecondary: 'rgb(40, 42, 46)', textColorPrimary: '#fff', @@ -46,8 +98,35 @@ export const darkChatTheme: IChatTheme = { accentTextColor: '#fff', btnColorPrimary: 'rgb(202, 89, 155)', border: 'none', - borderRadius: '32px', + borderRadius: '24px', iconColorPrimary: 'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)', + dropdownBorderColor: '1px solid rgb(74, 79, 103)', + fileIconColor: '#fff', + modalPrimaryTextColor: '#B6BCD6', + modalSearchBarBorderColor: '#4A4F67', + modalSearchBarBackground: '#282A2E', + snapFocusBg: '#404650', + groupButtonBackgroundColor: '#2F3137', + groupButtonTextColor: '#787E99', + modalConfirmButtonBorder: '1px solid #787E99', + groupSearchProfilBackground: '#404650', + modalInputBorderColor: '#4A4F67', + snackbarBorderText: '#B6BCD6', + snackbarBorderIcon: + 'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)', + modalContentBackground: '#2F3137', + modalProfileTextColor: '#B6BCD6', + toastSuccessBackground: 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #2F3137 42.81%)', + toastErrorBackground: 'linear-gradient(89.96deg, #FF2070 -101.85%, #2F3137 51.33%)', + toastShadowColor: '#00000010', + toastBorderColor: '#4A4F67', + mainBg: '#000', + modalBorderColor: '#4A4F67', + modalDescriptionTextColor: '#787E99', + modalIconColor: '#787E99', + pendingCardBackground: 'rgba(173, 176, 190, 0.08)', + modalHeadingColor: '#B6BCD6', + defaultBorder: '#4A4F67' }; diff --git a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx index afef6def9..b65c46478 100644 --- a/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx +++ b/packages/uiweb/src/lib/components/chatAndNotification/ChatAndNotification.tsx @@ -128,7 +128,7 @@ export const ChatAndNotification = () => { (async () => { let user; if (account) { - user = await fetchChatProfile({ profileId: account }); + user = await fetchChatProfile({ profileId: account ,env}); if (user) setConnectedProfile(user); } diff --git a/packages/uiweb/src/lib/components/reusables/sharedStyling.tsx b/packages/uiweb/src/lib/components/reusables/sharedStyling.tsx index 8fa096b69..6ce67adbf 100644 --- a/packages/uiweb/src/lib/components/reusables/sharedStyling.tsx +++ b/packages/uiweb/src/lib/components/reusables/sharedStyling.tsx @@ -41,7 +41,7 @@ export const Span = styled.span` cursor: ${(props) => props.cursor || 'default'}; margin: ${(props) => props.margin || '0px'}; padding: ${(props) => props.padding || '0px'}; - position: ${(props) => props.position || 'static'}; + position: ${(props) => props.position || 'relative'}; right: ${(props) => props.right || 'auto'}; text-align: ${(props) => props.textAlign || 'center'}; text-transform: ${(props) => props.textTransform || 'inherit'}; @@ -100,7 +100,7 @@ export const Section = styled.div` width: ${(props) => props.width || 'auto'}; overflow: ${(props) => props.overflow || 'default'}; padding: ${(props) => props.padding || '0px'}; - position: ${(props) => props.position || 'static'}; + position: ${(props) => props.position || 'relative'}; background: ${(props) => props.gradient ? props.gradient @@ -155,6 +155,7 @@ type DivStyleProps = { cursor?: string; alignSelf?:string; margin?:string; + textAlign?:string; }; export const Div = styled.div` height: ${(props) => props.height || 'auto'}; @@ -162,4 +163,5 @@ export const Div = styled.div` margin: ${(props) => props.margin || '0px'}; cursor: ${(props) => props.cursor || 'default'}; align-self: ${(props) => props.alignSelf || 'center'}; + text-align: ${(props) => props.textAlign || 'default'}; `; diff --git a/packages/uiweb/src/lib/components/supportChat/spinner/Spinner.tsx b/packages/uiweb/src/lib/components/supportChat/spinner/Spinner.tsx index 83627c35b..9aa0086c7 100644 --- a/packages/uiweb/src/lib/components/supportChat/spinner/Spinner.tsx +++ b/packages/uiweb/src/lib/components/supportChat/spinner/Spinner.tsx @@ -5,17 +5,18 @@ import { SpinnerSvg } from '../../../icons/SpinnerSvg'; type SpinnerPropType = { size?: string; + color?: string }; type SpinLoaderPropType = { width?: string; }; -export const Spinner: React.FC = ({ size = 42 }) => { +export const Spinner: React.FC = ({ size = 42, color }) => { const { theme } = useContext(SupportChatPropsContext); return ( - + ); }; diff --git a/packages/uiweb/src/lib/context/chatContext.ts b/packages/uiweb/src/lib/context/chatContext.ts index 330936e67..c075f3377 100644 --- a/packages/uiweb/src/lib/context/chatContext.ts +++ b/packages/uiweb/src/lib/context/chatContext.ts @@ -27,7 +27,7 @@ export const initialChatDataContextValues: IChatDataContextValues = { setPgpPrivateKey: () => { /**/ }, - env: Constants.ENV.DEV, + env: Constants.ENV.PROD, setEnv: () => { /**/ }, diff --git a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx index e099818fe..278f9f5ca 100644 --- a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx +++ b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx @@ -8,7 +8,6 @@ import { ThemeContext } from '../components/chat/theme/ThemeProvider'; import useGetChatProfile from '../hooks/useGetChatProfile'; import { IUser } from '@pushprotocol/restapi'; import { IChatTheme, lightChatTheme } from '../components/chat/theme'; -import { ChatThemeOptions } from '../components'; export interface IChatUIProviderProps { children: ReactNode; @@ -35,22 +34,37 @@ export const ChatUIProvider = ({ const [isPushChatSocketConnected, setIsPushChatSocketConnected] = useState(false); + -useEffect(()=>{ + useEffect(() => { + resetStates(); + setEnvVal(env); + setAccountVal(account); + setPgpPrivateKeyVal(pgpPrivateKey); + }, [env,account,pgpPrivateKey]) + + useEffect(() => { setAccountVal(account) - setPgpPrivateKeyVal(pgpPrivateKey) -},[pgpPrivateKey]) + }, [account]) + + + +const resetStates = () => { + setPushChatSocket(null); + setIsPushChatSocketConnected(false); + +}; useEffect(() => { (async () => { let user; if (account) { - user = await fetchChatProfile({ profileId: account }); + user = await fetchChatProfile({ profileId: account,env }); if (user) setConnectedProfile(user); } })(); - }, [account]); + }, [account,env]); const value: IChatDataContextValues = { account: accountVal, @@ -69,7 +83,7 @@ useEffect(() => { const PROVIDER_THEME = Object.assign({}, lightChatTheme, theme); - +console.log(PROVIDER_THEME) return ( diff --git a/packages/uiweb/src/lib/helpers/address.ts b/packages/uiweb/src/lib/helpers/address.ts index 5c1912572..5af01ad2c 100644 --- a/packages/uiweb/src/lib/helpers/address.ts +++ b/packages/uiweb/src/lib/helpers/address.ts @@ -1,5 +1,5 @@ import { ethers } from 'ethers'; -import type { Web3Provider } from '@ethersproject/providers'; +import type { Web3Provider, InfuraProvider } from '@ethersproject/providers'; /** * @@ -64,6 +64,36 @@ export const resolveEns = (address: string, provider: Web3Provider) => { }); }; +export const resolveNewEns = async (address: string, provider: InfuraProvider) => { + const walletLowercase = pCAIP10ToWallet(address).toLowerCase(); + const checksumWallet = ethers.utils.getAddress(walletLowercase); + let result; + // let provider = ethers.getDefaultProvider('mainnet'); + // if ( + // window.location.hostname == 'app.push.org' || + // window.location.hostname == 'staging.push.org' || + // window.location.hostname == 'dev.push.org' || + // window.location.hostname == 'alpha.push.org' || + // window.location.hostname == 'w2w.push.org' + // ) { + // provider = new ethers.providers.InfuraProvider( + // 'mainnet', + // appConfig.infuraAPIKey + // ); + // } + + await provider.lookupAddress(checksumWallet).then((ens) => { + if (ens) { + result = ens; + return ens; + } else { + result = null; + return null; + } + }); + return result; +}; + export const isPCAIP = (id: string) => { const prefix = `eip155:`; return id?.startsWith(prefix); diff --git a/packages/uiweb/src/lib/helpers/chat/chat.ts b/packages/uiweb/src/lib/helpers/chat/chat.ts index 8990916c9..357dce16e 100644 --- a/packages/uiweb/src/lib/helpers/chat/chat.ts +++ b/packages/uiweb/src/lib/helpers/chat/chat.ts @@ -1,11 +1,12 @@ import * as PushAPI from '@pushprotocol/restapi'; import type { ENV } from '../../config'; import { Constants } from '../../config'; -import type { AccountEnvOptionsType, IMessageIPFS, Messagetype } from '../../types'; +import type { AccountEnvOptionsType, IGroup, IMessageIPFS, Messagetype } from '../../types'; import { ChatFeedsType } from '../../types'; import type { Env, IConnectedUser, IFeeds, IUser } from '@pushprotocol/restapi'; import { isPCAIP, pCAIP10ToWallet, walletToPCAIP10 } from '../address'; import { getData } from './localStorage'; +import { ethers } from 'ethers'; type HandleOnChatIconClickProps = { isModalOpen: boolean; @@ -127,7 +128,7 @@ export const copyToClipboard = (address: string): void => { }; -export const getDefaultFeedObject = ({user}:{user:IUser}):IFeeds => { +export const getDefaultFeedObject = ({user,groupInformation}:{user?:IUser,groupInformation?:IGroup}) :IFeeds => { const feed = { msg: { messageContent: '', @@ -143,21 +144,21 @@ export const getDefaultFeedObject = ({user}:{user:IUser}):IFeeds => { toDID: '', toCAIP10: '', }, - wallets: user.wallets, - did: user.did, + wallets: groupInformation?null: user!.wallets, + did: groupInformation?null: user!.did, threadhash: null, - profilePicture: user?.profile?.picture, + profilePicture: groupInformation?groupInformation.groupImage:user?.profile.picture, name: null, - about: user.about, + about: groupInformation?null:user!.about, intent: null, intentSentBy: null, intentTimestamp: new Date(), - publicKey: user.publicKey, + publicKey: groupInformation?null: user!.publicKey, combinedDID: '', cid: '', groupInformation: undefined, }; - return feed; + return feed as IFeeds; } type CheckIfIntentType = { @@ -165,6 +166,8 @@ type CheckIfIntentType = { account:string, } export const checkIfIntent = ({chat,account}:CheckIfIntentType):boolean => { + console.log(chat) + console.log(account) if(Object.keys(chat || {}).length && (chat.combinedDID.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) { if( chat.intent && (chat.intent.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) @@ -211,4 +214,28 @@ export const appendUniqueMessages = (parentList:Messagetype,newlist:IMessageIPFS ) ); return newMessageList -} \ No newline at end of file +} + +export const checkIfSameChat = ( + msg: IMessageIPFS, + account: string, + chatId: string +) => { + if (ethers.utils.isAddress(chatId)) { + chatId = walletToPCAIP10(chatId); + } + if ( + Object.keys(msg || {}).length && + ((chatId.toLowerCase() === + msg.fromCAIP10?.toLowerCase() && + walletToPCAIP10(account!).toLowerCase() === + msg.toCAIP10?.toLowerCase()) || + (chatId.toLowerCase() === + msg.toCAIP10?.toLowerCase() && + walletToPCAIP10(account!).toLowerCase() === + msg.fromCAIP10?.toLowerCase())) + ) { + return true; + } + return false; +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/helpers/chat/search.ts b/packages/uiweb/src/lib/helpers/chat/search.ts index 9c0bd1546..cad3ae4c4 100644 --- a/packages/uiweb/src/lib/helpers/chat/search.ts +++ b/packages/uiweb/src/lib/helpers/chat/search.ts @@ -59,7 +59,7 @@ export const getNewChatUser = async ({ address = await getAddress(searchText, env); if (address) { - chatProfile = await fetchChatProfile({ profileId: address }); + chatProfile = await fetchChatProfile({ profileId: address ,env}); if (!chatProfile) chatProfile = displayDefaultUser({ caip10: walletToPCAIP10(address) }); return chatProfile; diff --git a/packages/uiweb/src/lib/helpers/chat/time.ts b/packages/uiweb/src/lib/helpers/chat/time.ts index 30b211377..496105bff 100644 --- a/packages/uiweb/src/lib/helpers/chat/time.ts +++ b/packages/uiweb/src/lib/helpers/chat/time.ts @@ -6,7 +6,7 @@ export const dateToFromNowDaily = (timestamp: number): string => { lastDay: '[Yesterday]', sameDay: '[Today]', nextWeek: 'dddd', - sameElse: 'L' + sameElse: 'LL' }); return timestampDate; }; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/chat/index.ts b/packages/uiweb/src/lib/hooks/chat/index.ts index 93b5dafbe..8aa6ea6bb 100644 --- a/packages/uiweb/src/lib/hooks/chat/index.ts +++ b/packages/uiweb/src/lib/hooks/chat/index.ts @@ -1,4 +1,11 @@ export * from './useFetchHistoryMessages'; export * from './useChatData'; -export * from './usePushChatSocket'; \ No newline at end of file +export * from './useChatProfile'; +export * from './usePushChatSocket'; +export * from './usePushSendMessage'; +export * from './useGetGroupByID'; +export * from './useFetchChat'; +export * from './useFetchConversationHash'; +export * from './usePushSendMessage'; +export * from './useGetGroupByID'; diff --git a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts new file mode 100644 index 000000000..474e64735 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts @@ -0,0 +1,41 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; +import { useChatData } from './useChatData'; + +interface ApproveChatParams { + chatId: string; +} + +const useApproveChatRequest = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const { account, env,pgpPrivateKey } =useChatData(); + const approveChatRequest = useCallback(async (options:ApproveChatParams) => { + const { + + chatId, + } = options || {}; + setLoading(true); + try { + const response = await PushAPI.chat.approve({ + status: 'Approved', + account: account, + senderAddress: chatId, // receiver's address or chatId of a group + pgpPrivateKey:pgpPrivateKey, + env: env, + }); + return response; + } catch (error: Error | any) { + setLoading(false); + setError(error.message); + console.log(error); + return; + } + }, + [] + ); + + return { approveChatRequest, error, loading }; +}; + +export default useApproveChatRequest; diff --git a/packages/uiweb/src/lib/hooks/chat/useChatProfile.ts b/packages/uiweb/src/lib/hooks/chat/useChatProfile.ts new file mode 100644 index 000000000..8a6d71411 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useChatProfile.ts @@ -0,0 +1,32 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { useCallback, useContext } from 'react'; +import { useChatData } from './useChatData'; + +export interface ProfileParams { + profileId: string; +} + +const useChatProfile = () => { + const { env } = useChatData(); + const fetchUserChatProfile = useCallback( + async ({ + profileId + }: ProfileParams): Promise => { + try { + const profile = await PushAPI.user.get({ + env: env, + account: profileId, + }); + return profile; + } catch (error) { + console.log(error); + return; + } + }, + [env] + ); + + return { fetchUserChatProfile }; +}; + +export default useChatProfile; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts new file mode 100644 index 000000000..4a0887956 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts @@ -0,0 +1,46 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { Env } from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; +import { useChatData } from './useChatData'; + + +interface fetchChat { + chatId: string; +} + +const useFetchChat = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const { account, env,pgpPrivateKey } = useChatData(); + + + const fetchChat = useCallback( + async ({ chatId}: fetchChat) => { + console.log(env); + setLoading(true); + try { + const chat = await PushAPI.chat.chat({ + account: account!, + toDecrypt: pgpPrivateKey ? true : false, + pgpPrivateKey: String(pgpPrivateKey), + recipient: chatId, + env: env + }); + return chat; + } catch (error: Error | any) { + setLoading(false); + setError(error.message); + console.log(error); + return; + } + finally { + setLoading(false); + } + }, + [pgpPrivateKey,env] + ); + + return { fetchChat, error, loading }; +}; + +export default useFetchChat; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts b/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts new file mode 100644 index 000000000..407e34576 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts @@ -0,0 +1,38 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { Env } from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; +import { useChatData } from './useChatData'; + +interface conversationHashParams { + conversationId: string; +} + +const useFetchConversationHash = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const { account, env } = useChatData(); + + const fetchConversationHash = useCallback( + async ({ conversationId }: conversationHashParams) => { + setLoading(true); + try { + const response = await PushAPI.chat.conversationHash({ + conversationId, + account: account!, + env: env, + }); + setLoading(false); + return response; + } catch (error: Error | any) { + setLoading(false); + setError(error.message); + console.log(error); + return; + } + }, + [env, account] + ); + return { fetchConversationHash, error, loading }; +}; + +export default useFetchConversationHash; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts b/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts index bddf1e64c..cdd2ee84c 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts @@ -3,6 +3,7 @@ import * as PushAPI from '@pushprotocol/restapi'; import type { IMessageIPFS } from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; import { ChatDataContext } from '../../context'; +import { useChatData } from './useChatData'; @@ -18,8 +19,7 @@ const useFetchHistoryMessages const [error, setError] = useState(); const [loading, setLoading] = useState(false); - const { account, env,pgpPrivateKey } = - useContext(ChatDataContext); + const { account, env,pgpPrivateKey } = useChatData(); const historyMessages = useCallback(async ({threadHash,limit = 10,}:HistoryMessagesParams) => { @@ -27,7 +27,7 @@ const useFetchHistoryMessages try { const chatHistory:IMessageIPFS[] = await PushAPI.chat.history({ threadhash: threadHash, - account: account, + account: account!, toDecrypt: pgpPrivateKey ? true : false, pgpPrivateKey: String(pgpPrivateKey), limit: limit, diff --git a/packages/uiweb/src/lib/hooks/chat/useGetGroup.ts b/packages/uiweb/src/lib/hooks/chat/useGetGroup.ts new file mode 100644 index 000000000..d98059dca --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useGetGroup.ts @@ -0,0 +1,51 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { Env } from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; +import { useChatData } from './useChatData'; +import { IGroup } from '../../types'; + +interface getGroup { + searchText: string; +} + +const useGetGroup = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const { env } = useChatData(); + + const getGroup = useCallback( + async ({ searchText }: getGroup) => { + setLoading(true); + let group: IGroup; + try { + group = await PushAPI.chat.getGroup({ chatId: searchText, env }); + } catch (error: Error | any) { + if ((error.message as string).includes('No group with chatId')) { + try { + group = await PushAPI.chat.getGroupByName({ + groupName: searchText, + env, + }); + } catch (err) { + setLoading(false); + setError(error.message); + console.log(error); + return; + } + } else { + setLoading(false); + setError(error.message); + console.log(error); + return; + } + } + return group; + + }, + [ env] + ); + + return { getGroup, error, loading }; +}; + +export default useGetGroup; diff --git a/packages/uiweb/src/lib/hooks/chat/useGetGroupByID.ts b/packages/uiweb/src/lib/hooks/chat/useGetGroupByID.ts new file mode 100644 index 000000000..93881577f --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useGetGroupByID.ts @@ -0,0 +1,37 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { Env } from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; +import { useChatData } from './useChatData'; +import { IGroup } from '../../types'; + +interface getGroup { + groupId: string; +} + +const useGetGroupByID = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const { env } = useChatData(); + + const getGroupByID = useCallback( + async ({ groupId }: getGroup) => { + setLoading(true); + let group: IGroup; + try { + group = await PushAPI.chat.getGroup({ + chatId: groupId, + env: env, + }); + } catch (error) { + console.log(error); + return; + } + return group; + }, + [env] + ); + + return { getGroupByID, error, loading }; +}; + +export default useGetGroupByID; \ No newline at end of file diff --git a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts index 81e173358..7d5484a7c 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts @@ -8,7 +8,6 @@ import { useChatData } from './useChatData'; import { SOCKET_TYPE } from '../../types'; import { getChatId } from '../../helpers'; - export type PushChatSocketHookOptions = { account?: string | null; env?: ENV; @@ -23,10 +22,21 @@ export const usePushChatSocket = () => { setIsPushChatSocketConnected, isPushChatSocketConnected, connectedProfile, - env + env, } = useChatData(); - const [messagesSinceLastConnection,setMessagesSinceLastConnection] = useState({}); + const [messagesSinceLastConnection, setMessagesSinceLastConnection] = + useState({}); + const [ + groupInformationSinceLastConnection, + setGroupInformationSinceLastConnection, + ] = useState({}); + + // useEffect(() => { + // // console.log(pgpPrivateKey, "pgppppppppp") + // // console.log(connectedProfile, "connectedProfileeeeeeeee") + // }, [pgpPrivateKey, connectedProfile]) + const addSocketEvents = useCallback(() => { console.log('addSocketEvents'); pushChatSocket?.on(EVENTS.CONNECT, () => { @@ -37,35 +47,41 @@ export const usePushChatSocket = () => { setIsPushChatSocketConnected(false); }); + pushChatSocket?.on(EVENTS.CHAT_RECEIVED_MESSAGE, async (chat: any) => { + console.log(chat) + console.log(connectedProfile) + console.log(pgpPrivateKey) + if (!connectedProfile || !pgpPrivateKey) { + return; + } + console.log(chat) + if ( + ( chat.messageCategory === 'Request') && + (chat.messageContent === null) && + (chat.messageType === null) + ) { + return; + } + console.log(chat) + const response = await PushAPI.chat.decryptConversation({ + messages: [chat], + connectedUser: connectedProfile, + pgpPrivateKey: pgpPrivateKey, + env: env, + }); + console.log(chat) + + if (response && response.length) { + setMessagesSinceLastConnection(response[0]); + } + }); + pushChatSocket?.on(EVENTS.CHAT_GROUPS, (groupInfo: any) => { + /** + * We receive a group creation or updated event. + */ + setGroupInformationSinceLastConnection(groupInfo); + }); - pushChatSocket?.on( - EVENTS.CHAT_RECEIVED_MESSAGE, - async (chat: any) => { - if (!connectedProfile || !pgpPrivateKey) { - return; - } - // const chatId = getChatId({ msg: chat, account:account! }).toLowerCase(); - if ( - chat.messageCategory === 'Request' && - chat.messageContent === null && - chat.messageType === null - ) { - return; - } - - const response = await PushAPI.chat.decryptConversation({ - messages: [chat], - connectedUser: connectedProfile, - pgpPrivateKey: pgpPrivateKey, - env: env, - }); - if (response && response.length) { - setMessagesSinceLastConnection(response[0]); - } - } - ); - - // eslint-disable-next-line react-hooks/exhaustive-deps }, [ pushChatSocket, @@ -73,7 +89,7 @@ export const usePushChatSocket = () => { pgpPrivateKey, messagesSinceLastConnection, env, - + connectedProfile, ]); const removeSocketEvents = useCallback(() => { @@ -93,7 +109,7 @@ export const usePushChatSocket = () => { removeSocketEvents(); } }; - }, [pushChatSocket]); + }, [pushChatSocket, pgpPrivateKey, connectedProfile]); /** * Whenever the required params to create a connection object change @@ -103,24 +119,21 @@ export const usePushChatSocket = () => { useEffect(() => { if (account) { if (pushChatSocket && pushChatSocket.connected) { - // console.log('=================>>> disconnection in the hook'); // pushChatSocket?.disconnect(); - } - else { + } else { const main = async () => { - const connectionObject = createSocketConnection({ - user: account, - env, - socketType: SOCKET_TYPE.CHAT, - socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, - }); - console.warn('new connection object: ', connectionObject); - - setPushChatSocket(connectionObject); - }; - main().catch((err) => console.error(err)); + const connectionObject = createSocketConnection({ + user: account, + env, + socketType: SOCKET_TYPE.CHAT, + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + }); + console.warn('new connection object: ', connectionObject); + + setPushChatSocket(connectionObject); + }; + main().catch((err) => console.error(err)); } - } // eslint-disable-next-line react-hooks/exhaustive-deps @@ -129,6 +142,7 @@ export const usePushChatSocket = () => { return { pushChatSocket, isPushChatSocketConnected, - messagesSinceLastConnection + messagesSinceLastConnection, + groupInformationSinceLastConnection, }; }; diff --git a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts new file mode 100644 index 000000000..dbba7517d --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts @@ -0,0 +1,50 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { useCallback, useContext, useState } from 'react'; + +import { useChatData } from '..'; +import { ENV } from '../../config'; + +interface SendMessageParams { + message: string; + chatId: string; + messageType?: 'Text' | 'Image' | 'File' | 'GIF' | 'MediaEmbed'; +} + +const usePushSendMessage = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + + const { pgpPrivateKey, env, account } = useChatData(); + + const sendMessage = useCallback( + async (options: SendMessageParams) => { + const { chatId, message, messageType } = options || {}; + setLoading(true); + try { + const response = await PushAPI.chat.send({ + messageContent: message, + messageType: messageType, + receiverAddress: chatId, + account: account ? account : undefined, + pgpPrivateKey: pgpPrivateKey ? pgpPrivateKey : undefined, + env: env, + }); + setLoading(false); + if (!response) { + return false; + } + return; + } catch (error: Error | any) { + setLoading(false); + setError(error.message); + console.log(error); + return; + } + }, + [pgpPrivateKey, account] + ); + + return { sendMessage, error, loading }; +}; + +export default usePushSendMessage; diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts index a5394d73d..48f23c7d0 100644 --- a/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/chat/useFetchHistoryMessages.ts @@ -36,6 +36,7 @@ const useFetchHistoryMessages limit: limit, env: env }); + console.log(chatHistory) chatHistory.reverse(); if (chats.get(selectedChatId as string)) { const uniqueMap: { [timestamp: number]: IMessageIPFS } = {}; diff --git a/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts b/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts index 921043f0d..927c85e9f 100644 --- a/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts +++ b/packages/uiweb/src/lib/hooks/chatAndNotification/useChatNotificationSocket.ts @@ -111,7 +111,7 @@ const useChatNotificationSocket = ({ chat.messageType === null ) { if (chat.messageOrigin === 'other') { - const user = await fetchChatProfile({ profileId: chatId }); + const user = await fetchChatProfile({ profileId: chatId,env }); if (user || Object.keys(user || {}).length) { let newOne: IFeeds = {} as IFeeds; diff --git a/packages/uiweb/src/lib/hooks/useGetChatProfile.ts b/packages/uiweb/src/lib/hooks/useGetChatProfile.ts index 6bfb1e5e5..8937a7026 100644 --- a/packages/uiweb/src/lib/hooks/useGetChatProfile.ts +++ b/packages/uiweb/src/lib/hooks/useGetChatProfile.ts @@ -4,13 +4,14 @@ import { ChatAndNotificationPropsContext } from '../context'; export interface GetProfileParams { profileId: string; + env:PushAPI.Env } const useGetChatProfile = () => { - const { env } = useContext(ChatAndNotificationPropsContext); const fetchChatProfile = useCallback( async ({ - profileId + profileId, + env }: GetProfileParams): Promise => { try { const profile = await PushAPI.user.get({ @@ -23,7 +24,7 @@ const useGetChatProfile = () => { return; } }, - [env] + [] ); return { fetchChatProfile }; diff --git a/packages/uiweb/src/lib/icons/Accept.svg b/packages/uiweb/src/lib/icons/Accept.svg deleted file mode 100644 index 183d2cbb7..000000000 --- a/packages/uiweb/src/lib/icons/Accept.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/packages/uiweb/src/lib/icons/Adddark.tsx b/packages/uiweb/src/lib/icons/Adddark.tsx new file mode 100644 index 000000000..b53d89497 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Adddark.tsx @@ -0,0 +1,12 @@ +import React from 'react'; + +export const AddUserDarkIcon = () => { + return ( + + + + + + + ); +}; diff --git a/packages/uiweb/src/lib/icons/Attachment.tsx b/packages/uiweb/src/lib/icons/Attachment.tsx index 2e4f8a8d5..c8979b221 100644 --- a/packages/uiweb/src/lib/icons/Attachment.tsx +++ b/packages/uiweb/src/lib/icons/Attachment.tsx @@ -1,6 +1,10 @@ import React from 'react'; -export const AttachmentIcon = () => { +interface IAttachmentIconProps { + color?: string; +} + +export const AttachmentIcon: React.FC = ({ color = "#494D5F" }) => { return ( { > ); -}; +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/BRBIcon.svg b/packages/uiweb/src/lib/icons/BRBIcon.svg new file mode 100644 index 000000000..1b4183b04 --- /dev/null +++ b/packages/uiweb/src/lib/icons/BRBIcon.svg @@ -0,0 +1,54 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/packages/uiweb/src/lib/icons/CaretDownGrey.tsx b/packages/uiweb/src/lib/icons/CaretDownGrey.tsx new file mode 100644 index 000000000..1e2fe2b7f --- /dev/null +++ b/packages/uiweb/src/lib/icons/CaretDownGrey.tsx @@ -0,0 +1,9 @@ +import React from 'react'; + +export const CaretDownIcon = () => { + return ( + + + + ); +}; diff --git a/packages/uiweb/src/lib/icons/CheckCircle.tsx b/packages/uiweb/src/lib/icons/CheckCircle.tsx index b45fceb11..f537b2fcc 100644 --- a/packages/uiweb/src/lib/icons/CheckCircle.tsx +++ b/packages/uiweb/src/lib/icons/CheckCircle.tsx @@ -1,9 +1,9 @@ import React from 'react'; -export const CheckCircleIcon = () => { +export const CheckCircleIcon = ({ stroke, height, width }: { stroke?: string, height?: string, width?: string }) => { return ( - - + + ); diff --git a/packages/uiweb/src/lib/icons/Emoji.tsx b/packages/uiweb/src/lib/icons/Emoji.tsx index a3737a75a..cb9a9dbfc 100644 --- a/packages/uiweb/src/lib/icons/Emoji.tsx +++ b/packages/uiweb/src/lib/icons/Emoji.tsx @@ -1,15 +1,17 @@ import React from 'react'; -export const EmojiIcon = () => { +type EmojiIconsProps = { + color?: string; +} + +export const EmojiIcon: React.FC = ({color="none"}) => { return ( - - - - - + + + + + - - - + ); }; \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/Encryption.tsx b/packages/uiweb/src/lib/icons/Encryption.tsx index 896bb983b..2ca9faf8a 100644 --- a/packages/uiweb/src/lib/icons/Encryption.tsx +++ b/packages/uiweb/src/lib/icons/Encryption.tsx @@ -1,8 +1,12 @@ import React from 'react'; -export const EncryptionIcon = () => { +export const EncryptionIcon = ({ + size, +}: { + size?: string; +}) => { return ( - + diff --git a/packages/uiweb/src/lib/icons/Gif.tsx b/packages/uiweb/src/lib/icons/Gif.tsx index 37e14cfad..8011a992f 100644 --- a/packages/uiweb/src/lib/icons/Gif.tsx +++ b/packages/uiweb/src/lib/icons/Gif.tsx @@ -3,10 +3,10 @@ import React from 'react'; export const GifIcon = () => { return ( - - + + - - + + ); }; \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/Lock.png b/packages/uiweb/src/lib/icons/Lock.png new file mode 100644 index 0000000000000000000000000000000000000000..e7713df829713eb9c1941f62776997b50cc5ab11 GIT binary patch literal 819 zcmeAS@N?(olHy`uVBq!ia0vp^20-kwra7byL^KQCqX=Q)|dm+i~G ziF+?s`Ru76eecYh-{(Hu`*T7e<;b_X^0!9sr|WLHX8A#h@g_%x_w0&&0_TH&D*7d# zPnsO~`l*N!L!w{Y6~9wFiT*nxTU;KnSky|^+>t#fvqUVQ_OkAxr{ylfuMOmbo&MF_ zsIqMoG4MEeZTDp5Ek7#R&Us&(aN}p#+URx>6{$wA$5+nn+^;TaDcACN?K!W-#}2yQ z;o8W0r}4A7iqJ+T!;?GTUAH(lnaA(TenED2$rww;d9H3rtPXb$yhzZ0a)$bcdOMPoxg$4=Pn6rv@4D-09kby4)~U{in(L~UGYh(Kt>_Sc*72VsGvQQl z%EVU>pDQVsc`0>FZPlr;`LW@3%U0o;tzj#(K(X)4Ckz$P>qvI}}P- z4psd>_VeBx<5hpWe;(Q2?QVTS?^(wMJ}%kD4foVr()633HsmyS%+lIDL-|zVS7+7^ zhua)~V!!-bV0vHZf!X12tIu7%q%`9~LO9orn(7z^*M^h#+ItiqCAXfuS94!~#Vbu# zfmNTkelI9vlPtFU?4~vQePt%ggIR~3sLXuz*yvS<87EWlvZD$+84M@h;JWM|A)quv zGqSM*C$K;g-QSX>*jYhU+2=% zOp4#6-h89&=~1)H5OcSNydH+T5{$bHnM#sj_DCx`V3FYE-kGt5$D-%L`9Gg7#WuG1 vs_9=j*Q~ttDnm{r-UW|x}k2_ literal 0 HcmV?d00001 diff --git a/packages/uiweb/src/lib/icons/LockSlash.png b/packages/uiweb/src/lib/icons/LockSlash.png new file mode 100644 index 0000000000000000000000000000000000000000..aa43a7d488098e917f8ae065b62eb629376b2688 GIT binary patch literal 1366 zcmV-c1*!UpP)@~0drDELIAGL9O(c600d`2O+f$vv5yPfU;*sd}rbm|J_O6h1)~1)~-kVN0zcy~Mdx#I1xQVp0K7oKFz< z(DrB|CC3DR1m~6`2f~ZNGkKo1t>AcOJ-Z&S*FOm%c8$G1&&&SjnPp%Rr|>i}b#k6! zF>w?Byn#On{7GJWNu2>}2q|7%@mRI8^>YI(!oUI~5kEa&7p#@Vi%ppSCp!copY8v- zRsjnPEwhq;e9yl`AB{`K7lv)Az%tI}1Z3~UYZ7_ac11Xk~Kfx%so$#hU5-`y;;@u=?IwdAp6 z@*!*SDh}-W^)p$VC{E5#QXrVa7`p`?2+0TDuvv@_v&ISGq8IxSlZw6KgBNRA60a%gfnDm@4;#g4B@6P zoDzaQFsV8xrOX8pAr6YaIC#;@?j%8Gox-;9ly5A<7&w|!6}+Ip(<#xsxLCq2(omg? zpT@Ibh>^_luRCc_vYqYH z;ZvvYOC1p+2`#8)elIHrJk2;5K^8$h>x><)h!P1DI$F8AtDN7T6z^1V+F8IBdJ7SQ zyGvIEQpgIeB30)o4bRQa-h_z3V~lB|1P=OwPRJw~hYhDYILGyO5TU5yPR(5*90$sq zmMgTeyA2ViXFcO&w-eLxcny!H)Gub$=FG*CZo$;9o1LT}D4eBmLQ;Kc71{b2oeus| zCy&0x*>b*o5959T^we<$xS$idy|Gi`z}I24DDQ_oGMV4X4t6|~o1$l(Yk700z$72_ zIO|(h_r@8{OxF(X657#3^N`|Cg1?XV+#ZZqnhK&I)Wa|`1PLAK;tvT?p#wr%HiU1jmXEe2wqVz4Dw_(y)P5 z8Nw_642n*}VqJzX5z5NQRT*Mn z{P}Edwx`QQS%&Zw`gA8E>N139p1aN@$Ph`da#oi~ks;dUEKQyxCP~J{YkP9yWC&gS z>5-AL73e|Fai9|Fk-2JKl}24cwaKS>PWf14W)nA^B)f`Lfup6BdtPg;3=J}f++ z=ag_i&_mke;?1l7s$YNi18%vpbl*wF8xti%ym|Tmp-O1tTBb`^hyzQys~`z?vD91n Y0P1aB^*K3#SO5S307*qoM6N<$f@q(1TmS$7 literal 0 HcmV?d00001 diff --git a/packages/uiweb/src/lib/icons/MoreDark.tsx b/packages/uiweb/src/lib/icons/MoreDark.tsx new file mode 100644 index 000000000..3f20f22fd --- /dev/null +++ b/packages/uiweb/src/lib/icons/MoreDark.tsx @@ -0,0 +1,12 @@ +import React from 'react'; + +export const MoreDarkIcon = () => { + return ( + + + + + + ); +}; + diff --git a/packages/uiweb/src/lib/icons/MoreLight.tsx b/packages/uiweb/src/lib/icons/MoreLight.tsx new file mode 100644 index 000000000..4aa3f66ea --- /dev/null +++ b/packages/uiweb/src/lib/icons/MoreLight.tsx @@ -0,0 +1,11 @@ +import React from 'react'; + +export const MoreLightIcon = () => { + return ( + + + + + + ); +}; diff --git a/packages/uiweb/src/lib/icons/NoEncryption.tsx b/packages/uiweb/src/lib/icons/NoEncryption.tsx index 8cfb043dc..fecdb5961 100644 --- a/packages/uiweb/src/lib/icons/NoEncryption.tsx +++ b/packages/uiweb/src/lib/icons/NoEncryption.tsx @@ -1,8 +1,12 @@ import React from 'react'; -export const NoEncryptionIcon = () => { +export const NoEncryptionIcon = ({ + size, +}: { + size?: string; +}) => { return ( - + diff --git a/packages/uiweb/src/lib/icons/Public-Chat.svg b/packages/uiweb/src/lib/icons/Public-Chat.svg new file mode 100644 index 000000000..60eedda28 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Public-Chat.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/SearchIcon.tsx b/packages/uiweb/src/lib/icons/SearchIcon.tsx new file mode 100644 index 000000000..54680b230 --- /dev/null +++ b/packages/uiweb/src/lib/icons/SearchIcon.tsx @@ -0,0 +1,10 @@ +import React from 'react'; + +export const SearchIcon = () => { + return ( + + + + + ); +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/SendCompIcon.tsx b/packages/uiweb/src/lib/icons/SendCompIcon.tsx new file mode 100644 index 000000000..e157b36ff --- /dev/null +++ b/packages/uiweb/src/lib/icons/SendCompIcon.tsx @@ -0,0 +1,13 @@ +import React from 'react'; + +type sendIconProps = { + color?: string; +}; + +export const SendCompIcon: React.FC = () => { + return ( + + + + ); +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/Tick.tsx b/packages/uiweb/src/lib/icons/Tick.tsx new file mode 100644 index 000000000..4aa03d6ed --- /dev/null +++ b/packages/uiweb/src/lib/icons/Tick.tsx @@ -0,0 +1,15 @@ +import React from 'react'; + +export const TickSvg = () => { + return ( + + + + + + + + + + ); +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/icons/Token-Gated.svg b/packages/uiweb/src/lib/icons/Token-Gated.svg new file mode 100644 index 000000000..8983ac268 --- /dev/null +++ b/packages/uiweb/src/lib/icons/Token-Gated.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/VerticalEllipsis.svg b/packages/uiweb/src/lib/icons/VerticalEllipsis.svg new file mode 100644 index 000000000..f03943378 --- /dev/null +++ b/packages/uiweb/src/lib/icons/VerticalEllipsis.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/addadmin.svg b/packages/uiweb/src/lib/icons/addadmin.svg new file mode 100644 index 000000000..6219bb4be --- /dev/null +++ b/packages/uiweb/src/lib/icons/addadmin.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/adddark.svg b/packages/uiweb/src/lib/icons/adddark.svg new file mode 100644 index 000000000..d6c0cf2ea --- /dev/null +++ b/packages/uiweb/src/lib/icons/adddark.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/addicon.svg b/packages/uiweb/src/lib/icons/addicon.svg new file mode 100644 index 000000000..8d18e64a5 --- /dev/null +++ b/packages/uiweb/src/lib/icons/addicon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/addlight.svg b/packages/uiweb/src/lib/icons/addlight.svg new file mode 100644 index 000000000..a20336863 --- /dev/null +++ b/packages/uiweb/src/lib/icons/addlight.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/close.svg b/packages/uiweb/src/lib/icons/close.svg new file mode 100644 index 000000000..9c8aa06e8 --- /dev/null +++ b/packages/uiweb/src/lib/icons/close.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/dismissadmin.svg b/packages/uiweb/src/lib/icons/dismissadmin.svg new file mode 100644 index 000000000..422831dd3 --- /dev/null +++ b/packages/uiweb/src/lib/icons/dismissadmin.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/greyImage.png b/packages/uiweb/src/lib/icons/greyImage.png new file mode 100644 index 0000000000000000000000000000000000000000..85ab7e29d53cc2ca4db34bf355c16894c09b98ac GIT binary patch literal 144 zcmeAS@N?(olHy`uVBq!ia0vp^4?&oN8Ax*GDtQ1Y<^Z1%*N%>kh}68zK(2?Ui(^Q| toVN!XfgFaz3w{R2Ki~*u1aU|KA9#-~VqgsCk6sMY<>~6@vd$@?2>{k_8SVf8 literal 0 HcmV?d00001 diff --git a/packages/uiweb/src/lib/icons/info.svg b/packages/uiweb/src/lib/icons/info.svg new file mode 100644 index 000000000..4aa6cdd7d --- /dev/null +++ b/packages/uiweb/src/lib/icons/info.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/infodark.svg b/packages/uiweb/src/lib/icons/infodark.svg new file mode 100644 index 000000000..c13ef750c --- /dev/null +++ b/packages/uiweb/src/lib/icons/infodark.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/more.svg b/packages/uiweb/src/lib/icons/more.svg new file mode 100644 index 000000000..b1450aaed --- /dev/null +++ b/packages/uiweb/src/lib/icons/more.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/moredark.svg b/packages/uiweb/src/lib/icons/moredark.svg new file mode 100644 index 000000000..cf68a170d --- /dev/null +++ b/packages/uiweb/src/lib/icons/moredark.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/packages/uiweb/src/lib/icons/remove.svg b/packages/uiweb/src/lib/icons/remove.svg new file mode 100644 index 000000000..84c460dd0 --- /dev/null +++ b/packages/uiweb/src/lib/icons/remove.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/search.svg b/packages/uiweb/src/lib/icons/search.svg new file mode 100644 index 000000000..146f4dd14 --- /dev/null +++ b/packages/uiweb/src/lib/icons/search.svg @@ -0,0 +1,4 @@ + + + + diff --git a/packages/uiweb/src/lib/icons/tick.svg b/packages/uiweb/src/lib/icons/tick.svg new file mode 100644 index 000000000..9b1fe7bdf --- /dev/null +++ b/packages/uiweb/src/lib/icons/tick.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/icons/videoCallIcon.svg b/packages/uiweb/src/lib/icons/videoCallIcon.svg new file mode 100644 index 000000000..8ec0d28a4 --- /dev/null +++ b/packages/uiweb/src/lib/icons/videoCallIcon.svg @@ -0,0 +1,3 @@ + + + diff --git a/packages/uiweb/src/lib/types/index.ts b/packages/uiweb/src/lib/types/index.ts index 51a5d97e9..4efb3e5ed 100644 --- a/packages/uiweb/src/lib/types/index.ts +++ b/packages/uiweb/src/lib/types/index.ts @@ -119,3 +119,21 @@ export interface FileMessageContent { size: number } export type Messagetype = { messages: IMessageIPFS[]; lastThreadHash: string | null }; + +export interface IGroup { + members: { wallet: string, publicKey: string, isAdmin: boolean, image: string }[], + pendingMembers: { wallet: string, publicKey: string, isAdmin: boolean, image: string }[], + contractAddressERC20: string | null, + numberOfERC20: number, + contractAddressNFT: string | null, + numberOfNFTTokens: number, + verificationProof: string, + groupImage: string | null, + groupName: string, + isPublic: boolean, + groupDescription: string | null, + groupCreator: string, + chatId: string, + groupType?:string | undefined +} + diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index 0e38365e7..80650f3c8 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -626,7 +626,7 @@ buffer-from@^1.1.2: resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== -clsx@^1.2.1: +clsx@^1.1.1, clsx@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== @@ -992,6 +992,11 @@ querystringify@^2.1.1: resolved "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz" integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== +react-icons@^4.10.1: + version "4.10.1" + resolved "https://registry.yarnpkg.com/react-icons/-/react-icons-4.10.1.tgz#3f3b5eec1f63c1796f6a26174a1091ca6437a500" + integrity sha512-/ngzDP/77tlCfqthiiGNZeYFACw85fUjZtLbedmJ5DTlNDIwETxhwBzdOJ21zj4iJdvc0J3y7yOsX3PpxAJzrw== + react-property@2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/react-property/-/react-property-2.0.0.tgz" @@ -1025,6 +1030,13 @@ react-style-singleton@^2.2.1: invariant "^2.2.4" tslib "^2.0.0" +react-toastify@^9.1.3: + version "9.1.3" + resolved "https://registry.yarnpkg.com/react-toastify/-/react-toastify-9.1.3.tgz#1e798d260d606f50e0fab5ee31daaae1d628c5ff" + integrity sha512-fPfb8ghtn/XMxw3LkxQBk3IyagNpF/LIKjOBflbexr2AWxAH1MJgvnESwEwBn9liLFXgTKWgBSdZpw9m4OTHTg== + dependencies: + clsx "^1.1.1" + react-twitter-embed@^4.0.4: version "4.0.4" resolved "https://registry.npmjs.org/react-twitter-embed/-/react-twitter-embed-4.0.4.tgz" From b7bc27dc3f4ecf5e80a630a6678953ee6dfb4770 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 18 Aug 2023 16:06:07 +0530 Subject: [PATCH 205/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 9111f5bb4..7856279ae 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.10...restapi-1.4.11) (2023-08-18) + + +### Bug Fixes + +* merge main ([f53a5e2](https://github.com/ethereum-push-notification-service/push-sdk/commit/f53a5e279e3780566b4e2a9242b3555ef50fb4a6)) + + + ## [1.4.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.9...restapi-1.4.10) (2023-08-18) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index bf297c806..c8baca2d9 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.10", + "version": "1.4.11", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 674d316db580bbb591b99cc1900c29110f925a84 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 18 Aug 2023 18:24:21 +0530 Subject: [PATCH 206/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 7856279ae..aedea7fa3 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.11...restapi-1.4.12) (2023-08-18) + + +### Bug Fixes + +* remove isSupported ([#661](https://github.com/ethereum-push-notification-service/push-sdk/issues/661)) ([3c3301c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3c3301c47547ee0ea1fbc412eac6395d6cf3de77)) + + + ## [1.4.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.10...restapi-1.4.11) (2023-08-18) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c8baca2d9..23da5dd70 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.11", + "version": "1.4.12", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 4cf5d676f61462d236db4cd17bfa42eb960b0733 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 18 Aug 2023 18:51:59 +0530 Subject: [PATCH 207/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 4 ++++ packages/uiweb/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 4589c675c..0d5db8b2a 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.10...uiweb-1.1.11) (2023-08-18) + + + ## [1.1.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.9...uiweb-1.1.10) (2023-08-10) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 7e3eea05b..60e6389b0 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.0", + "version": "1.1.11", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 0f6df723f66d25eeef28f0342af044d6b3247f25 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 23 Aug 2023 16:58:52 +0530 Subject: [PATCH 208/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index aedea7fa3..eb159aea2 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.12...restapi-1.4.13) (2023-08-23) + + +### Bug Fixes + +* changes messageObj for meta and reaction message type ([#645](https://github.com/ethereum-push-notification-service/push-sdk/issues/645)) ([4077049](https://github.com/ethereum-push-notification-service/push-sdk/commit/407704960117a8c7461e90cccf71a53696fa6770)) +* Merge branch 'main' into deployment ([5769701](https://github.com/ethereum-push-notification-service/push-sdk/commit/576970118ed6c8d5de8a83424aa3266f252ba586)) +* origin in user creation ([#665](https://github.com/ethereum-push-notification-service/push-sdk/issues/665)) ([13c471b](https://github.com/ethereum-push-notification-service/push-sdk/commit/13c471b6e4b17efe5ec15372373283db3f7fca1e)) + + + ## [1.4.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.11...restapi-1.4.12) (2023-08-18) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 822456243..37ab14e48 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.12", + "version": "1.4.13", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From a6d5e751fd4ba8037645fff64f41a8df701a36e0 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 23 Aug 2023 17:20:49 +0530 Subject: [PATCH 209/298] fix: update read me file --- packages/restapi/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 88f61c8c7..aa947fdd8 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -3436,7 +3436,8 @@ There are two main types of conditions: `PUSH` and `GUILD`. PUSH conditions may relate to: - **ERC721**: Needs an address and an amount, and can only have the `owner` subcategory. -- **ERC20**: Needs an address, an amount, and a decimals value. It can only have the `holder` subcategory. +. Comparison also can be given '>' | '<' | '>=' | '<=' | '==' | '!='. Default is > (greater than , that is minimum amount required) +- **ERC20**: Needs an address, an amount, and a decimals value. It can only have the `holder` subcategory. Comparison also can be given '>' | '<' | '>=' | '<=' | '==' | '!='. Default is > (greater than , that is minimum amount required) - **CustomEndpoint**: The `CustomEndpoint` provides a flexible way to validate a condition based on the response from a custom API endpoint. This is particularly useful when you want to incorporate data or validation logic that is external to your main application. As of now the Get API is supported and should return the 200 OK if the user is allowed to access.
   {

From 8cf6d2bea7c9e72fd6cb3db76da76eb44225b92d Mon Sep 17 00:00:00 2001
From: Mohammed S 
Date: Wed, 23 Aug 2023 17:31:35 +0530
Subject: [PATCH 210/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?=
 =?UTF-8?q?ease=20to=20restapi-v1.4.14?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 packages/restapi/CHANGELOG.md | 9 +++++++++
 packages/restapi/package.json | 2 +-
 2 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md
index eb159aea2..9b264465c 100644
--- a/packages/restapi/CHANGELOG.md
+++ b/packages/restapi/CHANGELOG.md
@@ -2,6 +2,15 @@
 
 This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
 
+## [1.4.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.13...restapi-1.4.14) (2023-08-23)
+
+
+### Bug Fixes
+
+* update read me file ([a6d5e75](https://github.com/ethereum-push-notification-service/push-sdk/commit/a6d5e751fd4ba8037645fff64f41a8df701a36e0))
+
+
+
 ## [1.4.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.12...restapi-1.4.13) (2023-08-23)
 
 
diff --git a/packages/restapi/package.json b/packages/restapi/package.json
index 37ab14e48..1ae47b46e 100644
--- a/packages/restapi/package.json
+++ b/packages/restapi/package.json
@@ -1,6 +1,6 @@
 {
   "name": "@pushprotocol/restapi",
-  "version": "1.4.13",
+  "version": "1.4.14",
   "type": "commonjs",
   "publishConfig": {
     "registry": "https://registry.npmjs.org/"

From aee7a33991a9da9df2a748adb1c18a02a31c02a0 Mon Sep 17 00:00:00 2001
From: Mohammed S 
Date: Wed, 23 Aug 2023 19:47:13 +0530
Subject: [PATCH 211/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?=
 =?UTF-8?q?ease=20to=20restapi-v1.4.15?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 packages/restapi/CHANGELOG.md | 10 ++++++++++
 packages/restapi/package.json |  2 +-
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md
index 9b264465c..e6581f531 100644
--- a/packages/restapi/CHANGELOG.md
+++ b/packages/restapi/CHANGELOG.md
@@ -2,6 +2,16 @@
 
 This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
 
+## [1.4.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.14...restapi-1.4.15) (2023-08-23)
+
+
+### Bug Fixes
+
+* Merge branch 'main' into deployment ([64278ec](https://github.com/ethereum-push-notification-service/push-sdk/commit/64278eccd6fd51d02b123ec00e1d36fa94a23608))
+* **spaces:** broadcast changes and UX fixes ([#674](https://github.com/ethereum-push-notification-service/push-sdk/issues/674)) ([375ebe7](https://github.com/ethereum-push-notification-service/push-sdk/commit/375ebe7f7e757d84df62cd103884e75d04bcc2b0)), closes [#642](https://github.com/ethereum-push-notification-service/push-sdk/issues/642) [#657](https://github.com/ethereum-push-notification-service/push-sdk/issues/657) [#656](https://github.com/ethereum-push-notification-service/push-sdk/issues/656)
+
+
+
 ## [1.4.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.13...restapi-1.4.14) (2023-08-23)
 
 
diff --git a/packages/restapi/package.json b/packages/restapi/package.json
index 133c9154d..6b648549b 100644
--- a/packages/restapi/package.json
+++ b/packages/restapi/package.json
@@ -1,6 +1,6 @@
 {
   "name": "@pushprotocol/restapi",
-  "version": "1.4.14",
+  "version": "1.4.15",
   "type": "commonjs",
   "publishConfig": {
     "registry": "https://registry.npmjs.org/"

From 29f0572deb71526539f916c21d2fe9b04cd43a40 Mon Sep 17 00:00:00 2001
From: Mohammed S 
Date: Wed, 23 Aug 2023 21:54:09 +0530
Subject: [PATCH 212/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?=
 =?UTF-8?q?se=20to=20uiweb-v1.1.12?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 packages/uiweb/CHANGELOG.md | 10 ++++++++++
 packages/uiweb/package.json |  2 +-
 2 files changed, 11 insertions(+), 1 deletion(-)

diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md
index 0d5db8b2a..4a132bf56 100644
--- a/packages/uiweb/CHANGELOG.md
+++ b/packages/uiweb/CHANGELOG.md
@@ -2,6 +2,16 @@
 
 This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver).
 
+## [1.1.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.11...uiweb-1.1.12) (2023-08-23)
+
+
+### Bug Fixes
+
+* Merge branch 'main' into deployment ([64278ec](https://github.com/ethereum-push-notification-service/push-sdk/commit/64278eccd6fd51d02b123ec00e1d36fa94a23608))
+* **spaces:** broadcast changes and UX fixes ([#674](https://github.com/ethereum-push-notification-service/push-sdk/issues/674)) ([375ebe7](https://github.com/ethereum-push-notification-service/push-sdk/commit/375ebe7f7e757d84df62cd103884e75d04bcc2b0)), closes [#642](https://github.com/ethereum-push-notification-service/push-sdk/issues/642) [#657](https://github.com/ethereum-push-notification-service/push-sdk/issues/657) [#656](https://github.com/ethereum-push-notification-service/push-sdk/issues/656)
+
+
+
 ## [1.1.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.10...uiweb-1.1.11) (2023-08-18)
 
 
diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json
index 60e6389b0..cc2bf67ce 100644
--- a/packages/uiweb/package.json
+++ b/packages/uiweb/package.json
@@ -1,6 +1,6 @@
 {
   "name": "@pushprotocol/uiweb",
-  "version": "1.1.11",
+  "version": "1.1.12",
   "publishConfig": {
     "registry": "https://registry.npmjs.org/"
   },

From 332f9204da51f962c437059ef81ec2625d6e18c9 Mon Sep 17 00:00:00 2001
From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com>
Date: Thu, 24 Aug 2023 00:50:47 +0530
Subject: [PATCH 213/298] Feat/chat components (#679)

* feat: created architechture

* fix: added context values (#594)

* Chat dataprovider (#596)

* feat: data provider for chat component

* fix: replaced react.usestate to usestate

* fix: added props as the initial state and changed state name

* fix: reverted chat context changes and renamed values

* fix: added test page for chat ui components (#597)

* added chatbubble component (#602)

* feat: added chatbubble component

* fix: made the messageBubble's width to fit-content

---------

Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com>

* fix: added theme

* Group chat bubble (#604)

* feat: moved test component to testui folder & replaced dummy data with sdk response

* feat: added twitter card and address for group chat received msg

* feat: made the messageaddress reusable, added account from context

* fix: removed unnecessary div and unused props and console logs

* feat: adding pfp in text bubbles

* fix: replaced hook with function and added pfp to messagebubble

* fix: fixed image alignment

* fix: changed border-radius of msg bubble and changed function name

* fix: fixed theme and decryptedPrivateKey name (#616)

* fix: fixed theme and decryptedPrivateKey name

* fix: fixed bug

* fix: fixed theme reviews

* Message list (#615)

* fix: message list comp

* fix: message list comp

* fix: added pagination

* fix: added pagination

* fix: pagination

* fix: create useChatData hook

* fix: fixed minor bug

* fix: socket issues fixed

* fix: added theme in msgbubble (#620)

* fix: added theme in msgbubble

* fix: fixed import

---------

Co-authored-by: Monalisha Mishra 

* fix: exported the theme (#623)

* fix: exported the theme

* fix: fixed issues

---------

Co-authored-by: Monalisha Mishra 

* Typebar component (#631)

* feat: added typebar UI

* feat: added functions to typebar

* fix: added icon

* fix: fixed theme issues

---------

Co-authored-by: Monalisha Mishra 

* feat: added connectbutton

* fix: fixed connectbtn ui and remove disconnect and fixed error on disconnect

* fix: fixed create account getting called twice

* Profile Header Component (#636)

* feat: profile header

* feat: update profile header

* fix: update hooks

* fix: video icon ui

* feat: add group modal

* fix: add modal info

* fix: edit components

* fix: commit modal theme

* fix: updating UI

* fix: ensname

* fix: add notifs

* fix: remove alerts

* fix: remove alert logs

* fix: push fixes

* fix: conflicts

* Message container (#635)

* fix: added theme in msgbubble

* fix: fixed import

* fix: fixed message-list

* fix: added approve intent

* fix: added fixes

* fix: fixed socket bug

* fix: fixed message from socket

* fix: fixed minor issues

* fix: fixed typebar theming

* fix: fixed env issue

* fix: fixed message not updating issue

* refactor: added isConnected prop in msgContainer

* refactor: resolve merge conflicts

* fix: fixed request sending

* fix: fixed decryption

* fix: fixed env issue

* feat: added profile header in message container

---------

Co-authored-by: KlausMikhaelson 
Co-authored-by: Nilesh Gupta 

* fix: updated svg to react component

* fix: changed svg to tsx component

* fix: fixed review changes (#646)

* fix: fixed review changes

* fix: resolved issues

---------

Co-authored-by: Nilesh Gupta 

* Profile Header -> Chat Profile fixes (#647)

* feat: profile header

* feat: update profile header

* fix: update hooks

* fix: video icon ui

* feat: add group modal

* fix: add modal info

* fix: edit components

* fix: commit modal theme

* fix: updating UI

* fix: ensname

* fix: add notifs

* fix: remove alerts

* fix: remove alert logs

* fix: push fixes

* fix: conflicts

* fix: notifs

* fix: correct theme colors

* fix: renaming profileHeader

* fix: qa fixes

* fix: loader

* refactor: resolved issues

* fix: edit types

---------

Co-authored-by: Nilesh Gupta 

* fix: resolved package not added issue

* Fix: modal issue in group info && alert remove members (#653)

* fix: modal

* fix: update changes

* refactor: resolved issue

---------

Co-authored-by: Nilesh Gupta 

* fix: QA fixes (#654)

* Connect btn revamp (#668)

* fix: added theme in msgbubble

* fix: fixed import

* fix: fixed message-list

* fix: added approve intent

* fix: added fixes

* fix: fixed socket bug

* fix: fixed message from socket

* fix: fixed minor issues

* fix: fixed typebar theming

* fix: fixed env issue

* fix: fixed message not updating issue

* refactor: added isConnected prop in msgContainer

* refactor: resolve merge conflicts

* fix: fixed request sending

* fix: fixed decryption

* fix: fixed env issue

* feat: added profile header in message container

* feat: adding rainbowkit for btn

* fix: fix issues

* fix: addec onnect functionality

* fix: connect button

* fix: added hack for rainbowkit css

---------

Co-authored-by: KlausMikhaelson 
Co-authored-by: Nilesh Gupta 

* Typebar UI issue (#666)

* fix: fixed typebar space not working and theme

* fix: fixed gif and emoji

---------

Co-authored-by: KlausMikhaelson 

* fix: fixed theme colours

* fix: added theme for brb

* fix: added filter  hat

* fix: merged with main

* fix: fixed msg border

* fix: fixed theme

* fix: fixed fonts

* fix: fixed bug

* Access control (#672)

* fix: fixed typebar space not working and theme

* feat: created access control UI

* feat: created verify access control hook

* fix: fixed access control hook issue

* feat: added access control verification

* feat: added onclick props for integration team to pass function and fixed btn ui

* fix: added link for learn more

* fix: fixed msg not updating in socket issue

* fix: added minor fix

---------

Co-authored-by: Monalisha Mishra 

* fix: fixed padding issues

* fix(f): fixed build issues

* fix: fix for chat status test

* Check rules access control (#678)

* fix: fixed typebar space not working and theme

* feat: created access control UI

* feat: created verify access control hook

* fix: fixed access control hook issue

* feat: added access control verification

* feat: added onclick props for integration team to pass function and fixed btn ui

* fix: added link for learn more

* fix: fixed msg not updating in socket issue

* 662 group access control v2 changes (#663)

* fix: spaces access API

* fix: custom endpoint doc impl

* Update README.md

* Update README.md

* fix: review comments change

* fix: read me update

* Update README.md

* Update README.md

* fix: origin in user creation (#665)

* fix: origin in user creation

* Update README.md

* fix: review comments

* 662 group access control v2 changes (#677)

* fix: spaces access API

* fix: custom endpoint doc impl

* Update README.md

* Update README.md

* fix: review comments change

* fix: read me update

* Update README.md

* Update README.md

* fix(spaces): broadcast changes and UX fixes (#674)

* fix: fix UI grid view (#642)

* fix: fix UI grid view

* refactor: conditional added

* fix: resolved muting/unmuting try catch error (#657)

* fix(spaces): fix livepeer broadcast (#656)

* fix(spaces): fix livepeer broadcast

* fix(spaces): fix data shown for unjoined space & promote listener logic

---------

Co-authored-by: Madhur Gupta 

* refactor(spaces): use local state instead of get from server while meta message fire (#676)

---------

Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com>
Co-authored-by: Nilesh Gupta 

* feat: added verification option to show only on token gated groups

* fix: fixing group access control

---------

Co-authored-by: Monalisha Mishra 
Co-authored-by: Mohammed S 
Co-authored-by: Madhur Gupta 
Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com>
Co-authored-by: Nilesh Gupta 

* fix: fixed build

---------

Co-authored-by: Satyam <100528412+KlausMikhaelson@users.noreply.github.com>
Co-authored-by: KlausMikhaelson 
Co-authored-by: Kolade 
Co-authored-by: Nilesh Gupta 
Co-authored-by: Mohammed S 
Co-authored-by: Madhur Gupta 
Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com>
---
 .../src/app/ChatTest/CreateGroupTest.tsx      |   21 +-
 .../src/app/ChatUITest/ChatUITest.tsx         |    1 +
 .../src/app/ChatUITest/ChatViewBubble.tsx     |    2 +-
 .../src/app/ChatUITest/ChatViewComponent.tsx  |   14 +-
 .../src/app/ChatUITest/ChatViewListTest.tsx   |    4 +-
 .../src/app/SpaceTest/CreateSpaceTest.tsx     |    2 +-
 .../sdk-frontend-react/src/app/app.tsx        |   11 +-
 .../src/app/components/Connect.tsx            |    4 +-
 .../examples/sdk-frontend/pages/index.tsx     |    4 +-
 .../examples/sdk-frontend/pages/video.tsx     |    2 +-
 packages/restapi/src/lib/types/index.ts       |    1 +
 packages/restapi/yarn.lock                    |  139 +-
 packages/uiweb/package.json                   |    4 +-
 .../chat/ChatProfile/AddWalletContent.tsx     |    6 +-
 .../chat/ChatProfile/ChatProfile.tsx          |   15 +-
 .../chat/ChatProfile/GroupInfoModal.tsx       |   10 +-
 .../chat/ChatViewBubble/ChatViewBubble.tsx    |  634 ++---
 .../ChatViewComponent/ChatViewComponent.tsx   |   46 +-
 .../ChatViewList/ApproveRequestBubble.tsx     |   14 +-
 .../chat/ChatViewList/ChatViewList.tsx        |  209 +-
 .../chat/ChatViewList/MessageEncryption.tsx   |    4 +-
 .../chat/ConnectButton/ConnectButton.tsx      |  263 +-
 .../components/chat/ConnectButton/index.css   | 2131 +++++++++++++++++
 .../components/chat/ConnectButton/index.ts    |    1 -
 .../components/chat/ConnectButton/index.tsx   |   75 +
 .../chat/MessageInput/MessageInput.tsx        |  284 ++-
 .../chat/MessageInput/VerificationFailed.tsx  |  107 +
 .../chat/ProfileHeader/AddWalletContent.tsx   |  355 +++
 .../src/lib/components/chat/exportedTypes.ts  |    4 +
 .../src/lib/components/chat/helpers/Modal.tsx |    4 +-
 .../lib/components/chat/helpers/NewToast.tsx  |    4 +-
 .../src/lib/components/chat/helpers/index.ts  |    6 +-
 .../src/lib/components/chat/theme/index.ts    |  295 ++-
 packages/uiweb/src/lib/config/constants.ts    |    3 +
 packages/uiweb/src/lib/context/chatContext.ts |    8 +-
 .../lib/dataProviders/ChatDataProvider.tsx    |   40 +-
 packages/uiweb/src/lib/helpers/address.ts     |    9 +
 .../src/lib/helpers/chat/localStorage.ts      |    9 +
 packages/uiweb/src/lib/hooks/chat/index.ts    |    2 -
 .../uiweb/src/lib/hooks/chat/useFetchChat.ts  |    2 +-
 .../src/lib/hooks/chat/usePushChatSocket.ts   |    2 +-
 .../src/lib/hooks/chat/usePushSendMessage.ts  |   11 +-
 .../lib/hooks/chat/useVerifyAccessControl.ts  |   65 +
 packages/uiweb/src/lib/hooks/index.ts         |    3 +-
 .../chat/helpers => hooks}/useMediaQuery.ts   |    0
 packages/uiweb/src/lib/icons/ArrowLeft.svg    |    4 -
 packages/uiweb/src/lib/icons/Emoji.tsx        |    4 +-
 packages/uiweb/src/lib/icons/OpenLink.tsx     |   16 +
 packages/uiweb/src/lib/types/index.ts         |    6 +-
 packages/uiweb/yarn.lock                      | 2081 +++++++++++++++-
 50 files changed, 6212 insertions(+), 729 deletions(-)
 create mode 100644 packages/uiweb/src/lib/components/chat/ConnectButton/index.css
 delete mode 100644 packages/uiweb/src/lib/components/chat/ConnectButton/index.ts
 create mode 100644 packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx
 create mode 100644 packages/uiweb/src/lib/components/chat/MessageInput/VerificationFailed.tsx
 create mode 100644 packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx
 create mode 100644 packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts
 rename packages/uiweb/src/lib/{components/chat/helpers => hooks}/useMediaQuery.ts (100%)
 delete mode 100644 packages/uiweb/src/lib/icons/ArrowLeft.svg
 create mode 100644 packages/uiweb/src/lib/icons/OpenLink.tsx

diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx
index 4f273a383..c37604b2e 100644
--- a/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx
+++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx
@@ -106,7 +106,26 @@ const CreateGroupTest = () => {
         signer: librarySigner,
         env,
         meta: meta,
-        rules: rules ? JSON.parse(rules) as Rules : undefined
+        rules: {
+          'chatAccess': {
+            'conditions': [
+              {
+                'all': [
+                  {
+                    'type': PushAPI.ConditionType.PUSH,
+                    'category': 'ERC20',
+                    'subcategory': 'holder',
+                    'data': {
+                      'contract': 'eip155:5:0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33',
+                      'amount': 1,
+                      'decimals': 18
+                    }
+                  }
+                ]
+              }
+            ]
+          }
+        }
       });
 
       setSendResponse(response);
diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx
index 7dd92f1ff..06cdb3837 100644
--- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx
+++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatUITest.tsx
@@ -38,6 +38,7 @@ const ChatUITest = () => {
           
             CHAT VIEW COMPONENT
           
+       
         
       
diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx index d9d184845..16cd126ad 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewBubble.tsx @@ -26,7 +26,7 @@ export const ChatViewBubbles = () => { const ConversationHash = await PUSHAPI.chat.conversationHash({ account: `eip155:${account}`, - conversationId: '831b1d93f36fa2fce6c3d8c7c41c53335c82ad13cbe05478579af235f10716dc', + conversationId: '196f58cbe07c7eb5716d939e0a3be1f15b22b2334d5179c601566600016860ac', env: env }); setConversationHash(ConversationHash.threadHash); diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index bf1273fa6..0f7dae1ef 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -4,10 +4,11 @@ import { Section } from '../components/StyledComponents'; import { ChatViewComponent } from '@pushprotocol/uiweb'; - const ChatViewComponentTest = () => { - - + const chatFilterList = [ + 'bafyreidesy6f4iu34eqccmqh55g35wu36lvlz42c63ivtmgjjhezlzdqta', + 'bafyreig3gs4tpwxumiz5fxypyt4omlxhvrvuj66kfoyioeshawlau6lgem', + ]; return (
@@ -16,7 +17,7 @@ const ChatViewComponentTest = () => { {/* */} - + console.log("BOIIII RETURNNNSSSSS")} chatId='c4828a375fd261577927a9d73fe3fa30204c6667a3adbc345e010eccf5ec740e' limit={10}/>
); @@ -24,7 +25,6 @@ const ChatViewComponentTest = () => { export default ChatViewComponentTest; - const ChatViewComponentCard = styled(Section)` -height:60vh; -`; \ No newline at end of file + height: 60vh; +`; diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx index 28eec588d..ea12b0819 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx @@ -22,10 +22,10 @@ const ChatViewListTest = () => { {/* */} - + - +
); }; diff --git a/packages/examples/sdk-frontend-react/src/app/SpaceTest/CreateSpaceTest.tsx b/packages/examples/sdk-frontend-react/src/app/SpaceTest/CreateSpaceTest.tsx index 889a97b65..925f516bb 100644 --- a/packages/examples/sdk-frontend-react/src/app/SpaceTest/CreateSpaceTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/SpaceTest/CreateSpaceTest.tsx @@ -107,7 +107,7 @@ const CreateSpaceTest = () => { numberOfERC20 != null ? Number(numberOfERC20) : undefined, signer: librarySigner, env, - meta: meta, + // meta: meta, scheduleAt: new Date(scheduleAt), scheduleEnd: scheduleEnd ? new Date(scheduleEnd) : null, }); diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index ba2047406..7f014cb07 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -2,7 +2,7 @@ import { useContext, useEffect, useMemo, useState } from 'react'; import styled from 'styled-components'; import { Route, Routes, Link } from 'react-router-dom'; import { useWeb3React } from '@web3-react/core'; -import ConnectButton from './components/Connect'; +import ConnectButtonComp from './components/Connect'; import { Checkbox } from './components/Checkbox'; import Dropdown from './components/Dropdown'; import { @@ -85,6 +85,7 @@ import { ChatViewBubbles } from './ChatUITest/ChatViewBubble'; import ChatViewComponentTest from './ChatUITest/ChatViewComponent'; import { lightChatTheme } from '@pushprotocol/uiweb'; + window.Buffer = window.Buffer || Buffer; interface Web3ReactState { @@ -214,8 +215,9 @@ const checkForWeb3Data = ({ export function App() { const { account, library, active, chainId } = useWeb3React(); - const [env, setEnv] = useState(ENV.PROD); + const [env, setEnv] = useState(ENV.STAGING); const [isCAIP, setIsCAIP] = useState(false); + const [signer, setSigner] = useState(); const { SpaceWidgetComponent } = useSpaceComponents(); const [spaceId, setSpaceId] = useState(''); @@ -243,6 +245,7 @@ export function App() { const user = await PushAPI.user.get({ account: account, env }); let pgpPrivateKey; const librarySigner = await library.getSigner(account); + setSigner(librarySigner); if (user?.encryptedPrivateKey) { pgpPrivateKey = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, @@ -255,7 +258,6 @@ export function App() { setPgpPrivateKey(pgpPrivateKey); })(); }, [account, env, library]); - const spaceUI = useMemo( () => new SpacesUI({ @@ -274,7 +276,7 @@ export function App() {

SDK Demo React App

- + } /> - } diff --git a/packages/examples/sdk-frontend-react/src/app/components/Connect.tsx b/packages/examples/sdk-frontend-react/src/app/components/Connect.tsx index 53ce68f1c..1041ea25b 100644 --- a/packages/examples/sdk-frontend-react/src/app/components/Connect.tsx +++ b/packages/examples/sdk-frontend-react/src/app/components/Connect.tsx @@ -65,7 +65,7 @@ const Disconnect = styled(StyledButton)` background: rgb(226, 8, 128); `; -const ConnectButton = () => { +const ConnectButtonComp = () => { const { active, account, activate, deactivate, chainId } = useWeb3React(); async function connect() { @@ -119,4 +119,4 @@ const ConnectButton = () => { ); }; -export default ConnectButton; +export default ConnectButtonComp; diff --git a/packages/examples/sdk-frontend/pages/index.tsx b/packages/examples/sdk-frontend/pages/index.tsx index e95310d1b..936704b2c 100644 --- a/packages/examples/sdk-frontend/pages/index.tsx +++ b/packages/examples/sdk-frontend/pages/index.tsx @@ -1,4 +1,4 @@ -import { ConnectButton } from '@rainbow-me/rainbowkit'; +import { ConnectButtonComp } from '@rainbow-me/rainbowkit'; import { NextPage } from 'next'; import Link from 'next/link'; import styled from 'styled-components'; @@ -7,7 +7,7 @@ const Index: NextPage = () => { return (

Hello Next.js 👋

- + diff --git a/packages/examples/sdk-frontend/pages/video.tsx b/packages/examples/sdk-frontend/pages/video.tsx index 05291f1d8..a44a90ac3 100644 --- a/packages/examples/sdk-frontend/pages/video.tsx +++ b/packages/examples/sdk-frontend/pages/video.tsx @@ -243,7 +243,7 @@ const Home: NextPage = () => { Video Call Status: {data.incoming[0].status} - + {isConnected ? ( diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 6e241d819..002660876 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -327,6 +327,7 @@ export type ConditionBase = { subcategory?: string; data?: Data; access?: boolean; + }; export type Condition = ConditionBase & { diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index b58d54013..bc200180b 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -596,6 +596,11 @@ ansi-regex@^5.0.1: resolved "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz" integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== +ansi-styles@^2.2.1: + version "2.2.1" + resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz" + integrity sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA== + ansi-styles@^3.2.1: version "3.2.1" resolved "https://registry.npmjs.org/ansi-styles/-/ansi-styles-3.2.1.tgz" @@ -801,6 +806,17 @@ chai@^4.3.7: pathval "^1.1.1" type-detect "^4.0.5" +chalk@^1.0.0: + version "1.1.3" + resolved "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz" + integrity sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A== + dependencies: + ansi-styles "^2.2.1" + escape-string-regexp "^1.0.2" + has-ansi "^2.0.0" + strip-ansi "^3.0.0" + supports-color "^2.0.0" + chalk@^2.4.1: version "2.4.2" resolved "https://registry.npmjs.org/chalk/-/chalk-2.4.2.tgz" @@ -1019,6 +1035,11 @@ dotignore@^0.1.2: dependencies: minimatch "^3.0.4" +duplexer@^0.1.1: + version "0.1.2" + resolved "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz" + integrity sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg== + elliptic@6.5.4: version "6.5.4" resolved "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz" @@ -1137,7 +1158,7 @@ escape-string-regexp@4.0.0: resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz" integrity sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA== -escape-string-regexp@^1.0.5: +escape-string-regexp@^1.0.2, escape-string-regexp@^1.0.5: version "1.0.5" resolved "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-1.0.5.tgz" integrity sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg== @@ -1209,6 +1230,14 @@ execa@^1.0.0: signal-exit "^3.0.0" strip-eof "^1.0.0" +figures@^1.4.0: + version "1.7.0" + resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" + integrity sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ== + dependencies: + escape-string-regexp "^1.0.5" + object-assign "^4.1.0" + fill-range@^7.0.1: version "7.0.1" resolved "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz" @@ -1373,6 +1402,13 @@ graceful-fs@^4.2.4: resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== +has-ansi@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" + integrity sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg== + dependencies: + ansi-regex "^2.0.0" + has-bigints@^1.0.1, has-bigints@^1.0.2: version "1.0.2" resolved "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz" @@ -1472,7 +1508,7 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.1: +inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.1, inherits@~2.0.3: version "2.0.4" resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -1554,6 +1590,11 @@ is-extglob@^2.1.1: resolved "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz" integrity sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ== +is-finite@^1.0.1: + version "1.1.0" + resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.1.0.tgz#904135c77fb42c0641d6aa1bcdbc4daa8da082f3" + integrity sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w== + is-fullwidth-code-point@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-1.0.0.tgz" @@ -1815,6 +1856,11 @@ lodash.uniqby@4.5.0: lodash._baseiteratee "~4.7.0" lodash._baseuniq "~4.6.0" +lodash@^4.17.10: + version "4.17.21" + resolved "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz" + integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== + log-symbols@4.1.0: version "4.1.0" resolved "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz" @@ -1976,6 +2022,11 @@ number-is-nan@^1.0.0: resolved "https://registry.npmjs.org/number-is-nan/-/number-is-nan-1.0.1.tgz" integrity sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ== +object-assign@^4.1.0: + version "4.1.1" + resolved "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz" + integrity sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg== + object-inspect@^1.12.3, object-inspect@^1.9.0: version "1.12.3" resolved "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz" @@ -2075,6 +2126,11 @@ p-try@^1.0.0: resolved "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz" integrity sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww== +parse-ms@^1.0.0: + version "1.0.1" + resolved "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz" + integrity sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg== + path-exists@^3.0.0: version "3.0.0" resolved "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz" @@ -2110,11 +2166,30 @@ picomatch@^2.0.4, picomatch@^2.2.1: resolved "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz" integrity sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA== +plur@^1.0.0: + version "1.0.0" + resolved "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz" + integrity sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw== + +pretty-ms@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz" + integrity sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg== + dependencies: + is-finite "^1.0.1" + parse-ms "^1.0.0" + plur "^1.0.0" + process-nextick-args@~1.0.6: version "1.0.7" resolved "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz" integrity sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw== +process-nextick-args@~2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz" + integrity sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag== + proper-lockfile@^4.1.2: version "4.1.2" resolved "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz" @@ -2176,6 +2251,19 @@ readable-stream@^3.6.0: string_decoder "^1.1.1" util-deprecate "^1.0.1" +readable-stream@~2.3.6: + version "2.3.8" + resolved "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz" + integrity sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA== + 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" + readdirp@~3.6.0: version "3.6.0" resolved "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz" @@ -2192,6 +2280,11 @@ regexp.prototype.flags@^1.5.0: define-properties "^1.2.0" functions-have-names "^1.2.3" +repeat-string@^1.5.2: + version "1.6.1" + resolved "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz" + integrity sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w== + require-directory@^2.1.1: version "2.1.1" resolved "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz" @@ -2236,7 +2329,7 @@ safe-buffer@^5.1.0, safe-buffer@~5.2.0: resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== -safe-buffer@~5.1.0: +safe-buffer@~5.1.0, safe-buffer@~5.1.1: version "5.1.2" resolved "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz" integrity sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g== @@ -2397,6 +2490,13 @@ string_decoder@~1.0.0: dependencies: safe-buffer "~5.1.0" +string_decoder@~1.1.1: + version "1.1.1" + resolved "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz" + integrity sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg== + dependencies: + safe-buffer "~5.1.0" + strip-ansi@^3.0.0, strip-ansi@^3.0.1: version "3.0.1" resolved "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz" @@ -2442,6 +2542,11 @@ supports-color@8.1.1: dependencies: has-flag "^4.0.0" +supports-color@^2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz" + integrity sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g== + supports-color@^5.3.0: version "5.5.0" resolved "https://registry.npmjs.org/supports-color/-/supports-color-5.5.0.tgz" @@ -2461,6 +2566,16 @@ supports-preserve-symlinks-flag@^1.0.0: resolved "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz" integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w== +tap-out@^2.1.0: + version "2.1.0" + resolved "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz" + integrity sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw== + dependencies: + re-emitter "1.1.3" + readable-stream "2.2.9" + split "1.0.0" + trim "0.0.1" + tap-spec@^5.0.0: version "5.0.0" resolved "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz" @@ -2502,6 +2617,19 @@ tape@^5.5.3: resolve "^2.0.0-next.4" string.prototype.trim "^1.2.7" +through2@^2.0.0: + version "2.0.5" + resolved "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz" + integrity sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ== + dependencies: + readable-stream "~2.3.6" + xtend "~4.0.1" + +through@2: + version "2.3.8" + resolved "https://registry.npmjs.org/through/-/through-2.3.8.tgz" + integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== + to-regex-range@^5.0.1: version "5.0.1" resolved "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz" @@ -2737,6 +2865,11 @@ ws@7.4.6: resolved "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz" integrity sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A== +xtend@~4.0.1: + version "4.0.2" + resolved "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz" + integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== + y18n@^3.2.1: version "3.2.2" resolved "https://registry.npmjs.org/y18n/-/y18n-3.2.2.tgz" diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 7e3eea05b..54792d089 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -7,6 +7,7 @@ "dependencies": { "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", + "@rainbow-me/rainbowkit": "^1.0.8", "@unstoppabledomains/resolution": "^8.5.0", "@web3-react/injected-connector": "^6.0.7", "date-fns": "^2.28.0", @@ -17,7 +18,8 @@ "moment": "^2.29.4", "react-icons": "^4.10.1", "react-toastify": "^9.1.3", - "react-twitter-embed": "^4.0.4" + "react-twitter-embed": "^4.0.4", + "wagmi": "^1.3.10" }, "peerDependencies": { "@pushprotocol/restapi": "^1.2.15", diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx index 0ba4639b9..f2a00f5e4 100644 --- a/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/AddWalletContent.tsx @@ -8,7 +8,7 @@ import * as PushAPI from '@pushprotocol/restapi'; import { ethers } from "ethers"; import { addWalletValidation } from "../helpers/helper"; import ArrowGreyIcon from '../../../icons/CaretDownGrey.svg' -import ArrowLeftIcon from '../../../icons/ArrowLeft.svg'; +// import ArrowLeftIcon from '../../../icons/ArrowLeft.svg'; import CloseIcon from '../../../icons/close.svg'; import { Spinner } from "../../supportChat/spinner/Spinner"; import { MoreLightIcon } from '../../../icons/MoreLight'; @@ -18,7 +18,7 @@ import { Section, Span, Image } from "../../reusables/sharedStyling"; import { AddUserDarkIcon } from '../../../icons/Adddark'; import { device } from "../../../config"; import { MemberListContainer } from "./MemberListContainer"; -import useMediaQuery from "../helpers/useMediaQuery"; +import useMediaQuery from "../../../hooks/useMediaQuery"; import useToast from "../helpers/NewToast"; import { MdCheckCircle, MdError } from "react-icons/md"; import { Modal } from "../helpers/Modal"; @@ -171,7 +171,7 @@ export const AddWalletContent = ({ onSubmit, handlePrevious, onClose, memberList
- handlePrevious()} cursor='pointer' /> + {/* handlePrevious()} cursor='pointer' /> */} Add Wallets diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx index 4949a44b6..9aab95552 100644 --- a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx @@ -23,7 +23,7 @@ import { ethers } from "ethers"; import { IChatProfile, IToast, OptionProps } from "../exportedTypes"; import { InfuraAPIKey, allowedNetworks, device } from "../../../config"; import Toast from "../helpers/Toast"; -import useMediaQuery from "../helpers/useMediaQuery"; +import useMediaQuery from "../../../hooks/useMediaQuery"; import { createBlockie } from "../../space/helpers/blockies"; // import { NewToast } from "../helpers/NewToast"; import { ToastContainer, toast } from 'react-toastify'; @@ -136,12 +136,12 @@ export const ChatProfile: React.FC = ({ chatId, style }: {chatId: {chatInfo || groupInfo ? ( + ?.toString()} height="48px" maxHeight="48px" width='48px' borderRadius="100%" /> ) : ()} + ?.toString()} height="48px" maxHeight="48px" width='48px' borderRadius="100%" />)} - + {isGroup ? groupInfo?.groupName : ensName ? `${ensName} (${isMobile ? shortenText(chatInfo?.did?.split(':')[1] ?? '', 4, true) : chatId})`: chatInfo ? shortenText(chatInfo.did?.split(':')[1] ?? '', 6, true) : shortenText(chatId,6, true)} @@ -175,8 +175,9 @@ export const ChatProfile: React.FC = ({ chatId, style }: {chatId: const Container = styled.div` width: 100%; - background: ${(props) => props.theme.bgColorPrimary}; - border-radius: 32px; + background: ${(props) => props.theme.backgroundColor.chatProfileBackground}; + border:${(props) => props.theme.border?.chatProfile}; + border-radius:${(props) => props.theme.borderRadius?.chatProfile}; display: flex; flex-direction: row; align-items: center; @@ -204,7 +205,7 @@ const DropDownBar = styled.div` min-width: 140px; color: rgb(101, 119, 149); border: ${(props) => `1px solid ${props.theme.defaultBorder}`}; - background: ${(props) => props.theme.bgColorPrimary}; + background: ${(props) => props.theme.backgroundColor.chatReceivedBubbleBackground}; z-index: 10; border-radius: 16px; `; diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx index c5a03ca8b..e13eefb3f 100644 --- a/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx @@ -21,7 +21,7 @@ import { AddWalletContent } from './AddWalletContent' import ArrowIcon from '../../../icons/CaretDown.svg' import { Modal } from "../helpers/Modal"; import { device } from "../../../config"; -import useMediaQuery from "../helpers/useMediaQuery"; +import useMediaQuery from "../../../hooks/useMediaQuery"; import useToast from "../helpers/NewToast"; import { MdCheckCircle, MdError } from "react-icons/md"; @@ -400,7 +400,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo
- Group Info + Group Info onClose()} cursor='pointer' />
@@ -409,7 +409,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo
- {groupInfo?.groupName} + {groupInfo?.groupName} {groupInfo?.members?.length} Members
@@ -423,7 +423,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo
- {groupInfo?.isPublic ? 'Public' : 'Private'} + {groupInfo?.isPublic ? 'Public' : 'Private'} {groupInfo?.isPublic ? 'Chats are not encrypted' : 'Chats are encrypted'}
@@ -435,7 +435,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo { - const { account } = useContext(ChatDataContext) - const theme = useContext(ThemeContext) - return ( - <> - {chat.fromCAIP10.split(":")[1] !== account && ( - {chat.fromDID.split(":")[1].slice(0, 6)}... - {chat.fromDID.split(":")[1].slice(-6)} - )} - - ) -} + const { account } = useContext(ChatDataContext); + const theme = useContext(ThemeContext); + return ( + <> + {chat.fromCAIP10.split(':')[1] !== account && ( + + {chat.fromDID.split(':')[1].slice(0, 6)}... + {chat.fromDID.split(':')[1].slice(-6)} + + )} + + ); +}; const SenderMessafeProfilePicture = ({ chat }: { chat: IMessagePayload }) => { - const { account, env } = useContext(ChatDataContext) - const [pfp, setPfp] = useState("") - const getUserPfp = async () => { - const pfp = await getPfp({ account: chat.fromCAIP10.split(":")[1], env: env }) - if (pfp) { - setPfp(pfp) - } + const { account, env } = useContext(ChatDataContext); + const [pfp, setPfp] = useState(''); + const getUserPfp = async () => { + const pfp = await getPfp({ + account: chat.fromCAIP10.split(':')[1], + env: env, + }); + if (pfp) { + setPfp(pfp); } - useEffect(() => { - getUserPfp() - }, [account, chat.fromCAIP10]) - return ( -
- {chat.fromCAIP10.split(":")[1] !== account && ( -
- {pfp && profile picture} -
- )} + }; + useEffect(() => { + getUserPfp(); + }, [account, chat.fromCAIP10]); + return ( +
+ {chat.fromCAIP10.split(':')[1] !== account && ( +
+ {pfp && ( + profile picture + )}
- ) -} + )} +
+ ); +}; const MessageCard = ({ - chat, - position, - isGroup, + chat, + position, + isGroup, }: { - chat: IMessagePayload; - position: number; - isGroup: boolean; + chat: IMessagePayload; + position: number; + isGroup: boolean; }) => { - const theme = useContext(ThemeContext) - const time = moment(chat.timestamp).format('hh:mm a'); - return ( -
- {isGroup && - - } -
- {isGroup && - + const theme = useContext(ThemeContext); + const time = moment(chat.timestamp).format('hh:mm a'); + return ( +
+ {isGroup && } +
+ {isGroup && } +
+ {' '} +
+ {chat.messageContent.split('\n').map((str) => ( + - {' '} -
- {chat.messageContent.split('\n').map((str) => ( - - {str} - - ))} -
- - {time} - -
-
+ fontWeight={ + position + ? `${theme.fontWeight?.chatSentBubbleText}` + : `${theme.fontWeight?.chatReceivedBubbleText}` + } + color={ + position + ? `${theme.textColor?.chatSentBubbleText}` + : `${theme.textColor?.chatReceivedBubbleText}` + } + > + {str} + + ))} +
+ + {time} +
- ); +
+
+ ); }; const FileCard = ({ - chat, - isGroup, + chat, + isGroup, }: { - chat: IMessagePayload; - position: number; - isGroup: boolean; + chat: IMessagePayload; + position: number; + isGroup: boolean; }) => { - const fileContent: FileMessageContent = JSON.parse(chat.messageContent); - const name = fileContent.name; + const fileContent: FileMessageContent = JSON.parse(chat.messageContent); + const name = fileContent.name; - const content = fileContent.content as string; - const size = fileContent.size; + const content = fileContent.content as string; + const size = fileContent.size; - return ( -
- {isGroup && - - } -
- {isGroup && - - } -
- extension icon -
- - {shortenText(name, 11)} - - - {formatFileSize(size)} - -
- - -
-
+ return ( +
+ {isGroup && } +
+ {isGroup && } +
+ extension icon +
+ + {shortenText(name, 11)} + + + {formatFileSize(size)} + +
+ +
- ); +
+
+ ); }; const ImageCard = ({ - chat, - position, - isGroup, + chat, + position, + isGroup, }: { - chat: IMessagePayload; - position: number; - isGroup: boolean; + chat: IMessagePayload; + position: number; + isGroup: boolean; }) => { - - return ( -
- {isGroup && - + return ( +
+ {isGroup && } +
+ {isGroup && } +
+ - {isGroup && ( - - )} -
- -
-
+ />
- ); +
+
+ ); }; const GIFCard = ({ - chat, - position, - isGroup, + chat, + position, + isGroup, }: { - chat: IMessagePayload; - position: number; - isGroup: boolean; + chat: IMessagePayload; + position: number; + isGroup: boolean; }) => { - return ( -
- {isGroup && - + return ( +
+ {isGroup && } +
+ {isGroup && } +
+ - {isGroup && - - } -
- -
-
+ />
- ); +
+
+ ); }; -const TwitterCard = ({ chat, tweetId, isGroup, position }: { chat: IMessagePayload, tweetId: string, isGroup: boolean, position: number }) => { - return ( -
- {isGroup && - - } -
- {isGroup && - - } -
- -
-
+const TwitterCard = ({ + chat, + tweetId, + isGroup, + position, +}: { + chat: IMessagePayload; + tweetId: string; + isGroup: boolean; + position: number; +}) => { + return ( +
+ {isGroup && } +
+ {isGroup && } +
+
- ) -} +
+
+ ); +}; export const ChatViewBubble = ({ chat }: { chat: IMessagePayload }) => { - const { account, setAccount, pgpPrivateKey, setPgpPrivateKey, env, setEnv } = useChatData(); - const position = pCAIP10ToWallet(chat.fromDID).toLowerCase() !== account?.toLowerCase() ? 0 : 1; - const { tweetId, messageType }: TwitterFeedReturnType = checkTwitterUrl({ message: chat?.messageContent }); - const [isGroup, setIsGroup] = useState(false); - useEffect(() => { - if (chat.toDID.split(':')[0] === 'eip155') { - if (isGroup) { - setIsGroup(false); - } - } else { - if (!isGroup) { - setIsGroup(true); - } - } - }, [chat.toDID, isGroup]) - - // useEffect(() => { - // setAccount(""); - // setPgpPrivateKey(""); - // setEnv(env); - // }, [account, env, pgpPrivateKey]) - - if (messageType === 'TwitterFeedLink') { - chat.messageType = 'TwitterFeedLink'; + const { account, setAccount, pgpPrivateKey, setPgpPrivateKey, env, setEnv } = + useChatData(); + const position = + pCAIP10ToWallet(chat.fromDID).toLowerCase() !== account?.toLowerCase() + ? 0 + : 1; + const { tweetId, messageType }: TwitterFeedReturnType = checkTwitterUrl({ + message: chat?.messageContent, + }); + const [isGroup, setIsGroup] = useState(false); + useEffect(() => { + if (chat.toDID.split(':')[0] === 'eip155') { + if (isGroup) { + setIsGroup(false); + } + } else { + if (!isGroup) { + setIsGroup(true); + } } + }, [chat.toDID, isGroup]); - if (chat.messageType === 'GIF') { - return - } - if (chat.messageType === 'Image') { - return ; - } - if (chat.messageType === 'File') { - return ; - } - if (chat.messageType === 'TwitterFeedLink') { - return ; - } - return ; -} + // useEffect(() => { + // setAccount(""); + // setPgpPrivateKey(""); + // setEnv(env); + // }, [account, env, pgpPrivateKey]) + if (messageType === 'TwitterFeedLink') { + chat.messageType = 'TwitterFeedLink'; + } + + if (chat.messageType === 'GIF') { + return ; + } + if (chat.messageType === 'Image') { + return ; + } + if (chat.messageType === 'File') { + return ; + } + if (chat.messageType === 'TwitterFeedLink') { + return ( + + ); + } + return ; +}; const FileDownloadIcon = styled.i` color: #575757; @@ -322,4 +404,4 @@ const FileDownloadIcon = styled.i` const FileDownloadIconAnchor = styled.a` font-size: 20px; -`; \ No newline at end of file +`; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx index 846112317..a8df6d6c9 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -1,22 +1,35 @@ import React, { useContext} from 'react'; -import { IChatViewComponentProps } from '../exportedTypes'; +import { IChatTheme, IChatViewComponentProps } from '../exportedTypes'; import { Section, } from '../../reusables'; import { ChatViewList } from '../ChatViewList'; -import { chatLimit } from '../../../config'; +import { chatLimit, device } from '../../../config'; import { ThemeContext } from '../theme/ThemeProvider'; import { useChatData } from '../../../hooks/chat/useChatData'; import { MessageInput } from '../MessageInput'; import { ChatProfile } from '../ChatProfile'; +import styled from 'styled-components'; +import useMediaQuery from '../../../hooks/useMediaQuery'; + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; +} + + export const ChatViewComponent: React.FC = ( options: IChatViewComponentProps ) => { const { chatId, + chatFilterList = [], messageInput = true, chatViewList = true, chatProfile = true, @@ -25,6 +38,7 @@ export const ChatViewComponent: React.FC = ( file = true, gif = true, isConnected = true, + onClick, } = options || {}; const {env } = useChatData(); @@ -35,39 +49,35 @@ export const ChatViewComponent: React.FC = ( const theme = useContext(ThemeContext); - - - - - - + const isMobile = useMediaQuery(device.mobileL); return ( -
{chatProfile && }
- {chatId && chatViewList && } + {chatId && chatViewList && }
@@ -75,12 +85,16 @@ export const ChatViewComponent: React.FC = ( {messageInput && (
- +
)} -
+ ); }; //styles - +const Conatiner = styled(Section)` +border:${(props) => props.theme.border?.chatViewComponent}; +backdrop-filter:${(props) => props.theme.backdropFilter}; +box-sizing:border-box; +`; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx index afdc1724a..2c12bd7e3 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx @@ -56,9 +56,9 @@ export const ApproveRequestBubble = ({ }; return (
{chatFeed?.groupInformation @@ -103,9 +103,9 @@ const Button = styled.button` border: none; cursor: pointer; border-radius: 8px; - background: ${(props) => props.theme.accentBgColor}; + background: ${(props) => props.theme.backgroundColor.buttonBackground}; border: none; - color: white; + color: ${(props) => props.theme.textColor.buttonText}; width: 100%; font-size: 16px; font-weight: 600; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx index 220aef905..f60e19f05 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -2,7 +2,11 @@ import React, { useContext, useEffect, useRef, useState } from 'react'; import { ChatDataContext } from '../../../context'; import { IChatViewListProps } from '../exportedTypes'; import { chatLimit } from '../../../config'; -import { IFeeds, IMessageIPFS } from '@pushprotocol/restapi'; +import { + IFeeds, + IMessageIPFS, + IMessageIPFSWithCID, +} from '@pushprotocol/restapi'; import useFetchHistoryMessages from '../../../hooks/chat/useFetchHistoryMessages'; import styled from 'styled-components'; import { Div, Section, Span, Spinner } from '../../reusables'; @@ -35,6 +39,7 @@ import { ApproveRequestBubble } from './ApproveRequestBubble'; */ interface IThemeProps { theme?: IChatTheme; + blur: boolean; } const ChatStatus = { FIRST_CHAT: `This is your first conversation with recipient.\n Start the conversation by sending a message.`, @@ -44,14 +49,15 @@ const ChatStatus = { export const ChatViewList: React.FC = ( options: IChatViewListProps ) => { - const { chatId, limit = chatLimit } = options || {}; + const { chatId, limit = chatLimit, chatFilterList = [] } = options || {}; const { pgpPrivateKey, account } = useChatData(); const [chatFeed, setChatFeed] = useState({} as IFeeds); const [chatStatusText, setChatStatusText] = useState(''); const [messages, setMessages] = useState(); - const [ loading,setLoading] = useState(true); + const [loading, setLoading] = useState(true); const [conversationHash, setConversationHash] = useState(); - const { historyMessages, loading:messageLoading } = useFetchHistoryMessages(); + const { historyMessages, loading: messageLoading } = + useFetchHistoryMessages(); const listInnerRef = useRef(null); const bottomRef = useRef(null); const { fetchChat } = useFetchChat(); @@ -76,6 +82,7 @@ export const ChatViewList: React.FC = ( useEffect(() => { (async () => { + if (!account && !env) return; const chat = await fetchChat({ chatId }); if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); else { @@ -98,12 +105,10 @@ export const ChatViewList: React.FC = ( if (!newChatFeed?.groupInformation) { setChatStatusText(ChatStatus.FIRST_CHAT); } - console.log(chatFeed) setChatFeed(newChatFeed); } else { setChatStatusText(ChatStatus.INVALID_CHAT); } - } setLoading(false); })(); @@ -112,10 +117,13 @@ export const ChatViewList: React.FC = ( useEffect(() => { if (checkIfSameChat(messagesSinceLastConnection, account!, chatId)) { if (!Object.keys(messages || {}).length) { - setMessages({ - messages: [messagesSinceLastConnection], - lastThreadHash: messagesSinceLastConnection.cid, - }); + setFilteredMessages([ + messagesSinceLastConnection, + ] as IMessageIPFSWithCID[]); + // setMessages({ + // messages: [messagesSinceLastConnection], + // lastThreadHash: messagesSinceLastConnection.cid, + // }); setConversationHash(messagesSinceLastConnection.cid); } else { const newChatViewList = appendUniqueMessages( @@ -123,10 +131,11 @@ export const ChatViewList: React.FC = ( [messagesSinceLastConnection], false ); - setMessages({ - messages: newChatViewList, - lastThreadHash: messages!.lastThreadHash, - }); + setFilteredMessages(newChatViewList as IMessageIPFSWithCID[]); + // setMessages({ + // messages: newChatViewList, + // lastThreadHash: messages!.lastThreadHash, + // }); } scrollToBottom(null); } @@ -134,6 +143,7 @@ export const ChatViewList: React.FC = ( useEffect(() => { (async function () { + if (!account && !env && !chatId) return; const hash = await fetchConversationHash({ conversationId: chatId }); setConversationHash(hash?.threadHash); })(); @@ -158,6 +168,7 @@ export const ChatViewList: React.FC = ( messages?.messages.length && messages?.messages.length <= limit ) { + setChatStatusText(''); scrollToBottom(null); } }, [messages]); @@ -230,15 +241,10 @@ export const ChatViewList: React.FC = ( chatHistory, true ); - setMessages({ - messages: newChatViewList, - lastThreadHash: chatHistory[0].link, - }); + + setFilteredMessages(newChatViewList as IMessageIPFSWithCID[]); } else { - setMessages({ - messages: chatHistory, - lastThreadHash: chatHistory[0].link, - }); + setFilteredMessages(chatHistory as IMessageIPFSWithCID[]); } } } @@ -249,15 +255,27 @@ export const ChatViewList: React.FC = ( dateNum: string; }; + const setFilteredMessages = (messageList: Array) => { + const updatedMessageList = messageList.filter( + (msg) => !chatFilterList.includes(msg.cid) + ); + + if (updatedMessageList && updatedMessageList.length) { + setMessages({ + messages: updatedMessageList, + lastThreadHash: updatedMessageList[0].link, + }); + } + }; const renderDate = ({ chat, dateNum }: RenderDataType) => { const timestampDate = dateToFromNowDaily(chat.timestamp as number); dates.add(dateNum); return ( {timestampDate} @@ -273,67 +291,87 @@ export const ChatViewList: React.FC = ( justifyContent="start" padding="0 2px" theme={theme} + blur={ + !!( + chatFeed && + chatFeed?.groupInformation && + !chatFeed?.groupInformation?.isPublic && + !pgpPrivateKey + ) + } onScroll={() => onScroll()} > - {loading ? : ''} - {!loading && - <> - {chatFeed && - (chatFeed.publicKey || - (chatFeed?.groupInformation && - !chatFeed?.groupInformation?.isPublic)) ? ( - - ) : ( - - )} + {loading ? : ''} + {!loading && ( + <> + {chatFeed && + (chatFeed.publicKey || + (chatFeed?.groupInformation && + !chatFeed?.groupInformation?.isPublic)) ? ( + + ) : ( + + )} - {chatStatusText && ( -
- - {chatStatusText} - -
- )} - {messageLoading ? : ''} + {chatStatusText && ( +
+ + {chatStatusText} + +
+ )} + {messageLoading ? : ''} - { - !messageLoading && - <> -
- {messages?.messages && - messages?.messages?.map((chat: IMessageIPFS, index: number) => { - const dateNum = moment(chat.timestamp).format('L'); - const position = - pCAIP10ToWallet(chat.fromDID).toLowerCase() !== - account?.toLowerCase() - ? 0 - : 1; - return ( - <> - {dates.has(dateNum) ? null : renderDate({ chat, dateNum })} -
- -
- - ); - })} -
-
- {chatFeed && checkIfIntent({ chat: chatFeed as IFeeds, account: account! }) && ( - + {!messageLoading && ( + <> +
+ {messages?.messages && + messages?.messages?.map( + (chat: IMessageIPFS, index: number) => { + const dateNum = moment(chat.timestamp).format('L'); + const position = + pCAIP10ToWallet(chat.fromDID).toLowerCase() !== + account?.toLowerCase() + ? 0 + : 1; + return ( + <> + {dates.has(dateNum) + ? null + : renderDate({ chat, dateNum })} +
+ +
+ + ); + } + )} +
+
+ {chatFeed && + account && + checkIfIntent({ + chat: chatFeed as IFeeds, + account: account!, + }) && ( + + )} + + )} + )} - - } - - } ); }; @@ -341,11 +379,18 @@ export const ChatViewList: React.FC = ( //styles const ChatViewListCard = styled(Section)` &::-webkit-scrollbar-thumb { - background: ${(props) => props.theme.accentBgColor}; + background: ${(props) => props.theme.scrollbarColor}; border-radius: 10px; } &::-webkit-scrollbar { width: 5px; } + ${({ blur }) => + blur && + ` + filter: blur(12px); + `} `; + +const Overlay = styled.div``; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx index d2519e6ed..cb6b4dc51 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx @@ -25,7 +25,7 @@ const EncryptionMessageContent = { padding="10px" alignSelf="center" borderRadius="12px" - background={theme.bgColorPrimary} + background={theme.backgroundColor?.encryptionMessageBackground} margin="10px 10px 0px" width={isMobile ? '80%' : 'fit-content'} > @@ -35,7 +35,7 @@ const EncryptionMessageContent = { diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx index d196b00b7..fc2e9c63f 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx @@ -1,174 +1,101 @@ -import React, { useContext, useEffect } from "react"; -import styled from "styled-components"; -import { InjectedConnector } from "@web3-react/injected-connector"; -import { useWeb3React } from "@web3-react/core"; -import { useChatData } from "../../../hooks"; -import * as PUSHAPI from "@pushprotocol/restapi" -import { Spinner } from "../../reusables"; -import { ThemeContext } from "../theme/ThemeProvider"; - -interface NwMappingType { - [key: number]: string; +import styled from 'styled-components'; +import { IChatTheme } from '../theme'; +import { useChatData } from '../../../hooks'; +import * as PushAPI from '@pushprotocol/restapi'; +import { useContext, useEffect } from 'react'; +import { ConnectButton } from '@rainbow-me/rainbowkit'; + +import './index.css'; + +import { useAccount } from 'wagmi'; + +import { useWalletClient } from 'wagmi'; +import { ThemeContext } from '../theme/ThemeProvider'; +import { device } from '../../../config'; + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; } - -const NETWORK_MAPPING: NwMappingType = { - 1: 'ETH_MAIN_NET', - 5: 'ETH_GOERLI', - 3: 'ETH_ROPSTEN', - 137: 'POLYGON_MAINNET', - 80001: 'POLYGON_MUMBAI', - 56: 'BSC_MAINNET', - 97: 'BSC_TESTNET', - 420: 'OPTIMISM_TESTNET', - 10: 'OPTIMISM_MAINNET', - 1442: 'POLYGON_ZK_EVM_TESTNET', - 1101: 'POLYGON_ZK_EVM_MAINNET', -}; - -const injected = new InjectedConnector({ - supportedChainIds: [1, 3, 4, 5, 42, 137, 80001, 56, 97, 10, 420, 1442, 1101], -}); - -const ConnectWrapper = styled.div` - display: flex; - align-items: center; - flex-direction: column; - margin: 20; - - & .account { - font-size: 1.2rem; - border: 1px solid green; - border-radius: 3px; - padding: 4px 7px; - font-weight: 500; - font-family: monospace; - } - - & .network { - margin: 5px 0; - } - `; - -const StyledButton = styled.button` - border: 0px; - outline: 0px; - padding: 24px 9px; - font-weight: 500; - margin: 10px; - border-radius: 12px; - font-size: 17px; - cursor: pointer; - width: 165px; - height: 44px; - text-align: start; - align-items: center; - display: flex; - justify-content: center; - `; - -const Connect = styled(StyledButton)` - color: rgb(255, 255, 255); - background: #D53A94; - `; - -const Disconnect = styled(StyledButton)` -display: flex; -padding: 9px 24px; -justify-content: center; -align-items: center; -gap: 10px; -background: var(--general-use-creamy-pink, #D53A94); -color: var(--general-use-white, #ffffff); - `; - -export const ConnectButton = () => { - const { active, activate, library } = useWeb3React(); - const { pgpPrivateKey, account, env, setPgpPrivateKey } = useChatData(); - const theme = useContext(ThemeContext); - - useEffect(() => { - if (active && account && env && library) { - const librarySigner = library.getSigner(); - - const connectBtn = async () => { - const user = await PUSHAPI.user.get({ account: account, env: env }); - if (!user) { - await createProfile(); - } - if (user?.encryptedPrivateKey && !pgpPrivateKey) { - const decryptPgpKey = await PUSHAPI.chat.decryptPGPKey({ - encryptedPGPPrivateKey: user.encryptedPrivateKey, - account: account, - signer: librarySigner, - env: env, - }); - setPgpPrivateKey(decryptPgpKey); - } - }; - - connectBtn(); - } - }, [active, account, env, library]); - - const createProfile = async () => { - if (!account || !env || !library) return; - - const librarySigner = library.getSigner(); - - const user = await PUSHAPI.user.create({ - signer: librarySigner, - env: env, - }); - - const createdUser = await PUSHAPI.user.get({ - account: account, - env: env, +export const ConnectButtonSub = () => { + const { + signer, + pgpPrivateKey, + account, + env, + setPgpPrivateKey, + setAccount, + setSigner, + } = useChatData(); + const { address } = useAccount(); + const { data: walletClient } = useWalletClient(); + const theme = useContext(ThemeContext); + + useEffect(() => { + (async () => { + console.log(account, signer); + if (!account) setAccount(address as string); + if (!signer) setSigner(walletClient as PushAPI.SignerType); + })(); + }, [address, walletClient]); + + useEffect(() => { + (async () => { + console.log(account); + if (account && signer) { + if (!pgpPrivateKey) await handleUserCreation(); + } + })(); + }, [account, signer]); + + const handleUserCreation = async () => { + if (!account && !env) return; + try { + let user = await PushAPI.user.get({ account: account!, env: env }); + if (!user) { + if (!signer) return; + user = await PushAPI.user.create({ + signer: signer, + env: env, }); - - const pvtKey = await PUSHAPI.chat.decryptPGPKey({ - encryptedPGPPrivateKey: createdUser.encryptedPrivateKey ? createdUser.encryptedPrivateKey : "", - signer: librarySigner, - env: env, - toUpgrade: true, + } + if (user?.encryptedPrivateKey && !pgpPrivateKey) { + const decryptPgpKey = await PushAPI.chat.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + account: account!, + signer: signer, + env: env, }); - - setPgpPrivateKey(pvtKey); - }; - - async function connect() { - try { - await activate(injected); - } catch (ex) { - console.log(ex); - } + setPgpPrivateKey(decryptPgpKey); + } + } catch (e: any) { + console.log(e); } + }; + return !signer ? ( + + + + ) : ( + <> + ); +}; - const connectWalletOnPageLoad = async () => { - if (!pgpPrivateKey && !account) { - try { - await activate(injected); - } catch (ex) { - console.log(ex); - } - } - }; - - useEffect(() => { - connectWalletOnPageLoad(); - }, [activate]); - - return ( - - {active ? ( - <> - - - - - ) : ( - Connect Wallet - )} - - ); -}; \ No newline at end of file +//styles +const ConnectButtonDiv = styled.div` + width: fit-content; + + button{ + background: ${(props) => `${props.theme.backgroundColor.buttonBackground}!important`}; + color: ${(props) => `${props.theme.backgroundColor.buttonText}!important`}; + text-align:center; + + } + @media ${device.mobileL} { + font-size: 12px; + } +`; diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.css b/packages/uiweb/src/lib/components/chat/ConnectButton/index.css new file mode 100644 index 000000000..d9edb6893 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.css @@ -0,0 +1,2131 @@ +/* @import '/packages/uiweb/node_modules/@rainbow-me/rainbowkit/dist/index.css'; */ +/* vanilla-extract-css-ns:src/css/reset.css.ts.vanilla.css?source=Lmlla2JjYzAgewogIGJvcmRlcjogMDsKICBib3gtc2l6aW5nOiBib3JkZXItYm94OwogIGZvbnQtc2l6ZTogMTAwJTsKICBsaW5lLWhlaWdodDogbm9ybWFsOwogIG1hcmdpbjogMDsKICBwYWRkaW5nOiAwOwogIHRleHQtYWxpZ246IGxlZnQ7CiAgdmVydGljYWwtYWxpZ246IGJhc2VsaW5lOwogIC13ZWJraXQtdGFwLWhpZ2hsaWdodC1jb2xvcjogdHJhbnNwYXJlbnQ7Cn0KLmlla2JjYzEgewogIGxpc3Qtc3R5bGU6IG5vbmU7Cn0KLmlla2JjYzIgewogIHF1b3Rlczogbm9uZTsKfQouaWVrYmNjMjpiZWZvcmUsIC5pZWtiY2MyOmFmdGVyIHsKICBjb250ZW50OiAnJzsKfQouaWVrYmNjMyB7CiAgYm9yZGVyLWNvbGxhcHNlOiBjb2xsYXBzZTsKICBib3JkZXItc3BhY2luZzogMDsKfQouaWVrYmNjNCB7CiAgYXBwZWFyYW5jZTogbm9uZTsKfQouaWVrYmNjNSB7CiAgb3V0bGluZTogbm9uZTsKfQouaWVrYmNjNTo6cGxhY2Vob2xkZXIgewogIG9wYWNpdHk6IDE7Cn0KLmlla2JjYzYgewogIGJhY2tncm91bmQtY29sb3I6IHRyYW5zcGFyZW50OwogIGNvbG9yOiBpbmhlcml0Owp9Ci5pZWtiY2M3OmRpc2FibGVkIHsKICBvcGFjaXR5OiAxOwp9Ci5pZWtiY2M3OjotbXMtZXhwYW5kIHsKICBkaXNwbGF5OiBub25lOwp9Ci5pZWtiY2M4OjotbXMtY2xlYXIgewogIGRpc3BsYXk6IG5vbmU7Cn0KLmlla2JjYzg6Oi13ZWJraXQtc2VhcmNoLWNhbmNlbC1idXR0b24gewogIC13ZWJraXQtYXBwZWFyYW5jZTogbm9uZTsKfQouaWVrYmNjOSB7CiAgYmFja2dyb3VuZDogbm9uZTsKICBjdXJzb3I6IHBvaW50ZXI7CiAgdGV4dC1hbGlnbjogbGVmdDsKfQouaWVrYmNjYSB7CiAgY29sb3I6IGluaGVyaXQ7CiAgdGV4dC1kZWNvcmF0aW9uOiBub25lOwp9 */ +[data-rk] .iekbcc0 { + border: 0; + box-sizing: border-box; + font-size: 100%; + line-height: normal; + margin: 0; + padding: 0; + text-align: left; + vertical-align: baseline; + -webkit-tap-highlight-color: transparent; +} +[data-rk] .iekbcc1 { + list-style: none; +} +[data-rk] .iekbcc2 { + quotes: none; +} +[data-rk] .iekbcc2:before, +[data-rk] .iekbcc2:after { + content: ""; +} +[data-rk] .iekbcc3 { + border-collapse: collapse; + border-spacing: 0; +} +[data-rk] .iekbcc4 { + -webkit-appearance: none; + -moz-appearance: none; + appearance: none; +} +[data-rk] .iekbcc5 { + outline: none; +} +[data-rk] .iekbcc5::-moz-placeholder { + opacity: 1; +} +[data-rk] .iekbcc5::placeholder { + opacity: 1; +} +[data-rk] .iekbcc6 { + background-color: transparent; + color: inherit; +} +[data-rk] .iekbcc7:disabled { + opacity: 1; +} +[data-rk] .iekbcc7::-ms-expand { + display: none; +} +[data-rk] .iekbcc8::-ms-clear { + display: none; +} +[data-rk] .iekbcc8::-webkit-search-cancel-button { + -webkit-appearance: none; +} +[data-rk] .iekbcc9 { + background: none; + cursor: pointer; + text-align: left; +} +[data-rk] .iekbcca { + color: inherit; + text-decoration: none; +} + +/* vanilla-extract-css-ns:src/css/sprinkles.css.ts.vanilla.css?source=#H4sIAAAAAAAAE6Vdy5LjxhG86yt4cYR0oIIECRAcX+yV7LAi7PDBivAZxIsYggAHAIfkOPTv5mMeqKzq7gJWpxUrK7uyu9BMoLHLn5+Pi2D1Opv874fJJCqLvJoWXbpvnyZZmZ6nbRc13Z9/+OOHnx84z4BLq6SHWnJUnFZd2vQwwR2TFO2hjC5Pk6qu0l40pNFNWce7Xjii4VsJvWhMo0VVFoQ87ZXXpmVm0JrJMCo1ZyCmdHuHbKJ4lzf1sUqmbfGWXnH1K4EVD1jdJGkzbaKkOF6nbX7oC3uWIAGB7ESWGcGUImZBMHsJ8xo1P06nze7+QTGN4q6oq2/Hrqurn3q5lSI3rqsqjTueXCuS92l15JkHTWadRGU/6UWb9K96U5RpP7WRUj3/Tz1IK0HW1//IXHd9VNtdymt3tHVZ9Pvs2MeciqTbPk3oqr4KCNo+JwHhEcRZQCwJ4nJHxMemrZunyaEuoNnf7vH7hZIUTXrvkKdJU596mPlMBMV1edxXfdz8gaurbppF+6K89Jbm9mk73dTJpb8mc+8r5XGZze8KJ5PbHjDdpkW+7a4fhkTUfMGyFoqsJctaKrJ8lhUIWR5d3HnAskIpiy7WfIVZD1pHVsiypNnwaBPP119Zp3fIcjbrIyKO8CliwxEBRcQcsaKIhCNCinjs/3l0uF5C/c+zr8/phTPPvyL0gplvvyJ0A50XXxGY3+eviE8ju68I3dbn5VcE+mnfqxqapuqFoO66F4LyDr0QVPHSC0EZTW+KoIy2F4Kxul4ICI+9mYXiX3shqPDUm3UY69ybXAhdvkJTWPrHhvZ5MZOgNyNBWqU3J0E6oueRIJXuLeiYwLukg9LJ9nwahWEDGoVxVyS6AOaQRqGqNY3CuBGN0kXzNnSmYNyYRoE5oVFQlJKoD7kZiQYwbg7zDOEtXaTZrP/F7xUkuo/ON8fTXa1hH/TYCJ6PbVdklw+AyXnvLGDqSb1ShjJn6u1lYHuI4nS6SbtTmva/kL3Kho/u7rYPf2wyXXrupneH/DQp04yIOjAEL/KFYYpqmzYFIXpsP/uoyYvq6gqu3nBPd3evlRBwPXcSBhr9KGHo3u+9ShhovpOEod8H3lnCwMVzkTBwGbyJ2mlDL2YiiKpfzEUQlbbwRBCte7EQQbTwxVJcECjcF0FQUyCCYLiVuLYwBaEIAnVrsQOgpkhcXgBtJBB8Sy3iPuh2kdHmXyQ8DgwpR4DujCNo2y9yjgAxW46gLb8oOAKm9pkjYBl3glromVKAgN69AAE5lQCBamsBAuUehKmHcl8ECNTSCBAYqBVWEER3AgQUHYVVhlpehUUEyIlDsKnJ7tc8vklJV18EAHC8CRAqeTkTILSxl3MBQvUsPQFCW3u5ECB0bpdLAUIXcelLomm7LAMJA7JXEgZEhRIGSl5LGKg5klYBat5IGKgnljAwViItJ2hPJQzoyqQ1h3pyaUUBsxUw0OlLsul1NdyYLp9ZGPJ3DACCSwaADt8zAMioGAC6u2YAmNADA8DKvXCZ0CMNR4DQliNASMcRUOiRI6DSVz7fUOmJI6COM0fAKBe+aKD2jSOoFn/G15XW4c/5ugHCYwjoX/9jZzvLDx79JcapDt/HOFQQYJzOlL9i48MAISuArpe/ZgAoIWIAqGGDALh/9mMGgCITBoAaUgaA1c7YPEINOQPAEFsGAJkFAuCm2n9GANxX+zu+FoAo2XLSu2t/jwD5Btt/37SubSv3ZY1xWJEDxkHrC8Zhsho2PgzQsgJgKjoGgBKODAA1vCIA+/LEAFDkmQGghgsDQF++sXmkNQQzBqBDBHMGoDIDDwHQl8ECAdCXwZKvBSB8tpy0L4MAAXJfBo/96nYAmJX16WmyLZKEPGkJHhvWIUqSosrFBxrBWoTQDg8iEUQXONiIIOoQglgEwSQnIog6hSAVQbRlgkwEwaLn8hTAsm1lFExCIaNA4LOMguJ3MgqqL+W1ger3MgrqqmQUjFjLCw0zcZBRoPFF7geoq5HXGlCtiAKXEXQExZ9yBEcBAByvAgTknwQIXAtnAQKSLgIEroM3AUIneTUTIHRNV3NJNO2hlSdhqOzVQsJQUaulhIGSfQkDNQfSKkDNKwkD9YQSBsZaS8sJ2iMJA7o20ppDPbG0ooBJBAx0+orukMKjj1UmIYAllzCgfCthaLevCgkDqp4lDO331U7CwCyXEgZWdC9qh/apRBCor0UQSDuIIKj7RQRB4Y24IFB4K4Kgpk4EwXBHcW1hCl5FEKg7iR0ANZ3F5QXQRQJh+9ONkT0PCWc8ThnCOUdQ3aHHEbTtwwVHUDHhkiNoy4c+R9CpDQOOoMsYrgS1tGfCUICA3rUAATmRAIFqNwIEyo2FqYdyEwECtaQCBAbKhBUE0bkAAUVbYZWhlkJYRIA8cwg0dfi++9Vt8XjdKdq0dXnsyFuPJWCy4pz2T1TDPQCatIy64pWQPHY+4UsjfD+PbaLqI3/289y73oSmUUsoDgx4/3NWN3tTymMDPLa3V9jSMo07/k7nY/sT78TDth+DVez6MZj4Yz8GDfJKxgPSExkQGvRMgjDkhQRhzLd+EO601zMSpAWt5yRIx1x7JEhbeL0g8wNjLkkQaH0SpFLWQT8Id9PrVT8Id9LrkM4tRNdkWegd9DrqB+W75/VjE7q9UJs09WGaFWWXNr1XAzflsWkfb23++3qLXUbkFcF1/Jn+eB+3lxnXZX1NjeLbWwi/3P6HZCZP29s9++j89On2yuz7+8djCLIhmX+vm/QBIxz5cBEGpu0IOQaqQsHx9bLxt/sLqoTgWa3KSrPTS7LylCMI+BvG6/1oVQJZNV6bwFYPovlPer2Ok6i5fPtMIGyHEUJdnC9j9LpI3SXGZd2m/O30dauUaMrvtHJMBMchmQb5r8NFGJhOI+QYqM5ujv7fNjCwXLTSFFxvanFusmg2luVvTUO/P6L592nkhN53CuWMi2FUv13/3BgmbjlGrY3QH6XWxhgMo/o9PXckfzVGImMJR+liNOvh+Xz9o7GKONVmtCzO5TaN7yTFbcGTIo46YNCaRxeP2kS6iNxmMqlPVVlHybf7A/lfoiYxtLHWU6oJ1dZSzeh2mB9Uv9cHC4/WaOrY1H5TR+e2nSnrbK3H5JlqQ8lT3e4xT6+7ZlRybx1pvaKZQe0MzRQDh/+12JN0rRm0kqgdoZXFbQtvf93yty7dG5pO6wkdNGpD6OBxu8H7k4Fv748PSK7WA5oZ1M7PSLFx+73PXC5/o7V4Ng61q7ORuI3cI5tdWxutbzPlq22aicDtyu6ZaIA2WjcmZ6tdmJzudl+febAFbLSey0igdlpGBre/+kz9vEUnBFp75aBRuysHj9tcHZo6K8r0r3eHRnK1bsrMoLZPZgq3XyK5/7hVTAi0RslBo3ZIDh63NXonkJ9QbrQ2yc6itkx2Grd9epzBpMm/D/dnW3yP07ooJ5HaTDmZFMV0UZVs6JWmtVJSrtpBScnkn2S449QP8jfEM41ioHZpFMV5WK6hFy9jpBi43kaJksnimYrF9hg/ng/QZiXyhgizMi1GUfAH+PHyO7QJdP73KBT4goFEjgf38WqUXBdrOE61i3at4DM85o8jtVATw0YvykQRD8s1TEMyRoqBKx0lykCWaVjcj/bjXC9QwbYdIFFBV4znYc9P4+fvVcopd98tl3OWQ8ksD/fj/TjNNspqpGYbZz2UDG8948M4oYznZaQ6RjSqFN4N7XhdnKz7DnGcTWM+HQcAsd6EupgGmFEXlcaUah/6x3pvqqYcYFG1nInGqaoOABK9YdXxDfCtOkKNfWXHBYneq/LcAcaUJ2tcqPGQINF7TjPHAIdpJtH4SdshQaI3lVaaAc7SyqOxl/ZjgkTvLR1EA4ylg0njKo3HBoneS5o5BjhIM4nGN1oODhK9VbSxDHCHNhqNITQcIyR6/2diGGD3TBQadyceKCR6VyfnD3BzMsGgoXGL0Hs3I8UAx2bk0Pg0+1FCordpDqIBLs3BpDFpxqOFRO/KzBwDbJiRJNX4LvuxQqo3XA6iAU7LwaSxWNbjhVRvt+w8A6yXnUhjw1zHC6nejTmpBpgyJ5fGmwnHD6nekknZA5yYlP5hwM7Tdhslt3/C4DPr8QHcxJJkar1GUYDpGsWRuZOTIirrnGTl2uKF3K26aiG5cGe9X0S/pl1UlK2w4T1ri3cy7dRSnFSlm4NeRCR7r5Vk4ajUYiwktT77v1FZpsTrpIehMgSOl8EyBBJFCad71j/rvCaZrVaCIb9Tl28geHgtwy5mOARN++5qYCrxUwNzz8okwxfiZVDVBpK3YfXLLNnMnm47zMzmGhlWBk+lwUqxGJbLzyqz5RgZAo8/SoxAFGgZHAeR2WqYMhddOFCgi29tIzKcTWaRW5MpdaOo35QbK5MMUpNBVRtI0mH1G1gya7r7ZDHLFVoUNFuNGgVPMYKAnchkz6NFca7deGWcrFSzWE4Js/1AeTauaqg8G1mtZsEHTNlhoCZG8DJUCGMYNjhf3HaEBM7SjdHBaawGzHHwlymMmItCY8hcHFZjpj3RyxT+TM2lsWlastzq1lRHeLnCtOmINN5Nx2S1cOxUL1f4NZ6kMWc8y+rEjAd2ucJ3mZM1LsucbfVUtlO5XGGsrPkad2UlsFos++FbrvBXDgaNuXJQWJ2V8cQtV/gpc7LGRZmzrd7JcrCWK+ySLV3jkGz5VlNkOEvLFR7IlKqxPKZcq8MRj85yhbOREzWORs7UDYaXrMK/GHM1rsWYbPUq9uOvXGFVHAwap+KgsBoV45lXrnAm5mSNFTFmb63ew36otVWYDgeDxm04KKw2w3qCtVVYDjuBxn7YGaxWxHVMtVU4EieHxpg4Saz+RDir2ipsiZSmcSP9vL/s06SIJm3cpGk1uX4++bH3D4GvgvBw/unO9T7A4997s/zo8mTyxxd6YUTff/uNYH0J+/G7agS5ekfCzzATzBox7z/GTEAbBD1+kplgEsR8/DDzDfXH/wG2t/GriXoAAA== */ +[data-rk] .ju367v0 { + align-items: flex-start; +} +[data-rk] .ju367v2 { + align-items: flex-end; +} +[data-rk] .ju367v4 { + align-items: center; +} +[data-rk] .ju367v6 { + display: none; +} +[data-rk] .ju367v8 { + display: block; +} +[data-rk] .ju367va { + display: flex; +} +[data-rk] .ju367vc { + display: inline; +} +[data-rk] .ju367ve { + align-self: flex-start; +} +[data-rk] .ju367vf { + align-self: flex-end; +} +[data-rk] .ju367vg { + align-self: center; +} +[data-rk] .ju367vh { + background-size: cover; +} +[data-rk] .ju367vi { + border-radius: 1px; +} +[data-rk] .ju367vj { + border-radius: 6px; +} +[data-rk] .ju367vk { + border-radius: 10px; +} +[data-rk] .ju367vl { + border-radius: 13px; +} +[data-rk] .ju367vm { + border-radius: var(--rk-radii-actionButton); +} +[data-rk] .ju367vn { + border-radius: var(--rk-radii-connectButton); +} +[data-rk] .ju367vo { + border-radius: var(--rk-radii-menuButton); +} +[data-rk] .ju367vp { + border-radius: var(--rk-radii-modal); +} +[data-rk] .ju367vq { + border-radius: var(--rk-radii-modalMobile); +} +[data-rk] .ju367vr { + border-radius: 25%; +} +[data-rk] .ju367vs { + border-radius: 9999px; +} +[data-rk] .ju367vt { + border-style: solid; +} +[data-rk] .ju367vu { + border-width: 0px; +} +[data-rk] .ju367vv { + border-width: 1px; +} +[data-rk] .ju367vw { + border-width: 2px; +} +[data-rk] .ju367vx { + border-width: 4px; +} +[data-rk] .ju367vy { + cursor: pointer; +} +[data-rk] .ju367vz { + flex-direction: row; +} +[data-rk] .ju367v10 { + flex-direction: column; +} +[data-rk] .ju367v11 { + font-family: var(--rk-fonts-body); +} +[data-rk] .ju367v12 { + font-size: 12px; + line-height: 18px; +} +[data-rk] .ju367v13 { + font-size: 13px; + line-height: 18px; +} +[data-rk] .ju367v14 { + font-size: 14px; + line-height: 18px; +} +[data-rk] .ju367v15 { + font-size: 16px; + line-height: 20px; +} +[data-rk] .ju367v16 { + font-size: 18px; + line-height: 24px; +} +[data-rk] .ju367v17 { + font-size: 20px; + line-height: 24px; +} +[data-rk] .ju367v18 { + font-size: 23px; + line-height: 29px; +} +[data-rk] .ju367v19 { + font-weight: 400; +} +[data-rk] .ju367v1a { + font-weight: 500; +} +[data-rk] .ju367v1b { + font-weight: 600; +} +[data-rk] .ju367v1c { + font-weight: 700; +} +[data-rk] .ju367v1d { + font-weight: 800; +} +[data-rk] .ju367v1e { + gap: 0; +} +[data-rk] .ju367v1f { + gap: 1px; +} +[data-rk] .ju367v1g { + gap: 2px; +} +[data-rk] .ju367v1h { + gap: 3px; +} +[data-rk] .ju367v1i { + gap: 4px; +} +[data-rk] .ju367v1j { + gap: 5px; +} +[data-rk] .ju367v1k { + gap: 6px; +} +[data-rk] .ju367v1l { + gap: 8px; +} +[data-rk] .ju367v1m { + gap: 10px; +} +[data-rk] .ju367v1n { + gap: 12px; +} +[data-rk] .ju367v1o { + gap: 14px; +} +[data-rk] .ju367v1p { + gap: 16px; +} +[data-rk] .ju367v1q { + gap: 18px; +} +[data-rk] .ju367v1r { + gap: 20px; +} +[data-rk] .ju367v1s { + gap: 24px; +} +[data-rk] .ju367v1t { + gap: 28px; +} +[data-rk] .ju367v1u { + gap: 32px; +} +[data-rk] .ju367v1v { + gap: 36px; +} +[data-rk] .ju367v1w { + gap: 44px; +} +[data-rk] .ju367v1x { + gap: 64px; +} +[data-rk] .ju367v1y { + gap: -1px; +} +[data-rk] .ju367v1z { + height: 1px; +} +[data-rk] .ju367v20 { + height: 2px; +} +[data-rk] .ju367v21 { + height: 4px; +} +[data-rk] .ju367v22 { + height: 8px; +} +[data-rk] .ju367v23 { + height: 12px; +} +[data-rk] .ju367v24 { + height: 20px; +} +[data-rk] .ju367v25 { + height: 24px; +} +[data-rk] .ju367v26 { + height: 28px; +} +[data-rk] .ju367v27 { + height: 30px; +} +[data-rk] .ju367v28 { + height: 32px; +} +[data-rk] .ju367v29 { + height: 34px; +} +[data-rk] .ju367v2a { + height: 36px; +} +[data-rk] .ju367v2b { + height: 40px; +} +[data-rk] .ju367v2c { + height: 44px; +} +[data-rk] .ju367v2d { + height: 48px; +} +[data-rk] .ju367v2e { + height: 54px; +} +[data-rk] .ju367v2f { + height: 60px; +} +[data-rk] .ju367v2g { + height: 200px; +} +[data-rk] .ju367v2h { + height: 100%; +} +[data-rk] .ju367v2i { + height: -moz-max-content; + height: max-content; +} +[data-rk] .ju367v2j { + justify-content: flex-start; +} +[data-rk] .ju367v2k { + justify-content: flex-end; +} +[data-rk] .ju367v2l { + justify-content: center; +} +[data-rk] .ju367v2m { + justify-content: space-between; +} +[data-rk] .ju367v2n { + justify-content: space-around; +} +[data-rk] .ju367v2o { + text-align: left; +} +[data-rk] .ju367v2p { + text-align: center; +} +[data-rk] .ju367v2q { + text-align: inherit; +} +[data-rk] .ju367v2r { + margin-bottom: 0; +} +[data-rk] .ju367v2s { + margin-bottom: 1px; +} +[data-rk] .ju367v2t { + margin-bottom: 2px; +} +[data-rk] .ju367v2u { + margin-bottom: 3px; +} +[data-rk] .ju367v2v { + margin-bottom: 4px; +} +[data-rk] .ju367v2w { + margin-bottom: 5px; +} +[data-rk] .ju367v2x { + margin-bottom: 6px; +} +[data-rk] .ju367v2y { + margin-bottom: 8px; +} +[data-rk] .ju367v2z { + margin-bottom: 10px; +} +[data-rk] .ju367v30 { + margin-bottom: 12px; +} +[data-rk] .ju367v31 { + margin-bottom: 14px; +} +[data-rk] .ju367v32 { + margin-bottom: 16px; +} +[data-rk] .ju367v33 { + margin-bottom: 18px; +} +[data-rk] .ju367v34 { + margin-bottom: 20px; +} +[data-rk] .ju367v35 { + margin-bottom: 24px; +} +[data-rk] .ju367v36 { + margin-bottom: 28px; +} +[data-rk] .ju367v37 { + margin-bottom: 32px; +} +[data-rk] .ju367v38 { + margin-bottom: 36px; +} +[data-rk] .ju367v39 { + margin-bottom: 44px; +} +[data-rk] .ju367v3a { + margin-bottom: 64px; +} +[data-rk] .ju367v3b { + margin-bottom: -1px; +} +[data-rk] .ju367v3c { + margin-left: 0; +} +[data-rk] .ju367v3d { + margin-left: 1px; +} +[data-rk] .ju367v3e { + margin-left: 2px; +} +[data-rk] .ju367v3f { + margin-left: 3px; +} +[data-rk] .ju367v3g { + margin-left: 4px; +} +[data-rk] .ju367v3h { + margin-left: 5px; +} +[data-rk] .ju367v3i { + margin-left: 6px; +} +[data-rk] .ju367v3j { + margin-left: 8px; +} +[data-rk] .ju367v3k { + margin-left: 10px; +} +[data-rk] .ju367v3l { + margin-left: 12px; +} +[data-rk] .ju367v3m { + margin-left: 14px; +} +[data-rk] .ju367v3n { + margin-left: 16px; +} +[data-rk] .ju367v3o { + margin-left: 18px; +} +[data-rk] .ju367v3p { + margin-left: 20px; +} +[data-rk] .ju367v3q { + margin-left: 24px; +} +[data-rk] .ju367v3r { + margin-left: 28px; +} +[data-rk] .ju367v3s { + margin-left: 32px; +} +[data-rk] .ju367v3t { + margin-left: 36px; +} +[data-rk] .ju367v3u { + margin-left: 44px; +} +[data-rk] .ju367v3v { + margin-left: 64px; +} +[data-rk] .ju367v3w { + margin-left: -1px; +} +[data-rk] .ju367v3x { + margin-right: 0; +} +[data-rk] .ju367v3y { + margin-right: 1px; +} +[data-rk] .ju367v3z { + margin-right: 2px; +} +[data-rk] .ju367v40 { + margin-right: 3px; +} +[data-rk] .ju367v41 { + margin-right: 4px; +} +[data-rk] .ju367v42 { + margin-right: 5px; +} +[data-rk] .ju367v43 { + margin-right: 6px; +} +[data-rk] .ju367v44 { + margin-right: 8px; +} +[data-rk] .ju367v45 { + margin-right: 10px; +} +[data-rk] .ju367v46 { + margin-right: 12px; +} +[data-rk] .ju367v47 { + margin-right: 14px; +} +[data-rk] .ju367v48 { + margin-right: 16px; +} +[data-rk] .ju367v49 { + margin-right: 18px; +} +[data-rk] .ju367v4a { + margin-right: 20px; +} +[data-rk] .ju367v4b { + margin-right: 24px; +} +[data-rk] .ju367v4c { + margin-right: 28px; +} +[data-rk] .ju367v4d { + margin-right: 32px; +} +[data-rk] .ju367v4e { + margin-right: 36px; +} +[data-rk] .ju367v4f { + margin-right: 44px; +} +[data-rk] .ju367v4g { + margin-right: 64px; +} +[data-rk] .ju367v4h { + margin-right: -1px; +} +[data-rk] .ju367v4i { + margin-top: 0; +} +[data-rk] .ju367v4j { + margin-top: 1px; +} +[data-rk] .ju367v4k { + margin-top: 2px; +} +[data-rk] .ju367v4l { + margin-top: 3px; +} +[data-rk] .ju367v4m { + margin-top: 4px; +} +[data-rk] .ju367v4n { + margin-top: 5px; +} +[data-rk] .ju367v4o { + margin-top: 6px; +} +[data-rk] .ju367v4p { + margin-top: 8px; +} +[data-rk] .ju367v4q { + margin-top: 10px; +} +[data-rk] .ju367v4r { + margin-top: 12px; +} +[data-rk] .ju367v4s { + margin-top: 14px; +} +[data-rk] .ju367v4t { + margin-top: 16px; +} +[data-rk] .ju367v4u { + margin-top: 18px; +} +[data-rk] .ju367v4v { + margin-top: 20px; +} +[data-rk] .ju367v4w { + margin-top: 24px; +} +[data-rk] .ju367v4x { + margin-top: 28px; +} +[data-rk] .ju367v4y { + margin-top: 32px; +} +[data-rk] .ju367v4z { + margin-top: 36px; +} +[data-rk] .ju367v50 { + margin-top: 44px; +} +[data-rk] .ju367v51 { + margin-top: 64px; +} +[data-rk] .ju367v52 { + margin-top: -1px; +} +[data-rk] .ju367v53 { + max-width: 1px; +} +[data-rk] .ju367v54 { + max-width: 2px; +} +[data-rk] .ju367v55 { + max-width: 4px; +} +[data-rk] .ju367v56 { + max-width: 8px; +} +[data-rk] .ju367v57 { + max-width: 12px; +} +[data-rk] .ju367v58 { + max-width: 20px; +} +[data-rk] .ju367v59 { + max-width: 24px; +} +[data-rk] .ju367v5a { + max-width: 28px; +} +[data-rk] .ju367v5b { + max-width: 30px; +} +[data-rk] .ju367v5c { + max-width: 32px; +} +[data-rk] .ju367v5d { + max-width: 34px; +} +[data-rk] .ju367v5e { + max-width: 36px; +} +[data-rk] .ju367v5f { + max-width: 40px; +} +[data-rk] .ju367v5g { + max-width: 44px; +} +[data-rk] .ju367v5h { + max-width: 48px; +} +[data-rk] .ju367v5i { + max-width: 54px; +} +[data-rk] .ju367v5j { + max-width: 60px; +} +[data-rk] .ju367v5k { + max-width: 200px; +} +[data-rk] .ju367v5l { + max-width: 100%; +} +[data-rk] .ju367v5m { + max-width: -moz-max-content; + max-width: max-content; +} +[data-rk] .ju367v5n { + min-width: 1px; +} +[data-rk] .ju367v5o { + min-width: 2px; +} +[data-rk] .ju367v5p { + min-width: 4px; +} +[data-rk] .ju367v5q { + min-width: 8px; +} +[data-rk] .ju367v5r { + min-width: 12px; +} +[data-rk] .ju367v5s { + min-width: 20px; +} +[data-rk] .ju367v5t { + min-width: 24px; +} +[data-rk] .ju367v5u { + min-width: 28px; +} +[data-rk] .ju367v5v { + min-width: 30px; +} +[data-rk] .ju367v5w { + min-width: 32px; +} +[data-rk] .ju367v5x { + min-width: 34px; +} +[data-rk] .ju367v5y { + min-width: 36px; +} +[data-rk] .ju367v5z { + min-width: 40px; +} +[data-rk] .ju367v60 { + min-width: 44px; +} +[data-rk] .ju367v61 { + min-width: 48px; +} +[data-rk] .ju367v62 { + min-width: 54px; +} +[data-rk] .ju367v63 { + min-width: 60px; +} +[data-rk] .ju367v64 { + min-width: 200px; +} +[data-rk] .ju367v65 { + min-width: 100%; +} +[data-rk] .ju367v66 { + min-width: -moz-max-content; + min-width: max-content; +} +[data-rk] .ju367v67 { + overflow: hidden; +} +[data-rk] .ju367v68 { + padding-bottom: 0; +} +[data-rk] .ju367v69 { + padding-bottom: 1px; +} +[data-rk] .ju367v6a { + padding-bottom: 2px; +} +[data-rk] .ju367v6b { + padding-bottom: 3px; +} +[data-rk] .ju367v6c { + padding-bottom: 4px; +} +[data-rk] .ju367v6d { + padding-bottom: 5px; +} +[data-rk] .ju367v6e { + padding-bottom: 6px; +} +[data-rk] .ju367v6f { + padding-bottom: 8px; +} +[data-rk] .ju367v6g { + padding-bottom: 10px; +} +[data-rk] .ju367v6h { + padding-bottom: 12px; +} +[data-rk] .ju367v6i { + padding-bottom: 14px; +} +[data-rk] .ju367v6j { + padding-bottom: 16px; +} +[data-rk] .ju367v6k { + padding-bottom: 18px; +} +[data-rk] .ju367v6l { + padding-bottom: 20px; +} +[data-rk] .ju367v6m { + padding-bottom: 24px; +} +[data-rk] .ju367v6n { + padding-bottom: 28px; +} +[data-rk] .ju367v6o { + padding-bottom: 32px; +} +[data-rk] .ju367v6p { + padding-bottom: 36px; +} +[data-rk] .ju367v6q { + padding-bottom: 44px; +} +[data-rk] .ju367v6r { + padding-bottom: 64px; +} +[data-rk] .ju367v6s { + padding-bottom: -1px; +} +[data-rk] .ju367v6t { + padding-left: 0; +} +[data-rk] .ju367v6u { + padding-left: 1px; +} +[data-rk] .ju367v6v { + padding-left: 2px; +} +[data-rk] .ju367v6w { + padding-left: 3px; +} +[data-rk] .ju367v6x { + padding-left: 4px; +} +[data-rk] .ju367v6y { + padding-left: 5px; +} +[data-rk] .ju367v6z { + padding-left: 6px; +} +[data-rk] .ju367v70 { + padding-left: 8px; +} +[data-rk] .ju367v71 { + padding-left: 10px; +} +[data-rk] .ju367v72 { + padding-left: 12px; +} +[data-rk] .ju367v73 { + padding-left: 14px; +} +[data-rk] .ju367v74 { + padding-left: 16px; +} +[data-rk] .ju367v75 { + padding-left: 18px; +} +[data-rk] .ju367v76 { + padding-left: 20px; +} +[data-rk] .ju367v77 { + padding-left: 24px; +} +[data-rk] .ju367v78 { + padding-left: 28px; +} +[data-rk] .ju367v79 { + padding-left: 32px; +} +[data-rk] .ju367v7a { + padding-left: 36px; +} +[data-rk] .ju367v7b { + padding-left: 44px; +} +[data-rk] .ju367v7c { + padding-left: 64px; +} +[data-rk] .ju367v7d { + padding-left: -1px; +} +[data-rk] .ju367v7e { + padding-right: 0; +} +[data-rk] .ju367v7f { + padding-right: 1px; +} +[data-rk] .ju367v7g { + padding-right: 2px; +} +[data-rk] .ju367v7h { + padding-right: 3px; +} +[data-rk] .ju367v7i { + padding-right: 4px; +} +[data-rk] .ju367v7j { + padding-right: 5px; +} +[data-rk] .ju367v7k { + padding-right: 6px; +} +[data-rk] .ju367v7l { + padding-right: 8px; +} +[data-rk] .ju367v7m { + padding-right: 10px; +} +[data-rk] .ju367v7n { + padding-right: 12px; +} +[data-rk] .ju367v7o { + padding-right: 14px; +} +[data-rk] .ju367v7p { + padding-right: 16px; +} +[data-rk] .ju367v7q { + padding-right: 18px; +} +[data-rk] .ju367v7r { + padding-right: 20px; +} +[data-rk] .ju367v7s { + padding-right: 24px; +} +[data-rk] .ju367v7t { + padding-right: 28px; +} +[data-rk] .ju367v7u { + padding-right: 32px; +} +[data-rk] .ju367v7v { + padding-right: 36px; +} +[data-rk] .ju367v7w { + padding-right: 44px; +} +[data-rk] .ju367v7x { + padding-right: 64px; +} +[data-rk] .ju367v7y { + padding-right: -1px; +} +[data-rk] .ju367v7z { + padding-top: 0; +} +[data-rk] .ju367v80 { + padding-top: 1px; +} +[data-rk] .ju367v81 { + padding-top: 2px; +} +[data-rk] .ju367v82 { + padding-top: 3px; +} +[data-rk] .ju367v83 { + padding-top: 4px; +} +[data-rk] .ju367v84 { + padding-top: 5px; +} +[data-rk] .ju367v85 { + padding-top: 6px; +} +[data-rk] .ju367v86 { + padding-top: 8px; +} +[data-rk] .ju367v87 { + padding-top: 10px; +} +[data-rk] .ju367v88 { + padding-top: 12px; +} +[data-rk] .ju367v89 { + padding-top: 14px; +} +[data-rk] .ju367v8a { + padding-top: 16px; +} +[data-rk] .ju367v8b { + padding-top: 18px; +} +[data-rk] .ju367v8c { + padding-top: 20px; +} +[data-rk] .ju367v8d { + padding-top: 24px; +} +[data-rk] .ju367v8e { + padding-top: 28px; +} +[data-rk] .ju367v8f { + padding-top: 32px; +} +[data-rk] .ju367v8g { + padding-top: 36px; +} +[data-rk] .ju367v8h { + padding-top: 44px; +} +[data-rk] .ju367v8i { + padding-top: 64px; +} +[data-rk] .ju367v8j { + padding-top: -1px; +} +[data-rk] .ju367v8k { + position: absolute; +} +[data-rk] .ju367v8l { + position: fixed; +} +[data-rk] .ju367v8m { + position: relative; +} +[data-rk] .ju367v8n { + right: 0; +} +[data-rk] .ju367v8o { + transition: 0.125s ease; +} +[data-rk] .ju367v8p { + transition: transform 0.125s ease; +} +[data-rk] .ju367v8q { + -webkit-user-select: none; + -moz-user-select: none; + user-select: none; +} +[data-rk] .ju367v8r { + width: 1px; +} +[data-rk] .ju367v8s { + width: 2px; +} +[data-rk] .ju367v8t { + width: 4px; +} +[data-rk] .ju367v8u { + width: 8px; +} +[data-rk] .ju367v8v { + width: 12px; +} +[data-rk] .ju367v8w { + width: 20px; +} +[data-rk] .ju367v8x { + width: 24px; +} +[data-rk] .ju367v8y { + width: 28px; +} +[data-rk] .ju367v8z { + width: 30px; +} +[data-rk] .ju367v90 { + width: 32px; +} +[data-rk] .ju367v91 { + width: 34px; +} +[data-rk] .ju367v92 { + width: 36px; +} +[data-rk] .ju367v93 { + width: 40px; +} +[data-rk] .ju367v94 { + width: 44px; +} +[data-rk] .ju367v95 { + width: 48px; +} +[data-rk] .ju367v96 { + width: 54px; +} +[data-rk] .ju367v97 { + width: 60px; +} +[data-rk] .ju367v98 { + width: 200px; +} +[data-rk] .ju367v99 { + width: 100%; +} +[data-rk] .ju367v9a { + width: -moz-max-content; + width: max-content; +} +[data-rk] .ju367v9b { + -webkit-backdrop-filter: var(--rk-blurs-modalOverlay); + backdrop-filter: var(--rk-blurs-modalOverlay); +} +[data-rk] .ju367v9c { + background: var(--rk-colors-accentColor); +} +[data-rk] .ju367v9d:hover { + background: var(--rk-colors-accentColor); +} +[data-rk] .ju367v9e:active { + background: var(--rk-colors-accentColor); +} +[data-rk] .ju367v9f { + background: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367v9g:hover { + background: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367v9h:active { + background: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367v9i { + background: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367v9j:hover { + background: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367v9k:active { + background: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367v9l { + background: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367v9m:hover { + background: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367v9n:active { + background: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367v9o { + background: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367v9p:hover { + background: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367v9q:active { + background: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367v9r { + background: var(--rk-colors-closeButton); +} +[data-rk] .ju367v9s:hover { + background: var(--rk-colors-closeButton); +} +[data-rk] .ju367v9t:active { + background: var(--rk-colors-closeButton); +} +[data-rk] .ju367v9u { + background: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367v9v:hover { + background: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367v9w:active { + background: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367v9x { + background: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367v9y:hover { + background: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367v9z:active { + background: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367va0 { + background: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367va1:hover { + background: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367va2:active { + background: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367va3 { + background: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367va4:hover { + background: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367va5:active { + background: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367va6 { + background: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367va7:hover { + background: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367va8:active { + background: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367va9 { + background: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vaa:hover { + background: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vab:active { + background: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vac { + background: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vad:hover { + background: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vae:active { + background: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vaf { + background: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vag:hover { + background: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vah:active { + background: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vai { + background: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vaj:hover { + background: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vak:active { + background: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367val { + background: var(--rk-colors-error); +} +[data-rk] .ju367vam:hover { + background: var(--rk-colors-error); +} +[data-rk] .ju367van:active { + background: var(--rk-colors-error); +} +[data-rk] .ju367vao { + background: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vap:hover { + background: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vaq:active { + background: var(--rk-colors-generalBorder); +} +[data-rk] .ju367var { + background: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vas:hover { + background: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vat:active { + background: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vau { + background: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vav:hover { + background: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vaw:active { + background: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vax { + background: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vay:hover { + background: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vaz:active { + background: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vb0 { + background: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vb1:hover { + background: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vb2:active { + background: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vb3 { + background: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vb4:hover { + background: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vb5:active { + background: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vb6 { + background: var(--rk-colors-modalText); +} +[data-rk] .ju367vb7:hover { + background: var(--rk-colors-modalText); +} +[data-rk] .ju367vb8:active { + background: var(--rk-colors-modalText); +} +[data-rk] .ju367vb9 { + background: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vba:hover { + background: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vbb:active { + background: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vbc { + background: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vbd:hover { + background: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vbe:active { + background: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vbf { + background: var(--rk-colors-profileAction); +} +[data-rk] .ju367vbg:hover { + background: var(--rk-colors-profileAction); +} +[data-rk] .ju367vbh:active { + background: var(--rk-colors-profileAction); +} +[data-rk] .ju367vbi { + background: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367vbj:hover { + background: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367vbk:active { + background: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367vbl { + background: var(--rk-colors-profileForeground); +} +[data-rk] .ju367vbm:hover { + background: var(--rk-colors-profileForeground); +} +[data-rk] .ju367vbn:active { + background: var(--rk-colors-profileForeground); +} +[data-rk] .ju367vbo { + background: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367vbp:hover { + background: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367vbq:active { + background: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367vbr { + background: var(--rk-colors-standby); +} +[data-rk] .ju367vbs:hover { + background: var(--rk-colors-standby); +} +[data-rk] .ju367vbt:active { + background: var(--rk-colors-standby); +} +[data-rk] .ju367vbu { + border-color: var(--rk-colors-accentColor); +} +[data-rk] .ju367vbv:hover { + border-color: var(--rk-colors-accentColor); +} +[data-rk] .ju367vbw:active { + border-color: var(--rk-colors-accentColor); +} +[data-rk] .ju367vbx { + border-color: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367vby:hover { + border-color: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367vbz:active { + border-color: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367vc0 { + border-color: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367vc1:hover { + border-color: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367vc2:active { + border-color: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367vc3 { + border-color: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367vc4:hover { + border-color: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367vc5:active { + border-color: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367vc6 { + border-color: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367vc7:hover { + border-color: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367vc8:active { + border-color: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367vc9 { + border-color: var(--rk-colors-closeButton); +} +[data-rk] .ju367vca:hover { + border-color: var(--rk-colors-closeButton); +} +[data-rk] .ju367vcb:active { + border-color: var(--rk-colors-closeButton); +} +[data-rk] .ju367vcc { + border-color: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367vcd:hover { + border-color: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367vce:active { + border-color: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367vcf { + border-color: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367vcg:hover { + border-color: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367vch:active { + border-color: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367vci { + border-color: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367vcj:hover { + border-color: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367vck:active { + border-color: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367vcl { + border-color: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367vcm:hover { + border-color: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367vcn:active { + border-color: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367vco { + border-color: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367vcp:hover { + border-color: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367vcq:active { + border-color: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367vcr { + border-color: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vcs:hover { + border-color: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vct:active { + border-color: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vcu { + border-color: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vcv:hover { + border-color: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vcw:active { + border-color: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vcx { + border-color: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vcy:hover { + border-color: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vcz:active { + border-color: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vd0 { + border-color: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vd1:hover { + border-color: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vd2:active { + border-color: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vd3 { + border-color: var(--rk-colors-error); +} +[data-rk] .ju367vd4:hover { + border-color: var(--rk-colors-error); +} +[data-rk] .ju367vd5:active { + border-color: var(--rk-colors-error); +} +[data-rk] .ju367vd6 { + border-color: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vd7:hover { + border-color: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vd8:active { + border-color: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vd9 { + border-color: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vda:hover { + border-color: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vdb:active { + border-color: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vdc { + border-color: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vdd:hover { + border-color: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vde:active { + border-color: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vdf { + border-color: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vdg:hover { + border-color: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vdh:active { + border-color: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vdi { + border-color: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vdj:hover { + border-color: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vdk:active { + border-color: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vdl { + border-color: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vdm:hover { + border-color: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vdn:active { + border-color: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vdo { + border-color: var(--rk-colors-modalText); +} +[data-rk] .ju367vdp:hover { + border-color: var(--rk-colors-modalText); +} +[data-rk] .ju367vdq:active { + border-color: var(--rk-colors-modalText); +} +[data-rk] .ju367vdr { + border-color: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vds:hover { + border-color: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vdt:active { + border-color: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vdu { + border-color: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vdv:hover { + border-color: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vdw:active { + border-color: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vdx { + border-color: var(--rk-colors-profileAction); +} +[data-rk] .ju367vdy:hover { + border-color: var(--rk-colors-profileAction); +} +[data-rk] .ju367vdz:active { + border-color: var(--rk-colors-profileAction); +} +[data-rk] .ju367ve0 { + border-color: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367ve1:hover { + border-color: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367ve2:active { + border-color: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367ve3 { + border-color: var(--rk-colors-profileForeground); +} +[data-rk] .ju367ve4:hover { + border-color: var(--rk-colors-profileForeground); +} +[data-rk] .ju367ve5:active { + border-color: var(--rk-colors-profileForeground); +} +[data-rk] .ju367ve6 { + border-color: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367ve7:hover { + border-color: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367ve8:active { + border-color: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367ve9 { + border-color: var(--rk-colors-standby); +} +[data-rk] .ju367vea:hover { + border-color: var(--rk-colors-standby); +} +[data-rk] .ju367veb:active { + border-color: var(--rk-colors-standby); +} +[data-rk] .ju367vec { + box-shadow: var(--rk-shadows-connectButton); +} +[data-rk] .ju367ved:hover { + box-shadow: var(--rk-shadows-connectButton); +} +[data-rk] .ju367vee:active { + box-shadow: var(--rk-shadows-connectButton); +} +[data-rk] .ju367vef { + box-shadow: var(--rk-shadows-dialog); +} +[data-rk] .ju367veg:hover { + box-shadow: var(--rk-shadows-dialog); +} +[data-rk] .ju367veh:active { + box-shadow: var(--rk-shadows-dialog); +} +[data-rk] .ju367vei { + box-shadow: var(--rk-shadows-profileDetailsAction); +} +[data-rk] .ju367vej:hover { + box-shadow: var(--rk-shadows-profileDetailsAction); +} +[data-rk] .ju367vek:active { + box-shadow: var(--rk-shadows-profileDetailsAction); +} +[data-rk] .ju367vel { + box-shadow: var(--rk-shadows-selectedOption); +} +[data-rk] .ju367vem:hover { + box-shadow: var(--rk-shadows-selectedOption); +} +[data-rk] .ju367ven:active { + box-shadow: var(--rk-shadows-selectedOption); +} +[data-rk] .ju367veo { + box-shadow: var(--rk-shadows-selectedWallet); +} +[data-rk] .ju367vep:hover { + box-shadow: var(--rk-shadows-selectedWallet); +} +[data-rk] .ju367veq:active { + box-shadow: var(--rk-shadows-selectedWallet); +} +[data-rk] .ju367ver { + box-shadow: var(--rk-shadows-walletLogo); +} +[data-rk] .ju367ves:hover { + box-shadow: var(--rk-shadows-walletLogo); +} +[data-rk] .ju367vet:active { + box-shadow: var(--rk-shadows-walletLogo); +} +[data-rk] .ju367veu { + color: var(--rk-colors-accentColor); +} +[data-rk] .ju367vev:hover { + color: var(--rk-colors-accentColor); +} +[data-rk] .ju367vew:active { + color: var(--rk-colors-accentColor); +} +[data-rk] .ju367vex { + color: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367vey:hover { + color: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367vez:active { + color: var(--rk-colors-accentColorForeground); +} +[data-rk] .ju367vf0 { + color: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367vf1:hover { + color: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367vf2:active { + color: var(--rk-colors-actionButtonBorder); +} +[data-rk] .ju367vf3 { + color: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367vf4:hover { + color: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367vf5:active { + color: var(--rk-colors-actionButtonBorderMobile); +} +[data-rk] .ju367vf6 { + color: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367vf7:hover { + color: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367vf8:active { + color: var(--rk-colors-actionButtonSecondaryBackground); +} +[data-rk] .ju367vf9 { + color: var(--rk-colors-closeButton); +} +[data-rk] .ju367vfa:hover { + color: var(--rk-colors-closeButton); +} +[data-rk] .ju367vfb:active { + color: var(--rk-colors-closeButton); +} +[data-rk] .ju367vfc { + color: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367vfd:hover { + color: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367vfe:active { + color: var(--rk-colors-closeButtonBackground); +} +[data-rk] .ju367vff { + color: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367vfg:hover { + color: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367vfh:active { + color: var(--rk-colors-connectButtonBackground); +} +[data-rk] .ju367vfi { + color: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367vfj:hover { + color: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367vfk:active { + color: var(--rk-colors-connectButtonBackgroundError); +} +[data-rk] .ju367vfl { + color: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367vfm:hover { + color: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367vfn:active { + color: var(--rk-colors-connectButtonInnerBackground); +} +[data-rk] .ju367vfo { + color: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367vfp:hover { + color: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367vfq:active { + color: var(--rk-colors-connectButtonText); +} +[data-rk] .ju367vfr { + color: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vfs:hover { + color: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vft:active { + color: var(--rk-colors-connectButtonTextError); +} +[data-rk] .ju367vfu { + color: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vfv:hover { + color: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vfw:active { + color: var(--rk-colors-connectionIndicator); +} +[data-rk] .ju367vfx { + color: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vfy:hover { + color: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vfz:active { + color: var(--rk-colors-downloadBottomCardBackground); +} +[data-rk] .ju367vg0 { + color: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vg1:hover { + color: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vg2:active { + color: var(--rk-colors-downloadTopCardBackground); +} +[data-rk] .ju367vg3 { + color: var(--rk-colors-error); +} +[data-rk] .ju367vg4:hover { + color: var(--rk-colors-error); +} +[data-rk] .ju367vg5:active { + color: var(--rk-colors-error); +} +[data-rk] .ju367vg6 { + color: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vg7:hover { + color: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vg8:active { + color: var(--rk-colors-generalBorder); +} +[data-rk] .ju367vg9 { + color: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vga:hover { + color: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vgb:active { + color: var(--rk-colors-generalBorderDim); +} +[data-rk] .ju367vgc { + color: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vgd:hover { + color: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vge:active { + color: var(--rk-colors-menuItemBackground); +} +[data-rk] .ju367vgf { + color: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vgg:hover { + color: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vgh:active { + color: var(--rk-colors-modalBackdrop); +} +[data-rk] .ju367vgi { + color: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vgj:hover { + color: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vgk:active { + color: var(--rk-colors-modalBackground); +} +[data-rk] .ju367vgl { + color: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vgm:hover { + color: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vgn:active { + color: var(--rk-colors-modalBorder); +} +[data-rk] .ju367vgo { + color: var(--rk-colors-modalText); +} +[data-rk] .ju367vgp:hover { + color: var(--rk-colors-modalText); +} +[data-rk] .ju367vgq:active { + color: var(--rk-colors-modalText); +} +[data-rk] .ju367vgr { + color: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vgs:hover { + color: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vgt:active { + color: var(--rk-colors-modalTextDim); +} +[data-rk] .ju367vgu { + color: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vgv:hover { + color: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vgw:active { + color: var(--rk-colors-modalTextSecondary); +} +[data-rk] .ju367vgx { + color: var(--rk-colors-profileAction); +} +[data-rk] .ju367vgy:hover { + color: var(--rk-colors-profileAction); +} +[data-rk] .ju367vgz:active { + color: var(--rk-colors-profileAction); +} +[data-rk] .ju367vh0 { + color: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367vh1:hover { + color: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367vh2:active { + color: var(--rk-colors-profileActionHover); +} +[data-rk] .ju367vh3 { + color: var(--rk-colors-profileForeground); +} +[data-rk] .ju367vh4:hover { + color: var(--rk-colors-profileForeground); +} +[data-rk] .ju367vh5:active { + color: var(--rk-colors-profileForeground); +} +[data-rk] .ju367vh6 { + color: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367vh7:hover { + color: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367vh8:active { + color: var(--rk-colors-selectedOptionBorder); +} +[data-rk] .ju367vh9 { + color: var(--rk-colors-standby); +} +[data-rk] .ju367vha:hover { + color: var(--rk-colors-standby); +} +[data-rk] .ju367vhb:active { + color: var(--rk-colors-standby); +} +@media screen and (min-width: 768px) { + [data-rk] .ju367v1 { + align-items: flex-start; + } + [data-rk] .ju367v3 { + align-items: flex-end; + } + [data-rk] .ju367v5 { + align-items: center; + } + [data-rk] .ju367v7 { + display: none; + } + [data-rk] .ju367v9 { + display: block; + } + [data-rk] .ju367vb { + display: flex; + } + [data-rk] .ju367vd { + display: inline; + } +} + +/* vanilla-extract-css-ns:src/css/touchableStyles.css.ts.vanilla.css?source=Ll8xMmNibzhpMywuXzEyY2JvOGkzOjphZnRlciB7CiAgLS1fMTJjYm84aTA6IDE7CiAgLS1fMTJjYm84aTE6IDE7Cn0KLl8xMmNibzhpMzpob3ZlciB7CiAgdHJhbnNmb3JtOiBzY2FsZSh2YXIoLS1fMTJjYm84aTApKTsKfQouXzEyY2JvOGkzOmFjdGl2ZSB7CiAgdHJhbnNmb3JtOiBzY2FsZSh2YXIoLS1fMTJjYm84aTEpKTsKfQouXzEyY2JvOGkzOmFjdGl2ZTo6YWZ0ZXIgewogIGNvbnRlbnQ6ICIiOwogIGJvdHRvbTogLTFweDsKICBkaXNwbGF5OiBibG9jazsKICBsZWZ0OiAtMXB4OwogIHBvc2l0aW9uOiBhYnNvbHV0ZTsKICByaWdodDogLTFweDsKICB0b3A6IC0xcHg7CiAgdHJhbnNmb3JtOiBzY2FsZShjYWxjKCgxIC8gdmFyKC0tXzEyY2JvOGkxKSkgKiB2YXIoLS1fMTJjYm84aTApKSk7Cn0KLl8xMmNibzhpNCwuXzEyY2JvOGk0OjphZnRlciB7CiAgLS1fMTJjYm84aTA6IDEuMDI1Owp9Ci5fMTJjYm84aTUsLl8xMmNibzhpNTo6YWZ0ZXIgewogIC0tXzEyY2JvOGkwOiAxLjE7Cn0KLl8xMmNibzhpNiwuXzEyY2JvOGk2OjphZnRlciB7CiAgLS1fMTJjYm84aTE6IDAuOTU7Cn0KLl8xMmNibzhpNywuXzEyY2JvOGk3OjphZnRlciB7CiAgLS1fMTJjYm84aTE6IDAuOTsKfQ== */ +[data-rk] ._12cbo8i3, +[data-rk] ._12cbo8i3::after { + --_12cbo8i0: 1; + --_12cbo8i1: 1; +} +[data-rk] ._12cbo8i3:hover { + transform: scale(var(--_12cbo8i0)); +} +[data-rk] ._12cbo8i3:active { + transform: scale(var(--_12cbo8i1)); +} +[data-rk] ._12cbo8i3:active::after { + content: ""; + bottom: -1px; + display: block; + left: -1px; + position: absolute; + right: -1px; + top: -1px; + transform: scale(calc((1 / var(--_12cbo8i1)) * var(--_12cbo8i0))); +} +[data-rk] ._12cbo8i4, +[data-rk] ._12cbo8i4::after { + --_12cbo8i0: 1.025; +} +[data-rk] ._12cbo8i5, +[data-rk] ._12cbo8i5::after { + --_12cbo8i0: 1.1; +} +[data-rk] ._12cbo8i6, +[data-rk] ._12cbo8i6::after { + --_12cbo8i1: 0.95; +} +[data-rk] ._12cbo8i7, +[data-rk] ._12cbo8i7::after { + --_12cbo8i1: 0.9; +} + +/* vanilla-extract-css-ns:src/components/Icons/Icons.css.ts.vanilla.css?source=QGtleWZyYW1lcyBfMWx1dWxlNDEgewogIDAlIHsKICAgIHRyYW5zZm9ybTogcm90YXRlKDBkZWcpOwogIH0KICAxMDAlIHsKICAgIHRyYW5zZm9ybTogcm90YXRlKDM2MGRlZyk7CiAgfQp9Ci5fMWx1dWxlNDIgewogIGFuaW1hdGlvbjogXzFsdXVsZTQxIDNzIGluZmluaXRlIGxpbmVhcjsKfQouXzFsdXVsZTQzIHsKICBiYWNrZ3JvdW5kOiBjb25pYy1ncmFkaWVudChmcm9tIDE4MGRlZyBhdCA1MCUgNTAlLCByZ2JhKDcyLCAxNDYsIDI1NCwgMCkgMGRlZywgY3VycmVudENvbG9yIDI4Mi4wNGRlZywgcmdiYSg3MiwgMTQ2LCAyNTQsIDApIDMxOS44NmRlZywgcmdiYSg3MiwgMTQ2LCAyNTQsIDApIDM2MGRlZyk7CiAgaGVpZ2h0OiAyMXB4OwogIHdpZHRoOiAyMXB4Owp9 */ +@keyframes _1luule41 { + 0% { + transform: rotate(0deg); + } + 100% { + transform: rotate(360deg); + } +} +[data-rk] ._1luule42 { + animation: _1luule41 3s infinite linear; +} +[data-rk] ._1luule43 { + background: conic-gradient(from 180deg at 50% 50%, rgba(72, 146, 254, 0) 0deg, currentColor 282.04deg, rgba(72, 146, 254, 0) 319.86deg, rgba(72, 146, 254, 0) 360deg); + height: 21px; + width: 21px; +} + +/* vanilla-extract-css-ns:src/components/Dialog/Dialog.css.ts.vanilla.css?source=QGtleWZyYW1lcyBfOXBtNGtpMCB7CiAgMCUgewogICAgdHJhbnNmb3JtOiB0cmFuc2xhdGVZKDEwMCUpOwogIH0KICAxMDAlIHsKICAgIHRyYW5zZm9ybTogdHJhbnNsYXRlWSgwKTsKICB9Cn0KQGtleWZyYW1lcyBfOXBtNGtpMSB7CiAgMCUgewogICAgb3BhY2l0eTogMDsKICB9CiAgMTAwJSB7CiAgICBvcGFjaXR5OiAxOwogIH0KfQouXzlwbTRraTMgewogIGFuaW1hdGlvbjogXzlwbTRraTEgMTUwbXMgZWFzZTsKICBib3R0b206IC0yMDBweDsKICBsZWZ0OiAtMjAwcHg7CiAgcGFkZGluZzogMjAwcHg7CiAgcmlnaHQ6IC0yMDBweDsKICB0b3A6IC0yMDBweDsKICB0cmFuc2Zvcm06IHRyYW5zbGF0ZVooMCk7CiAgei1pbmRleDogMjE0NzQ4MzY0NjsKfQouXzlwbTRraTUgewogIGFuaW1hdGlvbjogXzlwbTRraTAgMzUwbXMgY3ViaWMtYmV6aWVyKC4xNSwxLjE1LDAuNiwxLjAwKSwgXzlwbTRraTEgMTUwbXMgZWFzZTsKICBtYXgtd2lkdGg6IDEwMHZ3Owp9 */ +@keyframes _9pm4ki0 { + 0% { + transform: translateY(100%); + } + 100% { + transform: translateY(0); + } +} +@keyframes _9pm4ki1 { + 0% { + opacity: 0; + } + 100% { + opacity: 1; + } +} +[data-rk] ._9pm4ki3 { + animation: _9pm4ki1 150ms ease; + bottom: -200px; + left: -200px; + padding: 200px; + right: -200px; + top: -200px; + transform: translateZ(0); + z-index: 2147483646; +} +[data-rk] ._9pm4ki5 { + animation: _9pm4ki0 350ms cubic-bezier(.15, 1.15, 0.6, 1.00), _9pm4ki1 150ms ease; + max-width: 100vw; +} + +/* vanilla-extract-css-ns:src/components/Dialog/DialogContent.css.ts.vanilla.css?source=Ll8xY2tqcG9rMSB7CiAgYm94LXNpemluZzogY29udGVudC1ib3g7CiAgbWF4LXdpZHRoOiAxMDB2dzsKICB3aWR0aDogMzYwcHg7Cn0KLl8xY2tqcG9rMiB7CiAgd2lkdGg6IDEwMHZ3Owp9Ci5fMWNranBvazMgewogIHdpZHRoOiA3NjhweDsKfQouXzFja2pwb2s0IHsKICBtaW4td2lkdGg6IDM2OHB4OwogIHdpZHRoOiAzNjhweDsKfQouXzFja2pwb2s2IHsKICBib3JkZXItd2lkdGg6IDBweDsKICBib3gtc2l6aW5nOiBib3JkZXItYm94OwogIHdpZHRoOiAxMDB2dzsKfQpAbWVkaWEgc2NyZWVuIGFuZCAobWluLXdpZHRoOiA3NjhweCkgewogIC5fMWNranBvazEgewogICAgd2lkdGg6IDM2MHB4OwogIH0KICAuXzFja2pwb2syIHsKICAgIHdpZHRoOiA0ODBweDsKICB9CiAgLl8xY2tqcG9rMyB7CiAgICB3aWR0aDogNzIwcHg7CiAgfQogIC5fMWNranBvazQgewogICAgbWluLXdpZHRoOiAzNjhweDsKICAgIHdpZHRoOiAzNjhweDsKICB9Cn0KQG1lZGlhIHNjcmVlbiBhbmQgKG1heC13aWR0aDogNzY3cHgpIHsKICAuXzFja2pwb2s3IHsKICAgIGJvcmRlci1ib3R0b20tbGVmdC1yYWRpdXM6IDA7CiAgICBib3JkZXItYm90dG9tLXJpZ2h0LXJhZGl1czogMDsKICAgIG1hcmdpbi10b3A6IC0yMDBweDsKICAgIHBhZGRpbmctYm90dG9tOiAyMDBweDsKICAgIHRvcDogMjAwcHg7CiAgfQp9 */ +[data-rk] ._1ckjpok1 { + box-sizing: content-box; + max-width: 100vw; + width: 360px; +} +[data-rk] ._1ckjpok2 { + width: 100vw; +} +[data-rk] ._1ckjpok3 { + width: 768px; +} +[data-rk] ._1ckjpok4 { + min-width: 368px; + width: 368px; +} +[data-rk] ._1ckjpok6 { + border-width: 0px; + box-sizing: border-box; + width: 100vw; +} +@media screen and (min-width: 768px) { + [data-rk] ._1ckjpok1 { + width: 360px; + } + [data-rk] ._1ckjpok2 { + width: 480px; + } + [data-rk] ._1ckjpok3 { + width: 720px; + } + [data-rk] ._1ckjpok4 { + min-width: 368px; + width: 368px; + } +} +@media screen and (max-width: 767px) { + [data-rk] ._1ckjpok7 { + border-bottom-left-radius: 0; + border-bottom-right-radius: 0; + margin-top: -200px; + padding-bottom: 200px; + top: 200px; + } +} + +/* vanilla-extract-css-ns:src/components/MenuButton/MenuButton.css.ts.vanilla.css?source=LnY5aG9yYjA6aG92ZXIgewogIGJhY2tncm91bmQ6IHVuc2V0Owp9 */ +[data-rk] .v9horb0:hover { + background: unset; +} + +/* vanilla-extract-css-ns:src/components/ModalSelection/ModalSelection.css.ts.vanilla.css?source=Lmc1a2wwbDAgewogIGJvcmRlci1jb2xvcjogdHJhbnNwYXJlbnQ7Cn0= */ +[data-rk] .g5kl0l0 { + border-color: transparent; +} + +/* vanilla-extract-css-ns:src/components/ConnectOptions/DesktopOptions.css.ts.vanilla.css?source=Ll8xdnd0MGNnMCB7CiAgYmFja2dyb3VuZDogd2hpdGU7Cn0KLl8xdnd0MGNnMiB7CiAgbWF4LWhlaWdodDogNDU0cHg7CiAgb3ZlcmZsb3cteTogYXV0bzsKfQouXzF2d3QwY2czIHsKICBtaW4td2lkdGg6IDI0NnB4Owp9Ci5fMXZ3dDBjZzQgewogIG1pbi13aWR0aDogMTAwJTsKfQpAbWVkaWEgc2NyZWVuIGFuZCAobWluLXdpZHRoOiA3NjhweCkgewogIC5fMXZ3dDBjZzMgewogICAgbWluLXdpZHRoOiAyODdweDsKICB9Cn0= */ +[data-rk] ._1vwt0cg0 { + background: white; +} +[data-rk] ._1vwt0cg2 { + max-height: 454px; + overflow-y: auto; +} +[data-rk] ._1vwt0cg3 { + min-width: 246px; +} +[data-rk] ._1vwt0cg4 { + min-width: 100%; +} +@media screen and (min-width: 768px) { + [data-rk] ._1vwt0cg3 { + min-width: 287px; + } +} + +/* vanilla-extract-css-ns:src/components/ConnectOptions/MobileOptions.css.ts.vanilla.css?source=Ll8xYW0xNDQxMCB7CiAgb3ZlcmZsb3c6IGF1dG87CiAgc2Nyb2xsYmFyLXdpZHRoOiBub25lOwogIHRyYW5zZm9ybTogdHJhbnNsYXRlWigwKTsKfQouXzFhbTE0NDEwOjotd2Via2l0LXNjcm9sbGJhciB7CiAgZGlzcGxheTogbm9uZTsKfQ== */ +[data-rk] ._1am14410 { + overflow: auto; + scrollbar-width: none; + transform: translateZ(0); +} +[data-rk] ._1am14410::-webkit-scrollbar { + display: none; +} diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.ts b/packages/uiweb/src/lib/components/chat/ConnectButton/index.ts deleted file mode 100644 index d5457ba77..000000000 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/index.ts +++ /dev/null @@ -1 +0,0 @@ -export { ConnectButton } from './ConnectButton'; diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx new file mode 100644 index 000000000..9e4ee135a --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx @@ -0,0 +1,75 @@ +import styled from 'styled-components'; +import { IChatTheme } from '../theme'; +import { useChatData } from '../../../hooks'; + +import { ConnectButtonSub } from './ConnectButton'; + +import { getDefaultWallets, RainbowKitProvider } from '@rainbow-me/rainbowkit'; +import { configureChains, createConfig, WagmiConfig } from 'wagmi'; +import { + mainnet, + polygon, + optimism, + arbitrum, + zora, + goerli, + polygonMumbai, + optimismGoerli, + arbitrumGoerli, + zoraTestnet, +} from 'wagmi/chains'; +import { alchemyProvider } from 'wagmi/providers/alchemy'; +import { publicProvider } from 'wagmi/providers/public'; +import { ALCHEMY_API_KEY, RAINBOW_APP_NAME, RAINBOW_PROJECT_ID } from '../../../config'; +import { useWalletClient } from 'wagmi'; + +/** + * @interface IThemeProps + * this interface is used for defining the props for styled components + */ +interface IThemeProps { + theme?: IChatTheme; +} + +export const ConnectButtonComp = () => { + const { chains, publicClient } = configureChains( + [ + mainnet, + polygon, + optimism, + arbitrum, + zora, + goerli, + polygonMumbai, + optimismGoerli, + arbitrumGoerli, + zoraTestnet, + ], + [alchemyProvider({ apiKey: ALCHEMY_API_KEY }), publicProvider()] + ); + const {signer} = useChatData() + + //for walletConnect + const { connectors } = getDefaultWallets({ + appName: RAINBOW_APP_NAME, + projectId: RAINBOW_PROJECT_ID, + chains, + }); + + const wagmiConfig = createConfig({ + autoConnect: true, + connectors, + publicClient, + }); + + + return ( + + + + + + ); +}; + +//styles diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index a1305be48..0a14ccbcc 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -1,5 +1,5 @@ import { useChatData, useClickAway, useDeviceWidthCheck } from "../../../hooks"; -import type { FileMessageContent } from "../../../types"; +import type { FileMessageContent, IGroup } from "../../../types"; import type { ChatMainStateContextType } from "../../../context/chatAndNotification/chat/chatMainStateContext"; import { ChangeEvent, useContext, useEffect, useRef, useState } from "react"; import { GIFType, IChatTheme, MessageInputProps } from "../exportedTypes"; @@ -16,8 +16,16 @@ import usePushSendMessage from "../../../hooks/chat/usePushSendMessage"; import { SendCompIcon } from "../../../icons/SendCompIcon"; import { Spinner } from "../../reusables"; import { ThemeContext } from "../theme/ThemeProvider"; -import { ConnectButton } from "../ConnectButton"; - +import OpenLink from "../../../icons/OpenLink"; +import VerificationFailed from "./VerificationFailed"; +import useVerifyAccessControl from "../../../hooks/chat/useVerifyAccessControl"; +import TokenGatedIcon from "../../../icons/Token-Gated.svg"; +import { Modal } from "../helpers/Modal"; +import { Image } from "../../reusables"; +import { ConnectButtonComp } from "../ConnectButton"; +import useGetGroupByID from "../../../hooks/chat/useGetGroupByID"; +import { ethers } from "ethers"; +import { pCAIP10ToWallet, setAccessControl } from "../../../helpers"; /** * @interface IThemeProps @@ -27,7 +35,7 @@ interface IThemeProps { theme?: IChatTheme; } -export const MessageInput: React.FC = ({ chatId, Emoji = true, GIF = true, File = true, isConnected = true }) => { +export const MessageInput: React.FC = ({ chatId, Emoji = true, GIF = true, File = true, isConnected, onClick }) => { const [typedMessage, setTypedMessage] = useState(""); const [showEmojis, setShowEmojis] = useState(false); const [gifOpen, setGifOpen] = useState(false); @@ -35,13 +43,17 @@ export const MessageInput: React.FC = ({ chatId, Emoji = true const modalRef = useRef(null); const fileUploadInputRef = useRef(null); const [fileUploading, setFileUploading] = useState(false); + const [isRules, setIsRules] = useState(false) const onChangeTypedMessage = (val: string) => { - setTypedMessage(val.trim()); + setTypedMessage(val); }; const theme = useContext(ThemeContext); const isMobile = useDeviceWidthCheck(425); const { sendMessage, loading } = usePushSendMessage(); - const { pgpPrivateKey, setPgpPrivateKey } = useChatData(); + const { verificationSuccessfull, verifyAccessControl, setVerificationSuccessfull, verified, setVerified } = useVerifyAccessControl(); + const { account } = useChatData() + const { pgpPrivateKey, signer, setPgpPrivateKey } = useChatData(); + const { getGroupByID } = useGetGroupByID(); useClickAway(modalRef, () => { setShowEmojis(false); @@ -67,6 +79,30 @@ export const MessageInput: React.FC = ({ chatId, Emoji = true } } + const checkVerification = () => { + verifyAccessControl({ chatId, did: account! }); + console.log('chatId', chatId); + } + + useEffect(() => { + const storedTimestampJSON = localStorage.getItem(chatId); + + if (storedTimestampJSON) { + const storedTimestamp = JSON.parse(storedTimestampJSON); + const currentTimestamp = new Date().getTime(); + const twentyFourHoursInMilliseconds = 24 * 60 * 60 * 1000; + console.log(twentyFourHoursInMilliseconds) + + if (Math.abs(currentTimestamp - storedTimestamp) < twentyFourHoursInMilliseconds) { + console.log(Math.abs(currentTimestamp - storedTimestamp)) + setVerified(true); + } else { + setVerified(false); + setAccessControl(chatId, true) + } + } + }, [chatId, verified]) + const uploadFile = async ( e: ChangeEvent ): Promise => { @@ -115,11 +151,12 @@ export const MessageInput: React.FC = ({ chatId, Emoji = true const sendPushMessage = async (content: string, type: string) => { try { - await sendMessage({ + const sendTextMessage = await sendMessage({ message: content, chatId, messageType: type as any, }); + console.log(sendTextMessage, "messageee"); } catch (error) { console.log(error); } @@ -132,65 +169,138 @@ export const MessageInput: React.FC = ({ chatId, Emoji = true } } - // useEffect(() => { - // setPgpPrivateKey - // }, [pgpPrivateKey]) const sendGIF = async (emojiObject: GIFType) => { sendPushMessage(emojiObject.url as string, 'GIF'); setGifOpen(false); } + const checkIfrules = async() => { + if (!ethers.utils.isAddress(pCAIP10ToWallet(chatId))) { + console.log("beingnnggg calleddd") + const groupInfo = await getGroupByID({ groupId: chatId }) + if(groupInfo?.rules) { + setIsRules(true) + console.log(groupInfo?.rules) + } + console.log(groupInfo, "groupInfooooo") + } + } + console.log(verificationSuccessfull, "verrifficagtionnn") + + useEffect(() => { + console.log(chatId, "chatIdddd") + checkIfrules(); + }, [chatId]) + return ( {/* {isConnected && ( - + )} */} {!pgpPrivateKey && isConnected && ( - // align this button in right corner -
- + {!signer && You need to connect your wallet to get started - - + } +
) } - {pgpPrivateKey && + + {pgpPrivateKey && + !verified + // verified + && isRules && ( +
+ + Sending messages requires 1 PUSH Token for participation. Learn More + + + + Verify Access + + +
+ )} + {pgpPrivateKey && !verificationSuccessfull && ( + +
+ Verification Failed + Please ensure the following conditions are met to participate and send messages. +
+ token-gated +
{/* Added marginLeft */} + Token Gated + You need to have 1 PUSH Token in your wallet to be able to send messages. +
+
+
+ { + if (onClick) { + onClick(); + } + setVerificationSuccessfull(true) + } + }> + + Get Free Tokens + + + + { + setVerificationSuccessfull(true) + console.log(verificationSuccessfull) + }}> + + Close + + +
+
+
+ )} + {pgpPrivateKey && + (isRules ? verified : true) + // true + && <> -
+
{Emoji &&
setShowEmojis(!showEmojis)} > - +
} {showEmojis && (
)} @@ -210,7 +320,7 @@ export const MessageInput: React.FC = ({ chatId, Emoji = true rows={1} />
- + {GIF &&
= ({ chatId, Emoji = true {gifOpen && (
= ({ chatId, Emoji = true alignSelf="end" onClick={() => setNewChat(true)} > - +
uploadFile(e)} + /> )} @@ -263,26 +374,28 @@ export const MessageInput: React.FC = ({ chatId, Emoji = true height="24px" onClick={() => sendTextMsg()} > - +
)} {(loading || fileUploading) && (
- +
)}
} - + ) } -const Container = styled.div` +const Container = styled.div` width: 100%; overflow: hidden; + border:${(props) => props.theme.border?.messageInput}; + border-radius:${(props) => props.theme.borderRadius?.messageInput}; `; const TypebarSection = styled(Section)` gap: 10px; @@ -304,9 +417,9 @@ const MultiLineInput = styled.textarea` outline: none; overflow-y: auto; box-sizing: border-box; - background:${(props) => props.theme.bgColorPrimary}; + background:${(props) => props.theme.backgroundColor?.messageInputBackground}; border: none; - color: ${(props) => props.theme.textColorSecondary}; + color: ${(props) => props.theme.textColor?.messageInputText}; resize: none; flex: 1; padding-right: 5px; @@ -324,8 +437,8 @@ const MultiLineInput = styled.textarea` height: 50px; } ::placeholder { - color: ${(props) => props.theme.textColorSecondary}; - transform: translateY(1px); + color: ${(props) => props.theme.textColor?.messageInputText}; + transform: translateY(0px); @media ${device.mobileL} { font-size: 14px; } @@ -337,4 +450,97 @@ const MultiLineInput = styled.textarea` `; const FileInput = styled.input` display: none; -`; \ No newline at end of file +`; + + +const ConnectWrapper = styled.div` + display: flex; + align-items: center; + flex-direction: column; + `; + +const StyledButton = styled.button` + border: 0px; + outline: 0px; + padding: 24px 9px; + font-weight: 500; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 147px; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; + `; + +const Connect = styled(StyledButton)` + color: rgb(255, 255, 255); + background: #D53A94; + `; + +const ConnectWrapperClose = styled.div` + display: flex; + align-items: center; + flex-direction: column; +`; + + +const StyledButtonClose = styled.button` + border: 0px; + outline: 0px; + padding: 24px 9px; + font-weight: 500; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 147px; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; +`; + +const ConnectClose = styled(StyledButtonClose)` + color: rgb(255, 255, 255); + background: #D53A94; + gap: 8px; + `; + + +const TokenWrapper = styled.div` + display: flex; + align-items: center; + flex-direction: column; + `; + + +const TokenStyledButton = styled.button` +border: 0px; +outline: 0px; +padding: 22px 9px; +font-weight: 500; +border-radius: 12px; +font-size: 17px; +cursor: pointer; +width: 100%; +height: 44px; +text-align: start; +align-items: center; +display: flex; +justify-content: center; +`; + +const TokenGet = styled(TokenStyledButton)` + color: #D53A94; + border: 2px solid #D53A94; + background: none; + gap: 8px; + `; +const Link = styled.a` + color: #D53A94; + link-decoration: none; + text-decoration: none; +` \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/VerificationFailed.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/VerificationFailed.tsx new file mode 100644 index 000000000..98f5c3dcc --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/MessageInput/VerificationFailed.tsx @@ -0,0 +1,107 @@ +import React, { useContext } from 'react' +import { Modal } from '../helpers/Modal' +import { Image, Section, Span } from '../../reusables' +import { ThemeContext } from '../theme/ThemeProvider'; +import TokenGatedIcon from "../../../icons/Token-Gated.svg" +import OpenLink from "../../../icons/OpenLink"; +import styled from 'styled-components'; +import useVerifyAccessControl from '../../../hooks/chat/useVerifyAccessControl'; + + +const VerificationFailed = () => { + const theme = useContext(ThemeContext); + const { setVerificationSuccessfull, verificationSuccessfull } = useVerifyAccessControl(); + return ( + +
+ Verification Failed + Please ensure the following conditions are met to participate and send messages. +
+ token-gated +
{/* Added marginLeft */} + Token Gated + You need to have 1 PUSH Token in your wallet to be able to send messages. +
+
+
+ + + Get Tokens + + + + { + setVerificationSuccessfull(false) + console.log(verificationSuccessfull) + }}> + + Close + + +
+
+
+ ) +} + +export default VerificationFailed + + +const ConnectWrapper = styled.div` + display: flex; + align-items: center; + flex-direction: column; + `; + +const ConnectWrapperClose = styled.div` + display: flex; + align-items: center; + flex-direction: column; +`; + + +const StyledButton = styled.button` + border: 0px; + outline: 0px; + padding: 22px 9px; + font-weight: 500; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 147px; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; + `; + +const StyledButtonClose = styled.button` + border: 0px; + outline: 0px; + padding: 24px 9px; + font-weight: 500; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 147px; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; +`; + + +const Connect = styled(StyledButton)` + color: #D53A94; + border: 2px solid #D53A94; + background: none; + gap: 8px; + `; + +const ConnectClose = styled(StyledButtonClose)` + color: rgb(255, 255, 255); + background: #D53A94; + gap: 8px; + `; diff --git a/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx b/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx new file mode 100644 index 000000000..569eadba0 --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx @@ -0,0 +1,355 @@ +import { useContext, useEffect, useState } from "react"; +import styled from "styled-components"; +import { ThemeContext } from "../theme/ThemeProvider"; +import { useChatData } from "../../../hooks"; +import { displayDefaultUser, getAddress, walletToPCAIP10 } from "../../../helpers"; +import { IToast, ModalButtonProps, User } from "../exportedTypes"; +import * as PushAPI from '@pushprotocol/restapi'; +import { ethers } from "ethers"; +import { addWalletValidation } from "../helpers/helper"; +// import ArrowLeftIcon from '../../../icons/ArrowLeft.svg'; +import CloseIcon from '../../../icons/close.svg'; +import { Spinner } from "../../supportChat/spinner/Spinner"; +import { MoreLightIcon } from '../../../icons/MoreLight'; +import { MoreDarkIcon } from '../../../icons/MoreDark'; +import { SearchIcon } from '../../../icons/SearchIcon'; +import { Section, Span, Image } from "../../reusables/sharedStyling"; +import { AddUserDarkIcon } from '../../../icons/Adddark'; +import { device } from "../../../config"; +import { MemberListContainer } from "./MemberListContainer"; +import useMediaQuery from "../../../hooks/useMediaQuery"; + +export const AddWalletContent = ({ onSubmit, handlePrevious, onClose, memberList, handleMemberList, title, groupMembers, isLoading, setToastInfo }: { onSubmit: () => void, onClose: () => void, handlePrevious: () => void, memberList: any, handleMemberList: any, title: string, groupMembers: any, isLoading?: boolean, setToastInfo: React.Dispatch> }) => { + const theme = useContext(ThemeContext); + + const [searchedUser, setSearchedUser] = useState(''); + const [filteredUserData, setFilteredUserData] = useState(null); + const [isInValidAddress, setIsInvalidAddress] = useState(false); + const [isLoadingSearch, setIsLoadingSearch] = useState(false); + const { account, env } = useChatData(); + const isMobile = useMediaQuery(device.mobileL); + + + + useEffect(() => { + if (isInValidAddress) { + console.log('here we go'); + setToastInfo({ + message: 'Invalid Address', + status: 'error' + }) + } + }, [isInValidAddress]); + + const onChangeSearchBox = (e: any) => { + setSearchedUser(e.target.value); + }; + + const handleUserSearch = async (userSearchData: string): Promise => { + try { + const caip10 = walletToPCAIP10(userSearchData); + let filteredData: User; + + if (userSearchData.length) { + filteredData = await PushAPI.user.get({ + account: caip10, + env: env + }); + + if (filteredData !== null) { + setFilteredUserData(filteredData); + } + // User is not in the protocol. Create new user + else { + if (ethers.utils.isAddress(userSearchData)) { + const displayUser = displayDefaultUser({ caip10 }); + setFilteredUserData(displayUser); + } else { + setIsInvalidAddress(true); + setFilteredUserData(null); + } + } + } else { + setFilteredUserData(null); + } + setIsLoadingSearch(false); + } + catch (error) { + setToastInfo({ + message: 'Unsuccessful search, Try again', + status: 'error' + }) + } + }; + + const handleSearch = async (e: any): Promise => { + setIsLoadingSearch(true); + setIsInvalidAddress(false); + e.preventDefault(); + if (!ethers.utils.isAddress(searchedUser)) { + let address: string; + try { + address = await getAddress(searchedUser, env) as string; + // if (!address) { + // address = await library.resolveName(searchedUser); + // } + // this ensures address are checksummed + address = ethers.utils.getAddress(address?.toLowerCase()); + if (address) { + handleUserSearch(address); + } else { + setIsInvalidAddress(true); + setFilteredUserData(null); + } + } catch (err) { + setIsInvalidAddress(true); + setFilteredUserData(null); + } finally { + setIsLoadingSearch(false); + } + } else { + handleUserSearch(searchedUser); + } + }; + + const clearInput = () => { + setSearchedUser(''); + setFilteredUserData(null); + setIsLoadingSearch(false); + }; + + const addMemberToList = (member: User) => { + let errorMessage = ''; + + errorMessage = addWalletValidation(member, memberList, groupMembers, account); + + if (errorMessage) { + setToastInfo({ + message: `Error`, + status: 'error' + }) + } else { + handleMemberList((prev: any) => [...prev, { ...member, isAdmin: false }]); + } + + setFilteredUserData(''); + clearInput(); + }; + + const removeMemberFromList = (member: User) => { + const filteredMembers = memberList?.filter((user: any) => user.wallets !== member.wallets); + handleMemberList(filteredMembers); + }; + + return ( +
+
+ + {/* handlePrevious()} cursor='pointer' /> */} + + Add Wallets + + onClose()} cursor='pointer' /> +
+ +
+ Add Wallets + + + {groupMembers + ? `0${memberList?.length + groupMembers?.length} / 09 Members` + : `0${memberList?.length} / 09 Members`} + +
+ +
+ + +
+ {searchedUser.length > 0 && ( + clearInput()} cursor='pointer' /> + )} + {searchedUser.length == 0 && !filteredUserData && +
+ +
+ } +
+
+
+ + {filteredUserData ? ( + + } + darkIcon={} + /> + + ) : isLoadingSearch ? ( +
+ +
+ ) : null} + + + {memberList?.map((member: any, index: any) => ( + } + darkIcon={} + /> + ))} + + +
+ onSubmit()} + isLoading={isLoading} + // loaderTitle={groupMembers ? 'Adding Members' : 'Creating group'} + memberListCount={memberList?.length > 0} + theme={theme} + > + {groupMembers ? 'Add To Group' : 'Create Group'} + {isLoading && } + +
+ +
+ ) +} + +const SearchBarContent = styled.form` + position: relative; + display: flex; + flex: 1; +`; + +const Input = styled.input` + box-sizing: border-box; + display: flex; + flex: 1; +// min-width: 445px; + height: 48px; + padding: 0px 50px 0px 16px; + margin: 10px 0px 0px; + border-radius: 99px; + border: 1px solid; + border-color: ${(props) => props.theme.modalSearchBarBorderColor}; + background: ${(props) => props.theme.modalSearchBarBackground}; + color: ${(props) => props.color || '#000'}; + &:focus { + outline: none; + background-image: linear-gradient( + ${(props) => props.theme.snapFocusBg}, + ${(props) => props.theme.snapFocusBg} + ), + linear-gradient( + to right, + rgba(182, 160, 245, 1), + rgba(244, 110, 246, 1), + rgba(255, 222, 211, 1), + rgba(255, 207, 197, 1) + ); + background-origin: border; + border: 1px solid transparent !important; + background-clip: padding-box, border-box; + } + &::placeholder { + color: #657795; + } + @media ${device.mobileL} { + min-width: 100%; + } +`; + +const MemberList = styled.div` + // justify-content: flex-start; + // padding: 0px 2px; + // margin: 0 0 34px 0; + flex: 1; + // background: red; + width: 100%; +`; + +const MultipleMemberList = styled.div` + overflow-y: auto; + height: fit-content; + max-height: 216px; + padding: 0px 2px; + overflow-x: hidden; + width: 100%; + + &::-webkit-scrollbar-track { + background-color: ${(props) => props.theme.scrollBg}; + } + + &::-webkit-scrollbar { + background-color: ${(props) => props.theme.scrollBg}; + width: 6px; + } + + @media (max-width: 768px) { + padding: 0px 0px 0px 0px; + max-height: 35vh; + + &::-webkit-scrollbar-track { + background-color: none; + border-radius: 9px; + } + + &::-webkit-scrollbar { + background-color: none; + width: 4px; + } + } + + &::-webkit-scrollbar-thumb { + border-radius: 10px; + background-image: -webkit-gradient( + linear, + left top, + left bottom, + color-stop(0.44, #cf1c84), + color-stop(0.72, #cf1c84), + color-stop(0.86, #cf1c84) + ); + } +`; + +const ModalConfirmButton = styled.button` + margin: 60px 0 0 0; + background: ${(props) => props.memberListCount ? '#CF1C84' : props.theme.groupButtonBackgroundColor}; + color: ${(props) => props.memberListCount ? '#fff' : props.theme.groupButtonTextColor}; + border: ${(props) => props.memberListCount ? 'none' : props.theme.modalConfirmButtonBorder}; + min-width: 50%; + box-sizing: border-box; + cursor: pointer; + border-radius: 15px; + padding: 16px; + font-size: 1.125rem; + font-weight: 500; + display: flex; + align-items: center; + justify-content: ${(props) => props.isLoading ? 'space-between' : 'center'}; + box-shadow: none; +`; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/exportedTypes.ts b/packages/uiweb/src/lib/components/chat/exportedTypes.ts index 4da3d5691..b42fc9590 100644 --- a/packages/uiweb/src/lib/components/chat/exportedTypes.ts +++ b/packages/uiweb/src/lib/components/chat/exportedTypes.ts @@ -4,12 +4,14 @@ import { IGroup } from '../../types' export interface IChatViewListProps { chatId: string; + chatFilterList?: Array; limit?: number; } export interface IChatViewComponentProps { messageInput?: boolean; chatViewList?: boolean; + chatFilterList?: Array; chatProfile?: boolean; //name needs to change chatId: string; //need confirmation on this limit?: number; @@ -17,6 +19,7 @@ export interface IChatViewComponentProps { gif?: boolean; file?: boolean; isConnected?: boolean; + onClick?: () => void; } export interface IChatProfile { @@ -63,6 +66,7 @@ export interface MessageInputProps { File?: boolean; Image?: boolean; isConnected?: boolean; + onClick?: () => void; } export type UpdateGroupType = { diff --git a/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx b/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx index c7cbef9b4..c8c13f30e 100644 --- a/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx +++ b/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx @@ -65,7 +65,7 @@ const ModalOverlay = styled.div` height: 100%; background-color: rgba(0, 0, 0, 0.4); /* Black with 40% opacity */ display: flex; - color: ${props => props.theme.textColorPrimary ?? '#000'}; + color: ${(props) => props.theme.backgroundColor.chatReceivedBubbleText?? '#000'}; justify-content: center; align-items: center; z-index: 2000; @@ -86,7 +86,7 @@ const ModalParent = styled.div` align-items: center; padding: 24px 20px; - background: ${(props => props.theme.bgColorPrimary)}; + background: ${(props) => props.theme.backgroundColor.chatReceivedBubbleBackground}; border-radius: 12px; width: ${(props => props.width ? props.width : 'auto')}; diff --git a/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx b/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx index 3009b3054..6e9ae030f 100644 --- a/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx +++ b/packages/uiweb/src/lib/components/chat/helpers/NewToast.tsx @@ -6,7 +6,7 @@ import { Spinner } from '../../supportChat/spinner/Spinner'; import { toast } from 'react-toastify'; import styled, { ThemeProvider } from 'styled-components'; import CloseIcon from '../../../icons/close.svg'; -import useMediaQuery from './useMediaQuery'; +import useMediaQuery from '../../../hooks/useMediaQuery'; import { useContext, useRef } from 'react'; import { Image } from '../../reusables'; import { device } from '../../../config'; @@ -114,7 +114,7 @@ const useToast = ( {toastTitle} diff --git a/packages/uiweb/src/lib/components/chat/helpers/index.ts b/packages/uiweb/src/lib/components/chat/helpers/index.ts index eb150f0e9..33149132c 100644 --- a/packages/uiweb/src/lib/components/chat/helpers/index.ts +++ b/packages/uiweb/src/lib/components/chat/helpers/index.ts @@ -1 +1,5 @@ -export * from './twitter'; \ No newline at end of file +export * from './twitter'; +export * from './Modal'; +export * from './NewToast'; +export * from './Toast'; +export * from './helper'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/theme/index.ts b/packages/uiweb/src/lib/components/chat/theme/index.ts index 34947cdb4..922f69d37 100644 --- a/packages/uiweb/src/lib/components/chat/theme/index.ts +++ b/packages/uiweb/src/lib/components/chat/theme/index.ts @@ -3,22 +3,86 @@ */ import { CHAT_THEME_OPTIONS } from '../exportedTypes'; +//theme type +interface IBorder { + chatViewComponent?: string; + chatProfile?: string; + messageInput?: string; +} +interface IBorderRadius { + chatViewComponent?: string; + chatProfile?: string; + messageInput?: string; +} +interface IBackgroundColor { + chatViewComponentBackground?: string; + chatProfileBackground?: string; + messageInputBackground?: string; + chatSentBubbleBackground?: string; + chatReceivedBubbleBackground?: string; + encryptionMessageBackground?: string; + buttonBackground?: string; +} + +interface ITextColor { + chatProfileText?: string; + messageInputText?: string; + chatSentBubbleText?: string; + chatReceivedBubbleText?: string; + timestamp?: string; + encryptionMessageText?: string; + buttonText?: string; + chatReceivedBubbleAddressText?: string; + chatReceivedBubbleTimestampText?: string; + chatSentBubbleTimestampText?: string; +} +interface IFont { + chatProfileText?: string; + messageInputText?: string; + chatSentBubbleText?: string; + chatReceivedBubbleText?: string; + timestamp?: string; + encryptionMessageText?: string; + chatReceivedBubbleAddressText?: string; + chatReceivedBubbleTimestampText?: string; + chatSentBubbleTimestampText?: string; +} +interface IFontWeight { + chatProfileText?: string; + messageInputText?: string; + chatSentBubbleText?: string; + chatReceivedBubbleText?: string; + timestamp?: string; + encryptionMessageText?: string; + chatReceivedBubbleAddressText?: string; + chatReceivedBubbleTimestampText?: string; + chatSentBubbleTimestampText?: string; +} +interface IIconColor { + emoji?: string; + attachment?: string; + sendButton?: string; + groupSettings?: string; +} export interface IChatTheme { - bgColorPrimary?: string; - bgColorSecondary?: string; - textColorPrimary?: string; - textColorSecondary?: string; - accentBgColor?: string; - accentTextColor?: string; - btnColorPrimary?: string; - chatBubbleAccentBgColor?:string; - border?: string; - borderRadius?: string; - iconColorPrimary?: string; + borderRadius?: IBorderRadius; + + backgroundColor?: IBackgroundColor; + + fontSize?: IFont; + + fontWeight?: IFontWeight; + fontFamily?: string; - chatBubblePrimaryBgColor?: string; - fileIconColor?: string; - dropdownBorderColor?: string; + + border?: IBorder; + iconColor?: IIconColor; + textColor?: ITextColor; + backdropFilter?: string; + scrollbarColor?: string; + + //below needs to be categorised + spinnerColor?: string; modalPrimaryTextColor?: string; modalSearchBarBorderColor?: string; modalSearchBarBackground?: string; @@ -26,12 +90,12 @@ export interface IChatTheme { groupButtonBackgroundColor?: string; groupButtonTextColor?: string; modalConfirmButtonBorder?: string; - groupSearchProfilBackground?: string, - modalInputBorderColor?: string, - snackbarBorderText?: string, - snackbarBorderIcon?: string, - modalContentBackground?: string, - modalProfileTextColor?: string, + groupSearchProfilBackground?: string; + modalInputBorderColor?: string; + snackbarBorderText?: string; + snackbarBorderIcon?: string; + modalContentBackground?: string; + modalProfileTextColor?: string; toastSuccessBackground?: string; toastErrorBackground?: string; toastShadowColor?: string; @@ -40,27 +104,84 @@ export interface IChatTheme { modalBorderColor?: string; modalDescriptionTextColor?: string; modalIconColor?: string; - pendingCardBackground?: string, + pendingCardBackground?: string; modalHeadingColor?: string; defaultBorder?: string; } +//dark theme object export const lightChatTheme: IChatTheme = { - bgColorPrimary: '#fff', - chatBubblePrimaryBgColor: '#fff', - bgColorSecondary: - 'linear-gradient(179.97deg, #EEF5FF 0.02%, #ECE9FA 123.25%)', - textColorPrimary: '#000', - textColorSecondary: 'rgb(101, 119, 149)', - chatBubbleAccentBgColor: 'rgb(202, 89, 155)', - accentBgColor: 'rgb(202, 89, 155)', - accentTextColor: '#fff', - btnColorPrimary: 'rgb(202, 89, 155)', - border: 'none', - borderRadius: '24px', - iconColorPrimary: 'none', - fileIconColor: '#000', - dropdownBorderColor: '1px solid rgb(229, 232, 246)', + borderRadius: { + chatViewComponent: '24px', + chatProfile: '32px', + messageInput: '13px', + }, + + backgroundColor: { + chatViewComponentBackground: + 'linear-gradient(179.97deg, #EEF5FF 0.02%, #ECE9FA 123.25%)', + chatProfileBackground: '#fff', + messageInputBackground: '#fff', + chatSentBubbleBackground: 'rgb(202, 89, 155)', + chatReceivedBubbleBackground: '#fff', + encryptionMessageBackground: '#fff', + buttonBackground: 'rgb(202, 89, 155)', + }, + + fontSize: { + chatProfileText: '17px', + messageInputText: '16px', + chatSentBubbleText: '16px', + chatReceivedBubbleText: '16px', + timestamp: '12px', + encryptionMessageText: '13px', + chatReceivedBubbleAddressText: '16px', + chatReceivedBubbleTimestampText: '12px', + chatSentBubbleTimestampText: '12px', + }, + + fontWeight: { + chatProfileText: '300', + messageInputText: '400', + chatSentBubbleText: '400', + chatReceivedBubbleText: '400', + timestamp: '400', + encryptionMessageText: '400', + chatReceivedBubbleAddressText: '300', + chatReceivedBubbleTimestampText: '400', + chatSentBubbleTimestampText: '400', + }, + + fontFamily: 'inherit', + + border: { + chatViewComponent: 'none', + chatProfile: 'none', + messageInput: 'none', + }, + + iconColor: { + emoji: 'rgb(101, 119, 149)', + attachment: 'rgb(101, 119, 149)', + sendButton: 'rgb(101, 119, 149)', + groupSettings: 'rgb(101, 119, 149)', + }, + textColor: { + chatProfileText: '#000', + messageInputText: '#000', + chatSentBubbleText: '#fff', + chatReceivedBubbleText: '#000', + timestamp: '400', + encryptionMessageText: '#000', + buttonText: '#fff', + chatReceivedBubbleAddressText: '#000', + chatReceivedBubbleTimestampText: '#000', + chatSentBubbleTimestampText: '#fff', + }, + backdropFilter: 'none', + spinnerColor: 'rgb(202, 89, 155)', + scrollbarColor: 'rgb(202, 89, 155)', + //the rest param needs to be included in categories modalPrimaryTextColor: '#1E1E1E', modalSearchBarBorderColor: '#BAC4D6', modalSearchBarBackground: '#FFF', @@ -74,8 +195,10 @@ export const lightChatTheme: IChatTheme = { snackbarBorderIcon: 'none', modalContentBackground: '#FFFFFF', modalProfileTextColor: '#1E1E1E', - toastSuccessBackground: 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #F3FFF9 42.81%)', - toastErrorBackground: 'linear-gradient(90.15deg, #FF2070 -125.65%, #FF2D79 -125.63%, #FFF9FB 42.81%)', + toastSuccessBackground: + 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #F3FFF9 42.81%)', + toastErrorBackground: + 'linear-gradient(90.15deg, #FF2070 -125.65%, #FF2D79 -125.63%, #FFF9FB 42.81%)', toastShadowColor: '#ccc', toastBorderColor: '#F4F3FF', mainBg: '#fff', @@ -88,21 +211,76 @@ export const lightChatTheme: IChatTheme = { }; export const darkChatTheme: IChatTheme = { - chatBubblePrimaryBgColor: '#fff', - bgColorPrimary: 'rgb(47, 49, 55)', - bgColorSecondary: 'rgb(40, 42, 46)', - textColorPrimary: '#fff', - textColorSecondary: 'rgb(182, 188, 214)', - chatBubbleAccentBgColor: 'rgb(202, 89, 155)', - accentBgColor: 'rgb(202, 89, 155)', - accentTextColor: '#fff', - btnColorPrimary: 'rgb(202, 89, 155)', - border: 'none', - borderRadius: '24px', - iconColorPrimary: - 'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)', - dropdownBorderColor: '1px solid rgb(74, 79, 103)', - fileIconColor: '#fff', + borderRadius: { + chatViewComponent: '24px', + chatProfile: '32px', + messageInput: '13px', + }, + + backgroundColor: { + chatViewComponentBackground: 'rgb(40, 42, 46);', + chatProfileBackground: 'rgb(64, 70, 80);', + messageInputBackground: 'rgb(64, 70, 80);', + chatSentBubbleBackground: 'rgb(202, 89, 155)', + chatReceivedBubbleBackground: 'rgb(64, 70, 80);', + encryptionMessageBackground: 'rgb(64, 70, 80);', + buttonBackground: 'rgb(202, 89, 155)', + }, + + fontSize: { + chatProfileText: '17px', + messageInputText: '16px', + chatSentBubbleText: '16px', + chatReceivedBubbleText: '16px', + timestamp: '12px', + encryptionMessageText: '13px', + chatReceivedBubbleAddressText: '16px', + chatReceivedBubbleTimestampText: '12px', + chatSentBubbleTimestampText: '12px', + }, + + fontWeight: { + chatProfileText: '300', + messageInputText: '400', + chatSentBubbleText: '400', + chatReceivedBubbleText: '400', + timestamp: '400', + encryptionMessageText: '400', + chatReceivedBubbleAddressText: '300', + chatReceivedBubbleTimestampText: '400', + chatSentBubbleTimestampText: '400', + }, + + fontFamily: 'inherit', + + border: { + chatViewComponent: 'none', + chatProfile: 'none', + messageInput: 'none', + }, + + iconColor: { + emoji: 'rgba(120, 126, 153, 1)', + attachment: 'rgba(120, 126, 153, 1)', + sendButton: 'rgba(120, 126, 153, 1)', + groupSettings: 'rgba(120, 126, 153, 1)', + }, + textColor: { + chatProfileText: 'rgb(182, 188, 214)', + messageInputText: 'rgb(182, 188, 214)', + chatSentBubbleText: '#fff', + chatReceivedBubbleText: 'rgb(182, 188, 214)', + timestamp: 'rgb(182, 188, 214)', + encryptionMessageText: 'rgb(182, 188, 214)', + buttonText: '#fff', + chatReceivedBubbleAddressText: 'rgb(182, 188, 214)', + chatReceivedBubbleTimestampText: 'rgb(182, 188, 214)', + chatSentBubbleTimestampText: '#fff', + }, + backdropFilter: 'none', + spinnerColor: 'rgb(202, 89, 155)', + scrollbarColor: 'rgb(202, 89, 155)', + //the rest param needs to be included in categories modalPrimaryTextColor: '#B6BCD6', modalSearchBarBorderColor: '#4A4F67', modalSearchBarBackground: '#282A2E', @@ -114,11 +292,13 @@ export const darkChatTheme: IChatTheme = { modalInputBorderColor: '#4A4F67', snackbarBorderText: '#B6BCD6', snackbarBorderIcon: - 'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)', + 'brightness(0) saturate(100%) invert(89%) sepia(8%) saturate(1567%) hue-rotate(191deg) brightness(86%) contrast(93%)', modalContentBackground: '#2F3137', modalProfileTextColor: '#B6BCD6', - toastSuccessBackground: 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #2F3137 42.81%)', - toastErrorBackground: 'linear-gradient(89.96deg, #FF2070 -101.85%, #2F3137 51.33%)', + toastSuccessBackground: + 'linear-gradient(90.15deg, #30CC8B -125.65%, #30CC8B -125.63%, #2F3137 42.81%)', + toastErrorBackground: + 'linear-gradient(89.96deg, #FF2070 -101.85%, #2F3137 51.33%)', toastShadowColor: '#00000010', toastBorderColor: '#4A4F67', mainBg: '#000', @@ -127,6 +307,5 @@ export const darkChatTheme: IChatTheme = { modalIconColor: '#787E99', pendingCardBackground: 'rgba(173, 176, 190, 0.08)', modalHeadingColor: '#B6BCD6', - defaultBorder: '#4A4F67' + defaultBorder: '#4A4F67', }; - diff --git a/packages/uiweb/src/lib/config/constants.ts b/packages/uiweb/src/lib/config/constants.ts index 32782b3ce..bc6c35ab0 100644 --- a/packages/uiweb/src/lib/config/constants.ts +++ b/packages/uiweb/src/lib/config/constants.ts @@ -17,6 +17,9 @@ export const Constants = { }; +export const ALCHEMY_API_KEY = 'rtkd-a4JWpnViQBZdNCiFBGTJdp5e0R2'; +export const RAINBOW_PROJECT_ID = 'e22146926e005c4e513b24024521ef51'; +export const RAINBOW_APP_NAME = 'Push-sdk'; export const NETWORK_DETAILS = { 5: { network: "goerli", diff --git a/packages/uiweb/src/lib/context/chatContext.ts b/packages/uiweb/src/lib/context/chatContext.ts index c075f3377..1757a940a 100644 --- a/packages/uiweb/src/lib/context/chatContext.ts +++ b/packages/uiweb/src/lib/context/chatContext.ts @@ -1,4 +1,4 @@ -import { Env,IMessageIPFS, IUser } from "@pushprotocol/restapi"; +import { Env,IMessageIPFS, IUser, SignerType } from "@pushprotocol/restapi"; import { Constants } from "../config"; import { createContext } from "react"; @@ -8,6 +8,8 @@ export interface IChatDataContextValues { setAccount: React.Dispatch>; pgpPrivateKey: string | null; setPgpPrivateKey: React.Dispatch>; + signer: SignerType | undefined; + setSigner: React.Dispatch>; env: Env; setEnv: React.Dispatch>; pushChatSocket: any; @@ -23,6 +25,10 @@ export const initialChatDataContextValues: IChatDataContextValues = { setAccount: () => { /**/ }, + signer: undefined, + setSigner: () => { + /**/ + }, pgpPrivateKey: '', setPgpPrivateKey: () => { /**/ diff --git a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx index 278f9f5ca..56f8cbe6c 100644 --- a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx +++ b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx @@ -6,13 +6,16 @@ import { } from '../context/chatContext'; import { ThemeContext } from '../components/chat/theme/ThemeProvider'; import useGetChatProfile from '../hooks/useGetChatProfile'; -import { IUser } from '@pushprotocol/restapi'; +import { IUser, SignerType } from '@pushprotocol/restapi'; import { IChatTheme, lightChatTheme } from '../components/chat/theme'; +import { getAddressFromSigner } from '../helpers'; + export interface IChatUIProviderProps { children: ReactNode; theme?: IChatTheme; account?: string | null; + signer?: SignerType | undefined; pgpPrivateKey?: string | null; env?: ENV; } @@ -22,10 +25,13 @@ export const ChatUIProvider = ({ account = null, theme, pgpPrivateKey = null, + signer = undefined, env = Constants.ENV.PROD, }: IChatUIProviderProps) => { const [accountVal, setAccountVal] = useState(account); - const [pushChatSocket, setPushChatSocket] = useState(null); + const [pushChatSocket, setPushChatSocket] = useState(null); + const [signerVal, setSignerVal] = useState(signer); + const [pgpPrivateKeyVal, setPgpPrivateKeyVal] = useState(pgpPrivateKey); const [envVal, setEnvVal] = useState(env); @@ -34,18 +40,28 @@ export const ChatUIProvider = ({ const [isPushChatSocketConnected, setIsPushChatSocketConnected] = useState(false); - useEffect(() => { - resetStates(); - setEnvVal(env); - setAccountVal(account); - setPgpPrivateKeyVal(pgpPrivateKey); - }, [env,account,pgpPrivateKey]) + (async()=>{ + resetStates(); + setEnvVal(env); + + if (signer) { + if (!account) { + const address = await getAddressFromSigner(signer); + setAccountVal(address); + } + else{ + setAccountVal(account); + } + } + setSignerVal(signer); + setPgpPrivateKeyVal(pgpPrivateKey); + })() + + }, [env,account,pgpPrivateKey,signer]) + - useEffect(() => { - setAccountVal(account) - }, [account]) @@ -68,6 +84,8 @@ useEffect(() => { const value: IChatDataContextValues = { account: accountVal, + signer:signerVal, + setSigner:setSignerVal, setAccount: setAccountVal, pgpPrivateKey: pgpPrivateKeyVal, setPgpPrivateKey: setPgpPrivateKeyVal, diff --git a/packages/uiweb/src/lib/helpers/address.ts b/packages/uiweb/src/lib/helpers/address.ts index 5af01ad2c..c5909879a 100644 --- a/packages/uiweb/src/lib/helpers/address.ts +++ b/packages/uiweb/src/lib/helpers/address.ts @@ -1,5 +1,6 @@ import { ethers } from 'ethers'; import type { Web3Provider, InfuraProvider } from '@ethersproject/providers'; +import { SignerType } from '@pushprotocol/restapi'; /** * @@ -97,4 +98,12 @@ export const resolveNewEns = async (address: string, provider: InfuraProvider) = export const isPCAIP = (id: string) => { const prefix = `eip155:`; return id?.startsWith(prefix); +}; + +export const getAddressFromSigner = async (signer: SignerType): Promise => { + if ('getAddress' in signer) { + return await signer.getAddress(); + } else { + return signer.account['address'] ?? ''; + } }; \ No newline at end of file diff --git a/packages/uiweb/src/lib/helpers/chat/localStorage.ts b/packages/uiweb/src/lib/helpers/chat/localStorage.ts index 4d7dac903..9ceedaaf9 100644 --- a/packages/uiweb/src/lib/helpers/chat/localStorage.ts +++ b/packages/uiweb/src/lib/helpers/chat/localStorage.ts @@ -61,3 +61,12 @@ export const setPfp = ({ }) => { localStorage.setItem(account, value); }; + +export const setAccessControl = (chatId: string, toRemove: boolean) => { + if (toRemove) { + localStorage.removeItem(chatId); + } else { + const timestamp = new Date().getTime(); + localStorage.setItem(chatId, JSON.stringify(timestamp)); + } +}; diff --git a/packages/uiweb/src/lib/hooks/chat/index.ts b/packages/uiweb/src/lib/hooks/chat/index.ts index 8aa6ea6bb..9f32daab1 100644 --- a/packages/uiweb/src/lib/hooks/chat/index.ts +++ b/packages/uiweb/src/lib/hooks/chat/index.ts @@ -3,8 +3,6 @@ export * from './useChatData'; export * from './useChatProfile'; export * from './usePushChatSocket'; -export * from './usePushSendMessage'; -export * from './useGetGroupByID'; export * from './useFetchChat'; export * from './useFetchConversationHash'; export * from './usePushSendMessage'; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts index 4a0887956..1472d2752 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts @@ -20,7 +20,7 @@ const useFetchChat = () => { setLoading(true); try { const chat = await PushAPI.chat.chat({ - account: account!, + account: account ? account : '0x0', toDecrypt: pgpPrivateKey ? true : false, pgpPrivateKey: String(pgpPrivateKey), recipient: chatId, diff --git a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts index 7d5484a7c..80da0de72 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts @@ -137,7 +137,7 @@ export const usePushChatSocket = () => { } // eslint-disable-next-line react-hooks/exhaustive-deps - }, [account, env]); + }, [account, env, pgpPrivateKey]); return { pushChatSocket, diff --git a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts index dbba7517d..415799e77 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts @@ -1,8 +1,9 @@ import * as PushAPI from '@pushprotocol/restapi'; import { useCallback, useContext, useState } from 'react'; - +import useVerifyAccessControl from './useVerifyAccessControl'; import { useChatData } from '..'; import { ENV } from '../../config'; +import { setAccessControl } from '../../helpers'; interface SendMessageParams { message: string; @@ -14,6 +15,8 @@ const usePushSendMessage = () => { const [error, setError] = useState(); const [loading, setLoading] = useState(false); + const { verificationSuccessfull, setVerificationSuccessfull, setVerified } = + useVerifyAccessControl(); const { pgpPrivateKey, env, account } = useChatData(); const sendMessage = useCallback( @@ -30,11 +33,17 @@ const usePushSendMessage = () => { env: env, }); setLoading(false); + console.log(response); if (!response) { return false; } return; } catch (error: Error | any) { + if (error.message.includes('400')) { + setAccessControl(chatId, true); + setVerified(false); + setVerificationSuccessfull(false); + } setLoading(false); setError(error.message); console.log(error); diff --git a/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts b/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts new file mode 100644 index 000000000..f50ce89f6 --- /dev/null +++ b/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts @@ -0,0 +1,65 @@ +import * as PushAPI from '@pushprotocol/restapi'; +import { useCallback, useState } from 'react'; +import { ENV } from '../../config'; +import { useChatData } from './useChatData'; +import { setAccessControl } from '../../helpers'; + +interface VerifyAccessControlParams { + chatId: string; + did: string; +} + +const useVerifyAccessControl = () => { + const [error, setError] = useState(); + const [loading, setLoading] = useState(false); + const [verificationSuccessfull, setVerificationSuccessfull] = + useState(true); + const [verified, setVerified] = useState(false); + + const { pgpPrivateKey, env, account } = useChatData(); + + console.log('Verification control hook'); + const verifyAccessControl = useCallback( + async (options: VerifyAccessControlParams) => { + const { chatId, did } = options || {}; + setLoading(true); + try { + const response = await PushAPI.chat.getGroupAccess({ + chatId: chatId, + did: `eip155:${did}`, + env: env, + }); + setLoading(false); + if (response.chatAccess === false) { + setVerificationSuccessfull(false); + } else if (response.chatAccess === true) { + setVerified(true); + setAccessControl(chatId, false); + } + console.log(response); + if (!response) { + return false; + } + return; + } catch (error: Error | any) { + setLoading(false); + setVerificationSuccessfull(false); + setError(error.message); + console.log(error); + return; + } + }, + [pgpPrivateKey, account, verificationSuccessfull, verified, setVerified] + ); + return { + verifyAccessControl, + error, + loading, + verificationSuccessfull, + setVerificationSuccessfull, + verified, + setVerified, + }; +}; + +export default useVerifyAccessControl; diff --git a/packages/uiweb/src/lib/hooks/index.ts b/packages/uiweb/src/lib/hooks/index.ts index 35a59c29f..7b432b467 100644 --- a/packages/uiweb/src/lib/hooks/index.ts +++ b/packages/uiweb/src/lib/hooks/index.ts @@ -7,4 +7,5 @@ export * from './chat'; export * from './chatAndNotification'; export * from './useDivOffsetWidth'; export * from './useDeviceWidthCheck'; -export * from './useGetChatProfile'; \ No newline at end of file +export * from './useGetChatProfile'; +export * from './useMediaQuery'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/helpers/useMediaQuery.ts b/packages/uiweb/src/lib/hooks/useMediaQuery.ts similarity index 100% rename from packages/uiweb/src/lib/components/chat/helpers/useMediaQuery.ts rename to packages/uiweb/src/lib/hooks/useMediaQuery.ts diff --git a/packages/uiweb/src/lib/icons/ArrowLeft.svg b/packages/uiweb/src/lib/icons/ArrowLeft.svg deleted file mode 100644 index de2987515..000000000 --- a/packages/uiweb/src/lib/icons/ArrowLeft.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/packages/uiweb/src/lib/icons/Emoji.tsx b/packages/uiweb/src/lib/icons/Emoji.tsx index cb9a9dbfc..748bceb64 100644 --- a/packages/uiweb/src/lib/icons/Emoji.tsx +++ b/packages/uiweb/src/lib/icons/Emoji.tsx @@ -4,9 +4,9 @@ type EmojiIconsProps = { color?: string; } -export const EmojiIcon: React.FC = ({color="none"}) => { +export const EmojiIcon: React.FC = ({color="#494D5F"}) => { return ( - + diff --git a/packages/uiweb/src/lib/icons/OpenLink.tsx b/packages/uiweb/src/lib/icons/OpenLink.tsx new file mode 100644 index 000000000..a5f7decf3 --- /dev/null +++ b/packages/uiweb/src/lib/icons/OpenLink.tsx @@ -0,0 +1,16 @@ +import React from 'react' + +interface OpenLinkProps { + height?: string; + width?: string; +} + +const OpenLink = ({height="8", width="8"}) => { + return ( + + + + ) +} + +export default OpenLink \ No newline at end of file diff --git a/packages/uiweb/src/lib/types/index.ts b/packages/uiweb/src/lib/types/index.ts index 4efb3e5ed..8337566b4 100644 --- a/packages/uiweb/src/lib/types/index.ts +++ b/packages/uiweb/src/lib/types/index.ts @@ -1,6 +1,6 @@ import type { ReactElement } from 'react'; import type { ENV } from '../config'; -import type { ParsedResponseType, IFeeds, } from '@pushprotocol/restapi'; +import type { ParsedResponseType, IFeeds, Rules, } from '@pushprotocol/restapi'; import { Bytes, TypedDataDomain, TypedDataField, providers } from 'ethers'; export interface IMessageIPFS { @@ -134,6 +134,6 @@ export interface IGroup { groupDescription: string | null, groupCreator: string, chatId: string, - groupType?:string | undefined + groupType?:string | undefined, + rules?: Rules | null, } - diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index 13ac1d4f6..47ea13878 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -2,6 +2,18 @@ # yarn lockfile v1 +"@adraffy/ens-normalize@1.9.0": + version "1.9.0" + resolved "https://registry.yarnpkg.com/@adraffy/ens-normalize/-/ens-normalize-1.9.0.tgz#223572538f6bea336750039bb43a4016dcc8182d" + integrity sha512-iowxq3U30sghZotgl4s/oJRci6WPBfNO5YYgk2cIOMCHr3LeGPcsZjCEr+33Q4N+oV3OABDAtA+pyvWjbvBifQ== + +"@babel/runtime@^7.12.5", "@babel/runtime@^7.17.2", "@babel/runtime@^7.22.6": + version "7.22.10" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.10.tgz#ae3e9631fd947cb7e3610d3e9d8fef5f76696682" + integrity sha512-21t/fkKLMZI4pqP2wlmsQAWnYW1PDyKyyUV4vCi+B25ydmdaYTKXPwCj0BzSUnZf4seIiYvSA3jcZ3gdsMFkLQ== + dependencies: + regenerator-runtime "^0.14.0" + "@babel/runtime@^7.13.10", "@babel/runtime@^7.21.0": version "7.21.5" resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.21.5.tgz" @@ -9,6 +21,34 @@ dependencies: regenerator-runtime "^0.13.11" +"@coinbase/wallet-sdk@^3.6.6": + version "3.7.1" + resolved "https://registry.yarnpkg.com/@coinbase/wallet-sdk/-/wallet-sdk-3.7.1.tgz#44b3b7a925ff5cc974e4cbf7a44199ffdcf03541" + integrity sha512-LjyoDCB+7p0waQXfK+fUgcAs3Ezk6S6e+LYaoFjpJ6c9VTop3NyZF40Pi7df4z7QJohCwzuIDjz0Rhtig6Y7Pg== + dependencies: + "@metamask/safe-event-emitter" "2.0.0" + "@solana/web3.js" "^1.70.1" + bind-decorator "^1.0.11" + bn.js "^5.1.1" + buffer "^6.0.3" + clsx "^1.1.0" + eth-block-tracker "6.1.0" + eth-json-rpc-filters "5.1.0" + eth-rpc-errors "4.0.2" + json-rpc-engine "6.1.0" + keccak "^3.0.1" + preact "^10.5.9" + qs "^6.10.3" + rxjs "^6.6.3" + sha.js "^2.4.11" + stream-browserify "^3.0.0" + util "^0.12.4" + +"@emotion/hash@^0.8.0": + version "0.8.0" + resolved "https://registry.yarnpkg.com/@emotion/hash/-/hash-0.8.0.tgz#bbbff68978fefdbe68ccb533bc8cbe1d1afb5413" + integrity sha512-kBJtf7PH6aWwZ6fka3zQ0p6SBYzx4fl1LoZXE2RrnYST9Xljm7WfKJrU4g/Xr3Beg72MLrp1AWNUmuYJTL7Cow== + "@ethersproject/abi@^5.0.1": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz" @@ -213,6 +253,23 @@ resolved "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.1.1.tgz" integrity sha512-m0G6wlnhm/AX0H12IOWtK8gASEMffnX08RtKkCgTdHb9JpHKGloI7icFfLg9ZmQeavcvR0PKmzxClyuFPSjKWw== +"@ledgerhq/connect-kit-loader@^1.1.0": + version "1.1.2" + resolved "https://registry.yarnpkg.com/@ledgerhq/connect-kit-loader/-/connect-kit-loader-1.1.2.tgz#d550e3c1f046e4c796f32a75324b03606b7e226a" + integrity sha512-mscwGroSJQrCTjtNGBu+18FQbZYA4+q6Tyx6K7CXHl6AwgZKbWfZYdgP2F+fyZcRUdGRsMX8QtvU61VcGGtO1A== + +"@lit-labs/ssr-dom-shim@^1.0.0", "@lit-labs/ssr-dom-shim@^1.1.0": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@lit-labs/ssr-dom-shim/-/ssr-dom-shim-1.1.1.tgz#64df34e2f12e68e78ac57e571d25ec07fa460ca9" + integrity sha512-kXOeFbfCm4fFf2A3WwVEeQj55tMZa8c8/f9AKHMobQMkzNUfUj+antR3fRPaZJawsa1aZiP/Da3ndpZrwEe4rQ== + +"@lit/reactive-element@^1.3.0", "@lit/reactive-element@^1.6.0": + version "1.6.3" + resolved "https://registry.yarnpkg.com/@lit/reactive-element/-/reactive-element-1.6.3.tgz#25b4eece2592132845d303e091bad9b04cdcfe03" + integrity sha512-QuTgnG52Poic7uM1AN5yJ09QMe0O28e10XzSvWDz02TJiiKee4stsiownEIadWm8nYzyDAyT+gKzUoZmiWQtsQ== + dependencies: + "@lit-labs/ssr-dom-shim" "^1.0.0" + "@livepeer/core-react@^1.8.0": version "1.8.0" resolved "https://registry.npmjs.org/@livepeer/core-react/-/core-react-1.8.0.tgz" @@ -251,6 +308,114 @@ livepeer "2.8.0" zustand "^4.3.9" +"@metamask/safe-event-emitter@2.0.0", "@metamask/safe-event-emitter@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@metamask/safe-event-emitter/-/safe-event-emitter-2.0.0.tgz#af577b477c683fad17c619a78208cede06f9605c" + integrity sha512-/kSXhY692qiV1MXu6EeOZvg5nECLclxNXcKCxJ3cXQgYuRymRHpdx/t7JXfsK+JLjwA1e1c1/SBrlQYpusC29Q== + +"@metamask/utils@^3.0.1": + version "3.6.0" + resolved "https://registry.yarnpkg.com/@metamask/utils/-/utils-3.6.0.tgz#b218b969a05ca7a8093b5d1670f6625061de707d" + integrity sha512-9cIRrfkWvHblSiNDVXsjivqa9Ak0RYo/1H6tqTqTbAx+oBK2Sva0lWDHxGchOqA7bySGUJKAWSNJvH6gdHZ0gQ== + dependencies: + "@types/debug" "^4.1.7" + debug "^4.3.4" + semver "^7.3.8" + superstruct "^1.0.3" + +"@motionone/animation@^10.15.1": + version "10.15.1" + resolved "https://registry.yarnpkg.com/@motionone/animation/-/animation-10.15.1.tgz#4a85596c31cbc5100ae8eb8b34c459fb0ccf6807" + integrity sha512-mZcJxLjHor+bhcPuIFErMDNyrdb2vJur8lSfMCsuCB4UyV8ILZLvK+t+pg56erv8ud9xQGK/1OGPt10agPrCyQ== + dependencies: + "@motionone/easing" "^10.15.1" + "@motionone/types" "^10.15.1" + "@motionone/utils" "^10.15.1" + tslib "^2.3.1" + +"@motionone/dom@^10.16.2": + version "10.16.2" + resolved "https://registry.yarnpkg.com/@motionone/dom/-/dom-10.16.2.tgz#0c44df8ee3d1cfc50ee11d27050b27824355a61a" + integrity sha512-bnuHdNbge1FutZXv+k7xub9oPWcF0hsu8y1HTH/qg6av58YI0VufZ3ngfC7p2xhMJMnoh0LXFma2EGTgPeCkeg== + dependencies: + "@motionone/animation" "^10.15.1" + "@motionone/generators" "^10.15.1" + "@motionone/types" "^10.15.1" + "@motionone/utils" "^10.15.1" + hey-listen "^1.0.8" + tslib "^2.3.1" + +"@motionone/easing@^10.15.1": + version "10.15.1" + resolved "https://registry.yarnpkg.com/@motionone/easing/-/easing-10.15.1.tgz#95cf3adaef34da6deebb83940d8143ede3deb693" + integrity sha512-6hIHBSV+ZVehf9dcKZLT7p5PEKHGhDwky2k8RKkmOvUoYP3S+dXsKupyZpqx5apjd9f+php4vXk4LuS+ADsrWw== + dependencies: + "@motionone/utils" "^10.15.1" + tslib "^2.3.1" + +"@motionone/generators@^10.15.1": + version "10.15.1" + resolved "https://registry.yarnpkg.com/@motionone/generators/-/generators-10.15.1.tgz#dc6abb11139d1bafe758a41c134d4c753a9b871c" + integrity sha512-67HLsvHJbw6cIbLA/o+gsm7h+6D4Sn7AUrB/GPxvujse1cGZ38F5H7DzoH7PhX+sjvtDnt2IhFYF2Zp1QTMKWQ== + dependencies: + "@motionone/types" "^10.15.1" + "@motionone/utils" "^10.15.1" + tslib "^2.3.1" + +"@motionone/svelte@^10.16.2": + version "10.16.2" + resolved "https://registry.yarnpkg.com/@motionone/svelte/-/svelte-10.16.2.tgz#0b37c3b12927814d31d24941d1ca0ff49981b444" + integrity sha512-38xsroKrfK+aHYhuQlE6eFcGy0EwrB43Q7RGjF73j/kRUTcLNu/LAaKiLLsN5lyqVzCgTBVt4TMT/ShWbTbc5Q== + dependencies: + "@motionone/dom" "^10.16.2" + tslib "^2.3.1" + +"@motionone/types@^10.15.1": + version "10.15.1" + resolved "https://registry.yarnpkg.com/@motionone/types/-/types-10.15.1.tgz#89441b54285012795cbba8612cbaa0fa420db3eb" + integrity sha512-iIUd/EgUsRZGrvW0jqdst8st7zKTzS9EsKkP+6c6n4MPZoQHwiHuVtTQLD6Kp0bsBLhNzKIBlHXponn/SDT4hA== + +"@motionone/utils@^10.15.1": + version "10.15.1" + resolved "https://registry.yarnpkg.com/@motionone/utils/-/utils-10.15.1.tgz#6b5f51bde75be88b5411e084310299050368a438" + integrity sha512-p0YncgU+iklvYr/Dq4NobTRdAPv9PveRDUXabPEeOjBLSO/1FNB2phNTZxOxpi1/GZwYpAoECEa0Wam+nsmhSw== + dependencies: + "@motionone/types" "^10.15.1" + hey-listen "^1.0.8" + tslib "^2.3.1" + +"@motionone/vue@^10.16.2": + version "10.16.2" + resolved "https://registry.yarnpkg.com/@motionone/vue/-/vue-10.16.2.tgz#faf13afc27620a2df870c71c58a04ee8de8dea65" + integrity sha512-7/dEK/nWQXOkJ70bqb2KyNfSWbNvWqKKq1C8juj+0Mg/AorgD8O5wE3naddK0G+aXuNMqRuc4jlsYHHWHtIzVw== + dependencies: + "@motionone/dom" "^10.16.2" + tslib "^2.3.1" + +"@noble/curves@1.1.0", "@noble/curves@^1.0.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.1.0.tgz#f13fc667c89184bc04cccb9b11e8e7bae27d8c3d" + integrity sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA== + dependencies: + "@noble/hashes" "1.3.1" + +"@noble/curves@~1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.0.0.tgz#e40be8c7daf088aaf291887cbc73f43464a92932" + integrity sha512-2upgEu0iLiDVDZkNLeFV2+ht0BAVgQnEmCk6JsOch9Rp8xfkMCbvbAZlA2pBHQc73dbl+vFOXfqkf4uemdn0bw== + dependencies: + "@noble/hashes" "1.3.0" + +"@noble/hashes@1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.0.tgz#085fd70f6d7d9d109671090ccae1d3bec62554a1" + integrity sha512-ilHEACi9DwqJB0pw7kv+Apvh50jiiSyR/cQ3y4W7lOR5mhvn/50FLUfsnfJz0BDZtl/RR16kXvptiv6q1msYZg== + +"@noble/hashes@1.3.1", "@noble/hashes@^1.3.1", "@noble/hashes@~1.3.0": + version "1.3.1" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.1.tgz#8831ef002114670c603c458ab8b11328406953a9" + integrity sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA== + "@pushprotocol/socket@^0.5.0": version "0.5.0" resolved "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz" @@ -539,11 +704,238 @@ dependencies: "@babel/runtime" "^7.13.10" +"@rainbow-me/rainbowkit@^1.0.8": + version "1.0.8" + resolved "https://registry.yarnpkg.com/@rainbow-me/rainbowkit/-/rainbowkit-1.0.8.tgz#280b3c572118957cdcfd6e54bc5bea12f969d980" + integrity sha512-m1B9/X3p8MLmj4fDfs2NpJlFRmKz7vOR0jmcdBw2SMFzXqP1FQFQc4pjvtLEeyfEUGSNNceGrecFZRVS0Qk//A== + dependencies: + "@vanilla-extract/css" "1.9.1" + "@vanilla-extract/dynamic" "2.0.2" + "@vanilla-extract/sprinkles" "1.5.0" + clsx "1.1.1" + qrcode "1.5.0" + react-remove-scroll "2.5.4" + +"@safe-global/safe-apps-provider@^0.17.1": + version "0.17.1" + resolved "https://registry.yarnpkg.com/@safe-global/safe-apps-provider/-/safe-apps-provider-0.17.1.tgz#72df2a66be5343940ed505efe594ed3b0f2f7015" + integrity sha512-lYfRqrbbK1aKU1/UGkYWc/X7PgySYcumXKc5FB2uuwAs2Ghj8uETuW5BrwPqyjBknRxutFbTv+gth/JzjxAhdQ== + dependencies: + "@safe-global/safe-apps-sdk" "8.0.0" + events "^3.3.0" + +"@safe-global/safe-apps-sdk@8.0.0": + version "8.0.0" + resolved "https://registry.yarnpkg.com/@safe-global/safe-apps-sdk/-/safe-apps-sdk-8.0.0.tgz#9bdfe0e0d85e1b2d279bb840f40c4b930aaf8bc1" + integrity sha512-gYw0ki/EAuV1oSyMxpqandHjnthZjYYy+YWpTAzf8BqfXM3ItcZLpjxfg+3+mXW8HIO+3jw6T9iiqEXsqHaMMw== + dependencies: + "@safe-global/safe-gateway-typescript-sdk" "^3.5.3" + viem "^1.0.0" + +"@safe-global/safe-apps-sdk@^8.0.0": + version "8.1.0" + resolved "https://registry.yarnpkg.com/@safe-global/safe-apps-sdk/-/safe-apps-sdk-8.1.0.tgz#d1d0c69cd2bf4eef8a79c5d677d16971926aa64a" + integrity sha512-XJbEPuaVc7b9n23MqlF6c+ToYIS3f7P2Sel8f3cSBQ9WORE4xrSuvhMpK9fDSFqJ7by/brc+rmJR/5HViRr0/w== + dependencies: + "@safe-global/safe-gateway-typescript-sdk" "^3.5.3" + viem "^1.0.0" + +"@safe-global/safe-gateway-typescript-sdk@^3.5.3": + version "3.9.0" + resolved "https://registry.yarnpkg.com/@safe-global/safe-gateway-typescript-sdk/-/safe-gateway-typescript-sdk-3.9.0.tgz#5aa36c05b865f6fe754d1d460f83bc9bf3a0145e" + integrity sha512-DxRM/sBBQhv955dPtdo0z2Bf2fXxrzoRUnGyTa3+4Z0RAhcyiqnffRP1Bt3tyuvlyfZnFL0RsvkqDcAIKzq3RQ== + dependencies: + cross-fetch "^3.1.5" + +"@scure/base@~1.1.0": + version "1.1.1" + resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.1.tgz#ebb651ee52ff84f420097055f4bf46cfba403938" + integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== + +"@scure/bip32@1.3.0": + version "1.3.0" + resolved "https://registry.yarnpkg.com/@scure/bip32/-/bip32-1.3.0.tgz#6c8d980ef3f290987736acd0ee2e0f0d50068d87" + integrity sha512-bcKpo1oj54hGholplGLpqPHRbIsnbixFtc06nwuNM5/dwSXOq/AAYoIBRsBmnZJSdfeNW5rnff7NTAz3ZCqR9Q== + dependencies: + "@noble/curves" "~1.0.0" + "@noble/hashes" "~1.3.0" + "@scure/base" "~1.1.0" + +"@scure/bip39@1.2.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@scure/bip39/-/bip39-1.2.0.tgz#a207e2ef96de354de7d0002292ba1503538fc77b" + integrity sha512-SX/uKq52cuxm4YFXWFaVByaSHJh2w3BnokVSeUJVCv6K7WulT9u2BuNRBhuFl8vAuYnzx9bEu9WgpcNYTrYieg== + dependencies: + "@noble/hashes" "~1.3.0" + "@scure/base" "~1.1.0" + "@socket.io/component-emitter@~3.1.0": version "3.1.0" resolved "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz" integrity sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg== +"@solana/buffer-layout@^4.0.0": + version "4.0.1" + resolved "https://registry.yarnpkg.com/@solana/buffer-layout/-/buffer-layout-4.0.1.tgz#b996235eaec15b1e0b5092a8ed6028df77fa6c15" + integrity sha512-E1ImOIAD1tBZFRdjeM4/pzTiTApC0AOBGwyAMS4fwIodCWArzJ3DWdoh8cKxeFM2fElkxBh2Aqts1BPC373rHA== + dependencies: + buffer "~6.0.3" + +"@solana/web3.js@^1.70.1": + version "1.78.4" + resolved "https://registry.yarnpkg.com/@solana/web3.js/-/web3.js-1.78.4.tgz#e8ca9abe4ec2af5fc540c1d272efee24aaffedb3" + integrity sha512-up5VG1dK+GPhykmuMIozJZBbVqpm77vbOG6/r5dS7NBGZonwHfTLdBbsYc3rjmaQ4DpCXUa3tUc4RZHRORvZrw== + dependencies: + "@babel/runtime" "^7.22.6" + "@noble/curves" "^1.0.0" + "@noble/hashes" "^1.3.1" + "@solana/buffer-layout" "^4.0.0" + agentkeepalive "^4.3.0" + bigint-buffer "^1.1.5" + bn.js "^5.2.1" + borsh "^0.7.0" + bs58 "^4.0.1" + buffer "6.0.3" + fast-stable-stringify "^1.0.0" + jayson "^4.1.0" + node-fetch "^2.6.12" + rpc-websockets "^7.5.1" + superstruct "^0.14.2" + +"@stablelib/aead@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/aead/-/aead-1.0.1.tgz#c4b1106df9c23d1b867eb9b276d8f42d5fc4c0c3" + integrity sha512-q39ik6sxGHewqtO0nP4BuSe3db5G1fEJE8ukvngS2gLkBXyy6E7pLubhbYgnkDFv6V8cWaxcE4Xn0t6LWcJkyg== + +"@stablelib/binary@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/binary/-/binary-1.0.1.tgz#c5900b94368baf00f811da5bdb1610963dfddf7f" + integrity sha512-ClJWvmL6UBM/wjkvv/7m5VP3GMr9t0osr4yVgLZsLCOz4hGN9gIAFEqnJ0TsSMAN+n840nf2cHZnA5/KFqHC7Q== + dependencies: + "@stablelib/int" "^1.0.1" + +"@stablelib/bytes@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/bytes/-/bytes-1.0.1.tgz#0f4aa7b03df3080b878c7dea927d01f42d6a20d8" + integrity sha512-Kre4Y4kdwuqL8BR2E9hV/R5sOrUj6NanZaZis0V6lX5yzqC3hBuVSDXUIBqQv/sCpmuWRiHLwqiT1pqqjuBXoQ== + +"@stablelib/chacha20poly1305@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/chacha20poly1305/-/chacha20poly1305-1.0.1.tgz#de6b18e283a9cb9b7530d8767f99cde1fec4c2ee" + integrity sha512-MmViqnqHd1ymwjOQfghRKw2R/jMIGT3wySN7cthjXCBdO+qErNPUBnRzqNpnvIwg7JBCg3LdeCZZO4de/yEhVA== + dependencies: + "@stablelib/aead" "^1.0.1" + "@stablelib/binary" "^1.0.1" + "@stablelib/chacha" "^1.0.1" + "@stablelib/constant-time" "^1.0.1" + "@stablelib/poly1305" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/chacha@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/chacha/-/chacha-1.0.1.tgz#deccfac95083e30600c3f92803a3a1a4fa761371" + integrity sha512-Pmlrswzr0pBzDofdFuVe1q7KdsHKhhU24e8gkEwnTGOmlC7PADzLVxGdn2PoNVBBabdg0l/IfLKg6sHAbTQugg== + dependencies: + "@stablelib/binary" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/constant-time@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/constant-time/-/constant-time-1.0.1.tgz#bde361465e1cf7b9753061b77e376b0ca4c77e35" + integrity sha512-tNOs3uD0vSJcK6z1fvef4Y+buN7DXhzHDPqRLSXUel1UfqMB1PWNsnnAezrKfEwTLpN0cGH2p9NNjs6IqeD0eg== + +"@stablelib/ed25519@^1.0.2": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@stablelib/ed25519/-/ed25519-1.0.3.tgz#f8fdeb6f77114897c887bb6a3138d659d3f35996" + integrity sha512-puIMWaX9QlRsbhxfDc5i+mNPMY+0TmQEskunY1rZEBPi1acBCVQAhnsk/1Hk50DGPtVsZtAWQg4NHGlVaO9Hqg== + dependencies: + "@stablelib/random" "^1.0.2" + "@stablelib/sha512" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/hash@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/hash/-/hash-1.0.1.tgz#3c944403ff2239fad8ebb9015e33e98444058bc5" + integrity sha512-eTPJc/stDkdtOcrNMZ6mcMK1e6yBbqRBaNW55XA1jU8w/7QdnCF0CmMmOD1m7VSkBR44PWrMHU2l6r8YEQHMgg== + +"@stablelib/hkdf@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/hkdf/-/hkdf-1.0.1.tgz#b4efd47fd56fb43c6a13e8775a54b354f028d98d" + integrity sha512-SBEHYE16ZXlHuaW5RcGk533YlBj4grMeg5TooN80W3NpcHRtLZLLXvKyX0qcRFxf+BGDobJLnwkvgEwHIDBR6g== + dependencies: + "@stablelib/hash" "^1.0.1" + "@stablelib/hmac" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/hmac@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/hmac/-/hmac-1.0.1.tgz#3d4c1b8cf194cb05d28155f0eed8a299620a07ec" + integrity sha512-V2APD9NSnhVpV/QMYgCVMIYKiYG6LSqw1S65wxVoirhU/51ACio6D4yDVSwMzuTJXWZoVHbDdINioBwKy5kVmA== + dependencies: + "@stablelib/constant-time" "^1.0.1" + "@stablelib/hash" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/int@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/int/-/int-1.0.1.tgz#75928cc25d59d73d75ae361f02128588c15fd008" + integrity sha512-byr69X/sDtDiIjIV6m4roLVWnNNlRGzsvxw+agj8CIEazqWGOQp2dTYgQhtyVXV9wpO6WyXRQUzLV/JRNumT2w== + +"@stablelib/keyagreement@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/keyagreement/-/keyagreement-1.0.1.tgz#4612efb0a30989deb437cd352cee637ca41fc50f" + integrity sha512-VKL6xBwgJnI6l1jKrBAfn265cspaWBPAPEc62VBQrWHLqVgNRE09gQ/AnOEyKUWrrqfD+xSQ3u42gJjLDdMDQg== + dependencies: + "@stablelib/bytes" "^1.0.1" + +"@stablelib/poly1305@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/poly1305/-/poly1305-1.0.1.tgz#93bfb836c9384685d33d70080718deae4ddef1dc" + integrity sha512-1HlG3oTSuQDOhSnLwJRKeTRSAdFNVB/1djy2ZbS35rBSJ/PFqx9cf9qatinWghC2UbfOYD8AcrtbUQl8WoxabA== + dependencies: + "@stablelib/constant-time" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/random@^1.0.1", "@stablelib/random@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@stablelib/random/-/random-1.0.2.tgz#2dece393636489bf7e19c51229dd7900eddf742c" + integrity sha512-rIsE83Xpb7clHPVRlBj8qNe5L8ISQOzjghYQm/dZ7VaM2KHYwMW5adjQjrzTZCchFnNCNhkwtnOBa9HTMJCI8w== + dependencies: + "@stablelib/binary" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/sha256@1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/sha256/-/sha256-1.0.1.tgz#77b6675b67f9b0ea081d2e31bda4866297a3ae4f" + integrity sha512-GIIH3e6KH+91FqGV42Kcj71Uefd/QEe7Dy42sBTeqppXV95ggCcxLTk39bEr+lZfJmp+ghsR07J++ORkRELsBQ== + dependencies: + "@stablelib/binary" "^1.0.1" + "@stablelib/hash" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/sha512@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/sha512/-/sha512-1.0.1.tgz#6da700c901c2c0ceacbd3ae122a38ac57c72145f" + integrity sha512-13gl/iawHV9zvDKciLo1fQ8Bgn2Pvf7OV6amaRVKiq3pjQ3UmEpXxWiAfV8tYjUpeZroBxtyrwtdooQT/i3hzw== + dependencies: + "@stablelib/binary" "^1.0.1" + "@stablelib/hash" "^1.0.1" + "@stablelib/wipe" "^1.0.1" + +"@stablelib/wipe@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@stablelib/wipe/-/wipe-1.0.1.tgz#d21401f1d59ade56a62e139462a97f104ed19a36" + integrity sha512-WfqfX/eXGiAd3RJe4VU2snh/ZPwtSjLG4ynQ/vYzvghTh7dHFcI1wl+nrkWG6lGhukOxOsUHfv8dUXr58D0ayg== + +"@stablelib/x25519@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@stablelib/x25519/-/x25519-1.0.3.tgz#13c8174f774ea9f3e5e42213cbf9fc68a3c7b7fd" + integrity sha512-KnTbKmUhPhHavzobclVJQG5kuivH+qDLpe84iRqX3CLrKp881cF160JvXJ+hjn1aMyCwYOKeIZefIH/P5cJoRw== + dependencies: + "@stablelib/keyagreement" "^1.0.1" + "@stablelib/random" "^1.0.2" + "@stablelib/wipe" "^1.0.1" + "@stitches/core@^1.2.8": version "1.2.8" resolved "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz" @@ -566,6 +958,11 @@ resolved "https://registry.npmjs.org/@tanstack/query-core/-/query-core-4.29.23.tgz" integrity sha512-4BMHPrkfYmLP+NvqbbkV7Mk1nnphu+bNmxhhuB0+EMjKA7VfyFCfiyiTf55RRDgLaevyb9LrFK16lHW2owF52w== +"@tanstack/query-core@4.32.6": + version "4.32.6" + resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-4.32.6.tgz#cf7df91ab1542e67a82624fefb12a55f580b4c01" + integrity sha512-YVB+mVWENQwPyv+40qO7flMgKZ0uI41Ph7qXC2Zf1ft5AIGfnXnMZyifB2ghhZ27u+5wm5mlzO4Y6lwwadzxCA== + "@tanstack/query-persist-client-core@4.29.23": version "4.29.23" resolved "https://registry.npmjs.org/@tanstack/query-persist-client-core/-/query-persist-client-core-4.29.23.tgz" @@ -573,6 +970,20 @@ dependencies: "@tanstack/query-core" "4.29.23" +"@tanstack/query-persist-client-core@4.32.6": + version "4.32.6" + resolved "https://registry.yarnpkg.com/@tanstack/query-persist-client-core/-/query-persist-client-core-4.32.6.tgz#8dbe10c3e86246a708f2a8725a5596c55fe57d7e" + integrity sha512-MJJ7CldvT5HOel50h/3wOZZwVlIcroFD5Vxn8vPsfo2C0qQ208ilmN/81JWutm/lWy4n2BjnCrrWv6HvVI7S0w== + dependencies: + "@tanstack/query-core" "4.32.6" + +"@tanstack/query-sync-storage-persister@^4.27.1": + version "4.32.6" + resolved "https://registry.yarnpkg.com/@tanstack/query-sync-storage-persister/-/query-sync-storage-persister-4.32.6.tgz#f9fe8284372f9e15a7beb2913189dc4779063b60" + integrity sha512-hTwNo5O5EvydbfdVvwnwY0nIrNg1BxKEV4WAA8A+0NP9yc/9xoWy8RxbIkcz1p4JN2JhagaTKek8Fa5h5KitsA== + dependencies: + "@tanstack/query-persist-client-core" "4.32.6" + "@tanstack/react-query-persist-client@4.29.23": version "4.29.23" resolved "https://registry.npmjs.org/@tanstack/react-query-persist-client/-/react-query-persist-client-4.29.23.tgz" @@ -580,6 +991,13 @@ dependencies: "@tanstack/query-persist-client-core" "4.29.23" +"@tanstack/react-query-persist-client@^4.28.0": + version "4.32.6" + resolved "https://registry.yarnpkg.com/@tanstack/react-query-persist-client/-/react-query-persist-client-4.32.6.tgz#f8c539e8119461e4901dd6f212608ef8cfd4d117" + integrity sha512-EmNnYpvFYpxS4j5WFeNmfVVBxqq4RDnEFDBZwNKRfb4pzukcx/hcWtwqFk7Qj0EI4Dk8QGl239MEYwJbAc83tQ== + dependencies: + "@tanstack/query-persist-client-core" "4.32.6" + "@tanstack/react-query@4.29.23": version "4.29.23" resolved "https://registry.npmjs.org/@tanstack/react-query/-/react-query-4.29.23.tgz" @@ -588,6 +1006,62 @@ "@tanstack/query-core" "4.29.23" use-sync-external-store "^1.2.0" +"@tanstack/react-query@^4.28.0": + version "4.32.6" + resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-4.32.6.tgz#f88c2d57f423d4cd295c501df2edeb3285a301bd" + integrity sha512-AITu/IKJJJXsHHeXNBy5bclu12t08usMCY0vFC2dh9SP/w6JAk5U9GwfjOIPj3p+ATADZvxQPe8UiCtMLNeQbg== + dependencies: + "@tanstack/query-core" "4.32.6" + use-sync-external-store "^1.2.0" + +"@types/connect@^3.4.33": + version "3.4.35" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.35.tgz#5fcf6ae445e4021d1fc2219a4873cc73a3bb2ad1" + integrity sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ== + dependencies: + "@types/node" "*" + +"@types/debug@^4.1.7": + version "4.1.8" + resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.8.tgz#cef723a5d0a90990313faec2d1e22aee5eecb317" + integrity sha512-/vPO1EPOs306Cvhwv7KfVfYvOJqA/S/AXjaHQiJboCZzcNDb+TIJFN9/2C9DZ//ijSKWioNyUxD792QmDJ+HKQ== + dependencies: + "@types/ms" "*" + +"@types/ms@*": + version "0.7.31" + resolved "https://registry.yarnpkg.com/@types/ms/-/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" + integrity sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA== + +"@types/node@*": + version "20.5.0" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.5.0.tgz#7fc8636d5f1aaa3b21e6245e97d56b7f56702313" + integrity sha512-Mgq7eCtoTjT89FqNoTzzXg2XvCi5VMhRV6+I2aYanc6kQCBImeNaAYRs/DyoVqk1YEUJK5gN9VO7HRIdz4Wo3Q== + +"@types/node@^12.12.54": + version "12.20.55" + resolved "https://registry.yarnpkg.com/@types/node/-/node-12.20.55.tgz#c329cbd434c42164f846b909bd6f85b5537f6240" + integrity sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ== + +"@types/trusted-types@^2.0.2": + version "2.0.3" + resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.3.tgz#a136f83b0758698df454e328759dbd3d44555311" + integrity sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g== + +"@types/ws@^7.4.4": + version "7.4.7" + resolved "https://registry.yarnpkg.com/@types/ws/-/ws-7.4.7.tgz#f7c390a36f7a0679aa69de2d501319f4f8d9b702" + integrity sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww== + dependencies: + "@types/node" "*" + +"@types/ws@^8.5.4": + version "8.5.5" + resolved "https://registry.yarnpkg.com/@types/ws/-/ws-8.5.5.tgz#af587964aa06682702ee6dcbc7be41a80e4b28eb" + integrity sha512-lwhs8hktwxSjf9UaZ9tG5M03PGogvFaH8gUgLNbN9HKIg0dvv6q+gkSuJ8HN4/VbyxkuLzCjlN7GquQ0gUJfIg== + dependencies: + "@types/node" "*" + "@unstoppabledomains/resolution@^8.5.0": version "8.5.0" resolved "https://registry.npmjs.org/@unstoppabledomains/resolution/-/resolution-8.5.0.tgz" @@ -599,6 +1073,428 @@ crypto-js "^4.1.1" elliptic "^6.5.4" +"@vanilla-extract/css@1.9.1": + version "1.9.1" + resolved "https://registry.yarnpkg.com/@vanilla-extract/css/-/css-1.9.1.tgz#337b79faa5f8f98915a90c3fe3c30b54be746c09" + integrity sha512-pu2SFiff5jRhPwvGoj8cM5l/qIyLvigOmy22ss5DGjwV5pJYezRjDLxWumi2luIwioMWvh9EozCjyfH8nq+7fQ== + dependencies: + "@emotion/hash" "^0.8.0" + "@vanilla-extract/private" "^1.0.3" + ahocorasick "1.0.2" + chalk "^4.1.1" + css-what "^5.0.1" + cssesc "^3.0.0" + csstype "^3.0.7" + deep-object-diff "^1.1.0" + deepmerge "^4.2.2" + media-query-parser "^2.0.2" + outdent "^0.8.0" + +"@vanilla-extract/dynamic@2.0.2": + version "2.0.2" + resolved "https://registry.yarnpkg.com/@vanilla-extract/dynamic/-/dynamic-2.0.2.tgz#13a3e461964c8029a52e6b6b631009ca6a8b27f5" + integrity sha512-U4nKaEQ8Kuz+exXEr51DUpyaOuzo24/S/k1YbDPQR06cYcNjQqvwFRnwWtZ+9ImocqM1wTKtzrdUgSTtLGIwAg== + dependencies: + "@vanilla-extract/private" "^1.0.3" + +"@vanilla-extract/private@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@vanilla-extract/private/-/private-1.0.3.tgz#7ec72bc2ff6fe51f9d650f962e8d1989b073690f" + integrity sha512-17kVyLq3ePTKOkveHxXuIJZtGYs+cSoev7BlP+Lf4916qfDhk/HBjvlYDe8egrea7LNPHKwSZJK/bzZC+Q6AwQ== + +"@vanilla-extract/sprinkles@1.5.0": + version "1.5.0" + resolved "https://registry.yarnpkg.com/@vanilla-extract/sprinkles/-/sprinkles-1.5.0.tgz#c921183ae518bb484299c2dc81f2acefd91c3dbe" + integrity sha512-W58f2Rzz5lLmk0jbhgStVlZl5wEiPB1Ur3fRvUaBM+MrifZ3qskmFq/CiH//fEYeG5Dh9vF1qRviMMH46cX9Nw== + +"@wagmi/chains@1.6.0": + version "1.6.0" + resolved "https://registry.yarnpkg.com/@wagmi/chains/-/chains-1.6.0.tgz#eb992ad28dbaaab729b5bcab3e5b461e8a035656" + integrity sha512-5FRlVxse5P4ZaHG3GTvxwVANSmYJas1eQrTBHhjxVtqXoorm0aLmCHbhmN8Xo1yu09PaWKlleEvfE98yH4AgIw== + +"@wagmi/chains@1.7.0": + version "1.7.0" + resolved "https://registry.yarnpkg.com/@wagmi/chains/-/chains-1.7.0.tgz#8f6ad81cf867e1788417f7c978ca92bc083ecaf6" + integrity sha512-TKVeHv0GqP5sV1yQ8BDGYToAFezPnCexbbBpeH14x7ywi5a1dDStPffpt9x+ytE6LJWkZ6pAMs/HNWXBQ5Nqmw== + +"@wagmi/connectors@2.7.0": + version "2.7.0" + resolved "https://registry.yarnpkg.com/@wagmi/connectors/-/connectors-2.7.0.tgz#547972502cbe6719217043fe5b610ac48534dc93" + integrity sha512-1KOL0HTJl5kzSC/YdKwFwiokr6poUQn1V/tcT0TpG3iH2x0lSM7FTkvCjVVY/6lKzTXrLlo9y2aE7AsOPnkvqg== + dependencies: + "@coinbase/wallet-sdk" "^3.6.6" + "@ledgerhq/connect-kit-loader" "^1.1.0" + "@safe-global/safe-apps-provider" "^0.17.1" + "@safe-global/safe-apps-sdk" "^8.0.0" + "@walletconnect/ethereum-provider" "2.9.2" + "@walletconnect/legacy-provider" "^2.0.0" + "@walletconnect/modal" "2.6.1" + "@walletconnect/utils" "2.9.2" + abitype "0.8.7" + eventemitter3 "^4.0.7" + +"@wagmi/core@1.3.9": + version "1.3.9" + resolved "https://registry.yarnpkg.com/@wagmi/core/-/core-1.3.9.tgz#16bac164fe74203fde68abe7991b947d3a26e6ab" + integrity sha512-SrnABCrsDvhiMCLLLyzyHnZbEumsFT/XWlJJQZeyEDcixL95R7XQwOaaoRI4MpNilCtMtu3jzN57tA5Z2iA+kw== + dependencies: + "@wagmi/chains" "1.7.0" + "@wagmi/connectors" "2.7.0" + abitype "0.8.7" + eventemitter3 "^4.0.7" + zustand "^4.3.1" + +"@walletconnect/core@2.9.2": + version "2.9.2" + resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.9.2.tgz#c46734ca63771b28fd77606fd521930b7ecfc5e1" + integrity sha512-VARMPAx8sIgodeyngDHbealP3B621PQqjqKsByFUTOep8ZI1/R/20zU+cmq6j9RCrL+kLKZcrZqeVzs8Z7OlqQ== + dependencies: + "@walletconnect/heartbeat" "1.2.1" + "@walletconnect/jsonrpc-provider" "1.0.13" + "@walletconnect/jsonrpc-types" "1.0.3" + "@walletconnect/jsonrpc-utils" "1.0.8" + "@walletconnect/jsonrpc-ws-connection" "1.0.13" + "@walletconnect/keyvaluestorage" "^1.0.2" + "@walletconnect/logger" "^2.0.1" + "@walletconnect/relay-api" "^1.0.9" + "@walletconnect/relay-auth" "^1.0.4" + "@walletconnect/safe-json" "^1.0.2" + "@walletconnect/time" "^1.0.2" + "@walletconnect/types" "2.9.2" + "@walletconnect/utils" "2.9.2" + events "^3.3.0" + lodash.isequal "4.5.0" + uint8arrays "^3.1.0" + +"@walletconnect/crypto@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@walletconnect/crypto/-/crypto-1.0.3.tgz#7b8dd4d7e2884fe3543c7c07aea425eef5ef9dd4" + integrity sha512-+2jdORD7XQs76I2Odgr3wwrtyuLUXD/kprNVsjWRhhhdO9Mt6WqVzOPu0/t7OHSmgal8k7SoBQzUc5hu/8zL/g== + dependencies: + "@walletconnect/encoding" "^1.0.2" + "@walletconnect/environment" "^1.0.1" + "@walletconnect/randombytes" "^1.0.3" + aes-js "^3.1.2" + hash.js "^1.1.7" + tslib "1.14.1" + +"@walletconnect/encoding@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@walletconnect/encoding/-/encoding-1.0.2.tgz#cb3942ad038d6a6bf01158f66773062dd25724da" + integrity sha512-CrwSBrjqJ7rpGQcTL3kU+Ief+Bcuu9PH6JLOb+wM6NITX1GTxR/MfNwnQfhLKK6xpRAyj2/nM04OOH6wS8Imag== + dependencies: + is-typedarray "1.0.0" + tslib "1.14.1" + typedarray-to-buffer "3.1.5" + +"@walletconnect/environment@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@walletconnect/environment/-/environment-1.0.1.tgz#1d7f82f0009ab821a2ba5ad5e5a7b8ae3b214cd7" + integrity sha512-T426LLZtHj8e8rYnKfzsw1aG6+M0BT1ZxayMdv/p8yM0MU+eJDISqNY3/bccxRr4LrF9csq02Rhqt08Ibl0VRg== + dependencies: + tslib "1.14.1" + +"@walletconnect/ethereum-provider@2.9.2": + version "2.9.2" + resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.9.2.tgz#fb3a6fca279bb4e98e75baa2fb9730545d41bb99" + integrity sha512-eO1dkhZffV1g7vpG19XUJTw09M/bwGUwwhy1mJ3AOPbOSbMPvwiCuRz2Kbtm1g9B0Jv15Dl+TvJ9vTgYF8zoZg== + dependencies: + "@walletconnect/jsonrpc-http-connection" "^1.0.7" + "@walletconnect/jsonrpc-provider" "^1.0.13" + "@walletconnect/jsonrpc-types" "^1.0.3" + "@walletconnect/jsonrpc-utils" "^1.0.8" + "@walletconnect/sign-client" "2.9.2" + "@walletconnect/types" "2.9.2" + "@walletconnect/universal-provider" "2.9.2" + "@walletconnect/utils" "2.9.2" + events "^3.3.0" + +"@walletconnect/events@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@walletconnect/events/-/events-1.0.1.tgz#2b5f9c7202019e229d7ccae1369a9e86bda7816c" + integrity sha512-NPTqaoi0oPBVNuLv7qPaJazmGHs5JGyO8eEAk5VGKmJzDR7AHzD4k6ilox5kxk1iwiOnFopBOOMLs86Oa76HpQ== + dependencies: + keyvaluestorage-interface "^1.0.0" + tslib "1.14.1" + +"@walletconnect/heartbeat@1.2.1": + version "1.2.1" + resolved "https://registry.yarnpkg.com/@walletconnect/heartbeat/-/heartbeat-1.2.1.tgz#afaa3a53232ae182d7c9cff41c1084472d8f32e9" + integrity sha512-yVzws616xsDLJxuG/28FqtZ5rzrTA4gUjdEMTbWB5Y8V1XHRmqq4efAxCw5ie7WjbXFSUyBHaWlMR+2/CpQC5Q== + dependencies: + "@walletconnect/events" "^1.0.1" + "@walletconnect/time" "^1.0.2" + tslib "1.14.1" + +"@walletconnect/jsonrpc-http-connection@^1.0.4", "@walletconnect/jsonrpc-http-connection@^1.0.7": + version "1.0.7" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-http-connection/-/jsonrpc-http-connection-1.0.7.tgz#a6973569b8854c22da707a759d241e4f5c2d5a98" + integrity sha512-qlfh8fCfu8LOM9JRR9KE0s0wxP6ZG9/Jom8M0qsoIQeKF3Ni0FyV4V1qy/cc7nfI46SLQLSl4tgWSfLiE1swyQ== + dependencies: + "@walletconnect/jsonrpc-utils" "^1.0.6" + "@walletconnect/safe-json" "^1.0.1" + cross-fetch "^3.1.4" + tslib "1.14.1" + +"@walletconnect/jsonrpc-provider@1.0.13", "@walletconnect/jsonrpc-provider@^1.0.13", "@walletconnect/jsonrpc-provider@^1.0.6": + version "1.0.13" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-provider/-/jsonrpc-provider-1.0.13.tgz#9a74da648d015e1fffc745f0c7d629457f53648b" + integrity sha512-K73EpThqHnSR26gOyNEL+acEex3P7VWZe6KE12ZwKzAt2H4e5gldZHbjsu2QR9cLeJ8AXuO7kEMOIcRv1QEc7g== + dependencies: + "@walletconnect/jsonrpc-utils" "^1.0.8" + "@walletconnect/safe-json" "^1.0.2" + tslib "1.14.1" + +"@walletconnect/jsonrpc-types@1.0.3", "@walletconnect/jsonrpc-types@^1.0.2", "@walletconnect/jsonrpc-types@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-types/-/jsonrpc-types-1.0.3.tgz#65e3b77046f1a7fa8347ae02bc1b841abe6f290c" + integrity sha512-iIQ8hboBl3o5ufmJ8cuduGad0CQm3ZlsHtujv9Eu16xq89q+BG7Nh5VLxxUgmtpnrePgFkTwXirCTkwJH1v+Yw== + dependencies: + keyvaluestorage-interface "^1.0.0" + tslib "1.14.1" + +"@walletconnect/jsonrpc-utils@1.0.8", "@walletconnect/jsonrpc-utils@^1.0.4", "@walletconnect/jsonrpc-utils@^1.0.6", "@walletconnect/jsonrpc-utils@^1.0.7", "@walletconnect/jsonrpc-utils@^1.0.8": + version "1.0.8" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-utils/-/jsonrpc-utils-1.0.8.tgz#82d0cc6a5d6ff0ecc277cb35f71402c91ad48d72" + integrity sha512-vdeb03bD8VzJUL6ZtzRYsFMq1eZQcM3EAzT0a3st59dyLfJ0wq+tKMpmGH7HlB7waD858UWgfIcudbPFsbzVdw== + dependencies: + "@walletconnect/environment" "^1.0.1" + "@walletconnect/jsonrpc-types" "^1.0.3" + tslib "1.14.1" + +"@walletconnect/jsonrpc-ws-connection@1.0.13": + version "1.0.13" + resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-ws-connection/-/jsonrpc-ws-connection-1.0.13.tgz#23b0cdd899801bfbb44a6556936ec2b93ef2adf4" + integrity sha512-mfOM7uFH4lGtQxG+XklYuFBj6dwVvseTt5/ahOkkmpcAEgz2umuzu7fTR+h5EmjQBdrmYyEBOWADbeaFNxdySg== + dependencies: + "@walletconnect/jsonrpc-utils" "^1.0.6" + "@walletconnect/safe-json" "^1.0.2" + events "^3.3.0" + tslib "1.14.1" + ws "^7.5.1" + +"@walletconnect/keyvaluestorage@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@walletconnect/keyvaluestorage/-/keyvaluestorage-1.0.2.tgz#92f5ca0f54c1a88a093778842ce0c874d86369c8" + integrity sha512-U/nNG+VLWoPFdwwKx0oliT4ziKQCEoQ27L5Hhw8YOFGA2Po9A9pULUYNWhDgHkrb0gYDNt//X7wABcEWWBd3FQ== + dependencies: + safe-json-utils "^1.1.1" + tslib "1.14.1" + +"@walletconnect/legacy-client@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/legacy-client/-/legacy-client-2.0.0.tgz#9f2c09694789fd4b6c5d68d6423b44bac55aed30" + integrity sha512-v5L7rYk9loVnfvUf0mF+76bUPFaU5/Vh7mzL6/950CD/yoGdzYZ3Kj+L7mkC6HPMEGeQsBP1+sqBuiVGZ/aODA== + dependencies: + "@walletconnect/crypto" "^1.0.3" + "@walletconnect/encoding" "^1.0.2" + "@walletconnect/jsonrpc-utils" "^1.0.4" + "@walletconnect/legacy-types" "^2.0.0" + "@walletconnect/legacy-utils" "^2.0.0" + "@walletconnect/safe-json" "^1.0.1" + "@walletconnect/window-getters" "^1.0.1" + "@walletconnect/window-metadata" "^1.0.1" + detect-browser "^5.3.0" + query-string "^6.13.5" + +"@walletconnect/legacy-modal@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/legacy-modal/-/legacy-modal-2.0.0.tgz#d0fab01a1337a8f5d88cdb1430cbef2d46072bbf" + integrity sha512-jckNd8lMhm4X7dX9TDdxM3bXKJnaqkRs6K2Mo5j6GmbIF9Eyx40jZ5+q457RVxvM6ciZEDT5s1wBHWdWoOo+9Q== + dependencies: + "@walletconnect/legacy-types" "^2.0.0" + "@walletconnect/legacy-utils" "^2.0.0" + copy-to-clipboard "^3.3.3" + preact "^10.12.0" + qrcode "^1.5.1" + +"@walletconnect/legacy-provider@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/legacy-provider/-/legacy-provider-2.0.0.tgz#08e2db1e4c234743b2f30422bc8100bc42e8fc44" + integrity sha512-A8xPebMI1A+50HbWwTpFCbwP7G+1NGKdTKyg8BUUg3h3Y9JucpC1W6w/x0v1Xw7qFEqQnz74LoIN/A3ytH9xrQ== + dependencies: + "@walletconnect/jsonrpc-http-connection" "^1.0.4" + "@walletconnect/jsonrpc-provider" "^1.0.6" + "@walletconnect/legacy-client" "^2.0.0" + "@walletconnect/legacy-modal" "^2.0.0" + "@walletconnect/legacy-types" "^2.0.0" + "@walletconnect/legacy-utils" "^2.0.0" + +"@walletconnect/legacy-types@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/legacy-types/-/legacy-types-2.0.0.tgz#224278ae2874c6a2ca805c2d1d062a511dcf7227" + integrity sha512-sOVrA7HUdbI1OwKyPOQU0/DdvTSVFlsXWpAk2K2WvP2erTkBWPMTJq6cv2BmKdoJ3p6gLApT7sd+jHi3OF71uw== + dependencies: + "@walletconnect/jsonrpc-types" "^1.0.2" + +"@walletconnect/legacy-utils@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/legacy-utils/-/legacy-utils-2.0.0.tgz#e3a637c00783f9cd2ae139b640f82223ab78ed9d" + integrity sha512-CPWxSVVXw0kgNCxvU126g4GiV3mzXmC8IPJ15twE46aJ1FX+RHEIfAzFMFz2F2+fEhBxL63A7dwNQKDXorRPcQ== + dependencies: + "@walletconnect/encoding" "^1.0.2" + "@walletconnect/jsonrpc-utils" "^1.0.4" + "@walletconnect/legacy-types" "^2.0.0" + "@walletconnect/safe-json" "^1.0.1" + "@walletconnect/window-getters" "^1.0.1" + "@walletconnect/window-metadata" "^1.0.1" + detect-browser "^5.3.0" + query-string "^6.13.5" + +"@walletconnect/logger@^2.0.1": + version "2.0.1" + resolved "https://registry.yarnpkg.com/@walletconnect/logger/-/logger-2.0.1.tgz#7f489b96e9a1ff6bf3e58f0fbd6d69718bf844a8" + integrity sha512-SsTKdsgWm+oDTBeNE/zHxxr5eJfZmE9/5yp/Ku+zJtcTAjELb3DXueWkDXmE9h8uHIbJzIb5wj5lPdzyrjT6hQ== + dependencies: + pino "7.11.0" + tslib "1.14.1" + +"@walletconnect/modal-core@2.6.1": + version "2.6.1" + resolved "https://registry.yarnpkg.com/@walletconnect/modal-core/-/modal-core-2.6.1.tgz#bc76055d0b644a2d4b98024324825c108a700905" + integrity sha512-f2hYlJ5pwzGvjyaZ6BoGR5uiMgXzWXt6w6ktt1N8lmY6PiYp8whZgqx2hTxVWwVlsGnaIfh6UHp1hGnANx0eTQ== + dependencies: + valtio "1.11.0" + +"@walletconnect/modal-ui@2.6.1": + version "2.6.1" + resolved "https://registry.yarnpkg.com/@walletconnect/modal-ui/-/modal-ui-2.6.1.tgz#200c54c8dfe3c71321abb2724e18bb357dfd6371" + integrity sha512-RFUOwDAMijSK8B7W3+KoLKaa1l+KEUG0LCrtHqaB0H0cLnhEGdLR+kdTdygw+W8+yYZbkM5tXBm7MlFbcuyitA== + dependencies: + "@walletconnect/modal-core" "2.6.1" + lit "2.7.6" + motion "10.16.2" + qrcode "1.5.3" + +"@walletconnect/modal@2.6.1": + version "2.6.1" + resolved "https://registry.yarnpkg.com/@walletconnect/modal/-/modal-2.6.1.tgz#066fdbfcff83b58c8a9da66ab4af0eb93e3626de" + integrity sha512-G84tSzdPKAFk1zimgV7JzIUFT5olZUVtI3GcOk77OeLYjlMfnDT23RVRHm5EyCrjkptnvpD0wQScXePOFd2Xcw== + dependencies: + "@walletconnect/modal-core" "2.6.1" + "@walletconnect/modal-ui" "2.6.1" + +"@walletconnect/randombytes@^1.0.3": + version "1.0.3" + resolved "https://registry.yarnpkg.com/@walletconnect/randombytes/-/randombytes-1.0.3.tgz#e795e4918367fd1e6a2215e075e64ab93e23985b" + integrity sha512-35lpzxcHFbTN3ABefC9W+uBpNZl1GC4Wpx0ed30gibfO/y9oLdy1NznbV96HARQKSBV9J9M/rrtIvf6a23jfYw== + dependencies: + "@walletconnect/encoding" "^1.0.2" + "@walletconnect/environment" "^1.0.1" + randombytes "^2.1.0" + tslib "1.14.1" + +"@walletconnect/relay-api@^1.0.9": + version "1.0.9" + resolved "https://registry.yarnpkg.com/@walletconnect/relay-api/-/relay-api-1.0.9.tgz#f8c2c3993dddaa9f33ed42197fc9bfebd790ecaf" + integrity sha512-Q3+rylJOqRkO1D9Su0DPE3mmznbAalYapJ9qmzDgK28mYF9alcP3UwG/og5V7l7CFOqzCLi7B8BvcBUrpDj0Rg== + dependencies: + "@walletconnect/jsonrpc-types" "^1.0.2" + tslib "1.14.1" + +"@walletconnect/relay-auth@^1.0.4": + version "1.0.4" + resolved "https://registry.yarnpkg.com/@walletconnect/relay-auth/-/relay-auth-1.0.4.tgz#0b5c55c9aa3b0ef61f526ce679f3ff8a5c4c2c7c" + integrity sha512-kKJcS6+WxYq5kshpPaxGHdwf5y98ZwbfuS4EE/NkQzqrDFm5Cj+dP8LofzWvjrrLkZq7Afy7WrQMXdLy8Sx7HQ== + dependencies: + "@stablelib/ed25519" "^1.0.2" + "@stablelib/random" "^1.0.1" + "@walletconnect/safe-json" "^1.0.1" + "@walletconnect/time" "^1.0.2" + tslib "1.14.1" + uint8arrays "^3.0.0" + +"@walletconnect/safe-json@^1.0.1", "@walletconnect/safe-json@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@walletconnect/safe-json/-/safe-json-1.0.2.tgz#7237e5ca48046e4476154e503c6d3c914126fa77" + integrity sha512-Ogb7I27kZ3LPC3ibn8ldyUr5544t3/STow9+lzz7Sfo808YD7SBWk7SAsdBFlYgP2zDRy2hS3sKRcuSRM0OTmA== + dependencies: + tslib "1.14.1" + +"@walletconnect/sign-client@2.9.2": + version "2.9.2" + resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.9.2.tgz#ff4c81c082c2078878367d07f24bcb20b1f7ab9e" + integrity sha512-anRwnXKlR08lYllFMEarS01hp1gr6Q9XUgvacr749hoaC/AwGVlxYFdM8+MyYr3ozlA+2i599kjbK/mAebqdXg== + dependencies: + "@walletconnect/core" "2.9.2" + "@walletconnect/events" "^1.0.1" + "@walletconnect/heartbeat" "1.2.1" + "@walletconnect/jsonrpc-utils" "1.0.8" + "@walletconnect/logger" "^2.0.1" + "@walletconnect/time" "^1.0.2" + "@walletconnect/types" "2.9.2" + "@walletconnect/utils" "2.9.2" + events "^3.3.0" + +"@walletconnect/time@^1.0.2": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@walletconnect/time/-/time-1.0.2.tgz#6c5888b835750ecb4299d28eecc5e72c6d336523" + integrity sha512-uzdd9woDcJ1AaBZRhqy5rNC9laqWGErfc4dxA9a87mPdKOgWMD85mcFo9dIYIts/Jwocfwn07EC6EzclKubk/g== + dependencies: + tslib "1.14.1" + +"@walletconnect/types@2.9.2": + version "2.9.2" + resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.9.2.tgz#d5fd5a61dc0f41cbdca59d1885b85207ac7bf8c5" + integrity sha512-7Rdn30amnJEEal4hk83cdwHUuxI1SWQ+K7fFFHBMqkuHLGi3tpMY6kpyfDxnUScYEZXqgRps4Jo5qQgnRqVM7A== + dependencies: + "@walletconnect/events" "^1.0.1" + "@walletconnect/heartbeat" "1.2.1" + "@walletconnect/jsonrpc-types" "1.0.3" + "@walletconnect/keyvaluestorage" "^1.0.2" + "@walletconnect/logger" "^2.0.1" + events "^3.3.0" + +"@walletconnect/universal-provider@2.9.2": + version "2.9.2" + resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.9.2.tgz#40e54e98bc48b1f2f5f77eb5b7f05462093a8506" + integrity sha512-JmaolkO8D31UdRaQCHwlr8uIFUI5BYhBzqYFt54Mc6gbIa1tijGOmdyr6YhhFO70LPmS6gHIjljwOuEllmlrxw== + dependencies: + "@walletconnect/jsonrpc-http-connection" "^1.0.7" + "@walletconnect/jsonrpc-provider" "1.0.13" + "@walletconnect/jsonrpc-types" "^1.0.2" + "@walletconnect/jsonrpc-utils" "^1.0.7" + "@walletconnect/logger" "^2.0.1" + "@walletconnect/sign-client" "2.9.2" + "@walletconnect/types" "2.9.2" + "@walletconnect/utils" "2.9.2" + events "^3.3.0" + +"@walletconnect/utils@2.9.2": + version "2.9.2" + resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.9.2.tgz#035bdb859ee81a4bcc6420f56114cc5ec3e30afb" + integrity sha512-D44hwXET/8JhhIjqljY6qxSu7xXnlPrf63UN/Qfl98vDjWlYVcDl2+JIQRxD9GPastw0S8XZXdRq59XDXLuZBg== + dependencies: + "@stablelib/chacha20poly1305" "1.0.1" + "@stablelib/hkdf" "1.0.1" + "@stablelib/random" "^1.0.2" + "@stablelib/sha256" "1.0.1" + "@stablelib/x25519" "^1.0.3" + "@walletconnect/relay-api" "^1.0.9" + "@walletconnect/safe-json" "^1.0.2" + "@walletconnect/time" "^1.0.2" + "@walletconnect/types" "2.9.2" + "@walletconnect/window-getters" "^1.0.1" + "@walletconnect/window-metadata" "^1.0.1" + detect-browser "5.3.0" + query-string "7.1.3" + uint8arrays "^3.1.0" + +"@walletconnect/window-getters@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@walletconnect/window-getters/-/window-getters-1.0.1.tgz#f36d1c72558a7f6b87ecc4451fc8bd44f63cbbdc" + integrity sha512-vHp+HqzGxORPAN8gY03qnbTMnhqIwjeRJNOMOAzePRg4xVEEE2WvYsI9G2NMjOknA8hnuYbU3/hwLcKbjhc8+Q== + dependencies: + tslib "1.14.1" + +"@walletconnect/window-metadata@^1.0.1": + version "1.0.1" + resolved "https://registry.yarnpkg.com/@walletconnect/window-metadata/-/window-metadata-1.0.1.tgz#2124f75447b7e989e4e4e1581d55d25bc75f7be5" + integrity sha512-9koTqyGrM2cqFRW517BPY/iEtUDx2r1+Pwwu5m7sJ7ka79wi3EyqhqcICk/yDmv6jAS1rjKgTKXlEhanYjijcA== + dependencies: + "@walletconnect/window-getters" "^1.0.1" + tslib "1.14.1" + "@web3-react/abstract-connector@^6.0.7": version "6.0.7" resolved "https://registry.yarnpkg.com/@web3-react/abstract-connector/-/abstract-connector-6.0.7.tgz#401b3c045f1e0fab04256311be49d5144e9badc6" @@ -620,6 +1516,53 @@ resolved "https://registry.yarnpkg.com/@web3-react/types/-/types-6.0.7.tgz#34a6204224467eedc6123abaf55fbb6baeb2809f" integrity sha512-ofGmfDhxmNT1/P/MgVa8IKSkCStFiyvXe+U5tyZurKdrtTDFU+wJ/LxClPDtFerWpczNFPUSrKcuhfPX1sI6+A== +JSONStream@^1.3.5: + version "1.3.5" + resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.5.tgz#3208c1f08d3a4d99261ab64f92302bc15e111ca0" + integrity sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ== + dependencies: + jsonparse "^1.2.0" + through ">=2.2.7 <3" + +abitype@0.8.7: + version "0.8.7" + resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.8.7.tgz#e4b3f051febd08111f486c0cc6a98fa72d033622" + integrity sha512-wQ7hV8Yg/yKmGyFpqrNZufCxbszDe5es4AZGYPBitocfSqXtjrTG9JMWFcc4N30ukl2ve48aBTwt7NJxVQdU3w== + +abitype@0.9.3: + version "0.9.3" + resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.3.tgz#294d25288ee683d72baf4e1fed757034e3c8c277" + integrity sha512-dz4qCQLurx97FQhnb/EIYTk/ldQ+oafEDUqC0VVIeQS1Q48/YWt/9YNfMmp9SLFqN41ktxny3c8aYxHjmFIB/w== + +aes-js@^3.1.2: + version "3.1.2" + resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.1.2.tgz#db9aabde85d5caabbfc0d4f2a4446960f627146a" + integrity sha512-e5pEa2kBnBOgR4Y/p20pskXI74UEz7de8ZGVo58asOtvSVG5YAbJeELPZxOmt+Bnz3rX753YKhfIn4X4l1PPRQ== + +agentkeepalive@^4.3.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.5.0.tgz#2673ad1389b3c418c5a20c5d7364f93ca04be923" + integrity sha512-5GG/5IbQQpC9FpkRGsSvZI5QYeSCzlJHdpBQntCsuTOxhKD8lqKhrleg2Yi7yvMIf82Ycmmqln9U8V9qwEiJew== + dependencies: + humanize-ms "^1.2.1" + +ahocorasick@1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/ahocorasick/-/ahocorasick-1.0.2.tgz#9eee93aef9d02bfb476d9b648d9b7a40ef2fd500" + integrity sha512-hCOfMzbFx5IDutmWLAt6MZwOUjIfSM9G9FyVxytmE4Rs/5YDPWQrD/+IR1w+FweD9H2oOZEnv36TmkjhNURBVA== + +ansi-regex@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" + integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== + +ansi-styles@^4.0.0, ansi-styles@^4.1.0: + version "4.3.0" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" + integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== + dependencies: + color-convert "^2.0.1" + aria-hidden@^1.1.1: version "1.2.3" resolved "https://registry.npmjs.org/aria-hidden/-/aria-hidden-1.2.3.tgz" @@ -627,31 +1570,157 @@ aria-hidden@^1.1.1: dependencies: tslib "^2.0.0" +async-mutex@^0.2.6: + version "0.2.6" + resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.2.6.tgz#0d7a3deb978bc2b984d5908a2038e1ae2e54ff40" + integrity sha512-Hs4R+4SPgamu6rSGW8C7cV9gaWUKEHykfzCCvIRuaVv636Ju10ZdeUbvb4TBEW0INuq2DHZqXbK4Nd3yG4RaRw== + dependencies: + tslib "^2.0.0" + +atomic-sleep@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/atomic-sleep/-/atomic-sleep-1.0.0.tgz#eb85b77a601fc932cfe432c5acd364a9e2c9075b" + integrity sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ== + +available-typed-arrays@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz#92f95616501069d07d10edb2fc37d3e1c65123b7" + integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== + +base-x@^3.0.2: + version "3.0.9" + resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.9.tgz#6349aaabb58526332de9f60995e548a53fe21320" + integrity sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ== + dependencies: + safe-buffer "^5.0.1" + +base64-js@^1.3.1: + version "1.5.1" + resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" + integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== + +bigint-buffer@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/bigint-buffer/-/bigint-buffer-1.1.5.tgz#d038f31c8e4534c1f8d0015209bf34b4fa6dd442" + integrity sha512-trfYco6AoZ+rKhKnxA0hgX0HAbVP/s808/EuDSe2JDzUnCp/xAsli35Orvk67UrTEcwuxZqYZDmfA2RXJgxVvA== + dependencies: + bindings "^1.3.0" + +bind-decorator@^1.0.11: + version "1.0.11" + resolved "https://registry.yarnpkg.com/bind-decorator/-/bind-decorator-1.0.11.tgz#e41bc06a1f65dd9cec476c91c5daf3978488252f" + integrity sha512-yzkH0uog6Vv/vQ9+rhSKxecnqGUZHYncg7qS7voz3Q76+TAi1SGiOKk2mlOvusQnFz9Dc4BC/NMkeXu11YgjJg== + +bindings@^1.3.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" + integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== + dependencies: + file-uri-to-path "1.0.0" + bn.js@^4.11.9, bn.js@^4.4.0: version "4.12.0" resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== -bn.js@^5.2.1: +bn.js@^5.1.1, bn.js@^5.2.0, bn.js@^5.2.1: version "5.2.1" resolved "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== +borsh@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/borsh/-/borsh-0.7.0.tgz#6e9560d719d86d90dc589bca60ffc8a6c51fec2a" + integrity sha512-CLCsZGIBCFnPtkNnieW/a8wmreDmfUtjU2m9yHrzPXIlNbqVs0AQrSatSG6vdNYUqdc83tkQi2eHfF98ubzQLA== + dependencies: + bn.js "^5.2.0" + bs58 "^4.0.0" + text-encoding-utf-8 "^1.0.2" + brorand@^1.1.0: version "1.1.0" resolved "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== +bs58@^4.0.0, bs58@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/bs58/-/bs58-4.0.1.tgz#be161e76c354f6f788ae4071f63f34e8c4f0a42a" + integrity sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw== + dependencies: + base-x "^3.0.2" + buffer-from@^1.1.2: version "1.1.2" resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== -clsx@^1.1.1, clsx@^1.2.1: +buffer@6.0.3, buffer@^6.0.3, buffer@~6.0.3: + version "6.0.3" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" + integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== + dependencies: + base64-js "^1.3.1" + ieee754 "^1.2.1" + +bufferutil@^4.0.1: + version "4.0.7" + resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.7.tgz#60c0d19ba2c992dd8273d3f73772ffc894c153ad" + integrity sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw== + dependencies: + node-gyp-build "^4.3.0" + +call-bind@^1.0.0, call-bind@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + +camelcase@^5.0.0: + version "5.3.1" + resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" + integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== + +chalk@^4.1.1: + version "4.1.2" + resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" + integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== + dependencies: + ansi-styles "^4.1.0" + supports-color "^7.1.0" + +cliui@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-6.0.0.tgz#511d702c0c4e41ca156d7d0e96021f23e13225b1" + integrity sha512-t6wbgtoCXvAzst7QgXxJYqPt0usEfbgQdftEPbLL/cvv6HPE5VgvqCuAIDR0NgU52ds6rFwqrgakNLrHEjCbrQ== + dependencies: + string-width "^4.2.0" + strip-ansi "^6.0.0" + wrap-ansi "^6.2.0" + +clsx@1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.1.1.tgz#98b3134f9abbdf23b2663491ace13c5c03a73188" + integrity sha512-6/bPho624p3S2pMyvP5kKBPXnI3ufHLObBFCfgx+LkeR5lg2XYy2hqZqUf45ypD8COn2bhgGJSUE+l5dhNBieA== + +clsx@^1.1.0, clsx@^1.1.1, clsx@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== +color-convert@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" + integrity sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ== + dependencies: + color-name "~1.1.4" + +color-name@~1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" + integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== + combine-errors@^3.0.3: version "3.0.3" resolved "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz" @@ -660,12 +1729,24 @@ combine-errors@^3.0.3: custom-error-instance "2.1.1" lodash.uniqby "4.5.0" +commander@^2.20.3: + version "2.20.3" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== + +copy-to-clipboard@^3.3.3: + version "3.3.3" + resolved "https://registry.yarnpkg.com/copy-to-clipboard/-/copy-to-clipboard-3.3.3.tgz#55ac43a1db8ae639a4bd99511c148cdd1b83a1b0" + integrity sha512-2KV8NhB5JqC3ky0r9PMCAZKbUHSwtEo4CwCs0KXgruG43gX5PMqDEBbVU4OUzw2MuAWUfsuFmWvEKG5QRfSnJA== + dependencies: + toggle-selection "^1.0.6" + core-js@^3.31.1: version "3.32.0" resolved "https://registry.npmjs.org/core-js/-/core-js-3.32.0.tgz" integrity sha512-rd4rYZNlF3WuoYuRIDEmbR/ga9CeuWX9U05umAvgrrZoHY4Z++cp/xwPQMvUpBB4Ag6J8KfD80G0zwCyaSxDww== -cross-fetch@^3.1.4: +cross-fetch@^3.1.4, cross-fetch@^3.1.5: version "3.1.8" resolved "https://registry.npmjs.org/cross-fetch/-/cross-fetch-3.1.8.tgz" integrity sha512-cvA+JwZoU0Xq+h6WkMvAUqPEYy92Obet6UdKLfW60qn99ftItKjB5T+BkyWOFWe2pUyfQ+IJHmpOTznqk1M6Kg== @@ -684,6 +1765,21 @@ crypto-js@^4.1.1: resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== +css-what@^5.0.1: + version "5.1.0" + resolved "https://registry.yarnpkg.com/css-what/-/css-what-5.1.0.tgz#3f7b707aadf633baf62c2ceb8579b545bb40f7fe" + integrity sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw== + +cssesc@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" + integrity sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg== + +csstype@^3.0.7: + version "3.1.2" + resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.1.2.tgz#1d4bf9d572f11c14031f0436e1c10bc1f571f50b" + integrity sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ== + custom-error-instance@2.1.1: version "2.1.1" resolved "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz" @@ -696,18 +1792,53 @@ date-fns@^2.28.0: dependencies: "@babel/runtime" "^7.21.0" -debug@~4.3.1, debug@~4.3.2: +debug@^4.3.4, debug@~4.3.1, debug@~4.3.2: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== dependencies: ms "2.1.2" +decamelize@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-1.2.0.tgz#f6534d15148269b20352e7bee26f501f9a191290" + integrity sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA== + +decode-uri-component@^0.2.0, decode-uri-component@^0.2.2: + version "0.2.2" + resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.2.tgz#e69dbe25d37941171dd540e024c444cd5188e1e9" + integrity sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ== + +deep-object-diff@^1.1.0: + version "1.1.9" + resolved "https://registry.yarnpkg.com/deep-object-diff/-/deep-object-diff-1.1.9.tgz#6df7ef035ad6a0caa44479c536ed7b02570f4595" + integrity sha512-Rn+RuwkmkDwCi2/oXOFS9Gsr5lJZu/yTGpK7wAaAIE75CC+LCGEZHpY6VQJa/RoJcrmaA/docWJZvYohlNkWPA== + +deepmerge@^4.2.2: + version "4.3.1" + resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.3.1.tgz#44b5f2147cd3b00d4b56137685966f26fd25dd4a" + integrity sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A== + +delay@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/delay/-/delay-5.0.0.tgz#137045ef1b96e5071060dd5be60bf9334436bd1d" + integrity sha512-ReEBKkIfe4ya47wlPYf/gu5ib6yUG0/Aez0JQZQz94kiWtRQvZIQbTiehsnwHvLSWJnQdhVeqYue7Id1dKr0qw== + +detect-browser@5.3.0, detect-browser@^5.3.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/detect-browser/-/detect-browser-5.3.0.tgz#9705ef2bddf46072d0f7265a1fe300e36fe7ceca" + integrity sha512-53rsFbGdwMwlF7qvCt0ypLM5V5/Mbl0szB7GPN8y9NCcbknYOeVVXdrXEq+90IwAfrrzt6Hd+u2E2ntakICU8w== + detect-node-es@^1.1.0: version "1.1.0" resolved "https://registry.npmjs.org/detect-node-es/-/detect-node-es-1.1.0.tgz" integrity sha512-ypdmJU/TbBby2Dxibuv7ZLW3Bs1QEmM7nHjEANfohJLvE0XVujisn1qPJcZxg+qDucsr+bP6fLD1rPS3AhJ7EQ== +dijkstrajs@^1.0.1: + version "1.0.3" + resolved "https://registry.yarnpkg.com/dijkstrajs/-/dijkstrajs-1.0.3.tgz#4c8dbdea1f0f6478bff94d9c49c784d623e4fc23" + integrity sha512-qiSlmBq9+BCdCA/L46dw8Uy93mloxsPSbwnm5yrKn2vMPiy8KyAskTF6zuV/j5BMsmOGZDPs7KjU+mjb670kfA== + dom-serializer@^1.0.1: version "1.4.1" resolved "https://registry.npmjs.org/dom-serializer/-/dom-serializer-1.4.1.tgz" @@ -738,6 +1869,16 @@ domutils@^2.8.0: domelementtype "^2.2.0" domhandler "^4.2.0" +duplexify@^4.1.2: + version "4.1.2" + resolved "https://registry.yarnpkg.com/duplexify/-/duplexify-4.1.2.tgz#18b4f8d28289132fa0b9573c898d9f903f81c7b0" + integrity sha512-fz3OjcNCHmRP12MJoZMPglx8m4rrFP8rovnk4vT8Fs+aonZoCwGg10dSsQsfP/E62eZcPTMSMP6686fu9Qlqtw== + dependencies: + end-of-stream "^1.4.1" + inherits "^2.0.3" + readable-stream "^3.1.1" + stream-shift "^1.0.0" + elliptic@6.5.4, elliptic@^6.5.4: version "6.5.4" resolved "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz" @@ -758,6 +1899,23 @@ emoji-picker-react@^4.4.9: dependencies: clsx "^1.2.1" +emoji-regex@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" + integrity sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A== + +encode-utf8@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/encode-utf8/-/encode-utf8-1.0.3.tgz#f30fdd31da07fb596f281beb2f6b027851994cda" + integrity sha512-ucAnuBEhUK4boH2HjVYG5Q2mQyPorvv0u/ocS+zhdw0S8AlHYY+GOFhP1Gio5z4icpP2ivFSvhtFjQi8+T9ppw== + +end-of-stream@^1.4.1: + version "1.4.4" + resolved "https://registry.yarnpkg.com/end-of-stream/-/end-of-stream-1.4.4.tgz#5ae64a5f45057baf3626ec14da0ca5e4b2431eb0" + integrity sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q== + dependencies: + once "^1.4.0" + engine.io-client@~6.4.0: version "6.4.0" resolved "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.4.0.tgz" @@ -784,11 +1942,141 @@ entities@^3.0.1: resolved "https://registry.npmjs.org/entities/-/entities-3.0.1.tgz" integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== +es6-promise@^4.0.3: + version "4.2.8" + resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" + integrity sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w== + +es6-promisify@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/es6-promisify/-/es6-promisify-5.0.0.tgz#5109d62f3e56ea967c4b63505aef08291c8a5203" + integrity sha512-C+d6UdsYDk0lMebHNR4S2NybQMMngAOnOwYBQjTOiv0MkoJMP0Myw2mgpDLBcpfCmRLxyFqYhS/CfOENq4SJhQ== + dependencies: + es6-promise "^4.0.3" + +eth-block-tracker@6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/eth-block-tracker/-/eth-block-tracker-6.1.0.tgz#0481f97bbb88a100b9d45806fe7e37af741cbefc" + integrity sha512-K9SY8+/xMBi4M5HHTDdxnpEqEEGjbNpzHFqvxyjMZej8InV/B+CkFRKM6W+uvrFJ7m8Zd1E0qUkseU3vdIDFYQ== + dependencies: + "@metamask/safe-event-emitter" "^2.0.0" + "@metamask/utils" "^3.0.1" + json-rpc-random-id "^1.0.1" + pify "^3.0.0" + +eth-json-rpc-filters@5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/eth-json-rpc-filters/-/eth-json-rpc-filters-5.1.0.tgz#f0c2aeaec2a45e2dc6ca1b9843d8e85447821427" + integrity sha512-fos+9xmoa1A2Ytsc9eYof17r81BjdJOUcGcgZn4K/tKdCCTb+a8ytEtwlu1op5qsXFDlgGmstTELFrDEc89qEQ== + dependencies: + "@metamask/safe-event-emitter" "^2.0.0" + async-mutex "^0.2.6" + eth-query "^2.1.2" + json-rpc-engine "^6.1.0" + pify "^5.0.0" + +eth-query@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/eth-query/-/eth-query-2.1.2.tgz#d6741d9000106b51510c72db92d6365456a6da5e" + integrity sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA== + dependencies: + json-rpc-random-id "^1.0.0" + xtend "^4.0.1" + +eth-rpc-errors@4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/eth-rpc-errors/-/eth-rpc-errors-4.0.2.tgz#11bc164e25237a679061ac05b7da7537b673d3b7" + integrity sha512-n+Re6Gu8XGyfFy1it0AwbD1x0MUzspQs0D5UiPs1fFPCr6WAwZM+vbIhXheBFrpgosqN9bs5PqlB4Q61U/QytQ== + dependencies: + fast-safe-stringify "^2.0.6" + +eth-rpc-errors@^4.0.2: + version "4.0.3" + resolved "https://registry.yarnpkg.com/eth-rpc-errors/-/eth-rpc-errors-4.0.3.tgz#6ddb6190a4bf360afda82790bb7d9d5e724f423a" + integrity sha512-Z3ymjopaoft7JDoxZcEb3pwdGh7yiYMhOwm2doUt6ASXlMavpNlK6Cre0+IMl2VSGyEU9rkiperQhp5iRxn5Pg== + dependencies: + fast-safe-stringify "^2.0.6" + +eventemitter3@^4.0.7: + version "4.0.7" + resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" + integrity sha512-8guHBZCwKnFhYdHr2ysuRWErTwhoN2X8XELRlrRwpmfeY2jjuUN4taQMsULKUVo1K4DvZl+0pgfyoysHxvmvEw== + +events@^3.3.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" + integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== + +eyes@^0.1.8: + version "0.1.8" + resolved "https://registry.yarnpkg.com/eyes/-/eyes-0.1.8.tgz#62cf120234c683785d902348a800ef3e0cc20bc0" + integrity sha512-GipyPsXO1anza0AOZdy69Im7hGFCNB7Y/NGjDlZGJ3GJJLtwNSb2vrzYrTYJRrRloVx7pl+bhUaTB8yiccPvFQ== + +fast-redact@^3.0.0: + version "3.3.0" + resolved "https://registry.yarnpkg.com/fast-redact/-/fast-redact-3.3.0.tgz#7c83ce3a7be4898241a46560d51de10f653f7634" + integrity sha512-6T5V1QK1u4oF+ATxs1lWUmlEk6P2T9HqJG3e2DnHOdVgZy2rFJBoEnrIedcTXlkAHU/zKC+7KETJ+KGGKwxgMQ== + +fast-safe-stringify@^2.0.6: + version "2.1.1" + resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz#c406a83b6e70d9e35ce3b30a81141df30aeba884" + integrity sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA== + +fast-stable-stringify@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fast-stable-stringify/-/fast-stable-stringify-1.0.0.tgz#5c5543462b22aeeefd36d05b34e51c78cb86d313" + integrity sha512-wpYMUmFu5f00Sm0cj2pfivpmawLZ0NKdviQ4w9zJeR8JVtOpOxHmLaJuj0vxvGqMJQWyP/COUkF75/57OKyRag== + +file-uri-to-path@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" + integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== + +filter-obj@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/filter-obj/-/filter-obj-1.1.0.tgz#9b311112bc6c6127a16e016c6c5d7f19e0805c5b" + integrity sha512-8rXg1ZnX7xzy2NGDVkBVaAy+lSlPNwad13BtgSlLuxfIslyt5Vg64U7tFcCt4WS1R0hvtnQybT/IyCkGZ3DpXQ== + +find-up@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-4.1.0.tgz#97afe7d6cdc0bc5928584b7c8d7b16e8a9aa5d19" + integrity sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw== + dependencies: + locate-path "^5.0.0" + path-exists "^4.0.0" + font-awesome@^4.7.0: version "4.7.0" resolved "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz" integrity sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg== +for-each@^0.3.3: + version "0.3.3" + resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" + integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== + dependencies: + is-callable "^1.1.3" + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + +get-caller-file@^2.0.1: + version "2.0.5" + resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" + integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== + +get-intrinsic@^1.0.2, get-intrinsic@^1.1.3: + version "1.2.1" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" + integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-proto "^1.0.1" + has-symbols "^1.0.3" + get-nonce@^1.0.0: version "1.0.1" resolved "https://registry.npmjs.org/get-nonce/-/get-nonce-1.0.1.tgz" @@ -799,12 +2087,48 @@ gif-picker-react@^1.1.0: resolved "https://registry.npmjs.org/gif-picker-react/-/gif-picker-react-1.3.0.tgz" integrity sha512-IYDmx9iEouC84JCrOt/HSaiRgHD8o7/catZCspUVpNEXoIunq7CF65JcmyTyoPkVJZcQz0ofjU5Gp5C2bqwOlQ== +gopd@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" + integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== + dependencies: + get-intrinsic "^1.1.3" + graceful-fs@^4.2.4: version "4.2.11" resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== -hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: +has-flag@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" + integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== + +has-proto@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" + integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== + +has-symbols@^1.0.2, has-symbols@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" + integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== + +has-tostringtag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" + integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== + dependencies: + has-symbols "^1.0.2" + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + +hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3, hash.js@^1.1.7: version "1.1.7" resolved "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" integrity sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA== @@ -812,6 +2136,11 @@ hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: inherits "^2.0.3" minimalistic-assert "^1.0.1" +hey-listen@^1.0.8: + version "1.0.8" + resolved "https://registry.yarnpkg.com/hey-listen/-/hey-listen-1.0.8.tgz#8e59561ff724908de1aa924ed6ecc84a56a9aa68" + integrity sha512-COpmrF2NOg4TBWUJ5UVyaCU2A88wEMkUPK4hNqyCkqHbxT92BbvfjoSozkAIIm6XhicGlJHhFdullInrdhwU8Q== + hls.js@^1.4.9: version "1.4.10" resolved "https://registry.npmjs.org/hls.js/-/hls.js-1.4.10.tgz" @@ -854,7 +2183,19 @@ htmlparser2@7.2.0: domutils "^2.8.0" entities "^3.0.1" -inherits@^2.0.3, inherits@^2.0.4: +humanize-ms@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/humanize-ms/-/humanize-ms-1.2.1.tgz#c46e3159a293f6b896da29316d8b6fe8bb79bbed" + integrity sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ== + dependencies: + ms "^2.0.0" + +ieee754@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" + integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== + +inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.4: version "2.0.4" resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -871,11 +2212,76 @@ invariant@^2.2.4: dependencies: loose-envify "^1.0.0" +is-arguments@^1.0.4: + version "1.1.1" + resolved "https://registry.yarnpkg.com/is-arguments/-/is-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" + integrity sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-callable@^1.1.3: + version "1.2.7" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" + integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== + +is-fullwidth-code-point@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" + integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== + +is-generator-function@^1.0.7: + version "1.0.10" + resolved "https://registry.yarnpkg.com/is-generator-function/-/is-generator-function-1.0.10.tgz#f1558baf1ac17e0deea7c0415c438351ff2b3c72" + integrity sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A== + dependencies: + has-tostringtag "^1.0.0" + is-stream@^2.0.0: version "2.0.1" resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== +is-typed-array@^1.1.3: + version "1.1.12" + resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.12.tgz#d0bab5686ef4a76f7a73097b95470ab199c57d4a" + integrity sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg== + dependencies: + which-typed-array "^1.1.11" + +is-typedarray@1.0.0, is-typedarray@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" + integrity sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA== + +isomorphic-ws@5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-5.0.0.tgz#e5529148912ecb9b451b46ed44d53dae1ce04bbf" + integrity sha512-muId7Zzn9ywDsyXgTIafTry2sV3nySZeUDe6YedVd1Hvuuep5AsIlqK+XefWpYTyJG5e503F2xIuT2lcU6rCSw== + +isomorphic-ws@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-4.0.1.tgz#55fd4cd6c5e6491e76dc125938dd863f5cd4f2dc" + integrity sha512-BhBvN2MBpWTaSHdWRb/bwdZJ1WaehQ2L1KngkCkfLUGF0mAWAT1sQUQacEmQ0jXkFw/czDXPNQSL5u2/Krsz1w== + +jayson@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/jayson/-/jayson-4.1.0.tgz#60dc946a85197317f2b1439d672a8b0a99cea2f9" + integrity sha512-R6JlbyLN53Mjku329XoRT2zJAE6ZgOQ8f91ucYdMCD4nkGCF9kZSrcGXpHIU4jeKj58zUZke2p+cdQchU7Ly7A== + dependencies: + "@types/connect" "^3.4.33" + "@types/node" "^12.12.54" + "@types/ws" "^7.4.4" + JSONStream "^1.3.5" + commander "^2.20.3" + delay "^5.0.0" + es6-promisify "^5.0.0" + eyes "^0.1.8" + isomorphic-ws "^4.0.1" + json-stringify-safe "^5.0.1" + uuid "^8.3.2" + ws "^7.4.5" + js-base64@^3.7.2: version "3.7.5" resolved "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz" @@ -891,6 +2297,68 @@ js-sha3@0.8.0: resolved "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== +json-rpc-engine@6.1.0, json-rpc-engine@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/json-rpc-engine/-/json-rpc-engine-6.1.0.tgz#bf5ff7d029e1c1bf20cb6c0e9f348dcd8be5a393" + integrity sha512-NEdLrtrq1jUZyfjkr9OCz9EzCNhnRyWtt1PAnvnhwy6e8XETS0Dtc+ZNCO2gvuAoKsIn2+vCSowXTYE4CkgnAQ== + dependencies: + "@metamask/safe-event-emitter" "^2.0.0" + eth-rpc-errors "^4.0.2" + +json-rpc-random-id@^1.0.0, json-rpc-random-id@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-rpc-random-id/-/json-rpc-random-id-1.0.1.tgz#ba49d96aded1444dbb8da3d203748acbbcdec8c8" + integrity sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA== + +json-stringify-safe@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" + integrity sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA== + +jsonparse@^1.2.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" + integrity sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg== + +keccak@^3.0.1: + version "3.0.3" + resolved "https://registry.yarnpkg.com/keccak/-/keccak-3.0.3.tgz#4bc35ad917be1ef54ff246f904c2bbbf9ac61276" + integrity sha512-JZrLIAJWuZxKbCilMpNz5Vj7Vtb4scDG3dMXLOsbzBmQGyjwE61BbW7bJkfKKCShXiQZt3T6sBgALRtmd+nZaQ== + dependencies: + node-addon-api "^2.0.0" + node-gyp-build "^4.2.0" + readable-stream "^3.6.0" + +keyvaluestorage-interface@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/keyvaluestorage-interface/-/keyvaluestorage-interface-1.0.0.tgz#13ebdf71f5284ad54be94bd1ad9ed79adad515ff" + integrity sha512-8t6Q3TclQ4uZynJY9IGr2+SsIGwK9JHcO6ootkHCGA0CrQCRy+VkouYNO2xicET6b9al7QKzpebNow+gkpCL8g== + +lit-element@^3.3.0: + version "3.3.3" + resolved "https://registry.yarnpkg.com/lit-element/-/lit-element-3.3.3.tgz#10bc19702b96ef5416cf7a70177255bfb17b3209" + integrity sha512-XbeRxmTHubXENkV4h8RIPyr8lXc+Ff28rkcQzw3G6up2xg5E8Zu1IgOWIwBLEQsu3cOVFqdYwiVi0hv0SlpqUA== + dependencies: + "@lit-labs/ssr-dom-shim" "^1.1.0" + "@lit/reactive-element" "^1.3.0" + lit-html "^2.8.0" + +lit-html@^2.7.0, lit-html@^2.8.0: + version "2.8.0" + resolved "https://registry.yarnpkg.com/lit-html/-/lit-html-2.8.0.tgz#96456a4bb4ee717b9a7d2f94562a16509d39bffa" + integrity sha512-o9t+MQM3P4y7M7yNzqAyjp7z+mQGa4NS4CxiyLqFPyFWyc4O+nodLrkrxSaCTrla6M5YOLaT3RpbbqjszB5g3Q== + dependencies: + "@types/trusted-types" "^2.0.2" + +lit@2.7.6: + version "2.7.6" + resolved "https://registry.yarnpkg.com/lit/-/lit-2.7.6.tgz#810007b876ed43e0c70124de91831921598b1665" + integrity sha512-1amFHA7t4VaaDe+vdQejSVBklwtH9svGoG6/dZi9JhxtJBBlqY5D1RV7iLUYY0trCqQc4NfhYYZilZiVHt7Hxg== + dependencies: + "@lit/reactive-element" "^1.6.0" + lit-element "^3.3.0" + lit-html "^2.7.0" + livepeer@2.8.0: version "2.8.0" resolved "https://registry.npmjs.org/livepeer/-/livepeer-2.8.0.tgz" @@ -905,6 +2373,13 @@ livepeer@2.8.0: tus-js-client "^3.1.0" zustand "^4.3.9" +locate-path@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" + integrity sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g== + dependencies: + p-locate "^4.1.0" + lodash._baseiteratee@~4.7.0: version "4.7.0" resolved "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz" @@ -942,6 +2417,11 @@ lodash._stringtopath@~4.8.0: dependencies: lodash._basetostring "~4.12.0" +lodash.isequal@4.5.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0" + integrity sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ== + lodash.throttle@^4.1.1: version "4.1.1" resolved "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz" @@ -962,6 +2442,20 @@ loose-envify@^1.0.0: dependencies: js-tokens "^3.0.0 || ^4.0.0" +lru-cache@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" + integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== + dependencies: + yallist "^4.0.0" + +media-query-parser@^2.0.2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/media-query-parser/-/media-query-parser-2.0.2.tgz#ff79e56cee92615a304a1c2fa4f2bd056c0a1d29" + integrity sha512-1N4qp+jE0pL5Xv4uEcwVUhIkwdUO3S/9gML90nqKA7v7FcOS5vUtatfzok9S9U1EJU8dHWlcv95WLnKmmxZI9w== + dependencies: + "@babel/runtime" "^7.12.5" + minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" resolved "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" @@ -977,21 +2471,43 @@ moment@^2.29.4: resolved "https://registry.npmjs.org/moment/-/moment-2.29.4.tgz" integrity sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w== +motion@10.16.2: + version "10.16.2" + resolved "https://registry.yarnpkg.com/motion/-/motion-10.16.2.tgz#7dc173c6ad62210a7e9916caeeaf22c51e598d21" + integrity sha512-p+PurYqfUdcJZvtnmAqu5fJgV2kR0uLFQuBKtLeFVTrYEVllI99tiOTSefVNYuip9ELTEkepIIDftNdze76NAQ== + dependencies: + "@motionone/animation" "^10.15.1" + "@motionone/dom" "^10.16.2" + "@motionone/svelte" "^10.16.2" + "@motionone/types" "^10.15.1" + "@motionone/utils" "^10.15.1" + "@motionone/vue" "^10.16.2" + ms@2.1.2: version "2.1.2" resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== +ms@^2.0.0: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + ms@^3.0.0-canary.1: version "3.0.0-canary.1" resolved "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz" integrity sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g== -multiformats@9.9.0: +multiformats@9.9.0, multiformats@^9.4.2: version "9.9.0" resolved "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz" integrity sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg== +node-addon-api@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-2.0.2.tgz#432cfa82962ce494b132e9d72a15b29f71ff5d32" + integrity sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA== + node-fetch@^2.6.12: version "2.6.12" resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz" @@ -999,6 +2515,112 @@ node-fetch@^2.6.12: dependencies: whatwg-url "^5.0.0" +node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: + version "4.6.0" + resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.6.0.tgz#0c52e4cbf54bbd28b709820ef7b6a3c2d6209055" + integrity sha512-NTZVKn9IylLwUzaKjkas1e4u2DLNcV4rdYagA4PWdPwW87Bi7z+BznyKSRwS/761tV/lzCGXplWsiaMjLqP2zQ== + +object-inspect@^1.9.0: + version "1.12.3" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" + integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== + +on-exit-leak-free@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/on-exit-leak-free/-/on-exit-leak-free-0.2.0.tgz#b39c9e3bf7690d890f4861558b0d7b90a442d209" + integrity sha512-dqaz3u44QbRXQooZLTUKU41ZrzYrcvLISVgbrzbyCMxpmSLJvZ3ZamIJIZ29P6OhZIkNIQKosdeM6t1LYbA9hg== + +once@^1.4.0: + version "1.4.0" + resolved "https://registry.yarnpkg.com/once/-/once-1.4.0.tgz#583b1aa775961d4b113ac17d9c50baef9dd76bd1" + integrity sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w== + dependencies: + wrappy "1" + +outdent@^0.8.0: + version "0.8.0" + resolved "https://registry.yarnpkg.com/outdent/-/outdent-0.8.0.tgz#2ebc3e77bf49912543f1008100ff8e7f44428eb0" + integrity sha512-KiOAIsdpUTcAXuykya5fnVVT+/5uS0Q1mrkRHcF89tpieSmY33O/tmc54CqwA+bfhbtEfZUNLHaPUiB9X3jt1A== + +p-limit@^2.2.0: + version "2.3.0" + resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" + integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== + dependencies: + p-try "^2.0.0" + +p-locate@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" + integrity sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A== + dependencies: + p-limit "^2.2.0" + +p-try@^2.0.0: + version "2.2.0" + resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" + integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== + +path-exists@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" + integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== + +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" + integrity sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg== + +pify@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-5.0.0.tgz#1f5eca3f5e87ebec28cc6d54a0e4aaf00acc127f" + integrity sha512-eW/gHNMlxdSP6dmG6uJip6FXN0EQBwm2clYYd8Wul42Cwu/DK8HEftzsapcNdYe2MfLiIwZqsDk2RDEsTE79hA== + +pino-abstract-transport@v0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/pino-abstract-transport/-/pino-abstract-transport-0.5.0.tgz#4b54348d8f73713bfd14e3dc44228739aa13d9c0" + integrity sha512-+KAgmVeqXYbTtU2FScx1XS3kNyfZ5TrXY07V96QnUSFqo2gAqlvmaxH67Lj7SWazqsMabf+58ctdTcBgnOLUOQ== + dependencies: + duplexify "^4.1.2" + split2 "^4.0.0" + +pino-std-serializers@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/pino-std-serializers/-/pino-std-serializers-4.0.0.tgz#1791ccd2539c091ae49ce9993205e2cd5dbba1e2" + integrity sha512-cK0pekc1Kjy5w9V2/n+8MkZwusa6EyyxfeQCB799CQRhRt/CqYKiWs5adeu8Shve2ZNffvfC/7J64A2PJo1W/Q== + +pino@7.11.0: + version "7.11.0" + resolved "https://registry.yarnpkg.com/pino/-/pino-7.11.0.tgz#0f0ea5c4683dc91388081d44bff10c83125066f6" + integrity sha512-dMACeu63HtRLmCG8VKdy4cShCPKaYDR4youZqoSWLxl5Gu99HUw8bw75thbPv9Nip+H+QYX8o3ZJbTdVZZ2TVg== + dependencies: + atomic-sleep "^1.0.0" + fast-redact "^3.0.0" + on-exit-leak-free "^0.2.0" + pino-abstract-transport v0.5.0 + pino-std-serializers "^4.0.0" + process-warning "^1.0.0" + quick-format-unescaped "^4.0.3" + real-require "^0.1.0" + safe-stable-stringify "^2.1.0" + sonic-boom "^2.2.1" + thread-stream "^0.15.1" + +pngjs@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-5.0.0.tgz#e79dd2b215767fd9c04561c01236df960bce7fbb" + integrity sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw== + +preact@^10.12.0, preact@^10.5.9: + version "10.17.0" + resolved "https://registry.yarnpkg.com/preact/-/preact-10.17.0.tgz#77c0e3402767c999ac0f1ba39bd43cd85beab06b" + integrity sha512-SNsI8cbaCcUS5tbv9nlXuCfIXnJ9ysBMWk0WnB6UWwcVA3qZ2O6FxqDFECMAMttvLQcW/HaNZUe2BLidyvrVYw== + +process-warning@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/process-warning/-/process-warning-1.0.0.tgz#980a0b25dc38cd6034181be4b7726d89066b4616" + integrity sha512-du4wfLyj4yCZq1VupnVSZmRsPJsNuxoDQFdCFHLaYiEbFBD7QE0a+I4D7hOxrVnh78QE/YipFAj9lXHiXocV+Q== + proper-lockfile@^4.1.2: version "4.1.2" resolved "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz" @@ -1008,11 +2630,75 @@ proper-lockfile@^4.1.2: retry "^0.12.0" signal-exit "^3.0.2" +proxy-compare@2.5.1: + version "2.5.1" + resolved "https://registry.yarnpkg.com/proxy-compare/-/proxy-compare-2.5.1.tgz#17818e33d1653fbac8c2ec31406bce8a2966f600" + integrity sha512-oyfc0Tx87Cpwva5ZXezSp5V9vht1c7dZBhvuV/y3ctkgMVUmiAGDVeeB0dKhGSyT0v1ZTEQYpe/RXlBVBNuCLA== + +qrcode@1.5.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.0.tgz#95abb8a91fdafd86f8190f2836abbfc500c72d1b" + integrity sha512-9MgRpgVc+/+47dFvQeD6U2s0Z92EsKzcHogtum4QB+UNd025WOJSHvn/hjk9xmzj7Stj95CyUAs31mrjxliEsQ== + dependencies: + dijkstrajs "^1.0.1" + encode-utf8 "^1.0.3" + pngjs "^5.0.0" + yargs "^15.3.1" + +qrcode@1.5.3, qrcode@^1.5.1: + version "1.5.3" + resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.3.tgz#03afa80912c0dccf12bc93f615a535aad1066170" + integrity sha512-puyri6ApkEHYiVl4CFzo1tDkAZ+ATcnbJrJ6RiBM1Fhctdn/ix9MTE3hRph33omisEbC/2fcfemsseiKgBPKZg== + dependencies: + dijkstrajs "^1.0.1" + encode-utf8 "^1.0.3" + pngjs "^5.0.0" + yargs "^15.3.1" + +qs@^6.10.3: + version "6.11.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" + integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== + dependencies: + side-channel "^1.0.4" + +query-string@7.1.3: + version "7.1.3" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-7.1.3.tgz#a1cf90e994abb113a325804a972d98276fe02328" + integrity sha512-hh2WYhq4fi8+b+/2Kg9CEge4fDPvHS534aOOvOZeQ3+Vf2mCFsaFBYj0i+iXcAq6I9Vzp5fjMFBlONvayDC1qg== + dependencies: + decode-uri-component "^0.2.2" + filter-obj "^1.1.0" + split-on-first "^1.0.0" + strict-uri-encode "^2.0.0" + +query-string@^6.13.5: + version "6.14.1" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.14.1.tgz#7ac2dca46da7f309449ba0f86b1fd28255b0c86a" + integrity sha512-XDxAeVmpfu1/6IjyT/gXHOl+S0vQ9owggJ30hhWKdHAsNPOcasn5o9BW0eejZqL2e4vMjhAxoW3jVHcD6mbcYw== + dependencies: + decode-uri-component "^0.2.0" + filter-obj "^1.1.0" + split-on-first "^1.0.0" + strict-uri-encode "^2.0.0" + querystringify@^2.1.1: version "2.2.0" resolved "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz" integrity sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ== +quick-format-unescaped@^4.0.3: + version "4.0.4" + resolved "https://registry.yarnpkg.com/quick-format-unescaped/-/quick-format-unescaped-4.0.4.tgz#93ef6dd8d3453cbc7970dd614fad4c5954d6b5a7" + integrity sha512-tYC1Q1hgyRuHgloV/YXs2w15unPVh8qfu/qCTfhTYamaw7fyhumKa2yGpdSo87vY32rIclj+4fWYQXUMs9EHvg== + +randombytes@^2.1.0: + version "2.1.0" + resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" + integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== + dependencies: + safe-buffer "^5.1.0" + react-icons@^4.10.1: version "4.10.1" resolved "https://registry.yarnpkg.com/react-icons/-/react-icons-4.10.1.tgz#3f3b5eec1f63c1796f6a26174a1091ca6437a500" @@ -1031,6 +2717,17 @@ react-remove-scroll-bar@^2.3.3: react-style-singleton "^2.2.1" tslib "^2.0.0" +react-remove-scroll@2.5.4: + version "2.5.4" + resolved "https://registry.yarnpkg.com/react-remove-scroll/-/react-remove-scroll-2.5.4.tgz#afe6491acabde26f628f844b67647645488d2ea0" + integrity sha512-xGVKJJr0SJGQVirVFAUZ2k1QLyO6m+2fy0l8Qawbp5Jgrv3DeLalrfMNBFSlmz5kriGGzsVBtGVnf4pTKIhhWA== + dependencies: + react-remove-scroll-bar "^2.3.3" + react-style-singleton "^2.2.1" + tslib "^2.1.0" + use-callback-ref "^1.3.0" + use-sidecar "^1.1.2" + react-remove-scroll@2.5.5: version "2.5.5" resolved "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.5.5.tgz" @@ -1065,11 +2762,40 @@ react-twitter-embed@^4.0.4: dependencies: scriptjs "^2.5.9" +readable-stream@^3.1.1, readable-stream@^3.5.0, readable-stream@^3.6.0: + version "3.6.2" + resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" + integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== + dependencies: + inherits "^2.0.3" + string_decoder "^1.1.1" + util-deprecate "^1.0.1" + +real-require@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/real-require/-/real-require-0.1.0.tgz#736ac214caa20632847b7ca8c1056a0767df9381" + integrity sha512-r/H9MzAWtrv8aSVjPCMFpDMl5q66GqtmmRkRjpHTsp4zBAa+snZyiQNlMONiUmEJcsnaw0wCauJ2GWODr/aFkg== + regenerator-runtime@^0.13.11: version "0.13.11" resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== +regenerator-runtime@^0.14.0: + version "0.14.0" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz#5e19d68eb12d486f797e15a3c6a918f7cec5eb45" + integrity sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA== + +require-directory@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" + integrity sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q== + +require-main-filename@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/require-main-filename/-/require-main-filename-2.0.0.tgz#d0b329ecc7cc0f61649f62215be69af54aa8989b" + integrity sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg== + requires-port@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz" @@ -1080,11 +2806,75 @@ retry@^0.12.0: resolved "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz" integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== +rpc-websockets@^7.5.1: + version "7.6.0" + resolved "https://registry.yarnpkg.com/rpc-websockets/-/rpc-websockets-7.6.0.tgz#d3f4c0dac108ca35566b0e31552c32e58928cd04" + integrity sha512-Jgcs8q6t8Go98dEulww1x7RysgTkzpCMelVxZW4hvuyFtOGpeUz9prpr2KjUa/usqxgFCd9Tu3+yhHEP9GVmiQ== + dependencies: + "@babel/runtime" "^7.17.2" + eventemitter3 "^4.0.7" + uuid "^8.3.2" + ws "^8.5.0" + optionalDependencies: + bufferutil "^4.0.1" + utf-8-validate "^5.0.2" + +rxjs@^6.6.3: + version "6.6.7" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" + integrity sha512-hTdwr+7yYNIT5n4AMYp85KA6yw2Va0FLa3Rguvbpa4W3I5xynaBZo41cM3XM+4Q6fRMj3sBYIR1VAmZMXYJvRQ== + dependencies: + tslib "^1.9.0" + +safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@~5.2.0: + version "5.2.1" + resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" + integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== + +safe-json-utils@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/safe-json-utils/-/safe-json-utils-1.1.1.tgz#0e883874467d95ab914c3f511096b89bfb3e63b1" + integrity sha512-SAJWGKDs50tAbiDXLf89PDwt9XYkWyANFWVzn4dTXl5QyI8t2o/bW5/OJl3lvc2WVU4MEpTo9Yz5NVFNsp+OJQ== + +safe-stable-stringify@^2.1.0: + version "2.4.3" + resolved "https://registry.yarnpkg.com/safe-stable-stringify/-/safe-stable-stringify-2.4.3.tgz#138c84b6f6edb3db5f8ef3ef7115b8f55ccbf886" + integrity sha512-e2bDA2WJT0wxseVd4lsDP4+3ONX6HpMXQa1ZhFQ7SU+GjvORCmShbCMltrtIDfkYhVHrOcPtj+KhmDBdPdZD1g== + scriptjs@^2.5.9: version "2.5.9" resolved "https://registry.npmjs.org/scriptjs/-/scriptjs-2.5.9.tgz" integrity sha512-qGVDoreyYiP1pkQnbnFAUIS5AjenNwwQBdl7zeos9etl+hYKWahjRTfzAZZYBv5xNHx7vNKCmaLDQZ6Fr2AEXg== +semver@^7.3.8: + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== + dependencies: + lru-cache "^6.0.0" + +set-blocking@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" + integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== + +sha.js@^2.4.11: + version "2.4.11" + resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.11.tgz#37a5cf0b81ecbc6943de109ba2960d1b26584ae7" + integrity sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ== + dependencies: + inherits "^2.0.1" + safe-buffer "^5.0.1" + +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" + integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + signal-exit@^3.0.2: version "3.0.7" resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" @@ -1108,6 +2898,64 @@ socket.io-parser@~4.2.1: "@socket.io/component-emitter" "~3.1.0" debug "~4.3.1" +sonic-boom@^2.2.1: + version "2.8.0" + resolved "https://registry.yarnpkg.com/sonic-boom/-/sonic-boom-2.8.0.tgz#c1def62a77425090e6ad7516aad8eb402e047611" + integrity sha512-kuonw1YOYYNOve5iHdSahXPOK49GqwA+LZhI6Wz/l0rP57iKyXXIHaRagOBHAPmGwJC6od2Z9zgvZ5loSgMlVg== + dependencies: + atomic-sleep "^1.0.0" + +split-on-first@^1.0.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/split-on-first/-/split-on-first-1.1.0.tgz#f610afeee3b12bce1d0c30425e76398b78249a5f" + integrity sha512-43ZssAJaMusuKWL8sKUBQXHWOpq8d6CfN/u1p4gUzfJkM05C8rxTmYrkIPTXapZpORA6LkkzcUulJ8FqA7Uudw== + +split2@^4.0.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/split2/-/split2-4.2.0.tgz#c9c5920904d148bab0b9f67145f245a86aadbfa4" + integrity sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg== + +stream-browserify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/stream-browserify/-/stream-browserify-3.0.0.tgz#22b0a2850cdf6503e73085da1fc7b7d0c2122f2f" + integrity sha512-H73RAHsVBapbim0tU2JwwOiXUj+fikfiaoYAKHF3VJfA0pe2BCzkhAHBlLG6REzE+2WNZcxOXjK7lkso+9euLA== + dependencies: + inherits "~2.0.4" + readable-stream "^3.5.0" + +stream-shift@^1.0.0: + version "1.0.1" + resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" + integrity sha512-AiisoFqQ0vbGcZgQPY1cdP2I76glaVA/RauYR4G4thNFgkTqr90yXTo4LYX60Jl+sIlPNHHdGSwo01AvbKUSVQ== + +strict-uri-encode@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-2.0.0.tgz#b9c7330c7042862f6b142dc274bbcc5866ce3546" + integrity sha512-QwiXZgpRcKkhTj2Scnn++4PKtWsH0kpzZ62L2R6c/LUVYv7hVnZqcg2+sMuT6R7Jusu1vviK/MFsu6kNJfWlEQ== + +string-width@^4.1.0, string-width@^4.2.0: + version "4.2.3" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" + integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g== + dependencies: + emoji-regex "^8.0.0" + is-fullwidth-code-point "^3.0.0" + strip-ansi "^6.0.1" + +string_decoder@^1.1.1: + version "1.3.0" + resolved "https://registry.yarnpkg.com/string_decoder/-/string_decoder-1.3.0.tgz#42f114594a46cf1a8e30b0a84f56c78c3edac21e" + integrity sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA== + dependencies: + safe-buffer "~5.2.0" + +strip-ansi@^6.0.0, strip-ansi@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" + integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A== + dependencies: + ansi-regex "^5.0.1" + style-to-js@1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/style-to-js/-/style-to-js-1.1.1.tgz" @@ -1122,21 +2970,70 @@ style-to-object@0.3.0: dependencies: inline-style-parser "0.1.1" +superstruct@^0.14.2: + version "0.14.2" + resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-0.14.2.tgz#0dbcdf3d83676588828f1cf5ed35cda02f59025b" + integrity sha512-nPewA6m9mR3d6k7WkZ8N8zpTWfenFH3q9pA2PkuiZxINr9DKB2+40wEQf0ixn8VaGuJ78AB6iWOtStI+/4FKZQ== + +superstruct@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-1.0.3.tgz#de626a5b49c6641ff4d37da3c7598e7a87697046" + integrity sha512-8iTn3oSS8nRGn+C2pgXSKPI3jmpm6FExNazNpjvqS6ZUJQCej3PUXEKM8NjHBOs54ExM+LPW/FBRhymrdcCiSg== + +supports-color@^7.1.0: + version "7.2.0" + resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" + integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== + dependencies: + has-flag "^4.0.0" + +text-encoding-utf-8@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/text-encoding-utf-8/-/text-encoding-utf-8-1.0.2.tgz#585b62197b0ae437e3c7b5d0af27ac1021e10d13" + integrity sha512-8bw4MY9WjdsD2aMtO0OzOCY3pXGYNx2d2FfHRVUKkiCPDWjKuOlhLVASS+pD7VkLTVjW268LYJHwsnPFlBpbAg== + +thread-stream@^0.15.1: + version "0.15.2" + resolved "https://registry.yarnpkg.com/thread-stream/-/thread-stream-0.15.2.tgz#fb95ad87d2f1e28f07116eb23d85aba3bc0425f4" + integrity sha512-UkEhKIg2pD+fjkHQKyJO3yoIvAP3N6RlNFt2dUhcS1FGvCD1cQa1M/PGknCLFIyZdtJOWQjejp7bdNqmN7zwdA== + dependencies: + real-require "^0.1.0" + +"through@>=2.2.7 <3": + version "2.3.8" + resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" + integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== + tiny-warning@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754" integrity sha512-lBN9zLN/oAf68o3zNXYrdCt1kP8WsiGW8Oo2ka41b2IM5JL/S1CTyX1rW0mb/zSuJun0ZUrDxx4sqvYS2FWzPA== +toggle-selection@^1.0.6: + version "1.0.6" + resolved "https://registry.yarnpkg.com/toggle-selection/-/toggle-selection-1.0.6.tgz#6e45b1263f2017fa0acc7d89d78b15b8bf77da32" + integrity sha512-BiZS+C1OS8g/q2RRbJmy59xpyghNBqrr6k5L/uKBGRsTfxmu3ffiRnd8mlGPUVayg8pvfi5urfnu8TU7DVOkLQ== + tr46@~0.0.3: version "0.0.3" resolved "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz" integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== +tslib@1.14.1, tslib@^1.9.0: + version "1.14.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" + integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== + tslib@^2.0.0, tslib@^2.1.0, tslib@^2.3.0: version "2.5.0" resolved "https://registry.npmjs.org/tslib/-/tslib-2.5.0.tgz" integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg== +tslib@^2.3.1: + version "2.6.1" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.1.tgz#fd8c9a0ff42590b25703c0acb3de3d3f4ede0410" + integrity sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig== + tus-js-client@^3.1.0: version "3.1.1" resolved "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz" @@ -1150,6 +3047,20 @@ tus-js-client@^3.1.0: proper-lockfile "^4.1.2" url-parse "^1.5.7" +typedarray-to-buffer@3.1.5: + version "3.1.5" + resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz#a97ee7a9ff42691b9f783ff1bc5112fe3fca9080" + integrity sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q== + dependencies: + is-typedarray "^1.0.0" + +uint8arrays@^3.0.0, uint8arrays@^3.1.0: + version "3.1.1" + resolved "https://registry.yarnpkg.com/uint8arrays/-/uint8arrays-3.1.1.tgz#2d8762acce159ccd9936057572dade9459f65ae0" + integrity sha512-+QJa8QRnbdXVpHYjLoTpJIdCTiw9Ir62nocClWuXIq2JIh4Uta0cQsTSpFL678p2CN8B+XSApwcU+pQEqVpKWg== + dependencies: + multiformats "^9.4.2" + url-parse@^1.5.7: version "1.5.10" resolved "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz" @@ -1178,6 +3089,70 @@ use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: resolved "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz" integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== +utf-8-validate@^5.0.2: + version "5.0.10" + resolved "https://registry.yarnpkg.com/utf-8-validate/-/utf-8-validate-5.0.10.tgz#d7d10ea39318171ca982718b6b96a8d2442571a2" + integrity sha512-Z6czzLq4u8fPOyx7TU6X3dvUZVvoJmxSQ+IcrlmagKhilxlhZgxPK6C5Jqbkw1IDUmFTM+cz9QDnnLTwDz/2gQ== + dependencies: + node-gyp-build "^4.3.0" + +util-deprecate@^1.0.1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" + integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== + +util@^0.12.4: + version "0.12.5" + resolved "https://registry.yarnpkg.com/util/-/util-0.12.5.tgz#5f17a6059b73db61a875668781a1c2b136bd6fbc" + integrity sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA== + dependencies: + inherits "^2.0.3" + is-arguments "^1.0.4" + is-generator-function "^1.0.7" + is-typed-array "^1.1.3" + which-typed-array "^1.1.2" + +uuid@^8.3.2: + version "8.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" + integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== + +valtio@1.11.0: + version "1.11.0" + resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.11.0.tgz#c029dcd17a0f99d2fbec933721fe64cfd32a31ed" + integrity sha512-65Yd0yU5qs86b5lN1eu/nzcTgQ9/6YnD6iO+DDaDbQLn1Zv2w12Gwk43WkPlUBxk5wL/6cD5YMFf7kj6HZ1Kpg== + dependencies: + proxy-compare "2.5.1" + use-sync-external-store "1.2.0" + +viem@^1.0.0: + version "1.6.0" + resolved "https://registry.yarnpkg.com/viem/-/viem-1.6.0.tgz#8befa678c3ac79b9558dfd1708130b2ecb1994f4" + integrity sha512-ae9Twkd0q2Qlj4yYpWjb4DzYAhKY0ibEpRH8FJaTywZXNpTjFidSdBaT0CVn1BaH7O7cnX4/O47zvDUMGJD1AA== + dependencies: + "@adraffy/ens-normalize" "1.9.0" + "@noble/curves" "1.1.0" + "@noble/hashes" "1.3.0" + "@scure/bip32" "1.3.0" + "@scure/bip39" "1.2.0" + "@types/ws" "^8.5.4" + "@wagmi/chains" "1.6.0" + abitype "0.9.3" + isomorphic-ws "5.0.0" + ws "8.12.0" + +wagmi@^1.3.10: + version "1.3.10" + resolved "https://registry.yarnpkg.com/wagmi/-/wagmi-1.3.10.tgz#100aeaecf7a030e9e91118d366a734ec30c56551" + integrity sha512-MMGJcnxOmeUZWDmzUxgRGcB1cqxbJoSFSa+pNY4vBCWMz0n4ptpE5F8FKISLCx+BGoDwsaz2ldcMALcdJZ+29w== + dependencies: + "@tanstack/query-sync-storage-persister" "^4.27.1" + "@tanstack/react-query" "^4.28.0" + "@tanstack/react-query-persist-client" "^4.28.0" + "@wagmi/core" "1.3.9" + abitype "0.8.7" + use-sync-external-store "^1.2.0" + webidl-conversions@^3.0.0: version "3.0.1" resolved "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz" @@ -1191,6 +3166,51 @@ whatwg-url@^5.0.0: tr46 "~0.0.3" webidl-conversions "^3.0.0" +which-module@^2.0.0: + version "2.0.1" + resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.1.tgz#776b1fe35d90aebe99e8ac15eb24093389a4a409" + integrity sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ== + +which-typed-array@^1.1.11, which-typed-array@^1.1.2: + version "1.1.11" + resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.11.tgz#99d691f23c72aab6768680805a271b69761ed61a" + integrity sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew== + dependencies: + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + for-each "^0.3.3" + gopd "^1.0.1" + has-tostringtag "^1.0.0" + +wrap-ansi@^6.2.0: + version "6.2.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-6.2.0.tgz#e9393ba07102e6c91a3b221478f0257cd2856e53" + integrity sha512-r6lPcBGxZXlIcymEu7InxDMhdW0KDxpLgoFLcguasxCaJ/SOIZwINatK9KY/tf+ZrlywOKU0UDj3ATXUBfxJXA== + dependencies: + ansi-styles "^4.0.0" + string-width "^4.1.0" + strip-ansi "^6.0.0" + +wrappy@1: + version "1.0.2" + resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" + integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== + +ws@8.12.0: + version "8.12.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.12.0.tgz#485074cc392689da78e1828a9ff23585e06cddd8" + integrity sha512-kU62emKIdKVeEIOIKVegvqpXMSTAMLJozpHZaJNDYqBjzlSYXQGviYwN1osDLJ9av68qHd4a2oSjd7yD4pacig== + +ws@^7.4.5, ws@^7.5.1: + version "7.5.9" + resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591" + integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q== + +ws@^8.5.0: + version "8.13.0" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.13.0.tgz#9a9fb92f93cf41512a0735c8f4dd09b8a1211cd0" + integrity sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA== + ws@~8.11.0: version "8.11.0" resolved "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz" @@ -1201,6 +3221,53 @@ xmlhttprequest-ssl@~2.0.0: resolved "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz" integrity sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A== +xtend@^4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" + integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== + +y18n@^4.0.0: + version "4.0.3" + resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.3.tgz#b5f259c82cd6e336921efd7bfd8bf560de9eeedf" + integrity sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ== + +yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== + +yargs-parser@^18.1.2: + version "18.1.3" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-18.1.3.tgz#be68c4975c6b2abf469236b0c870362fab09a7b0" + integrity sha512-o50j0JeToy/4K6OZcaQmW6lyXXKhq7csREXcDwk2omFPJEwUNOVtJKvmDr9EI1fAJZUyZcRF7kxGBWmRXudrCQ== + dependencies: + camelcase "^5.0.0" + decamelize "^1.2.0" + +yargs@^15.3.1: + version "15.4.1" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-15.4.1.tgz#0d87a16de01aee9d8bec2bfbf74f67851730f4f8" + integrity sha512-aePbxDmcYW++PaqBsJ+HYUFwCdv4LVvdnhBy78E57PIor8/OVvhMrADFFEDh8DHDFRv/O9i3lPhsENjO7QX0+A== + dependencies: + cliui "^6.0.0" + decamelize "^1.2.0" + find-up "^4.1.0" + get-caller-file "^2.0.1" + require-directory "^2.1.1" + require-main-filename "^2.0.0" + set-blocking "^2.0.0" + string-width "^4.2.0" + which-module "^2.0.0" + y18n "^4.0.0" + yargs-parser "^18.1.2" + +zustand@^4.3.1: + version "4.4.1" + resolved "https://registry.yarnpkg.com/zustand/-/zustand-4.4.1.tgz#0cd3a3e4756f21811bd956418fdc686877e8b3b0" + integrity sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw== + dependencies: + use-sync-external-store "1.2.0" + zustand@^4.3.9: version "4.4.0" resolved "https://registry.npmjs.org/zustand/-/zustand-4.4.0.tgz" From e1fc4038485180588d15780f6c327e01d90fe41a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 24 Aug 2023 01:13:30 +0530 Subject: [PATCH 214/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 13 +++++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 746e43385..15792fe2f 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.1...uiweb-0.0.1-alpha.2) (2023-08-23) + + +### Bug Fixes + +* hide few spaces features ([#622](https://github.com/ethereum-push-notification-service/push-sdk/issues/622)) ([0e2556c](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e2556c6bbe3438cd30851ffdd9764b027f42f6e)) +* merge alpha ([1783d45](https://github.com/ethereum-push-notification-service/push-sdk/commit/1783d45bb3ceab1cce3c6bb19dfbda38c3662a3e)) +* Merge branch 'alpha' into alpha-deployment ([8b50b53](https://github.com/ethereum-push-notification-service/push-sdk/commit/8b50b53eae51729ab9c5202b1750d70c444be829)) +* merge main ([f338fd4](https://github.com/ethereum-push-notification-service/push-sdk/commit/f338fd49707933c65bdcc7736cdd08d6784625ba)) +* **spaces:** broadcast changes and UX fixes ([#674](https://github.com/ethereum-push-notification-service/push-sdk/issues/674)) ([375ebe7](https://github.com/ethereum-push-notification-service/push-sdk/commit/375ebe7f7e757d84df62cd103884e75d04bcc2b0)), closes [#642](https://github.com/ethereum-push-notification-service/push-sdk/issues/642) [#657](https://github.com/ethereum-push-notification-service/push-sdk/issues/657) [#656](https://github.com/ethereum-push-notification-service/push-sdk/issues/656) + + + ## [0.0.1-alpha.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.0...uiweb-0.0.1-alpha.1) (2023-08-10) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index f5654f205..acb8160ac 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.1", + "version": "0.0.1-alpha.2", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From cbfbec0b17a460361b4b5ecef84aaa45b06ab7a2 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 24 Aug 2023 15:11:38 +0530 Subject: [PATCH 215/298] fix: dummy change --- packages/uiweb/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/packages/uiweb/README.md b/packages/uiweb/README.md index d7bbe3e09..fe84d77d5 100644 --- a/packages/uiweb/README.md +++ b/packages/uiweb/README.md @@ -330,3 +330,4 @@ Allowed Options (props with * are mandatory) | activeChat | string | - | to open a particular chat when modal first opens | | onClose | () => void | - | function to execute when modal is minimised | | env | string | 'prod' | API env - 'prod', 'staging', 'dev'| + From c76c01c8e8fa6f23c03484cf89389de3a83cb488 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 24 Aug 2023 15:31:19 +0530 Subject: [PATCH 216/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 4a132bf56..460f32368 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.12...uiweb-1.1.13) (2023-08-24) + + +### Bug Fixes + +* dummy change ([cbfbec0](https://github.com/ethereum-push-notification-service/push-sdk/commit/cbfbec0b17a460361b4b5ecef84aaa45b06ab7a2)) + + + ## [1.1.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.11...uiweb-1.1.12) (2023-08-23) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index cc2bf67ce..04a0fc8d3 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.12", + "version": "1.1.13", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 8f3eaf363f8a4558403bbef98d6d2c433471e8fd Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 24 Aug 2023 16:45:17 +0530 Subject: [PATCH 217/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.16?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index e6581f531..3f3e5fe92 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.15...restapi-1.4.16) (2023-08-24) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([5d959cc](https://github.com/ethereum-push-notification-service/push-sdk/commit/5d959cc4d11b8a937612f2c5b9ef15c961f3ffb1)) +* Merge branch 'main' into deployment ([d5da240](https://github.com/ethereum-push-notification-service/push-sdk/commit/d5da2403d44118d919d9ed14cc6f37372701fc3b)) + + + ## [1.4.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.14...restapi-1.4.15) (2023-08-23) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 6b648549b..c04cf2647 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.15", + "version": "1.4.16", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 2e178db826b82f60664746ae4b9e3f13df72411f Mon Sep 17 00:00:00 2001 From: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Date: Fri, 25 Aug 2023 16:59:52 +0530 Subject: [PATCH 218/298] Join group option (#681) * feat: created architechture * fix: added context values (#594) * Chat dataprovider (#596) * feat: data provider for chat component * fix: replaced react.usestate to usestate * fix: added props as the initial state and changed state name * fix: reverted chat context changes and renamed values * fix: added test page for chat ui components (#597) * added chatbubble component (#602) * feat: added chatbubble component * fix: made the messageBubble's width to fit-content --------- Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> * fix: added theme * Group chat bubble (#604) * feat: moved test component to testui folder & replaced dummy data with sdk response * feat: added twitter card and address for group chat received msg * feat: made the messageaddress reusable, added account from context * fix: removed unnecessary div and unused props and console logs * feat: adding pfp in text bubbles * fix: replaced hook with function and added pfp to messagebubble * fix: fixed image alignment * fix: changed border-radius of msg bubble and changed function name * fix: fixed theme and decryptedPrivateKey name (#616) * fix: fixed theme and decryptedPrivateKey name * fix: fixed bug * fix: fixed theme reviews * Message list (#615) * fix: message list comp * fix: message list comp * fix: added pagination * fix: added pagination * fix: pagination * fix: create useChatData hook * fix: fixed minor bug * fix: socket issues fixed * fix: added theme in msgbubble (#620) * fix: added theme in msgbubble * fix: fixed import --------- Co-authored-by: Monalisha Mishra * fix: exported the theme (#623) * fix: exported the theme * fix: fixed issues --------- Co-authored-by: Monalisha Mishra * Typebar component (#631) * feat: added typebar UI * feat: added functions to typebar * fix: added icon * fix: fixed theme issues --------- Co-authored-by: Monalisha Mishra * feat: added connectbutton * fix: fixed connectbtn ui and remove disconnect and fixed error on disconnect * fix: fixed create account getting called twice * Profile Header Component (#636) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * Message container (#635) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * fix: updated svg to react component * fix: changed svg to tsx component * fix: fixed review changes (#646) * fix: fixed review changes * fix: resolved issues --------- Co-authored-by: Nilesh Gupta * Profile Header -> Chat Profile fixes (#647) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * fix: notifs * fix: correct theme colors * fix: renaming profileHeader * fix: qa fixes * fix: loader * refactor: resolved issues * fix: edit types --------- Co-authored-by: Nilesh Gupta * fix: resolved package not added issue * Fix: modal issue in group info && alert remove members (#653) * fix: modal * fix: update changes * refactor: resolved issue --------- Co-authored-by: Nilesh Gupta * fix: QA fixes (#654) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * Connect btn revamp (#668) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container * feat: adding rainbowkit for btn * fix: fix issues * fix: addec onnect functionality * fix: connect button * fix: added hack for rainbowkit css --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * Typebar UI issue (#666) * fix: fixed typebar space not working and theme * fix: fixed gif and emoji --------- Co-authored-by: KlausMikhaelson * fix: fixed theme colours * fix: added theme for brb * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * fix: added filter hat * fix: merged with main * fix: fixed msg border * fix: fixed theme * fix: fixed fonts * fix: fixed bug * Access control (#672) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * fix: added minor fix --------- Co-authored-by: Monalisha Mishra * fix: fixed padding issues * fix(f): fixed build issues * fix: fix for chat status test * feat: added verification option to show only on token gated groups * fix: fixing group access control * Check rules access control (#678) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * 662 group access control v2 changes (#663) * fix: spaces access API * fix: custom endpoint doc impl * Update README.md * Update README.md * fix: review comments change * fix: read me update * Update README.md * Update README.md * fix: origin in user creation (#665) * fix: origin in user creation * Update README.md * fix: review comments * 662 group access control v2 changes (#677) * fix: spaces access API * fix: custom endpoint doc impl * Update README.md * Update README.md * fix: review comments change * fix: read me update * Update README.md * Update README.md * fix(spaces): broadcast changes and UX fixes (#674) * fix: fix UI grid view (#642) * fix: fix UI grid view * refactor: conditional added * fix: resolved muting/unmuting try catch error (#657) * fix(spaces): fix livepeer broadcast (#656) * fix(spaces): fix livepeer broadcast * fix(spaces): fix data shown for unjoined space & promote listener logic --------- Co-authored-by: Madhur Gupta * refactor(spaces): use local state instead of get from server while meta message fire (#676) --------- Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Nilesh Gupta * feat: added verification option to show only on token gated groups * fix: fixing group access control --------- Co-authored-by: Monalisha Mishra Co-authored-by: Mohammed S Co-authored-by: Madhur Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Nilesh Gupta * fix: fixed build * feat: added send request to join group * fix: fixed verification on send * fix: fixed verify access btn not showing after joining group * fix: fixed join group showing for members too * fix: fixed join group showing to members * 667 chat.send enhancement (#673) * fix: changes messageObj for meta and reaction message type * fix: enhance send fn * fix: fixed intent issues * 680 group rules cosmetic changes (#682) * fix: fixed guild condition * fix: add did validation * fix: fixed * fix: fixed minor issues * fix: fixe dissue * fix: fixed minor issues * fix: check for scroll * fix: fixed scrolling * fix: fixed theme * fix: fixed * fix: fixed * fix: fixed * fix: fixed issues * fix: fixed * feat: added toast in join group btn for pvt groups * fix: fixed blurr --------- Co-authored-by: Monalisha Mishra Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Co-authored-by: Kolade Co-authored-by: Nilesh Gupta Co-authored-by: Mohammed S Co-authored-by: Madhur Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Aman Gupta --- .../src/app/ChatTest/CreateGroupTest.tsx | 2 +- .../src/app/ChatUITest/ChatViewComponent.tsx | 3 +- .../sdk-frontend-react/src/app/app.tsx | 2 +- packages/restapi/README.md | 104 +- .../restapi/src/lib/chat/getGroupAccess.ts | 6 +- .../src/lib/chat/helpers/payloadHelper.ts | 41 +- packages/restapi/src/lib/chat/send.ts | 153 ++- packages/restapi/src/lib/space/Space.ts | 2 +- .../src/lib/space/broadcastRaisedHand.ts | 2 +- .../src/lib/space/helpers/getLiveSpaceData.ts | 6 +- .../lib/space/helpers/sendLiveSpaceData.ts | 2 +- .../restapi/src/lib/space/onJoinListener.ts | 2 +- .../src/lib/space/onReceiveMetaMessage.ts | 7 +- .../src/lib/space/rejectPromotionRequest.ts | 2 +- packages/restapi/src/lib/space/start.ts | 2 +- packages/restapi/src/lib/types/index.ts | 46 +- ...{messageObjectTypes.ts => messageTypes.ts} | 68 +- .../src/lib/validations/messageObject.ts | 13 +- packages/restapi/tests/lib/chat/send.test.ts | 445 ++++++- packages/restapi/yarn.lock | 90 +- .../chat/ChatProfile/ChatProfile.tsx | 1 - .../chat/ChatProfile/GroupInfoModal.tsx | 8 +- .../chat/ChatProfile/ProfileCard.tsx | 2 +- .../ChatViewComponent/ChatViewComponent.tsx | 1 - .../ChatViewList/ApproveRequestBubble.tsx | 1 + .../chat/ChatViewList/ChatViewList.tsx | 71 +- .../chat/ChatViewList/MessageEncryption.tsx | 17 +- .../chat/ConnectButton/ConnectButton.tsx | 2 - .../chat/MessageInput/MessageInput.tsx | 1130 +++++++++++------ .../chat/ProfileHeader/AddWalletContent.tsx | 1 - .../src/lib/components/chat/helpers/Modal.tsx | 6 +- .../src/lib/components/chat/theme/index.ts | 3 + .../lib/dataProviders/ChatDataProvider.tsx | 6 +- packages/uiweb/src/lib/helpers/address.ts | 10 +- packages/uiweb/src/lib/helpers/chat/chat.ts | 20 +- .../lib/hooks/chat/useApproveChatRequest.ts | 2 + .../uiweb/src/lib/hooks/chat/useFetchChat.ts | 3 +- .../hooks/chat/useFetchConversationHash.ts | 2 +- .../lib/hooks/chat/useFetchHistoryMessages.ts | 2 +- .../src/lib/hooks/chat/usePushChatSocket.ts | 43 +- .../src/lib/hooks/chat/usePushSendMessage.ts | 12 +- .../lib/hooks/chat/useVerifyAccessControl.ts | 10 +- packages/uiweb/src/lib/icons/MoreLight.tsx | 12 +- 43 files changed, 1591 insertions(+), 772 deletions(-) rename packages/restapi/src/lib/types/{messageObjectTypes.ts => messageTypes.ts} (69%) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx index c37604b2e..2c52acb7d 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/CreateGroupTest.tsx @@ -107,7 +107,7 @@ const CreateGroupTest = () => { env, meta: meta, rules: { - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 0f7dae1ef..410f01f57 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -17,7 +17,7 @@ const ChatViewComponentTest = () => { {/* */} - console.log("BOIIII RETURNNNSSSSS")} chatId='c4828a375fd261577927a9d73fe3fa30204c6667a3adbc345e010eccf5ec740e' limit={10}/> + console.log("BOIIII RETURNNNSSSSS")} chatId='c2d544ad9d1efd5c5a593b143bf8232875c926cf28015564e70ad078b95f807e' limit={10}/> ); @@ -28,3 +28,4 @@ export default ChatViewComponentTest; const ChatViewComponentCard = styled(Section)` height: 60vh; `; +//c2d544ad9d1efd5c5a593b143bf8232875c926cf28015564e70ad078b95f807e diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index 7f014cb07..187401c5b 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -309,7 +309,7 @@ export function App() { - + } - chatAccess?: { + chat?: { conditions: Array } } @@ -3421,7 +3425,7 @@ export interface Rules { ## Rules Object Description -The rules object consists of two main sections: `groupAccess` and `chatAccess`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. +The rules object consists of two main sections: `groupAccess` and `chat`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. ### Conditions @@ -3458,15 +3462,37 @@ Explanation: #### GUILD Conditions -GUILD conditions require both guildID and guildRoleId or guildRoleAction. +Sample GUILD condition schema +
+{
+	"type": "GUILD",
+	"category": "guildRoles",
+	"subcategory": ,
+	"data": {
+		"guildId": ,
+		"guildRoleId": 
+	}
+}
+
- **Working**: -Guild ID Validation: The function first checks for the presence of the guildId. -API Call: On confirming its presence, the function then fetches guild data from a specific API endpoint to ascertain the guild's validity. -Role and Action Checks: After validating the guild: -The function checks for the presence of guildRoleId or guildRoleAction. At least one must be specified. -If guildRoleId is given, its legitimacy is cross-verified with the guild's roles. -For guildRoleAction, the function ensures its value is strictly "all" or "any". + +Fields: + type: + Always set to: "GUILD" + category: + Always set to: "guildRoles" + subcategory: + Role type classification. + Values: + specificRole: For a singular role. + allRoles: Pertaining to all roles in the guild. + anyRole: Referring to any role within the guild. + data: + guildId: Unique identifier of a guild. + guildRoleId: Role ID within the guild. (Required only for the specificRole subcategory.) +Usage: +This structure governs user permissions within a guild. The subcategory dictates the manner of role-based operations, from checking permissions of a single role (specificRole) to broad checks across any or all roles (anyRole, allRoles).
Expected response (create group) @@ -3594,6 +3620,8 @@ For guildRoleAction, the function ensures its value is strictly "all" or "any". }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -3611,7 +3639,7 @@ For guildRoleAction, the function ensures its value is strictly "all" or "any". } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -3627,6 +3655,8 @@ For guildRoleAction, the function ensures its value is strictly "all" or "any". }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -3634,9 +3664,10 @@ For guildRoleAction, the function ensures its value is strictly "all" or "any". }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'anyRole', 'data': { - 'guildId': '13468', - 'guildRoleAction': 'all/any' + 'guildId': '13468' } } ] @@ -3680,7 +3711,7 @@ Allowed Options (params with _ are mandatory) // PushAPI_chat_getGroupAccess | Response - 200 OK { 'groupAccess': true, - 'chatAccess': false, + 'chat': false, 'rules': { 'groupAccess': { 'conditions': [ @@ -3699,6 +3730,8 @@ Allowed Options (params with _ are mandatory) }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -3719,7 +3752,7 @@ Allowed Options (params with _ are mandatory) } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -3736,6 +3769,8 @@ Allowed Options (params with _ are mandatory) }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -3817,6 +3852,8 @@ const response = await PushAPI.chat.updateGroup({ }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guidlRoleId': '19924' @@ -3826,7 +3863,7 @@ const response = await PushAPI.chat.updateGroup({ } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -3842,6 +3879,8 @@ const response = await PushAPI.chat.updateGroup({ }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -4017,6 +4056,8 @@ Allowed Options (params with _ are mandatory) }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -4026,7 +4067,7 @@ Allowed Options (params with _ are mandatory) } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -4042,6 +4083,8 @@ Allowed Options (params with _ are mandatory) }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -4716,6 +4759,8 @@ const response = await PushAPI.space.create({ }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -4791,7 +4836,7 @@ export interface Rules { groupAccess?: { conditions: Array } - chatAccess?: { + chat?: { conditions: Array } } @@ -4893,6 +4938,8 @@ export interface Rules { }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -4957,6 +5004,8 @@ Allowed Options (params with _ are mandatory) }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', 'guildRoleId': '19924' @@ -5053,16 +5102,17 @@ const response = await PushAPI.space.update({ }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'allRoles', 'data': { - 'guildId': '13468', - 'roleId': '19924' + 'guildId': '13468' } } ] } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -5078,9 +5128,11 @@ const response = await PushAPI.space.update({ }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', - 'roleId': '19924' + 'guildRoleId': '19924' } } ] @@ -5221,9 +5273,11 @@ Allowed Options (params with _ are mandatory) }, { 'type': 'GUILD', + 'category': 'guildRoles', + 'subcategory': 'specificRole', 'data': { 'guildId': '13468', - 'roleId': '19924' + 'guildRoleId': '19924' } }, { diff --git a/packages/restapi/src/lib/chat/getGroupAccess.ts b/packages/restapi/src/lib/chat/getGroupAccess.ts index fa82629eb..51653f097 100644 --- a/packages/restapi/src/lib/chat/getGroupAccess.ts +++ b/packages/restapi/src/lib/chat/getGroupAccess.ts @@ -2,6 +2,7 @@ import axios from 'axios'; import { getAPIBaseUrls } from '../helpers'; import Constants, { ENV } from '../constants'; import { GroupAccess } from '../types'; +import { getUserDID } from './helpers'; /** * GET /v1/chat/groups/:chatId/access/:did @@ -22,12 +23,15 @@ export const getGroupAccess = async ( if (chatId == null || chatId.length === 0) { throw new Error(`chatId cannot be null or empty`); } + if (did == null || did.length === 0) { throw new Error(`did cannot be null or empty`); } + const user = await getUserDID(did, env); + const API_BASE_URL = getAPIBaseUrls(env); - const requestUrl = `${API_BASE_URL}/v1/chat/groups/${chatId}/access/${did}`; + const requestUrl = `${API_BASE_URL}/v1/chat/groups/${chatId}/access/${user}`; return axios .get(requestUrl) .then((response) => { diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index 3acf55182..70ed9c2c0 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -1,9 +1,18 @@ import { isValidETHAddress, walletToPCAIP10 } from '../../helpers'; -import { IConnectedUser, GroupDTO, SpaceDTO, ChatStatus, Rules, SpaceRules, GroupAccess, SpaceAccess } from '../../types'; +import { + IConnectedUser, + GroupDTO, + SpaceDTO, + ChatStatus, + Rules, + SpaceRules, + GroupAccess, + SpaceAccess +} from '../../types'; import { getEncryptedRequest } from './crypto'; -import { ENV, MessageType } from '../../constants'; +import { ENV } from '../../constants'; import * as AES from './aes'; -import { MessageTypeSpecificObject } from '../../types/messageObjectTypes'; +import { MessageObj } from '../../types/messageTypes'; import { sign } from './pgp'; import * as CryptoJS from 'crypto-js'; export interface ISendMessagePayload { @@ -11,7 +20,7 @@ export interface ISendMessagePayload { toDID: string; fromCAIP10: string; toCAIP10: string; - messageObj: MessageTypeSpecificObject[MessageType] | string; + messageObj: MessageObj | string; messageType: string; encType: string; encryptedSecret: string | null | undefined; @@ -68,7 +77,7 @@ export interface IUpdateGroupRequestPayload { export const sendMessagePayload = async ( receiverAddress: string, senderCreatedUser: IConnectedUser, - messageObj: MessageTypeSpecificObject[MessageType], + messageObj: MessageObj, messageContent: string, messageType: string, group: GroupDTO | null, @@ -172,7 +181,7 @@ export const createGroupPayload = ( groupType?: string | null, scheduleAt?: Date | null, scheduleEnd?: Date | null, - rules?: Rules | null, + rules?: Rules | null ): ICreateGroupRequestPayload => { const body = { groupName: groupName, @@ -191,7 +200,7 @@ export const createGroupPayload = ( groupType: groupType, scheduleAt: scheduleAt, scheduleEnd: scheduleEnd, - rules: rules + rules: rules, }; return body; }; @@ -224,14 +233,14 @@ export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { scheduleAt: groupDto.scheduleAt, scheduleEnd: groupDto.scheduleEnd, status: groupDto.status ?? null, - meta: groupDto.meta + meta: groupDto.meta, }; - if (groupDto.rules) { - spaceDto.rules = { - spaceAccess: groupDto.rules.groupAccess, - }; - } + if (groupDto.rules) { + spaceDto.rules = { + spaceAccess: groupDto.rules.groupAccess, + }; + } return spaceDto; }; @@ -239,9 +248,9 @@ export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { export const convertSpaceRulesToRules = (spaceRules: SpaceRules): Rules => { return { groupAccess: spaceRules.spaceAccess, - chatAccess: undefined, + chat: undefined, }; -} +}; export const convertRulesToSpaceRules = (rules: Rules): SpaceRules => { return { @@ -277,7 +286,7 @@ export const updateGroupPayload = ( scheduleEnd?: Date | null, status?: ChatStatus | null, meta?: string | null, - rules? : Rules | null + rules?: Rules | null ): IUpdateGroupRequestPayload => { const body = { groupName: groupName, diff --git a/packages/restapi/src/lib/chat/send.ts b/packages/restapi/src/lib/chat/send.ts index 28c4a31ee..30a396495 100644 --- a/packages/restapi/src/lib/chat/send.ts +++ b/packages/restapi/src/lib/chat/send.ts @@ -1,7 +1,7 @@ import axios from 'axios'; import { getAPIBaseUrls, isValidETHAddress } from '../helpers'; -import Constants, { MessageType } from '../constants'; -import { ChatSendOptionsType, MessageWithCID } from '../types'; +import Constants, { MessageType, ENV } from '../constants'; +import { ChatSendOptionsType, MessageWithCID, SignerType } from '../types'; import { getAccountAddress, getConnectedUserV2, @@ -12,9 +12,10 @@ import { conversationHash } from './conversationHash'; import { ISendMessagePayload, sendMessagePayload } from './helpers'; import { getGroup } from './getGroup'; import { - MessageTypeSpecificObject, + MessageObj, REACTION_SYMBOL, -} from '../types/messageObjectTypes'; + ReactionMessage, +} from '../types/messageTypes'; import { messageObjSchema, metaMessageObjSchema, @@ -27,46 +28,38 @@ import { export const send = async ( options: ChatSendOptionsType ): Promise => { - const { - messageType = 'Text', - receiverAddress, - pgpPrivateKey = null, - account = null, - signer = null, - env = Constants.ENV.PROD, - } = options || {}; - try { - await validateOptions(options); + /** + * Compute Input Options + * 1. Provides the options object with default values + * 2. Takes care of deprecated fields + */ + const computedOptions = computeOptions(options); + const { messageType, messageObj, account, to, signer, pgpPrivateKey, env } = + computedOptions; + /** + * Validate Input Options + */ + await validateOptions(computedOptions); const wallet = getWallet({ account, signer }); const sender = await getConnectedUserV2(wallet, pgpPrivateKey, env); - const receiver = await getUserDID(receiverAddress, env); + const receiver = await getUserDID(to, env); const API_BASE_URL = getAPIBaseUrls(env); - const isGroup = isValidETHAddress(receiverAddress) ? false : true; + const isGroup = isValidETHAddress(to) ? false : true; const group = isGroup ? await getGroup({ - chatId: receiverAddress, + chatId: to, env: env, }) : null; - let messageObj = options.messageObj; - // OVERRIDE CONTENT FOR REACTION MESSAGE - if (messageType === MessageType.REACTION && messageObj) { + if (messageType === MessageType.REACTION) { messageObj.content = - REACTION_SYMBOL[ - (messageObj as MessageTypeSpecificObject[MessageType.REACTION]).action - ]; + REACTION_SYMBOL[(messageObj as Omit).action]; } - // possible for initial types 'Text', 'Image', 'File', 'GIF', 'MediaEmbed' - if (!messageObj) { - messageObj = { - content: options.messageContent ? options.messageContent : '', - }; - } const messageContent = messageObj.content; // provide backward compatibility & override deprecated field const conversationResponse = await conversationHash({ @@ -98,17 +91,19 @@ export const send = async ( } }; -const validateOptions = async (options: ChatSendOptionsType) => { - const { - messageType = 'Text', - messageObj, - messageContent, - receiverAddress, - pgpPrivateKey = null, - account = null, - signer = null, - env, - } = options; +type ComputedOptionsType = { + messageType: MessageType; + messageObj: MessageObj; + account: string | null; + to: string; + signer: SignerType | null; + pgpPrivateKey: string | null; + env: ENV; +}; + +const validateOptions = async (options: ComputedOptionsType) => { + const { messageType, messageObj, account, to, signer, pgpPrivateKey, env } = + options; if (!account && !signer) { throw new Error( @@ -130,10 +125,10 @@ const validateOptions = async (options: ChatSendOptionsType) => { ); } - const isGroup = isValidETHAddress(receiverAddress) ? false : true; + const isGroup = isValidETHAddress(to) ? false : true; if (isGroup) { const group = await getGroup({ - chatId: receiverAddress, + chatId: to, env: env, }); if (!group) { @@ -144,12 +139,11 @@ const validateOptions = async (options: ChatSendOptionsType) => { } if ( - (messageType === MessageType.TEXT || - messageType === MessageType.IMAGE || - messageType === MessageType.FILE || - messageType === MessageType.MEDIA_EMBED || - messageType === MessageType.GIF) && - messageObj + messageType === MessageType.TEXT || + messageType === MessageType.IMAGE || + messageType === MessageType.FILE || + messageType === MessageType.MEDIA_EMBED || + messageType === MessageType.GIF ) { const { error } = messageObjSchema.validate(messageObj); if (error) { @@ -159,14 +153,14 @@ const validateOptions = async (options: ChatSendOptionsType) => { } } - if (messageType === MessageType.META && messageObj) { + if (messageType === MessageType.META) { const { error } = metaMessageObjSchema.validate(messageObj); if (error) { throw new Error( `Unable to parse this messageType. Please ensure 'messageObj' is properly defined.` ); } - } else if (messageType === MessageType.REACTION && messageObj) { + } else if (messageType === MessageType.REACTION) { const { error } = reationMessageObjSchema.validate(messageObj); if (error) { throw new Error( @@ -174,11 +168,62 @@ const validateOptions = async (options: ChatSendOptionsType) => { ); } } +}; - if (!pgpPrivateKey) { - // WARNING - WALLET SIGNING POPUPS +const computeOptions = (options: ChatSendOptionsType): ComputedOptionsType => { + const messageType = + options.message?.type !== undefined + ? options.message.type + : options.messageType ?? 'Text'; + + let messageObj: any = options.message; + if (messageObj === undefined) { + if ( + options.messageObj === undefined && + ![ + MessageType.TEXT, + MessageType.IMAGE, + MessageType.FILE, + MessageType.MEDIA_EMBED, + MessageType.GIF, + ].includes(messageType as MessageType) + ) { + throw new Error('Options.message is required'); + } else { + messageObj = + options.messageObj !== undefined + ? options.messageObj + : { + content: options.messageContent ?? '', + }; + } + } else { + // Remove the 'type' property from messageObj + const { type, ...rest } = messageObj; + messageObj = rest; } - if (messageContent) { - // WARNING - DEPRECATED AND TO BE REMOVED IN UPCOMING MAJOR RELEASE + + const account = options.account !== undefined ? options.account : null; + + const to = options.to !== undefined ? options.to : options.receiverAddress; + if (to === undefined) { + throw new Error('Options.to is required'); } + + const signer = options.signer !== undefined ? options.signer : null; + + const pgpPrivateKey = + options.pgpPrivateKey !== undefined ? options.pgpPrivateKey : null; + + const env = options.env !== undefined ? options.env : Constants.ENV.PROD; + + return { + messageType: messageType as MessageType, + messageObj: messageObj as MessageObj, + account: account, + to: to, + signer: signer, + pgpPrivateKey: pgpPrivateKey, + env: env, + }; }; diff --git a/packages/restapi/src/lib/space/Space.ts b/packages/restapi/src/lib/space/Space.ts index 5f2399f85..7ddd78b27 100644 --- a/packages/restapi/src/lib/space/Space.ts +++ b/packages/restapi/src/lib/space/Space.ts @@ -29,7 +29,7 @@ import { } from '../types'; import { VIDEO_CALL_TYPE } from '../payloads/constants'; import sendLiveSpaceData from './helpers/sendLiveSpaceData'; -import { META_ACTION } from '../types/messageObjectTypes'; +import { META_ACTION } from '../types/messageTypes'; import { broadcastRaisedHand } from './broadcastRaisedHand'; import { onReceiveMetaMessage } from './onReceiveMetaMessage'; import { onJoinListener } from './onJoinListener'; diff --git a/packages/restapi/src/lib/space/broadcastRaisedHand.ts b/packages/restapi/src/lib/space/broadcastRaisedHand.ts index 3554de01c..db2c0b1c9 100644 --- a/packages/restapi/src/lib/space/broadcastRaisedHand.ts +++ b/packages/restapi/src/lib/space/broadcastRaisedHand.ts @@ -1,6 +1,6 @@ import { produce } from 'immer'; import sendLiveSpaceData from './helpers/sendLiveSpaceData'; -import { META_ACTION } from '../types/messageObjectTypes'; +import { META_ACTION } from '../types/messageTypes'; import { pCAIP10ToWallet } from '../helpers'; import type Space from './Space'; diff --git a/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts b/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts index 4f36f2f22..4d3f952a4 100644 --- a/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts +++ b/packages/restapi/src/lib/space/helpers/getLiveSpaceData.ts @@ -1,7 +1,7 @@ import { conversationHash, history } from '../../chat'; import { MessageType } from '../../constants'; import { EnvOptionsType, LiveSpaceData } from '../../types'; -import { META_MESSAGE_OBJECT } from '../../types/messageObjectTypes'; +import { MetaMessage } from '../../types/messageTypes'; import { initLiveSpaceData } from '../Space'; interface GetLatestMessageType extends EnvOptionsType { @@ -54,8 +54,8 @@ const getLiveSpaceData = async ({ latestMetaMessage.messageObj !== null ) { // found the latest meta message - liveSpaceData = (latestMetaMessage.messageObj as META_MESSAGE_OBJECT)?.info - ?.arbitrary as LiveSpaceData; + liveSpaceData = (latestMetaMessage.messageObj as Omit) + ?.info?.arbitrary as LiveSpaceData; } return liveSpaceData; diff --git a/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts b/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts index ea3b5518a..78cb59fb1 100644 --- a/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts +++ b/packages/restapi/src/lib/space/helpers/sendLiveSpaceData.ts @@ -1,7 +1,7 @@ import { send } from '../../chat'; import { MessageType } from '../../constants'; import { EnvOptionsType, LiveSpaceData, SignerType } from '../../types'; -import { META_ACTION } from '../../types/messageObjectTypes'; +import { META_ACTION } from '../../types/messageTypes'; interface SendLiveSpaceData extends EnvOptionsType { liveSpaceData?: LiveSpaceData; diff --git a/packages/restapi/src/lib/space/onJoinListener.ts b/packages/restapi/src/lib/space/onJoinListener.ts index 497701d57..30db1c4dd 100644 --- a/packages/restapi/src/lib/space/onJoinListener.ts +++ b/packages/restapi/src/lib/space/onJoinListener.ts @@ -3,7 +3,7 @@ import { get } from './get'; import { pCAIP10ToWallet } from '../helpers'; import { produce } from 'immer'; -import { META_ACTION } from '../types/messageObjectTypes'; +import { META_ACTION } from '../types/messageTypes'; import type Space from './Space'; export interface OnJoinListenerType { diff --git a/packages/restapi/src/lib/space/onReceiveMetaMessage.ts b/packages/restapi/src/lib/space/onReceiveMetaMessage.ts index 9edf416b6..f6b6ae24c 100644 --- a/packages/restapi/src/lib/space/onReceiveMetaMessage.ts +++ b/packages/restapi/src/lib/space/onReceiveMetaMessage.ts @@ -1,6 +1,6 @@ import { MessageType } from '../constants'; import { IMessageIPFS, LiveSpaceData } from '../types'; -import { META_MESSAGE_OBJECT } from '../types/messageObjectTypes'; +import { MetaMessage } from '../types/messageTypes'; import type Space from './Space'; export interface OnReceiveMetaMessageType { @@ -18,13 +18,14 @@ export function onReceiveMetaMessage( if ( receivedMetaMessage.messageType !== MessageType.META || typeof receivedMetaMessage.messageObj !== 'object' || - !(receivedMetaMessage?.messageObj as META_MESSAGE_OBJECT)?.info?.arbitrary + !(receivedMetaMessage?.messageObj as Omit)?.info + ?.arbitrary ) { return; } const receivedLiveSpaceData = ( - receivedMetaMessage.messageObj as META_MESSAGE_OBJECT + receivedMetaMessage.messageObj as Omit ).info.arbitrary as LiveSpaceData; console.log('RECEIVED LIVE SPACE DATA', receivedLiveSpaceData); diff --git a/packages/restapi/src/lib/space/rejectPromotionRequest.ts b/packages/restapi/src/lib/space/rejectPromotionRequest.ts index fba5b91ed..3fb45154b 100644 --- a/packages/restapi/src/lib/space/rejectPromotionRequest.ts +++ b/packages/restapi/src/lib/space/rejectPromotionRequest.ts @@ -1,6 +1,6 @@ import { produce } from 'immer'; import sendLiveSpaceData from './helpers/sendLiveSpaceData'; -import { META_ACTION } from '../types/messageObjectTypes'; +import { META_ACTION } from '../types/messageTypes'; import { pCAIP10ToWallet } from '../helpers'; import type Space from './Space'; diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts index c5df1f0bc..6a14791e7 100644 --- a/packages/restapi/src/lib/space/start.ts +++ b/packages/restapi/src/lib/space/start.ts @@ -24,7 +24,7 @@ export interface StartSpaceType extends EnvOptionsType { import type Space from './Space'; import { produce } from 'immer'; import { pCAIP10ToWallet } from '../helpers'; -import { META_ACTION } from '../types/messageObjectTypes'; +import { META_ACTION } from '../types/messageTypes'; import sendLiveSpaceData from './helpers/sendLiveSpaceData'; type StartType = { diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 002660876..d71e60eec 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -10,7 +10,7 @@ import { } from '../../lib/payloads/constants'; import { ENV, MessageType } from '../constants'; import { EthEncryptedData } from '@metamask/eth-sig-util'; -import { MessageTypeSpecificObject } from './messageObjectTypes'; +import { Message, MessageObj } from './messageTypes'; export type Env = typeof ENV[keyof typeof ENV]; @@ -162,7 +162,7 @@ export interface IMessageIPFS { fromDID: string; toDID: string; messageType: string; - messageObj?: MessageTypeSpecificObject[MessageType] | string; + messageObj?: MessageObj | string; /** * @deprecated - Use messageObj.content instead */ @@ -316,7 +316,6 @@ export type Data = { decimals?: number; guildId?: string; guildRoleId?: string; - guildRoleAction?: 'all' | 'any'; url?: string; comparison?: '>' | '<' | '>=' | '<=' | '==' | '!='; }; @@ -339,7 +338,7 @@ export interface Rules { groupAccess?: { conditions: Array; }; - chatAccess?: { + chat?: { conditions: Array; }; } @@ -352,7 +351,7 @@ export interface SpaceRules { export interface GroupAccess { groupAccess: boolean; - chatAccess: boolean; + chat: boolean; rules?: Rules; } @@ -477,7 +476,7 @@ export interface AccountEnvOptionsType extends EnvOptionsType { export interface ChatStartOptionsType { messageType: `${MessageType}`; - messageObj: MessageTypeSpecificObject[MessageType]; + messageObj: MessageObj | string; /** * @deprecated - To be used for now to provide backward compatibility */ @@ -491,20 +490,37 @@ export interface ChatStartOptionsType { * EXPORTED ( Chat.send ) */ export interface ChatSendOptionsType { - messageType?: `${MessageType}`; - messageObj?: MessageTypeSpecificObject[MessageType]; + /** Message to be send */ + message?: Message; /** - * @deprecated - Use messageObj.content instead + * Message Sender's Account ( DID ) + * In case account is not provided, it will be derived from signer */ - messageContent?: string; - receiverAddress: string; - pgpPrivateKey?: string; account?: string; + /** Message Receiver's Account ( DID ) */ + to?: string; + /** + * Message Sender's ethers signer or viem walletClient + * Used for deriving account if not provided + * Used for decrypting pgpPrivateKey if not provided + */ signer?: SignerType; - env?: ENV; /** - * @deprecated APIkey is not needed now + * Message Sender's decrypted pgp private key + * Used for signing message */ + pgpPrivateKey?: string; + /** Enironment - prod, staging, dev */ + env?: ENV; + /** @deprecated - Use message instead */ + messageObj?: MessageObj; + /** @deprecated - Use message.content instead */ + messageContent?: string; + /** @deprecated - Use message.type instead */ + messageType?: `${MessageType}`; + /** @deprecated - Use to instead */ + receiverAddress?: string; + /** @deprecated Not needed anymore */ apiKey?: string; } @@ -600,7 +616,7 @@ export type MessageWithCID = { fromDID: string; toDID: string; messageType: string; - messageObj?: MessageTypeSpecificObject[MessageType] | string; + messageObj?: MessageObj | string; /** * @deprecated - Use messageObj.content instead */ diff --git a/packages/restapi/src/lib/types/messageObjectTypes.ts b/packages/restapi/src/lib/types/messageTypes.ts similarity index 69% rename from packages/restapi/src/lib/types/messageObjectTypes.ts rename to packages/restapi/src/lib/types/messageTypes.ts index 06753bf7d..044f148e2 100644 --- a/packages/restapi/src/lib/types/messageObjectTypes.ts +++ b/packages/restapi/src/lib/types/messageTypes.ts @@ -1,22 +1,8 @@ /** - * This file defines the type for messageObj property for a Push Chat message + * This file defines the type for message property for a Push Chat message */ import { MessageType } from '../constants'; -export interface MessageTypeSpecificObject { - [MessageType.TEXT]: MESSAGE_OBJECT; - [MessageType.IMAGE]: MESSAGE_OBJECT; - [MessageType.FILE]: MESSAGE_OBJECT; - [MessageType.MEDIA_EMBED]: MESSAGE_OBJECT; - [MessageType.GIF]: MESSAGE_OBJECT; - [MessageType.META]: META_MESSAGE_OBJECT; - [MessageType.REACTION]: REACTION_MESSAGE_OBJECT; -} - -export type MESSAGE_OBJECT = { - content: string; -}; - export enum META_ACTION { /** * DEFAULT GROUP ACTIONS @@ -44,16 +30,6 @@ export enum META_ACTION { USER_INTERACTION = 15, // For MIC_ON | MIC_OFF | RAISE_HAND | EMOJI REACTION | or any other user activity } -export type META_MESSAGE_OBJECT = MESSAGE_OBJECT & { - action: META_ACTION; - info: { - affected: string[]; - arbitrary?: { - [key: string]: any; - }; - }; -}; - export enum REACTION_TYPE { THUMBS_UP, THUMBS_DOWN, @@ -81,12 +57,42 @@ export const REACTION_SYMBOL: Record = { [REACTION_TYPE.FIRE]: '\u{1F525}', }; -export type REACTION_MESSAGE_OBJECT = MESSAGE_OBJECT & { +export interface BaseMessage { + type: T; + content: string; +} + +export interface MetaMessage extends BaseMessage { + action: META_ACTION; + info: { + affected: string[]; + arbitrary?: { + [key: string]: any; + }; + }; +} + +export interface ReactionMessage extends BaseMessage { action: REACTION_TYPE; reference?: string | null; -}; +} -// TODO -// export type REPLY_MESSAGE_OBJECT = {}; -// export type COMPOSITE_MESSAGE_OBJECT = {}; -// export type PAYMENT_MESSAGE_OBJECT = {}; +export type BaseMessageTypes = + | MessageType.TEXT + | MessageType.IMAGE + | MessageType.FILE + | MessageType.MEDIA_EMBED + | MessageType.GIF; + +export type Message = + | BaseMessage + | MetaMessage + | ReactionMessage; + +/** + * @deprecated + */ +export type MessageObj = + | Omit, 'type'> + | Omit + | Omit; diff --git a/packages/restapi/src/lib/validations/messageObject.ts b/packages/restapi/src/lib/validations/messageObject.ts index 5f25a0872..6057d12d5 100644 --- a/packages/restapi/src/lib/validations/messageObject.ts +++ b/packages/restapi/src/lib/validations/messageObject.ts @@ -1,16 +1,11 @@ import * as Joi from 'joi'; -import { - META_ACTION, - META_MESSAGE_OBJECT, - REACTION_MESSAGE_OBJECT, - REACTION_TYPE, -} from '../types/messageObjectTypes'; +import { META_ACTION, REACTION_TYPE } from '../types/messageTypes'; -export const messageObjSchema = Joi.object({ +export const messageObjSchema = Joi.object({ content: Joi.string().required().allow(''), }); -export const metaMessageObjSchema = Joi.object({ +export const metaMessageObjSchema = Joi.object({ content: Joi.string().required().allow(''), action: Joi.number() .valid(...Object.values(META_ACTION)) @@ -21,7 +16,7 @@ export const metaMessageObjSchema = Joi.object({ }).required(), }); -export const reationMessageObjSchema = Joi.object({ +export const reationMessageObjSchema = Joi.object({ content: Joi.string().required().allow(''), action: Joi.number() .valid(...Object.values(REACTION_TYPE)) diff --git a/packages/restapi/tests/lib/chat/send.test.ts b/packages/restapi/tests/lib/chat/send.test.ts index e1fbfd976..fc3e8d0dd 100644 --- a/packages/restapi/tests/lib/chat/send.test.ts +++ b/packages/restapi/tests/lib/chat/send.test.ts @@ -18,7 +18,7 @@ import { import { REACTION_SYMBOL, REACTION_TYPE, -} from '../../../src/lib/types/messageObjectTypes'; +} from '../../../src/lib/types/messageTypes'; chai.use(chaiAsPromised); const _env = Constants.ENV.DEV; @@ -361,7 +361,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('Depreacted | EncType - PlainText', async () => { + it('Depreacted V1 | EncType - PlainText', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageContent: MESSAGE, @@ -379,7 +379,31 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - Plaintext', async () => { + it('Deprecated V1 | EncType - pgp', async () => { + await create({ + account: account2, + env: _env, + signer: _signer2, + version: Constants.ENC_TYPE_V1, + }); + const msg = await send({ + messageType: MESSAGE_TYPE, + messageContent: MESSAGE, + receiverAddress: account2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + MESSAGE, + account1, + _signer1, + account2, + 'pgp' + ); + }); + it('Deprecated V2 | EncType - Plaintext', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageObj: { content: MESSAGE }, @@ -397,7 +421,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('Deprecated | EncType - pgp', async () => { + it('Deprecated V2 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -406,8 +430,8 @@ describe('PushAPI.chat.send', () => { }); const msg = await send({ messageType: MESSAGE_TYPE, - messageContent: MESSAGE, - receiverAddress: account2, + messageObj: { content: MESSAGE }, + receiverAddress: walletAddress2, signer: _signer1, env: _env, }); @@ -421,7 +445,24 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); - it('EncType - pgp', async () => { + it('V3 | EncType - Plaintext', async () => { + const msg = await send({ + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE }, + account1, + _signer1, + account2, + 'PlainText' + ); + }); + it('V3 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -429,16 +470,15 @@ describe('PushAPI.chat.send', () => { version: Constants.ENC_TYPE_V1, }); const msg = await send({ - messageType: MESSAGE_TYPE, - messageObj: { content: MESSAGE }, - receiverAddress: walletAddress2, + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, signer: _signer1, env: _env, }); await expectMsg( msg, MESSAGE_TYPE, - MESSAGE, + { content: MESSAGE }, account1, _signer1, account2, @@ -465,7 +505,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('Depreacted | EncType - PlainText', async () => { + it('Depreacted V1 | EncType - PlainText', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageContent: MESSAGE, @@ -483,7 +523,31 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - Plaintext', async () => { + it('Deprecated V1 | EncType - pgp', async () => { + await create({ + account: account2, + env: _env, + signer: _signer2, + version: Constants.ENC_TYPE_V1, + }); + const msg = await send({ + messageType: MESSAGE_TYPE, + messageContent: MESSAGE, + receiverAddress: account2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + MESSAGE, + account1, + _signer1, + account2, + 'pgp' + ); + }); + it('Deprecated V2 | EncType - Plaintext', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageObj: { content: MESSAGE }, @@ -501,7 +565,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('Deprecated | EncType - pgp', async () => { + it('Deprecated V2 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -510,8 +574,8 @@ describe('PushAPI.chat.send', () => { }); const msg = await send({ messageType: MESSAGE_TYPE, - messageContent: MESSAGE, - receiverAddress: account2, + messageObj: { content: MESSAGE }, + receiverAddress: walletAddress2, signer: _signer1, env: _env, }); @@ -525,7 +589,24 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); - it('EncType - pgp', async () => { + it('V3 | EncType - Plaintext', async () => { + const msg = await send({ + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE }, + account1, + _signer1, + account2, + 'PlainText' + ); + }); + it('V3 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -533,8 +614,7 @@ describe('PushAPI.chat.send', () => { version: Constants.ENC_TYPE_V1, }); const msg = await send({ - messageType: MESSAGE_TYPE, - messageObj: { content: MESSAGE }, + message: { type: MESSAGE_TYPE, content: MESSAGE }, receiverAddress: walletAddress2, signer: _signer1, env: _env, @@ -542,7 +622,7 @@ describe('PushAPI.chat.send', () => { await expectMsg( msg, MESSAGE_TYPE, - MESSAGE, + { content: MESSAGE }, account1, _signer1, account2, @@ -568,7 +648,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('Depreacted | EncType - PlainText', async () => { + it('Depreacted V1 | EncType - PlainText', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageContent: MESSAGE, @@ -586,7 +666,31 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - Plaintext', async () => { + it('Deprecated V1 | EncType - pgp', async () => { + await create({ + account: account2, + env: _env, + signer: _signer2, + version: Constants.ENC_TYPE_V1, + }); + const msg = await send({ + messageType: MESSAGE_TYPE, + messageContent: MESSAGE, + receiverAddress: account2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + MESSAGE, + account1, + _signer1, + account2, + 'pgp' + ); + }); + it('Deprecated V2 | EncType - Plaintext', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageObj: { content: MESSAGE }, @@ -604,7 +708,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('Deprecated | EncType - pgp', async () => { + it('Deprecated V2 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -613,8 +717,8 @@ describe('PushAPI.chat.send', () => { }); const msg = await send({ messageType: MESSAGE_TYPE, - messageContent: MESSAGE, - receiverAddress: account2, + messageObj: { content: MESSAGE }, + receiverAddress: walletAddress2, signer: _signer1, env: _env, }); @@ -628,7 +732,24 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); - it('EncType - pgp', async () => { + it('V3 | EncType - Plaintext', async () => { + const msg = await send({ + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE }, + account1, + _signer1, + account2, + 'PlainText' + ); + }); + it('V3 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -636,16 +757,15 @@ describe('PushAPI.chat.send', () => { version: Constants.ENC_TYPE_V1, }); const msg = await send({ - messageType: MESSAGE_TYPE, - messageObj: { content: MESSAGE }, - receiverAddress: walletAddress2, + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, signer: _signer1, env: _env, }); await expectMsg( msg, MESSAGE_TYPE, - MESSAGE, + { content: MESSAGE }, account1, _signer1, account2, @@ -672,7 +792,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('Depreacted | EncType - PlainText', async () => { + it('Depreacted V1 | EncType - PlainText', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageContent: MESSAGE, @@ -690,7 +810,31 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - Plaintext', async () => { + it('Deprecated V1 | EncType - pgp', async () => { + await create({ + account: account2, + env: _env, + signer: _signer2, + version: Constants.ENC_TYPE_V1, + }); + const msg = await send({ + messageType: MESSAGE_TYPE, + messageContent: MESSAGE, + receiverAddress: account2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + MESSAGE, + account1, + _signer1, + account2, + 'pgp' + ); + }); + it('Deprecated V2 | EncType - Plaintext', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageObj: { content: MESSAGE }, @@ -708,7 +852,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('Deprecated | EncType - pgp', async () => { + it('Deprecated V2 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -717,8 +861,8 @@ describe('PushAPI.chat.send', () => { }); const msg = await send({ messageType: MESSAGE_TYPE, - messageContent: MESSAGE, - receiverAddress: account2, + messageObj: { content: MESSAGE }, + receiverAddress: walletAddress2, signer: _signer1, env: _env, }); @@ -732,7 +876,24 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); - it('EncType - pgp', async () => { + it('V3 | EncType - Plaintext', async () => { + const msg = await send({ + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE }, + account1, + _signer1, + account2, + 'PlainText' + ); + }); + it('V3 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -740,16 +901,15 @@ describe('PushAPI.chat.send', () => { version: Constants.ENC_TYPE_V1, }); const msg = await send({ - messageType: MESSAGE_TYPE, - messageObj: { content: MESSAGE }, - receiverAddress: walletAddress2, + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, signer: _signer1, env: _env, }); await expectMsg( msg, MESSAGE_TYPE, - MESSAGE, + { content: MESSAGE }, account1, _signer1, account2, @@ -776,7 +936,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('Depreacted | EncType - PlainText', async () => { + it('Depreacted V1 | EncType - PlainText', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageContent: MESSAGE, @@ -794,7 +954,31 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - Plaintext', async () => { + it('Deprecated V1 | EncType - pgp', async () => { + await create({ + account: account2, + env: _env, + signer: _signer2, + version: Constants.ENC_TYPE_V1, + }); + const msg = await send({ + messageType: MESSAGE_TYPE, + messageContent: MESSAGE, + receiverAddress: account2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + MESSAGE, + account1, + _signer1, + account2, + 'pgp' + ); + }); + it('Deprecated V2 | EncType - Plaintext', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageObj: { content: MESSAGE }, @@ -812,7 +996,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('Deprecated | EncType - pgp', async () => { + it('Deprecated V2 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -821,8 +1005,8 @@ describe('PushAPI.chat.send', () => { }); const msg = await send({ messageType: MESSAGE_TYPE, - messageContent: MESSAGE, - receiverAddress: account2, + messageObj: { content: MESSAGE }, + receiverAddress: walletAddress2, signer: _signer1, env: _env, }); @@ -836,7 +1020,24 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); - it('EncType - pgp', async () => { + it('V3 | EncType - Plaintext', async () => { + const msg = await send({ + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE }, + account1, + _signer1, + account2, + 'PlainText' + ); + }); + it('V3 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -844,16 +1045,15 @@ describe('PushAPI.chat.send', () => { version: Constants.ENC_TYPE_V1, }); const msg = await send({ - messageType: MESSAGE_TYPE, - messageObj: { content: MESSAGE }, - receiverAddress: walletAddress2, + message: { type: MESSAGE_TYPE, content: MESSAGE }, + to: walletAddress2, signer: _signer1, env: _env, }); await expectMsg( msg, MESSAGE_TYPE, - MESSAGE, + { content: MESSAGE }, account1, _signer1, account2, @@ -988,7 +1188,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('EncType - PlainText ( Public Grp )', async () => { + it('Deprecated V1 | EncType - PlainText ( Public Grp )', async () => { const groupName = uniqueNamesGenerator({ dictionaries: [adjectives, colors, animals], }); @@ -1029,7 +1229,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - pgp ( Private Grp )', async () => { + it('Deprecated V1 | EncType - pgp ( Private Grp )', async () => { const groupName = uniqueNamesGenerator({ dictionaries: [adjectives, colors, animals], }); @@ -1070,6 +1270,88 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); + it('V2 | EncType - PlainText ( Public Grp )', async () => { + const groupName = uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], + }); + const groupDescription = uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], + }); + const groupImage = + 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg=='; + + const group = await createGroup({ + groupName, + groupDescription, + members: [_nftAccount1, _nftAccount2, account2], + groupImage, + admins: [], // takes signer as admin automatically, add more if you want to + isPublic: true, + signer: _signer1, + env: _env, + }); + const msg = await send({ + message: { + type: MESSAGE_TYPE, + content: MESSAGE, + action: 1, + info: { affected: [] }, + }, + to: group.chatId, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE, action: 1, info: { affected: [] } }, + account1, + _signer1, + group.chatId, + 'PlainText' + ); + }); + it('V2 | EncType - pgp ( Private Grp )', async () => { + const groupName = uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], + }); + const groupDescription = uniqueNamesGenerator({ + dictionaries: [adjectives, colors, animals], + }); + const groupImage = + 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAvklEQVR4AcXBsW2FMBiF0Y8r3GQb6jeBxRauYRpo4yGQkMd4A7kg7Z/GUfSKe8703fKDkTATZsJsrr0RlZSJ9r4RLayMvLmJjnQS1d6IhJkwE2bT13U/DBzp5BN73xgRZsJMmM1HOolqb/yWiWpvjJSUiRZWopIykTATZsJs5g+1N6KSMiO1N/5DmAkzYTa9Lh6MhJkwE2ZzSZlo7xvRwson3txERzqJhJkwE2bT6+JhoKTMJ2pvjAgzYSbMfgDlXixqjH6gRgAAAABJRU5ErkJggg=='; + + const group = await createGroup({ + groupName, + groupDescription, + members: [_nftAccount1, _nftAccount2, account2], + groupImage, + admins: [], // takes signer as admin automatically, add more if you want to + isPublic: false, + signer: _signer1, + env: _env, + }); + const msg = await send({ + message: { + type: MESSAGE_TYPE, + content: MESSAGE, + action: 1, + info: { affected: [] }, + }, + to: group.chatId, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { content: MESSAGE, action: 1, info: { affected: [] } }, + account1, + _signer1, + group.chatId, + 'pgp' + ); + }); }); describe('Reaction Message', () => { const MESSAGE_TYPE = MessageType.REACTION; @@ -1105,7 +1387,7 @@ describe('PushAPI.chat.send', () => { }) ).to.be.rejected; }); - it('EncType - PlainText', async () => { + it('Deprecated V1 | EncType - PlainText', async () => { const msg = await send({ messageType: MESSAGE_TYPE, messageObj: { @@ -1129,7 +1411,7 @@ describe('PushAPI.chat.send', () => { 'PlainText' ); }); - it('EncType - pgp', async () => { + it('Deprecated V1 | EncType - pgp', async () => { await create({ account: account2, env: _env, @@ -1158,11 +1440,64 @@ describe('PushAPI.chat.send', () => { 'pgp' ); }); + it('V2 | EncType - PlainText', async () => { + const msg = await send({ + message: { + type: MESSAGE_TYPE, + content: MESSAGE, + action: REACTION_TYPE.THUMBS_UP, + }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { + content: REACTION_SYMBOL[REACTION_TYPE.THUMBS_UP], // REACTION OVERRIDES THE MESSAGE CONTENT TO THE SYMBOL, + action: REACTION_TYPE.THUMBS_UP, + }, + account1, + _signer1, + account2, + 'PlainText' + ); + }); + it('V2 | EncType - pgp', async () => { + await create({ + account: account2, + env: _env, + signer: _signer2, + }); + const msg = await send({ + message: { + type: MESSAGE_TYPE, + content: MESSAGE, + action: REACTION_TYPE.THUMBS_UP, + }, + to: walletAddress2, + signer: _signer1, + env: _env, + }); + await expectMsg( + msg, + MESSAGE_TYPE, + { + content: REACTION_SYMBOL[REACTION_TYPE.THUMBS_UP], // REACTION OVERRIDES THE MESSAGE CONTENT TO THE SYMBOL + action: REACTION_TYPE.THUMBS_UP, + }, + account1, + _signer1, + account2, + 'pgp' + ); + }); }); }); /** - * HELPER FUNCTIONS + * HELPER FUNCTION */ const expectMsg = async ( msg: MessageWithCID, diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index bc200180b..de55ed8e8 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -1267,7 +1267,7 @@ flat@^5.0.2: for-each@^0.3.3: version "0.3.3" - resolved "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz" + resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== dependencies: is-callable "^1.1.3" @@ -1284,12 +1284,12 @@ fsevents@~2.3.2: function-bind@^1.1.1: version "1.1.1" - resolved "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== function.prototype.name@^1.1.5: version "1.1.5" - resolved "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.5.tgz" + resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.5.tgz#cce0505fe1ffb80503e6f9e46cc64e46a12a9621" integrity sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA== dependencies: call-bind "^1.0.2" @@ -1299,7 +1299,7 @@ function.prototype.name@^1.1.5: functions-have-names@^1.2.2, functions-have-names@^1.2.3: version "1.2.3" - resolved "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz" + resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== get-browser-rtc@^1.1.0: @@ -1324,7 +1324,7 @@ get-func-name@^2.0.0: get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@^1.2.0, get-intrinsic@^1.2.1: version "1.2.1" - resolved "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== dependencies: function-bind "^1.1.1" @@ -1334,7 +1334,7 @@ get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@ get-package-type@^0.1.0: version "0.1.0" - resolved "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz" + resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== get-stream@^4.0.0: @@ -1346,7 +1346,7 @@ get-stream@^4.0.0: get-symbol-description@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz" + resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.0.tgz#7fdb81c900101fbd564dd5f1a30af5aadc1e58d6" integrity sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw== dependencies: call-bind "^1.0.2" @@ -1373,7 +1373,7 @@ glob@7.2.0: glob@^7.2.3: version "7.2.3" - resolved "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz" + resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== dependencies: fs.realpath "^1.0.0" @@ -1385,21 +1385,21 @@ glob@^7.2.3: globalthis@^1.0.3: version "1.0.3" - resolved "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz" + resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.3.tgz#5852882a52b80dc301b0660273e1ed082f0b6ccf" integrity sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA== dependencies: define-properties "^1.1.3" gopd@^1.0.1: version "1.0.1" - resolved "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz" + resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== dependencies: get-intrinsic "^1.1.3" graceful-fs@^4.2.4: version "4.2.11" - resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== has-ansi@^2.0.0: @@ -1411,12 +1411,12 @@ has-ansi@^2.0.0: has-bigints@^1.0.1, has-bigints@^1.0.2: version "1.0.2" - resolved "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz" + resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.2.tgz#0871bd3e3d51626f6ca0966668ba35d5602d6eaa" integrity sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ== has-dynamic-import@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz" + resolved "https://registry.yarnpkg.com/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz#9bca87846aa264f2ad224fcd014946f5e5182f52" integrity sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ== dependencies: call-bind "^1.0.2" @@ -1434,38 +1434,38 @@ has-flag@^4.0.0: has-property-descriptors@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz" + resolved "https://registry.yarnpkg.com/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz#610708600606d36961ed04c196193b6a607fa861" integrity sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ== dependencies: get-intrinsic "^1.1.1" has-proto@^1.0.1: version "1.0.1" - resolved "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz" + resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== has-symbols@^1.0.2, has-symbols@^1.0.3: version "1.0.3" - resolved "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== has-tostringtag@^1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz" + resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== dependencies: has-symbols "^1.0.2" has@^1.0.3: version "1.0.3" - resolved "https://registry.npmjs.org/has/-/has-1.0.3.tgz" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== dependencies: function-bind "^1.1.1" hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: version "1.1.7" - resolved "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" + resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" integrity sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA== dependencies: inherits "^2.0.3" @@ -1483,7 +1483,7 @@ hls.js@^1.4.9: hmac-drbg@^1.0.1: version "1.0.1" - resolved "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz" + resolved "https://registry.yarnpkg.com/hmac-drbg/-/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1" integrity sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg== dependencies: hash.js "^1.0.3" @@ -1515,7 +1515,7 @@ inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.1, internal-slot@^1.0.4, internal-slot@^1.0.5: version "1.0.5" - resolved "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz" + resolved "https://registry.yarnpkg.com/internal-slot/-/internal-slot-1.0.5.tgz#f2a2ee21f668f8627a4667f309dc0f4fb6674986" integrity sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ== dependencies: get-intrinsic "^1.2.0" @@ -1529,7 +1529,7 @@ invert-kv@^2.0.0: is-arguments@^1.1.1: version "1.1.1" - resolved "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz" + resolved "https://registry.yarnpkg.com/is-arguments/-/is-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" integrity sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA== dependencies: call-bind "^1.0.2" @@ -1537,7 +1537,7 @@ is-arguments@^1.1.1: is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: version "3.0.2" - resolved "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-array-buffer/-/is-array-buffer-3.0.2.tgz#f2653ced8412081638ecb0ebbd0c41c6e0aecbbe" integrity sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w== dependencies: call-bind "^1.0.2" @@ -1546,7 +1546,7 @@ is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: is-bigint@^1.0.1: version "1.0.4" - resolved "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz" + resolved "https://registry.yarnpkg.com/is-bigint/-/is-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" integrity sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg== dependencies: has-bigints "^1.0.1" @@ -1560,7 +1560,7 @@ is-binary-path@~2.1.0: is-boolean-object@^1.1.0: version "1.1.2" - resolved "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz" + resolved "https://registry.yarnpkg.com/is-boolean-object/-/is-boolean-object-1.1.2.tgz#5c6dc200246dd9321ae4b885a114bb1f75f63719" integrity sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA== dependencies: call-bind "^1.0.2" @@ -1568,19 +1568,19 @@ is-boolean-object@^1.1.0: is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.2.7: version "1.2.7" - resolved "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== is-core-module@^2.9.0: - version "2.13.0" - resolved "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz" - integrity sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ== + version "2.12.1" + resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.12.1.tgz#0c0b6885b6f80011c71541ce15c8d66cf5a4f9fd" + integrity sha512-Q4ZuBAe2FUsKtyQJoQHlvP8OvBERxO3jEmy1I7hcRXcJBGGHFh/aJBswbXuS9sgrDH2QUO8ilkwNPHvHMd8clg== dependencies: has "^1.0.3" is-date-object@^1.0.1, is-date-object@^1.0.5: version "1.0.5" - resolved "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz" + resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.5.tgz#0841d5536e724c25597bf6ea62e1bd38298df31f" integrity sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ== dependencies: has-tostringtag "^1.0.0" @@ -1626,17 +1626,17 @@ is-hex-prefixed@1.0.0: is-map@^2.0.1, is-map@^2.0.2: version "2.0.2" - resolved "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-map/-/is-map-2.0.2.tgz#00922db8c9bf73e81b7a335827bc2a43f2b91127" integrity sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg== is-negative-zero@^2.0.2: version "2.0.2" - resolved "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.2.tgz#7bf6f03a28003b8b3965de3ac26f664d765f3150" integrity sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA== is-number-object@^1.0.4: version "1.0.7" - resolved "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz" + resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.7.tgz#59d50ada4c45251784e9904f5246c742f07a42fc" integrity sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ== dependencies: has-tostringtag "^1.0.0" @@ -1653,7 +1653,7 @@ is-plain-obj@^2.1.0: is-regex@^1.1.4: version "1.1.4" - resolved "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz" + resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== dependencies: call-bind "^1.0.2" @@ -1661,12 +1661,12 @@ is-regex@^1.1.4: is-set@^2.0.1, is-set@^2.0.2: version "2.0.2" - resolved "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-set/-/is-set-2.0.2.tgz#90755fa4c2562dc1c5d4024760d6119b94ca18ec" integrity sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g== is-shared-array-buffer@^1.0.2: version "1.0.2" - resolved "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz#8f259c573b60b6a32d4058a1a07430c0a7344c79" integrity sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA== dependencies: call-bind "^1.0.2" @@ -1678,26 +1678,26 @@ is-stream@^1.1.0: is-stream@^2.0.0: version "2.0.1" - resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" + resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== is-string@^1.0.5, is-string@^1.0.7: version "1.0.7" - resolved "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz" + resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" integrity sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg== dependencies: has-tostringtag "^1.0.0" is-symbol@^1.0.2, is-symbol@^1.0.3: version "1.0.4" - resolved "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz" + resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.4.tgz#a6dac93b635b063ca6872236de88910a57af139c" integrity sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg== dependencies: has-symbols "^1.0.2" is-typed-array@^1.1.10, is-typed-array@^1.1.9: version "1.1.12" - resolved "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz" + resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.12.tgz#d0bab5686ef4a76f7a73097b95470ab199c57d4a" integrity sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg== dependencies: which-typed-array "^1.1.11" @@ -1709,19 +1709,19 @@ is-unicode-supported@^0.1.0: is-weakmap@^2.0.1: version "2.0.1" - resolved "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz" + resolved "https://registry.yarnpkg.com/is-weakmap/-/is-weakmap-2.0.1.tgz#5008b59bdc43b698201d18f62b37b2ca243e8cf2" integrity sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA== is-weakref@^1.0.2: version "1.0.2" - resolved "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-weakref/-/is-weakref-1.0.2.tgz#9529f383a9338205e89765e0392efc2f100f06f2" integrity sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ== dependencies: call-bind "^1.0.2" is-weakset@^2.0.1: version "2.0.2" - resolved "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz" + resolved "https://registry.yarnpkg.com/is-weakset/-/is-weakset-2.0.2.tgz#4569d67a747a1ce5a994dfd4ef6dcea76e7c0a1d" integrity sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg== dependencies: call-bind "^1.0.2" @@ -1729,12 +1729,12 @@ is-weakset@^2.0.1: isarray@^2.0.5: version "2.0.5" - resolved "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723" integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== isarray@~1.0.0: version "1.0.0" - resolved "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" integrity sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ== isexe@^2.0.0: diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx index 9aab95552..1b0d45e8d 100644 --- a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx @@ -119,7 +119,6 @@ export const ChatProfile: React.FC = ({ chatId, style }: {chatId: if(isValidETHAddress(chatId)){ const result = await resolveNewEns(chatId, provider); // if(result) - console.log(result); setEnsName(result); } } diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx index e13eefb3f..e684cef63 100644 --- a/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/GroupInfoModal.tsx @@ -47,7 +47,7 @@ const PendingMembers = ({ groupInfo, setShowPendingRequests, showPendingRequests - + {shortenText(item?.wallet?.split(':')[1] ?? '', 6, true)} @@ -400,7 +400,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo
- Group Info + Group Info onClose()} cursor='pointer' />
@@ -409,7 +409,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo
- {groupInfo?.groupName} + {groupInfo?.groupName} {groupInfo?.members?.length} Members
@@ -435,7 +435,7 @@ export const GroupInfoModal = ({ theme, modal, setModal, groupInfo, setGroupInfo - {theme ? : } +
)}
diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx index a8df6d6c9..407ef477f 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -43,7 +43,6 @@ export const ChatViewComponent: React.FC = ( const {env } = useChatData(); - console.log(env); // const [conversationHash, setConversationHash] = useState(); diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx index 2c12bd7e3..41a006d74 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx @@ -41,6 +41,7 @@ export const ApproveRequestBubble = ({ if (!pgpPrivateKey) { return; } + const response = await approveChatRequest({ chatId, }); diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx index f60e19f05..b256f3c3f 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -20,6 +20,7 @@ import { getDefaultFeedObject, getNewChatUser, pCAIP10ToWallet, + walletToPCAIP10, } from '../../../helpers'; import { useChatData, usePushChatSocket } from '../../../hooks'; import { Messagetype } from '../../../types'; @@ -27,7 +28,7 @@ import { ThemeContext } from '../theme/ThemeProvider'; import { IChatTheme } from '../theme'; import useFetchConversationHash from '../../../hooks/chat/useFetchConversationHash'; -import { EncryptionMessage } from './MessageEncryption'; +import { ENCRYPTION_KEYS, EncryptionMessage } from './MessageEncryption'; import useGetGroup from '../../../hooks/chat/useGetGroup'; import useGetChatProfile from '../../../hooks/useGetChatProfile'; import useFetchChat from '../../../hooks/chat/useFetchChat'; @@ -50,7 +51,8 @@ export const ChatViewList: React.FC = ( options: IChatViewListProps ) => { const { chatId, limit = chatLimit, chatFilterList = [] } = options || {}; - const { pgpPrivateKey, account } = useChatData(); + const { pgpPrivateKey, account, connectedProfile, setConnectedProfile } = + useChatData(); const [chatFeed, setChatFeed] = useState({} as IFeeds); const [chatStatusText, setChatStatusText] = useState(''); const [messages, setMessages] = useState(); @@ -59,7 +61,9 @@ export const ChatViewList: React.FC = ( const { historyMessages, loading: messageLoading } = useFetchHistoryMessages(); const listInnerRef = useRef(null); - const bottomRef = useRef(null); + const [isMember, setIsMember] = useState(false); + + // const bottomRef = useRef(null); const { fetchChat } = useFetchChat(); const { fetchChatProfile } = useGetChatProfile(); const { getGroup } = useGetGroup(); @@ -75,6 +79,15 @@ export const ChatViewList: React.FC = ( setChatStatusText(''); }, [chatId, account, env]); + useEffect(() => { + (async () => { + if (!connectedProfile && account) { + const user = await fetchChatProfile({ profileId: account!, env }); + if (user) setConnectedProfile(user); + } + })(); + }, [account]); + useEffect(() => { setMessages(undefined); setConversationHash(undefined); @@ -188,11 +201,25 @@ export const ChatViewList: React.FC = ( }, [messagesSinceLastConnection]); const scrollToBottom = (behavior?: string | null) => { - bottomRef?.current?.scrollIntoView( - !behavior ? true : { behavior: 'smooth' } - ); + if (listInnerRef.current) { + listInnerRef.current.scrollTop = listInnerRef.current.scrollHeight; + } }; + useEffect(()=>{ + + if(chatFeed && !chatFeed?.groupInformation?.isPublic && account) + { + chatFeed?.groupInformation?.members.forEach((acc) => { + if ( + acc.wallet.toLowerCase() === walletToPCAIP10(account!).toLowerCase() + ) { + setIsMember(true); + } + }); + } + },[account,chatFeed]) + useEffect(() => { if (Object.keys(groupInformationSinceLastConnection || {}).length) { if ( @@ -229,7 +256,11 @@ export const ChatViewList: React.FC = ( } else { threadHash = messages?.lastThreadHash; } - if (threadHash && account) { + if ( + threadHash && + ((account && pgpPrivateKey&& chatFeed && !chatFeed?.groupInformation) || + (chatFeed && chatFeed?.groupInformation)) + ) { const chatHistory = await historyMessages({ limit: limit, threadHash, @@ -296,10 +327,13 @@ export const ChatViewList: React.FC = ( chatFeed && chatFeed?.groupInformation && !chatFeed?.groupInformation?.isPublic && - !pgpPrivateKey + ((!isMember && pgpPrivateKey) || (!pgpPrivateKey)) ) } - onScroll={() => onScroll()} + onScroll={(e) => { + e.stopPropagation(); + onScroll(); + }} > {loading ? : ''} {!loading && ( @@ -308,9 +342,15 @@ export const ChatViewList: React.FC = ( (chatFeed.publicKey || (chatFeed?.groupInformation && !chatFeed?.groupInformation?.isPublic)) ? ( - + ) : ( - + )} {chatStatusText && ( @@ -347,14 +387,17 @@ export const ChatViewList: React.FC = ( {dates.has(dateNum) ? null : renderDate({ chat, dateNum })} -
+
); } )} -
+ {/*
*/}
{chatFeed && account && @@ -391,6 +434,8 @@ const ChatViewListCard = styled(Section)` ` filter: blur(12px); `} + overscroll-behavior: contain; + scroll-behavior: smooth; `; const Overlay = styled.div``; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx index cb6b4dc51..74e307637 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/MessageEncryption.tsx @@ -6,6 +6,14 @@ import { ThemeContext } from "../theme/ThemeProvider"; import { NoEncryptionIcon } from "../../../icons/NoEncryption"; import { EncryptionIcon } from "../../../icons/Encryption"; +export const ENCRYPTION_KEYS = { + ENCRYPTED: 'ENCRYPTED', + NO_ENCRYPTED: 'NO_ENCRYPTED', + NO_ENCRYPTED_GROUP: 'NO_ENCRYPTED_GROUP' +} as const; + +export type EncryptionKeys = (typeof ENCRYPTION_KEYS)[keyof typeof ENCRYPTION_KEYS]; + const EncryptionMessageContent = { ENCRYPTED: { IconComponent: , @@ -14,10 +22,15 @@ const EncryptionMessageContent = { NO_ENCRYPTED: { IconComponent: , text: `Messages are not encrypted`, + }, + NO_ENCRYPTED_GROUP: { + IconComponent: , + text: `Messages in this group are not encrypted`, + }, + }; - export const EncryptionMessage = ({ id }: { id: 'ENCRYPTED' | 'NO_ENCRYPTED' }) => { - console.log(id) + export const EncryptionMessage = ({ id }: { id: EncryptionKeys}) => { const theme = useContext(ThemeContext); const isMobile = useDeviceWidthCheck(771); return ( diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx index fc2e9c63f..cbdd7edb7 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx @@ -37,7 +37,6 @@ export const ConnectButtonSub = () => { useEffect(() => { (async () => { - console.log(account, signer); if (!account) setAccount(address as string); if (!signer) setSigner(walletClient as PushAPI.SignerType); })(); @@ -45,7 +44,6 @@ export const ConnectButtonSub = () => { useEffect(() => { (async () => { - console.log(account); if (account && signer) { if (!pgpPrivateKey) await handleUserCreation(); } diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 0a14ccbcc..c9243419f 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -1,401 +1,690 @@ -import { useChatData, useClickAway, useDeviceWidthCheck } from "../../../hooks"; -import type { FileMessageContent, IGroup } from "../../../types"; -import type { ChatMainStateContextType } from "../../../context/chatAndNotification/chat/chatMainStateContext"; -import { ChangeEvent, useContext, useEffect, useRef, useState } from "react"; -import { GIFType, IChatTheme, MessageInputProps } from "../exportedTypes"; -import styled from "styled-components"; -import { PUBLIC_GOOGLE_TOKEN, device } from "../../../config"; -import { Section, Div, Span } from "../../reusables"; -import { EmojiIcon } from "../../../icons/Emoji"; -import EmojiPicker, { EmojiClickData } from "emoji-picker-react"; -import * as PUSHAPI from "@pushprotocol/restapi"; -import { GifIcon } from "../../../icons/Gif"; -import GifPicker from "gif-picker-react"; -import { AttachmentIcon } from "../../../icons/Attachment"; -import usePushSendMessage from "../../../hooks/chat/usePushSendMessage"; -import { SendCompIcon } from "../../../icons/SendCompIcon"; -import { Spinner } from "../../reusables"; -import { ThemeContext } from "../theme/ThemeProvider"; -import OpenLink from "../../../icons/OpenLink"; -import VerificationFailed from "./VerificationFailed"; -import useVerifyAccessControl from "../../../hooks/chat/useVerifyAccessControl"; -import TokenGatedIcon from "../../../icons/Token-Gated.svg"; -import { Modal } from "../helpers/Modal"; -import { Image } from "../../reusables"; -import { ConnectButtonComp } from "../ConnectButton"; -import useGetGroupByID from "../../../hooks/chat/useGetGroupByID"; -import { ethers } from "ethers"; -import { pCAIP10ToWallet, setAccessControl } from "../../../helpers"; +import { + useChatData, + useClickAway, + useDeviceWidthCheck, + usePushChatSocket, +} from '../../../hooks'; +import type { FileMessageContent, IGroup } from '../../../types'; +import type { ChatMainStateContextType } from '../../../context/chatAndNotification/chat/chatMainStateContext'; +import { ChangeEvent, useContext, useEffect, useRef, useState } from 'react'; +import { GIFType, IChatTheme, MessageInputProps } from '../exportedTypes'; +import styled from 'styled-components'; +import { PUBLIC_GOOGLE_TOKEN, device } from '../../../config'; +import { Section, Div, Span } from '../../reusables'; +import { EmojiIcon } from '../../../icons/Emoji'; +import EmojiPicker, { EmojiClickData } from 'emoji-picker-react'; +import * as PUSHAPI from '@pushprotocol/restapi'; +import { GifIcon } from '../../../icons/Gif'; +import GifPicker from 'gif-picker-react'; +import { AttachmentIcon } from '../../../icons/Attachment'; +import usePushSendMessage from '../../../hooks/chat/usePushSendMessage'; +import { SendCompIcon } from '../../../icons/SendCompIcon'; +import { Spinner } from '../../reusables'; +import { ThemeContext } from '../theme/ThemeProvider'; +import OpenLink from '../../../icons/OpenLink'; +import useVerifyAccessControl from '../../../hooks/chat/useVerifyAccessControl'; +import TokenGatedIcon from '../../../icons/Token-Gated.svg'; +import { Modal } from '../helpers/Modal'; +import { Image } from '../../reusables'; +import { ConnectButtonComp } from '../ConnectButton'; +import useGetGroupByID from '../../../hooks/chat/useGetGroupByID'; +import { ethers } from 'ethers'; +import { + checkIfIntent, + checkIfSameChat, + getDefaultFeedObject, + getNewChatUser, + pCAIP10ToWallet, + setAccessControl, + walletToPCAIP10, +} from '../../../helpers'; +import useFetchChat from '../../../hooks/chat/useFetchChat'; +import useGetChatProfile from '../../../hooks/useGetChatProfile'; +import { IFeeds } from '@pushprotocol/restapi'; +import useGetGroup from '../../../hooks/chat/useGetGroup'; +import useApproveChatRequest from '../../../hooks/chat/useApproveChatRequest'; +import useToast from '../helpers/NewToast'; +import { MdCheckCircle, MdError } from 'react-icons/md'; /** * @interface IThemeProps * this interface is used for defining the props for styled components */ interface IThemeProps { - theme?: IChatTheme; + theme?: IChatTheme; } -export const MessageInput: React.FC = ({ chatId, Emoji = true, GIF = true, File = true, isConnected, onClick }) => { - const [typedMessage, setTypedMessage] = useState(""); - const [showEmojis, setShowEmojis] = useState(false); - const [gifOpen, setGifOpen] = useState(false); - const [newChat, setNewChat] = useState(false); - const modalRef = useRef(null); - const fileUploadInputRef = useRef(null); - const [fileUploading, setFileUploading] = useState(false); - const [isRules, setIsRules] = useState(false) - const onChangeTypedMessage = (val: string) => { - setTypedMessage(val); - }; - const theme = useContext(ThemeContext); - const isMobile = useDeviceWidthCheck(425); - const { sendMessage, loading } = usePushSendMessage(); - const { verificationSuccessfull, verifyAccessControl, setVerificationSuccessfull, verified, setVerified } = useVerifyAccessControl(); - const { account } = useChatData() - const { pgpPrivateKey, signer, setPgpPrivateKey } = useChatData(); - const { getGroupByID } = useGetGroupByID(); - - useClickAway(modalRef, () => { - setShowEmojis(false); - setGifOpen(false); - }); - const textAreaRef = useRef(null); - useEffect(() => { - if (textAreaRef?.current?.style) { - textAreaRef.current.style.height = 25 + 'px'; - const scrollHeight = textAreaRef.current?.scrollHeight; - textAreaRef.current.style.height = scrollHeight + 'px'; - } - }, [textAreaRef, typedMessage]) - - const addEmoji = (emojiData: EmojiClickData, event: MouseEvent): void => { - setTypedMessage(typedMessage + emojiData.emoji); - setShowEmojis(false); +export const MessageInput: React.FC = ({ + chatId, + Emoji = true, + GIF = true, + File = true, + isConnected, + onClick, +}) => { + const [typedMessage, setTypedMessage] = useState(''); + const [showEmojis, setShowEmojis] = useState(false); + const [gifOpen, setGifOpen] = useState(false); + const [newChat, setNewChat] = useState(false); + const modalRef = useRef(null); + const fileUploadInputRef = useRef(null); + const [fileUploading, setFileUploading] = useState(false); + const [isRules, setIsRules] = useState(false); + const [isMember, setIsMember] = useState(false); + const { approveChatRequest, loading: approveLoading } = + useApproveChatRequest(); + // const [groupInformation, setGroupInformation] = useState(undefined); + const onChangeTypedMessage = (val: string) => { + setTypedMessage(val); + }; + const { acceptedRequestMessage, groupInformationSinceLastConnection } = + usePushChatSocket(); + const [chatFeed, setChatFeed] = useState({} as IFeeds); + const theme = useContext(ThemeContext); + const isMobile = useDeviceWidthCheck(425); + const { sendMessage, loading } = usePushSendMessage(); + const { + verificationSuccessfull, + verifyAccessControl, + setVerificationSuccessfull, + verified, + setVerified, + loading: accessLoading, + } = useVerifyAccessControl(); + const { account, env ,connectedProfile,setConnectedProfile,pgpPrivateKey, signer,} = useChatData(); + const { fetchChat } = useFetchChat(); + const { fetchChatProfile } = useGetChatProfile(); + const { getGroupByID } = useGetGroupByID(); + const { getGroup } = useGetGroup(); + const statusToast = useToast(); + + useClickAway(modalRef, () => { + setShowEmojis(false); + setGifOpen(false); + }); + const textAreaRef = useRef(null); + useEffect(() => { + if (textAreaRef?.current?.style) { + textAreaRef.current.style.height = 25 + 'px'; + const scrollHeight = textAreaRef.current?.scrollHeight; + textAreaRef.current.style.height = scrollHeight + 'px'; } + }, [textAreaRef, typedMessage]); - const handleUploadFile = () => { - if (fileUploadInputRef.current) { - fileUploadInputRef.current.click(); - } - } + const addEmoji = (emojiData: EmojiClickData, event: MouseEvent): void => { + setTypedMessage(typedMessage + emojiData.emoji); + setShowEmojis(false); + }; - const checkVerification = () => { - verifyAccessControl({ chatId, did: account! }); - console.log('chatId', chatId); + const handleUploadFile = () => { + if (fileUploadInputRef.current) { + fileUploadInputRef.current.click(); } + }; + + const checkVerification = () => { + verifyAccessControl({ chatId, did: account! }); + }; + + const handleJoinGroup = async () => { + if (chatFeed && chatFeed?.groupInformation?.isPublic) { + const response = await approveChatRequest({ + chatId, + }); + if(response) + await updateChatFeed(); + } else { + const sendTextMessage = await sendMessage({ + message: `Hello, please let me join this group, my wallet address is ${account}`, + chatId: chatFeed?.groupInformation?.groupCreator || '', + messageType: 'Text', + }); + if(sendTextMessage) { + statusToast.showMessageToast({ + toastTitle: 'Success', + toastMessage: 'Request sent successfully', + toastType: 'SUCCESS', + getToastIcon: (size) => ( + + ), + }) + } else { + statusToast.showMessageToast({ + toastTitle: 'Error', + toastMessage: 'Unable to send request', + toastType: 'ERROR', + getToastIcon: (size) => ( + + ), + }) + } + } + }; + + useEffect(() => { + const storedTimestampJSON = localStorage.getItem(chatId); + + if (storedTimestampJSON) { + const storedTimestamp = JSON.parse(storedTimestampJSON); + const currentTimestamp = new Date().getTime(); + const twentyFourHoursInMilliseconds = 24 * 60 * 60 * 1000; + + if ( + Math.abs(currentTimestamp - storedTimestamp) < + twentyFourHoursInMilliseconds + ) { + setVerified(true); + } else { + setVerified(false); + setAccessControl(chatId, true); + } + } + }, [chatId, verified, isMember, account, env]); - useEffect(() => { - const storedTimestampJSON = localStorage.getItem(chatId); - - if (storedTimestampJSON) { - const storedTimestamp = JSON.parse(storedTimestampJSON); - const currentTimestamp = new Date().getTime(); - const twentyFourHoursInMilliseconds = 24 * 60 * 60 * 1000; - console.log(twentyFourHoursInMilliseconds) - - if (Math.abs(currentTimestamp - storedTimestamp) < twentyFourHoursInMilliseconds) { - console.log(Math.abs(currentTimestamp - storedTimestamp)) - setVerified(true); - } else { - setVerified(false); - setAccessControl(chatId, true) - } - } - }, [chatId, verified]) - - const uploadFile = async ( - e: ChangeEvent - ): Promise => { - if (!(e.target instanceof HTMLInputElement)) { - return; - } - if (!e.target.files) { - return; - } - if ( - e.target && - (e.target as HTMLInputElement).files && - ((e.target as HTMLInputElement).files as FileList).length - ) { - const file: File = e.target.files[0]; - if (file) { - try { - const TWO_MB = 1024 * 1024 * 2; - if (file.size > TWO_MB) { - console.log('Files larger than 2mb is now allowed'); - throw new Error('Files larger than 2mb is now allowed'); - } - setFileUploading(true); - const messageType = file.type.startsWith('image') ? 'Image' : 'File'; - const reader = new FileReader(); - let fileMessageContent: FileMessageContent; - reader.readAsDataURL(file); - reader.onloadend = async (e): Promise => { - fileMessageContent = { - content: e.target!.result as string, - name: file.name, - type: file.type, - size: file.size, - }; - - sendPushMessage(JSON.stringify(fileMessageContent), messageType); - }; - } catch (err) { - console.log(err); - } finally { - setFileUploading(false); - } - } - } - }; - - const sendPushMessage = async (content: string, type: string) => { + const uploadFile = async ( + e: ChangeEvent + ): Promise => { + if (!(e.target instanceof HTMLInputElement)) { + return; + } + if (!e.target.files) { + return; + } + if ( + e.target && + (e.target as HTMLInputElement).files && + ((e.target as HTMLInputElement).files as FileList).length + ) { + const file: File = e.target.files[0]; + if (file) { try { - const sendTextMessage = await sendMessage({ - message: content, - chatId, - messageType: type as any, - }); - console.log(sendTextMessage, "messageee"); - } catch (error) { - console.log(error); + const TWO_MB = 1024 * 1024 * 2; + if (file.size > TWO_MB) { + console.log('Files larger than 2mb is now allowed'); + throw new Error('Files larger than 2mb is now allowed'); + } + setFileUploading(true); + const messageType = file.type.startsWith('image') ? 'Image' : 'File'; + const reader = new FileReader(); + let fileMessageContent: FileMessageContent; + reader.readAsDataURL(file); + reader.onloadend = async (e): Promise => { + fileMessageContent = { + content: e.target!.result as string, + name: file.name, + type: file.type, + size: file.size, + }; + + sendPushMessage(JSON.stringify(fileMessageContent), messageType); + }; + } catch (err) { + console.log(err); + } finally { + setFileUploading(false); } + } } - - const sendTextMsg = async () => { - if (typedMessage.trim() !== '') { - await sendPushMessage(typedMessage as string, 'Text'); - setTypedMessage(''); - } + }; + + const sendPushMessage = async (content: string, type: string) => { + try { + const sendMessageResponse = await sendMessage({ + message: content, + chatId, + messageType: type as any, + }); + if (sendMessageResponse&&sendMessageResponse.includes('400')) { + setAccessControl(chatId, true); + setVerified(false); + setVerificationSuccessfull(false); + } + } catch (error) { + console.log(error); } - - - const sendGIF = async (emojiObject: GIFType) => { - sendPushMessage(emojiObject.url as string, 'GIF'); - setGifOpen(false); + }; + + useEffect(() => { + (async () => { + if (!connectedProfile && account) { + const user = await fetchChatProfile({ profileId: account!, env }); + if (user) setConnectedProfile(user); + } + })(); + }, [account]); + + const sendTextMsg = async () => { + if (typedMessage.trim() !== '') { + await sendPushMessage(typedMessage as string, 'Text'); + setTypedMessage(''); + } + }; + + const sendGIF = async (emojiObject: GIFType) => { + sendPushMessage(emojiObject.url as string, 'GIF'); + setGifOpen(false); + }; + + useEffect(() => { + if (Object.keys(groupInformationSinceLastConnection || {}).length) { + if ( + chatFeed?.groupInformation?.chatId.toLowerCase() === + groupInformationSinceLastConnection.chatId.toLowerCase() + ) { + const updateChatFeed = chatFeed; + updateChatFeed.groupInformation = groupInformationSinceLastConnection; + setChatFeed(updateChatFeed); + } } + }, [groupInformationSinceLastConnection]); - const checkIfrules = async() => { - if (!ethers.utils.isAddress(pCAIP10ToWallet(chatId))) { - console.log("beingnnggg calleddd") - const groupInfo = await getGroupByID({ groupId: chatId }) - if(groupInfo?.rules) { - setIsRules(true) - console.log(groupInfo?.rules) + const updateChatFeed = async() => { + const chat = await fetchChat({ chatId }); + if (Object.keys(chat || {}).length) { + setChatFeed(chat as IFeeds); + } + } + + useEffect(() => { + (async () => { + if ( + Object.keys(acceptedRequestMessage || {}).length && + Object.keys(chatFeed || {}).length + ) { + await updateChatFeed(); + } + })(); + }, [acceptedRequestMessage]); + + useEffect(() => { + (async () => { + if (!account && !env) return; + if(account && env){ + const chat = await fetchChat({ chatId }); + if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); + else { + let newChatFeed; + let group; + const result = await getNewChatUser({ + searchText: chatId, + fetchChatProfile, + env, + }); + if (result) { + newChatFeed = getDefaultFeedObject({ user: result }); + } else { + group = await getGroup({ searchText: chatId }); + if (group) { + newChatFeed = getDefaultFeedObject({ groupInformation: group }); } - console.log(groupInfo, "groupInfooooo") + } + if (newChatFeed) { + setChatFeed(newChatFeed); + } } + } + + + + })(); + }, [chatId, pgpPrivateKey, account, env]); + + const checkIfrules = async () => { + const members = chatFeed?.groupInformation?.members || []; + const pendingMembers = chatFeed?.groupInformation?.pendingMembers || []; + const allMembers = [...members, ...pendingMembers]; + allMembers.forEach((acc) => { + if ( + acc.wallet.toLowerCase() === walletToPCAIP10(account!).toLowerCase() + ) { + setIsMember(true); + } + }); + + if (chatFeed?.groupInformation?.rules) { + setIsRules(true); } - console.log(verificationSuccessfull, "verrifficagtionnn") - - useEffect(() => { - console.log(chatId, "chatIdddd") - checkIfrules(); - }, [chatId]) - - return ( - - {/* {isConnected && ( - - )} */} - { + if (!account && !env && !chatId) return; + if (account && env && chatId && chatFeed && chatFeed?.groupInformation) + checkIfrules(); + }, [chatId, chatFeed, account, env]); + + return ( + !Object.keys(chatFeed || {}).length? <> + {!pgpPrivateKey && isConnected && ( + +
+ {!signer && ( + - {!pgpPrivateKey && isConnected && ( -
+ )} + +
+ + )} + + : + !checkIfIntent({ chat: chatFeed, account: account! }) && + Object.keys(chatFeed || {}).length ? ( + + {/* {isConnected && ( + + )} */} + + + {Object.keys(chatFeed || {}).length && chatFeed?.groupInformation ? ( + <> + {pgpPrivateKey && !isMember && ( +
+ + Click on the button to join the group + + + handleJoinGroup()}> + {approveLoading ? ( + + ) : ( + ' Join Group ' + )} + + +
+ )} + {pgpPrivateKey && !verified && isMember && isRules && ( +
+ + Sending messages requires{' '} + + 1 PUSH Token + {' '} + for participation.{' '} + - {!signer && - You need to connect your wallet to get started - } - -
- ) - } - - {pgpPrivateKey && - !verified - // verified - && isRules && ( -
+ + + + checkVerification()}> + {accessLoading ? ( + + ) : ( + 'Verify Access' + )} + + +
+ )} + {pgpPrivateKey && !verificationSuccessfull && ( + +
+ + Verification Failed + + - - Sending messages requires 1 PUSH Token for participation. Learn More + Please ensure the following conditions are met to + participate and send messages. + +
+ token-gated +
+ {' '} + {/* Added marginLeft */} + + Token Gated - - - Verify Access - - -
- )} - {pgpPrivateKey && !verificationSuccessfull && ( - -
- Verification Failed - Please ensure the following conditions are met to participate and send messages. -
- token-gated -
{/* Added marginLeft */} - Token Gated - You need to have 1 PUSH Token in your wallet to be able to send messages. -
-
-
- { - if (onClick) { - onClick(); - } - setVerificationSuccessfull(true) - } - }> - - Get Free Tokens - - - - { - setVerificationSuccessfull(true) - console.log(verificationSuccessfull) - }}> - - Close - - -
-
-
- )} - {pgpPrivateKey && - (isRules ? verified : true) - // true - && - <> -
- {Emoji && -
setShowEmojis(!showEmojis)} - > - -
+ + You need to have{' '} + -
- )} - { - if (event.key === 'Enter' && !event.shiftKey) { - event.preventDefault(); - sendTextMsg(); - } - }} - placeholder="Type your message..." - onChange={(e) => onChangeTypedMessage(e.target.value)} - value={typedMessage} - ref={textAreaRef} - rows={1} - /> + > + 1 PUSH Token + {' '} + in your wallet to be able to send messages. + +
+
+
+ { + if (onClick) { + onClick(); + } + setVerificationSuccessfull(true); + }} + > + + Get Free Tokens + + + + { + setVerificationSuccessfull(true); + }} + > + Close + +
+
+ + )} + + ) : null} + {pgpPrivateKey && + (((isRules ? verified : true) && isMember) || + (chatFeed && !chatFeed?.groupInformation)) && ( + <> +
+ {Emoji && ( +
setShowEmojis(!showEmojis)} + > + +
+ )} + {showEmojis && ( +
+ +
+ )} + { + if (event.key === 'Enter' && !event.shiftKey) { + event.preventDefault(); + sendTextMsg(); + } + }} + placeholder="Type your message..." + onChange={(e) => onChangeTypedMessage(e.target.value)} + value={typedMessage} + ref={textAreaRef} + rows={1} + /> +
+ + {GIF && ( +
setGifOpen(!gifOpen)} + > + +
+ )} + {gifOpen && ( +
+ +
+ )} +
+ {!fileUploading && File && ( + <> +
setNewChat(true)} + > +
- - {GIF && -
setGifOpen(!gifOpen)}> - -
- } - {gifOpen && ( -
- -
- )} -
- {!fileUploading && File && ( - <> -
setNewChat(true)} - > - -
- uploadFile(e)} - - /> - - )} -
- {!(loading || fileUploading) && ( -
sendTextMsg()} - > - -
- )} - - {(loading || fileUploading) && ( -
- -
- )} -
- - } - - - ) -} + uploadFile(e)} + /> + + )} +
+ {!(loading || fileUploading) && ( +
sendTextMsg()} + > + +
+ )} + + {(loading || fileUploading) && ( +
+ +
+ )} +
+ + )} +
+
+ ) : ( + <> + ) + + ); +}; const Container = styled.div` width: 100%; overflow: hidden; - border:${(props) => props.theme.border?.messageInput}; - border-radius:${(props) => props.theme.borderRadius?.messageInput}; + border: ${(props) => props.theme.border?.messageInput}; + border-radius: ${(props) => props.theme.borderRadius?.messageInput}; `; const TypebarSection = styled(Section)` gap: 10px; @@ -417,7 +706,7 @@ const MultiLineInput = styled.textarea` outline: none; overflow-y: auto; box-sizing: border-box; - background:${(props) => props.theme.backgroundColor?.messageInputBackground}; + background: ${(props) => props.theme.backgroundColor?.messageInputBackground}; border: none; color: ${(props) => props.theme.textColor?.messageInputText}; resize: none; @@ -452,33 +741,33 @@ const FileInput = styled.input` display: none; `; - const ConnectWrapper = styled.div` - display: flex; - align-items: center; - flex-direction: column; - `; + display: flex; + align-items: center; + flex-direction: column; + cursor:pointer; +`; const StyledButton = styled.button` - border: 0px; - outline: 0px; - padding: 24px 9px; - font-weight: 500; - border-radius: 12px; - font-size: 17px; - cursor: pointer; - width: 147px; - height: 44px; - text-align: start; - align-items: center; - display: flex; - justify-content: center; - `; + border: 0px; + outline: 0px; + padding: 24px 9px; + font-weight: 500; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 147px; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; +`; const Connect = styled(StyledButton)` - color: rgb(255, 255, 255); - background: #D53A94; - `; + color: rgb(255, 255, 255); + background: #d53a94; +`; const ConnectWrapperClose = styled.div` display: flex; @@ -486,7 +775,6 @@ const ConnectWrapperClose = styled.div` flex-direction: column; `; - const StyledButtonClose = styled.button` border: 0px; outline: 0px; @@ -504,43 +792,41 @@ const StyledButtonClose = styled.button` `; const ConnectClose = styled(StyledButtonClose)` - color: rgb(255, 255, 255); - background: #D53A94; - gap: 8px; - `; - + color: rgb(255, 255, 255); + background: #d53a94; + gap: 8px; +`; const TokenWrapper = styled.div` - display: flex; - align-items: center; - flex-direction: column; - `; - + display: flex; + align-items: center; + flex-direction: column; +`; const TokenStyledButton = styled.button` -border: 0px; -outline: 0px; -padding: 22px 9px; -font-weight: 500; -border-radius: 12px; -font-size: 17px; -cursor: pointer; -width: 100%; -height: 44px; -text-align: start; -align-items: center; -display: flex; -justify-content: center; + border: 0px; + outline: 0px; + padding: 22px 9px; + font-weight: 500; + border-radius: 12px; + font-size: 17px; + cursor: pointer; + width: 100%; + height: 44px; + text-align: start; + align-items: center; + display: flex; + justify-content: center; `; const TokenGet = styled(TokenStyledButton)` - color: #D53A94; - border: 2px solid #D53A94; - background: none; - gap: 8px; - `; + color: #d53a94; + border: 2px solid #d53a94; + background: none; + gap: 8px; +`; const Link = styled.a` - color: #D53A94; - link-decoration: none; - text-decoration: none; -` \ No newline at end of file + color: #d53a94; + link-decoration: none; + text-decoration: none; +`; diff --git a/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx b/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx index 569eadba0..f370e5278 100644 --- a/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx +++ b/packages/uiweb/src/lib/components/chat/ProfileHeader/AddWalletContent.tsx @@ -33,7 +33,6 @@ export const AddWalletContent = ({ onSubmit, handlePrevious, onClose, memberList useEffect(() => { if (isInValidAddress) { - console.log('here we go'); setToastInfo({ message: 'Invalid Address', status: 'error' diff --git a/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx b/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx index c8c13f30e..8fd4e5797 100644 --- a/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx +++ b/packages/uiweb/src/lib/components/chat/helpers/Modal.tsx @@ -7,6 +7,7 @@ import { useRef, useContext } from 'react'; import styled from 'styled-components' import { ThemeContext } from '../theme/ThemeProvider'; import { useClickAway } from '../../../hooks'; +import { IChatTheme } from '../theme'; // import { ThemeContext } from '../theme/ThemeProvider'; @@ -16,6 +17,7 @@ interface IModalProps { width?: string; clickawayClose?: () => void; children: any; + theme?:IChatTheme } const ClickawayCloseModal = ({ children, clickawayClose, width }: IModalProps) => { @@ -65,7 +67,7 @@ const ModalOverlay = styled.div` height: 100%; background-color: rgba(0, 0, 0, 0.4); /* Black with 40% opacity */ display: flex; - color: ${(props) => props.theme.backgroundColor.chatReceivedBubbleText?? '#000'}; + color: ${(props) => props.theme.modalBackgroundColor?? '#000'}; justify-content: center; align-items: center; z-index: 2000; @@ -86,7 +88,7 @@ const ModalParent = styled.div` align-items: center; padding: 24px 20px; - background: ${(props) => props.theme.backgroundColor.chatReceivedBubbleBackground}; + background: ${(props) => props.theme.modalBackgroundColor}; border-radius: 12px; width: ${(props => props.width ? props.width : 'auto')}; diff --git a/packages/uiweb/src/lib/components/chat/theme/index.ts b/packages/uiweb/src/lib/components/chat/theme/index.ts index 922f69d37..0f6e78dba 100644 --- a/packages/uiweb/src/lib/components/chat/theme/index.ts +++ b/packages/uiweb/src/lib/components/chat/theme/index.ts @@ -83,6 +83,7 @@ export interface IChatTheme { //below needs to be categorised spinnerColor?: string; + modalBackgroundColor?:string; modalPrimaryTextColor?: string; modalSearchBarBorderColor?: string; modalSearchBarBackground?: string; @@ -182,6 +183,7 @@ export const lightChatTheme: IChatTheme = { spinnerColor: 'rgb(202, 89, 155)', scrollbarColor: 'rgb(202, 89, 155)', //the rest param needs to be included in categories + modalBackgroundColor:'#fff', modalPrimaryTextColor: '#1E1E1E', modalSearchBarBorderColor: '#BAC4D6', modalSearchBarBackground: '#FFF', @@ -281,6 +283,7 @@ export const darkChatTheme: IChatTheme = { spinnerColor: 'rgb(202, 89, 155)', scrollbarColor: 'rgb(202, 89, 155)', //the rest param needs to be included in categories + modalBackgroundColor:'rgba(47, 49, 55, 1)', modalPrimaryTextColor: '#B6BCD6', modalSearchBarBorderColor: '#4A4F67', modalSearchBarBackground: '#282A2E', diff --git a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx index 56f8cbe6c..c18e42e30 100644 --- a/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx +++ b/packages/uiweb/src/lib/dataProviders/ChatDataProvider.tsx @@ -71,16 +71,17 @@ const resetStates = () => { }; + + useEffect(() => { (async () => { let user; if (account) { user = await fetchChatProfile({ profileId: account,env }); - if (user) setConnectedProfile(user); } })(); - }, [account,env]); + }, [account,env,pgpPrivateKey]); const value: IChatDataContextValues = { account: accountVal, @@ -101,7 +102,6 @@ useEffect(() => { const PROVIDER_THEME = Object.assign({}, lightChatTheme, theme); -console.log(PROVIDER_THEME) return ( diff --git a/packages/uiweb/src/lib/helpers/address.ts b/packages/uiweb/src/lib/helpers/address.ts index c5909879a..d27d7da54 100644 --- a/packages/uiweb/src/lib/helpers/address.ts +++ b/packages/uiweb/src/lib/helpers/address.ts @@ -26,10 +26,14 @@ export const isValidCAIP10NFTAddress = (wallet: string): boolean => { }; export const walletToPCAIP10 = (account:string): string => { - if(isValidCAIP10NFTAddress(account) || account.includes('eip155:')){ - return account + if(account){ + if(isValidCAIP10NFTAddress(account) || account.includes('eip155:')){ + return account + } + return 'eip155:' + account } - return 'eip155:' + account + return account; + } export const pCAIP10ToWallet = (wallet: string): string => { diff --git a/packages/uiweb/src/lib/helpers/chat/chat.ts b/packages/uiweb/src/lib/helpers/chat/chat.ts index 357dce16e..90459a951 100644 --- a/packages/uiweb/src/lib/helpers/chat/chat.ts +++ b/packages/uiweb/src/lib/helpers/chat/chat.ts @@ -156,7 +156,7 @@ export const getDefaultFeedObject = ({user,groupInformation}:{user?:IUser,groupI publicKey: groupInformation?null: user!.publicKey, combinedDID: '', cid: '', - groupInformation: undefined, + groupInformation: groupInformation??undefined, }; return feed as IFeeds; } @@ -166,15 +166,17 @@ type CheckIfIntentType = { account:string, } export const checkIfIntent = ({chat,account}:CheckIfIntentType):boolean => { - console.log(chat) - console.log(account) - if(Object.keys(chat || {}).length && (chat.combinedDID.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) - { - if( chat.intent && (chat.intent.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) - return false; - else - return true; + + if(account){ + if(Object.keys(chat || {}).length && (chat.combinedDID.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) + { + if( chat.intent && (chat.intent.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) + return false; + else + return true; + } } + return false; } diff --git a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts index 474e64735..7e1629351 100644 --- a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts +++ b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts @@ -17,6 +17,7 @@ const useApproveChatRequest = () => { } = options || {}; setLoading(true); try { + console.log(account) const response = await PushAPI.chat.approve({ status: 'Approved', account: account, @@ -24,6 +25,7 @@ const useApproveChatRequest = () => { pgpPrivateKey:pgpPrivateKey, env: env, }); + setLoading(false); return response; } catch (error: Error | any) { setLoading(false); diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts index 1472d2752..c338c7c89 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts @@ -16,11 +16,10 @@ const useFetchChat = () => { const fetchChat = useCallback( async ({ chatId}: fetchChat) => { - console.log(env); setLoading(true); try { const chat = await PushAPI.chat.chat({ - account: account ? account : '0x0', + account: account? account : '0xeeE5A266D7cD954bE3Eb99062172E7071E664023', toDecrypt: pgpPrivateKey ? true : false, pgpPrivateKey: String(pgpPrivateKey), recipient: chatId, diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts b/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts index 407e34576..5b65d4c61 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchConversationHash.ts @@ -18,7 +18,7 @@ const useFetchConversationHash = () => { try { const response = await PushAPI.chat.conversationHash({ conversationId, - account: account!, + account: account ? account : '0xeeE5A266D7cD954bE3Eb99062172E7071E664023', env: env, }); setLoading(false); diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts b/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts index cdd2ee84c..0082622f9 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchHistoryMessages.ts @@ -27,7 +27,7 @@ const useFetchHistoryMessages try { const chatHistory:IMessageIPFS[] = await PushAPI.chat.history({ threadhash: threadHash, - account: account!, + account:account ? account : '0xeeE5A266D7cD954bE3Eb99062172E7071E664023', toDecrypt: pgpPrivateKey ? true : false, pgpPrivateKey: String(pgpPrivateKey), limit: limit, diff --git a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts index 80da0de72..91d8a737c 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushChatSocket.ts @@ -2,11 +2,10 @@ import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; import { useCallback, useEffect, useState } from 'react'; import { ENV } from '../../config'; import * as PushAPI from '@pushprotocol/restapi'; -import type { IMessageIPFS } from '@pushprotocol/restapi'; -import { isAccountsEqual } from '../../components/space/helpers/account'; + import { useChatData } from './useChatData'; import { SOCKET_TYPE } from '../../types'; -import { getChatId } from '../../helpers'; +import useGetChatProfile from '../useGetChatProfile'; export type PushChatSocketHookOptions = { account?: string | null; @@ -22,11 +21,14 @@ export const usePushChatSocket = () => { setIsPushChatSocketConnected, isPushChatSocketConnected, connectedProfile, + setConnectedProfile, env, } = useChatData(); - +const {fetchChatProfile} = useGetChatProfile(); const [messagesSinceLastConnection, setMessagesSinceLastConnection] = useState({}); + const [acceptedRequestMessage, setAcceptedRequestMessage] = + useState({}); const [ groupInformationSinceLastConnection, setGroupInformationSinceLastConnection, @@ -48,32 +50,32 @@ export const usePushChatSocket = () => { }); pushChatSocket?.on(EVENTS.CHAT_RECEIVED_MESSAGE, async (chat: any) => { - console.log(chat) - console.log(connectedProfile) - console.log(pgpPrivateKey) + + if (!connectedProfile || !pgpPrivateKey) { return; } - console.log(chat) if ( ( chat.messageCategory === 'Request') && (chat.messageContent === null) && (chat.messageType === null) ) { - return; + setAcceptedRequestMessage(chat); } - console.log(chat) - const response = await PushAPI.chat.decryptConversation({ - messages: [chat], - connectedUser: connectedProfile, - pgpPrivateKey: pgpPrivateKey, - env: env, - }); - console.log(chat) - - if (response && response.length) { - setMessagesSinceLastConnection(response[0]); + else + { + const response = await PushAPI.chat.decryptConversation({ + messages: [chat], + connectedUser: connectedProfile, + pgpPrivateKey: pgpPrivateKey, + env: env, + }); + + if (response && response.length) { + setMessagesSinceLastConnection(response[0]); + } } + }); pushChatSocket?.on(EVENTS.CHAT_GROUPS, (groupInfo: any) => { /** @@ -143,6 +145,7 @@ export const usePushChatSocket = () => { pushChatSocket, isPushChatSocketConnected, messagesSinceLastConnection, + acceptedRequestMessage, groupInformationSinceLastConnection, }; }; diff --git a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts index 415799e77..ac866a162 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts @@ -15,8 +15,6 @@ const usePushSendMessage = () => { const [error, setError] = useState(); const [loading, setLoading] = useState(false); - const { verificationSuccessfull, setVerificationSuccessfull, setVerified } = - useVerifyAccessControl(); const { pgpPrivateKey, env, account } = useChatData(); const sendMessage = useCallback( @@ -37,17 +35,13 @@ const usePushSendMessage = () => { if (!response) { return false; } - return; + return response; } catch (error: Error | any) { - if (error.message.includes('400')) { - setAccessControl(chatId, true); - setVerified(false); - setVerificationSuccessfull(false); - } + setLoading(false); setError(error.message); console.log(error); - return; + return error.message; } }, [pgpPrivateKey, account] diff --git a/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts b/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts index f50ce89f6..7e491644f 100644 --- a/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts +++ b/packages/uiweb/src/lib/hooks/chat/useVerifyAccessControl.ts @@ -18,7 +18,6 @@ const useVerifyAccessControl = () => { const { pgpPrivateKey, env, account } = useChatData(); - console.log('Verification control hook'); const verifyAccessControl = useCallback( async (options: VerifyAccessControlParams) => { const { chatId, did } = options || {}; @@ -30,13 +29,13 @@ const useVerifyAccessControl = () => { env: env, }); setLoading(false); - if (response.chatAccess === false) { + if (response.chat === false) { + setVerificationSuccessfull(false); - } else if (response.chatAccess === true) { + } else if (response.chat === true) { setVerified(true); setAccessControl(chatId, false); } - console.log(response); if (!response) { return false; } @@ -49,8 +48,9 @@ const useVerifyAccessControl = () => { return; } }, - [pgpPrivateKey, account, verificationSuccessfull, verified, setVerified] + [pgpPrivateKey, account, env] ); + return { verifyAccessControl, error, diff --git a/packages/uiweb/src/lib/icons/MoreLight.tsx b/packages/uiweb/src/lib/icons/MoreLight.tsx index 4aa3f66ea..e208c2191 100644 --- a/packages/uiweb/src/lib/icons/MoreLight.tsx +++ b/packages/uiweb/src/lib/icons/MoreLight.tsx @@ -1,11 +1,15 @@ import React from 'react'; -export const MoreLightIcon = () => { +export const MoreLightIcon = ({ + fill, +}: { + fill?: string; +}) => { return ( - - - + + + ); }; From 1a19561da8d9f90937315095e0f6ac66b83e5028 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 25 Aug 2023 17:33:49 +0530 Subject: [PATCH 219/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 4 ++++ packages/uiweb/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 15792fe2f..06877ef30 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.2...uiweb-0.0.1-alpha.3) (2023-08-25) + + + ## [0.0.1-alpha.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.1...uiweb-0.0.1-alpha.2) (2023-08-23) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index acb8160ac..9ec4cb5ea 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.2", + "version": "0.0.1-alpha.3", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 4a149d84767f081be1bea3970321fd33ccac35ab Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Fri, 25 Aug 2023 20:31:35 +0530 Subject: [PATCH 220/298] Join group option (#687) * feat: created architechture * fix: added context values (#594) * Chat dataprovider (#596) * feat: data provider for chat component * fix: replaced react.usestate to usestate * fix: added props as the initial state and changed state name * fix: reverted chat context changes and renamed values * fix: added test page for chat ui components (#597) * added chatbubble component (#602) * feat: added chatbubble component * fix: made the messageBubble's width to fit-content --------- Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> * fix: added theme * Group chat bubble (#604) * feat: moved test component to testui folder & replaced dummy data with sdk response * feat: added twitter card and address for group chat received msg * feat: made the messageaddress reusable, added account from context * fix: removed unnecessary div and unused props and console logs * feat: adding pfp in text bubbles * fix: replaced hook with function and added pfp to messagebubble * fix: fixed image alignment * fix: changed border-radius of msg bubble and changed function name * fix: fixed theme and decryptedPrivateKey name (#616) * fix: fixed theme and decryptedPrivateKey name * fix: fixed bug * fix: fixed theme reviews * Message list (#615) * fix: message list comp * fix: message list comp * fix: added pagination * fix: added pagination * fix: pagination * fix: create useChatData hook * fix: fixed minor bug * fix: socket issues fixed * fix: added theme in msgbubble (#620) * fix: added theme in msgbubble * fix: fixed import --------- Co-authored-by: Monalisha Mishra * fix: exported the theme (#623) * fix: exported the theme * fix: fixed issues --------- Co-authored-by: Monalisha Mishra * Typebar component (#631) * feat: added typebar UI * feat: added functions to typebar * fix: added icon * fix: fixed theme issues --------- Co-authored-by: Monalisha Mishra * feat: added connectbutton * fix: fixed connectbtn ui and remove disconnect and fixed error on disconnect * fix: fixed create account getting called twice * Profile Header Component (#636) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * Message container (#635) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * fix: updated svg to react component * fix: changed svg to tsx component * fix: fixed review changes (#646) * fix: fixed review changes * fix: resolved issues --------- Co-authored-by: Nilesh Gupta * Profile Header -> Chat Profile fixes (#647) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * fix: notifs * fix: correct theme colors * fix: renaming profileHeader * fix: qa fixes * fix: loader * refactor: resolved issues * fix: edit types --------- Co-authored-by: Nilesh Gupta * fix: resolved package not added issue * Fix: modal issue in group info && alert remove members (#653) * fix: modal * fix: update changes * refactor: resolved issue --------- Co-authored-by: Nilesh Gupta * fix: QA fixes (#654) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * Connect btn revamp (#668) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container * feat: adding rainbowkit for btn * fix: fix issues * fix: addec onnect functionality * fix: connect button * fix: added hack for rainbowkit css --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * Typebar UI issue (#666) * fix: fixed typebar space not working and theme * fix: fixed gif and emoji --------- Co-authored-by: KlausMikhaelson * fix: fixed theme colours * fix: added theme for brb * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * fix: added filter hat * fix: merged with main * fix: fixed msg border * fix: fixed theme * fix: fixed fonts * fix: fixed bug * Access control (#672) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * fix: added minor fix --------- Co-authored-by: Monalisha Mishra * fix: fixed padding issues * fix(f): fixed build issues * fix: fix for chat status test * feat: added verification option to show only on token gated groups * fix: fixing group access control * Check rules access control (#678) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * 662 group access control v2 changes (#663) * fix: spaces access API * fix: custom endpoint doc impl * Update README.md * Update README.md * fix: review comments change * fix: read me update * Update README.md * Update README.md * fix: origin in user creation (#665) * fix: origin in user creation * Update README.md * fix: review comments * 662 group access control v2 changes (#677) * fix: spaces access API * fix: custom endpoint doc impl * Update README.md * Update README.md * fix: review comments change * fix: read me update * Update README.md * Update README.md * fix(spaces): broadcast changes and UX fixes (#674) * fix: fix UI grid view (#642) * fix: fix UI grid view * refactor: conditional added * fix: resolved muting/unmuting try catch error (#657) * fix(spaces): fix livepeer broadcast (#656) * fix(spaces): fix livepeer broadcast * fix(spaces): fix data shown for unjoined space & promote listener logic --------- Co-authored-by: Madhur Gupta * refactor(spaces): use local state instead of get from server while meta message fire (#676) --------- Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Nilesh Gupta * feat: added verification option to show only on token gated groups * fix: fixing group access control --------- Co-authored-by: Monalisha Mishra Co-authored-by: Mohammed S Co-authored-by: Madhur Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Nilesh Gupta * fix: fixed build * feat: added send request to join group * fix: fixed verification on send * fix: fixed verify access btn not showing after joining group * fix: fixed join group showing for members too * fix: fixed join group showing to members * 667 chat.send enhancement (#673) * fix: changes messageObj for meta and reaction message type * fix: enhance send fn * fix: fixed intent issues * 680 group rules cosmetic changes (#682) * fix: fixed guild condition * fix: add did validation * fix: fixed * fix: fixed minor issues * fix: fixe dissue * fix: fixed minor issues * fix: check for scroll * fix: fixed scrolling * fix: fixed theme * fix: fixed * fix: fixed * fix: fixed * fix: fixed issues * fix: fixed * feat: added toast in join group btn for pvt groups * fix: fixed blurr * fix: fixed minor issues rules * fix: fixed * fix: fixed --------- Co-authored-by: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Co-authored-by: KlausMikhaelson Co-authored-by: Kolade Co-authored-by: Nilesh Gupta Co-authored-by: Mohammed S Co-authored-by: Madhur Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Aman Gupta --- .../src/app/ChatUITest/ChatViewComponent.tsx | 4 ++-- .../chat/ChatViewBubble/ChatViewBubble.tsx | 2 +- .../chat/ChatViewList/ChatViewList.tsx | 10 +++++--- .../chat/MessageInput/MessageInput.tsx | 24 +++++++++++-------- .../lib/hooks/chat/useApproveChatRequest.ts | 7 +++--- .../uiweb/src/lib/hooks/chat/useFetchChat.ts | 2 +- 6 files changed, 29 insertions(+), 20 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 410f01f57..6f210c9b2 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -17,11 +17,11 @@ const ChatViewComponentTest = () => { {/* */} - console.log("BOIIII RETURNNNSSSSS")} chatId='c2d544ad9d1efd5c5a593b143bf8232875c926cf28015564e70ad078b95f807e' limit={10}/> + console.log("BOIIII RETURNNNSSSSS")} chatId='24b029b8e07e60291bf9d8c0c48ff993fa1e0a99105459f7404c425c92e91bac' limit={10}/> ); -}; +} export default ChatViewComponentTest; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx index 1e5a33a1b..00b9f4203 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx @@ -108,7 +108,7 @@ const MessageCard = ({ margin="5px 0" alignSelf={position ? 'end' : 'start'} justifyContent="start" - maxWidth="80%" + maxWidth="86%" minWidth="71px" position="relative" width="fit-content" diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx index b256f3c3f..5ce3582b7 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -201,9 +201,13 @@ export const ChatViewList: React.FC = ( }, [messagesSinceLastConnection]); const scrollToBottom = (behavior?: string | null) => { - if (listInnerRef.current) { - listInnerRef.current.scrollTop = listInnerRef.current.scrollHeight; - } + setTimeout(()=>{ + if (listInnerRef.current) { + listInnerRef.current.scrollTop = listInnerRef.current.scrollHeight +100000; + console.log(listInnerRef.current.scrollHeight +100000) + } + },0) + }; useEffect(()=>{ diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index c9243419f..1e6315409 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -139,7 +139,7 @@ export const MessageInput: React.FC = ({ chatId: chatFeed?.groupInformation?.groupCreator || '', messageType: 'Text', }); - if(sendTextMessage) { + if (sendTextMessage) { statusToast.showMessageToast({ toastTitle: 'Success', toastMessage: 'Request sent successfully', @@ -240,7 +240,11 @@ export const MessageInput: React.FC = ({ chatId, messageType: type as any, }); - if (sendMessageResponse&&sendMessageResponse.includes('400')) { + if ( + sendMessageResponse && + typeof sendMessageResponse === 'string' && + sendMessageResponse.includes('400') + ) { setAccessControl(chatId, true); setVerified(false); setVerificationSuccessfull(false); @@ -289,15 +293,15 @@ export const MessageInput: React.FC = ({ if (Object.keys(chat || {}).length) { setChatFeed(chat as IFeeds); } - } - + }; + useEffect(() => { (async () => { if ( Object.keys(acceptedRequestMessage || {}).length && Object.keys(chatFeed || {}).length ) { - await updateChatFeed(); + await updateChatFeed(); } })(); }, [acceptedRequestMessage]); @@ -305,7 +309,7 @@ export const MessageInput: React.FC = ({ useEffect(() => { (async () => { if (!account && !env) return; - if(account && env){ + if (account && env) { const chat = await fetchChat({ chatId }); if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); else { @@ -329,9 +333,6 @@ export const MessageInput: React.FC = ({ } } } - - - })(); }, [chatId, pgpPrivateKey, account, env]); @@ -347,7 +348,10 @@ export const MessageInput: React.FC = ({ } }); - if (chatFeed?.groupInformation?.rules) { + if (chatFeed?.groupInformation?.rules && + (chatFeed?.groupInformation?.rules?.groupAccess || + chatFeed?.groupInformation?.rules?.chat) + ) { setIsRules(true); } }; diff --git a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts index 7e1629351..68778c0f7 100644 --- a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts +++ b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts @@ -9,7 +9,7 @@ interface ApproveChatParams { const useApproveChatRequest = () => { const [error, setError] = useState(); const [loading, setLoading] = useState(false); - const { account, env,pgpPrivateKey } =useChatData(); + const { account, env,pgpPrivateKey,signer } =useChatData(); const approveChatRequest = useCallback(async (options:ApproveChatParams) => { const { @@ -21,7 +21,8 @@ const useApproveChatRequest = () => { const response = await PushAPI.chat.approve({ status: 'Approved', account: account, - senderAddress: chatId, // receiver's address or chatId of a group + senderAddress: chatId, + signer:signer, // receiver's address or chatId of a group pgpPrivateKey:pgpPrivateKey, env: env, }); @@ -34,7 +35,7 @@ const useApproveChatRequest = () => { return; } }, - [] + [account,env,signer] ); return { approveChatRequest, error, loading }; diff --git a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts index c338c7c89..d1bbd06dc 100644 --- a/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts +++ b/packages/uiweb/src/lib/hooks/chat/useFetchChat.ts @@ -36,7 +36,7 @@ const useFetchChat = () => { setLoading(false); } }, - [pgpPrivateKey,env] + [pgpPrivateKey,env,account] ); return { fetchChat, error, loading }; From 87149fd88bb37c798fbd065136daa5f63ba23939 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 25 Aug 2023 20:34:20 +0530 Subject: [PATCH 221/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 06877ef30..0e5e25221 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.3...uiweb-0.0.1-alpha.4) (2023-08-25) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([7a0d87e](https://github.com/ethereum-push-notification-service/push-sdk/commit/7a0d87eb35a77cad6898be54af5431eb5335c80d)) + + + ## [0.0.1-alpha.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.2...uiweb-0.0.1-alpha.3) (2023-08-25) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 9ec4cb5ea..694894dc0 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.3", + "version": "0.0.1-alpha.4", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From fcecb0c0c8c2c7ffb62a7193036b737f88e23d66 Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Fri, 25 Aug 2023 22:12:24 +0530 Subject: [PATCH 222/298] Join group option (#688) * feat: created architechture * fix: added context values (#594) * Chat dataprovider (#596) * feat: data provider for chat component * fix: replaced react.usestate to usestate * fix: added props as the initial state and changed state name * fix: reverted chat context changes and renamed values * fix: added test page for chat ui components (#597) * added chatbubble component (#602) * feat: added chatbubble component * fix: made the messageBubble's width to fit-content --------- Co-authored-by: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> * fix: added theme * Group chat bubble (#604) * feat: moved test component to testui folder & replaced dummy data with sdk response * feat: added twitter card and address for group chat received msg * feat: made the messageaddress reusable, added account from context * fix: removed unnecessary div and unused props and console logs * feat: adding pfp in text bubbles * fix: replaced hook with function and added pfp to messagebubble * fix: fixed image alignment * fix: changed border-radius of msg bubble and changed function name * fix: fixed theme and decryptedPrivateKey name (#616) * fix: fixed theme and decryptedPrivateKey name * fix: fixed bug * fix: fixed theme reviews * Message list (#615) * fix: message list comp * fix: message list comp * fix: added pagination * fix: added pagination * fix: pagination * fix: create useChatData hook * fix: fixed minor bug * fix: socket issues fixed * fix: added theme in msgbubble (#620) * fix: added theme in msgbubble * fix: fixed import --------- Co-authored-by: Monalisha Mishra * fix: exported the theme (#623) * fix: exported the theme * fix: fixed issues --------- Co-authored-by: Monalisha Mishra * Typebar component (#631) * feat: added typebar UI * feat: added functions to typebar * fix: added icon * fix: fixed theme issues --------- Co-authored-by: Monalisha Mishra * feat: added connectbutton * fix: fixed connectbtn ui and remove disconnect and fixed error on disconnect * fix: fixed create account getting called twice * Profile Header Component (#636) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * Message container (#635) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * fix: updated svg to react component * fix: changed svg to tsx component * fix: fixed review changes (#646) * fix: fixed review changes * fix: resolved issues --------- Co-authored-by: Nilesh Gupta * Profile Header -> Chat Profile fixes (#647) * feat: profile header * feat: update profile header * fix: update hooks * fix: video icon ui * feat: add group modal * fix: add modal info * fix: edit components * fix: commit modal theme * fix: updating UI * fix: ensname * fix: add notifs * fix: remove alerts * fix: remove alert logs * fix: push fixes * fix: conflicts * fix: notifs * fix: correct theme colors * fix: renaming profileHeader * fix: qa fixes * fix: loader * refactor: resolved issues * fix: edit types --------- Co-authored-by: Nilesh Gupta * fix: resolved package not added issue * Fix: modal issue in group info && alert remove members (#653) * fix: modal * fix: update changes * refactor: resolved issue --------- Co-authored-by: Nilesh Gupta * fix: QA fixes (#654) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * Connect btn revamp (#668) * fix: added theme in msgbubble * fix: fixed import * fix: fixed message-list * fix: added approve intent * fix: added fixes * fix: fixed socket bug * fix: fixed message from socket * fix: fixed minor issues * fix: fixed typebar theming * fix: fixed env issue * fix: fixed message not updating issue * refactor: added isConnected prop in msgContainer * refactor: resolve merge conflicts * fix: fixed request sending * fix: fixed decryption * fix: fixed env issue * feat: added profile header in message container * feat: adding rainbowkit for btn * fix: fix issues * fix: addec onnect functionality * fix: connect button * fix: added hack for rainbowkit css --------- Co-authored-by: KlausMikhaelson Co-authored-by: Nilesh Gupta * Typebar UI issue (#666) * fix: fixed typebar space not working and theme * fix: fixed gif and emoji --------- Co-authored-by: KlausMikhaelson * fix: fixed theme colours * fix: added theme for brb * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * fix: added filter hat * fix: merged with main * fix: fixed msg border * fix: fixed theme * fix: fixed fonts * fix: fixed bug * Access control (#672) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * fix: added minor fix --------- Co-authored-by: Monalisha Mishra * fix: fixed padding issues * fix(f): fixed build issues * fix: fix for chat status test * feat: added verification option to show only on token gated groups * fix: fixing group access control * Check rules access control (#678) * fix: fixed typebar space not working and theme * feat: created access control UI * feat: created verify access control hook * fix: fixed access control hook issue * feat: added access control verification * feat: added onclick props for integration team to pass function and fixed btn ui * fix: added link for learn more * fix: fixed msg not updating in socket issue * 662 group access control v2 changes (#663) * fix: spaces access API * fix: custom endpoint doc impl * Update README.md * Update README.md * fix: review comments change * fix: read me update * Update README.md * Update README.md * fix: origin in user creation (#665) * fix: origin in user creation * Update README.md * fix: review comments * 662 group access control v2 changes (#677) * fix: spaces access API * fix: custom endpoint doc impl * Update README.md * Update README.md * fix: review comments change * fix: read me update * Update README.md * Update README.md * fix(spaces): broadcast changes and UX fixes (#674) * fix: fix UI grid view (#642) * fix: fix UI grid view * refactor: conditional added * fix: resolved muting/unmuting try catch error (#657) * fix(spaces): fix livepeer broadcast (#656) * fix(spaces): fix livepeer broadcast * fix(spaces): fix data shown for unjoined space & promote listener logic --------- Co-authored-by: Madhur Gupta * refactor(spaces): use local state instead of get from server while meta message fire (#676) --------- Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Nilesh Gupta * feat: added verification option to show only on token gated groups * fix: fixing group access control --------- Co-authored-by: Monalisha Mishra Co-authored-by: Mohammed S Co-authored-by: Madhur Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Nilesh Gupta * fix: fixed build * feat: added send request to join group * fix: fixed verification on send * fix: fixed verify access btn not showing after joining group * fix: fixed join group showing for members too * fix: fixed join group showing to members * 667 chat.send enhancement (#673) * fix: changes messageObj for meta and reaction message type * fix: enhance send fn * fix: fixed intent issues * 680 group rules cosmetic changes (#682) * fix: fixed guild condition * fix: add did validation * fix: fixed * fix: fixed minor issues * fix: fixe dissue * fix: fixed minor issues * fix: check for scroll * fix: fixed scrolling * fix: fixed theme * fix: fixed * fix: fixed * fix: fixed * fix: fixed issues * fix: fixed * feat: added toast in join group btn for pvt groups * fix: fixed blurr * fix: fixed minor issues rules * fix: fixed * fix: fixed * fix: fixed socket issue * fix: fixed --------- Co-authored-by: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Co-authored-by: KlausMikhaelson Co-authored-by: Kolade Co-authored-by: Nilesh Gupta Co-authored-by: Mohammed S Co-authored-by: Madhur Gupta Co-authored-by: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Co-authored-by: Aman Gupta --- .../chat/ChatViewList/ChatViewList.tsx | 2 +- packages/uiweb/src/lib/helpers/chat/chat.ts | 181 +++++++++++------- .../lib/hooks/chat/useApproveChatRequest.ts | 5 +- .../src/lib/hooks/chat/usePushSendMessage.ts | 2 +- 4 files changed, 112 insertions(+), 78 deletions(-) diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx index 5ce3582b7..e2037dc06 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -204,7 +204,7 @@ export const ChatViewList: React.FC = ( setTimeout(()=>{ if (listInnerRef.current) { listInnerRef.current.scrollTop = listInnerRef.current.scrollHeight +100000; - console.log(listInnerRef.current.scrollHeight +100000) + } },0) diff --git a/packages/uiweb/src/lib/helpers/chat/chat.ts b/packages/uiweb/src/lib/helpers/chat/chat.ts index 90459a951..81c4ade7d 100644 --- a/packages/uiweb/src/lib/helpers/chat/chat.ts +++ b/packages/uiweb/src/lib/helpers/chat/chat.ts @@ -1,7 +1,12 @@ import * as PushAPI from '@pushprotocol/restapi'; import type { ENV } from '../../config'; import { Constants } from '../../config'; -import type { AccountEnvOptionsType, IGroup, IMessageIPFS, Messagetype } from '../../types'; +import type { + AccountEnvOptionsType, + IGroup, + IMessageIPFS, + Messagetype, +} from '../../types'; import { ChatFeedsType } from '../../types'; import type { Env, IConnectedUser, IFeeds, IUser } from '@pushprotocol/restapi'; import { isPCAIP, pCAIP10ToWallet, walletToPCAIP10 } from '../address'; @@ -18,11 +23,9 @@ type GetChatsType = { supportAddress: string; limit: number; threadHash?: string; - env?: Env; + env?: Env; account: string; -} - - +}; export const handleOnChatIconClick = ({ isModalOpen, @@ -37,13 +40,17 @@ export const createUserIfNecessary = async ( const { account, signer, env = Constants.ENV.PROD } = options || {}; let connectedUser = await PushAPI.user.get({ account: account, env }); if (!connectedUser?.encryptedPrivateKey) { - connectedUser = await PushAPI.user.create({ account: account, signer: signer, env }); + connectedUser = await PushAPI.user.create({ + account: account, + signer: signer, + env, + }); } const decryptedPrivateKey = await PushAPI.chat.decryptPGPKey({ encryptedPGPPrivateKey: connectedUser.encryptedPrivateKey, account, signer, - env + env, }); return { ...connectedUser, privateKey: decryptedPrivateKey }; }; @@ -80,7 +87,7 @@ export const getChats = async ( account: account, pgpPrivateKey: pgpPrivateKey, threadhash: threadhash, - toDecrypt:true, + toDecrypt: true, limit: limit, env, }); @@ -93,19 +100,15 @@ export const getChats = async ( }; type DecrypteChatType = { - message: IMessageIPFS, - connectedUser: IConnectedUser, - env: ENV -} + message: IMessageIPFS; + connectedUser: IConnectedUser; + env: ENV; +}; export const decryptChat = async ( options: DecrypteChatType -):Promise => { - const { - message, - connectedUser, - env = Constants.ENV.PROD, - } = options || {}; - const decryptedChat:IMessageIPFS[] = await PushAPI.chat.decryptConversation({ +): Promise => { + const { message, connectedUser, env = Constants.ENV.PROD } = options || {}; + const decryptedChat: IMessageIPFS[] = await PushAPI.chat.decryptConversation({ messages: [message], connectedUser, pgpPrivateKey: connectedUser.privateKey!, @@ -127,8 +130,13 @@ export const copyToClipboard = (address: string): void => { } }; - -export const getDefaultFeedObject = ({user,groupInformation}:{user?:IUser,groupInformation?:IGroup}) :IFeeds => { +export const getDefaultFeedObject = ({ + user, + groupInformation, +}: { + user?: IUser; + groupInformation?: IGroup; +}): IFeeds => { const feed = { msg: { messageContent: '', @@ -144,49 +152,64 @@ export const getDefaultFeedObject = ({user,groupInformation}:{user?:IUser,groupI toDID: '', toCAIP10: '', }, - wallets: groupInformation?null: user!.wallets, - did: groupInformation?null: user!.did, + wallets: groupInformation ? null : user!.wallets, + did: groupInformation ? null : user!.did, threadhash: null, - profilePicture: groupInformation?groupInformation.groupImage:user?.profile.picture, + profilePicture: groupInformation + ? groupInformation.groupImage + : user?.profile.picture, name: null, - about: groupInformation?null:user!.about, + about: groupInformation ? null : user!.about, intent: null, intentSentBy: null, intentTimestamp: new Date(), - publicKey: groupInformation?null: user!.publicKey, + publicKey: groupInformation ? null : user!.publicKey, combinedDID: '', cid: '', - groupInformation: groupInformation??undefined, + groupInformation: groupInformation ?? undefined, }; return feed as IFeeds; -} +}; type CheckIfIntentType = { - chat:IFeeds, - account:string, -} -export const checkIfIntent = ({chat,account}:CheckIfIntentType):boolean => { - - if(account){ - if(Object.keys(chat || {}).length && (chat.combinedDID.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) - { - if( chat.intent && (chat.intent.toLowerCase()).includes(walletToPCAIP10(account).toLowerCase())) - return false; - else - return true; + chat: IFeeds; + account: string; +}; +export const checkIfIntent = ({ + chat, + account, +}: CheckIfIntentType): boolean => { + if (account) { + if ( + Object.keys(chat || {}).length && + chat.combinedDID + .toLowerCase() + .includes(walletToPCAIP10(account).toLowerCase()) + ) { + if ( + chat.intent && + chat.intent + .toLowerCase() + .includes(walletToPCAIP10(account).toLowerCase()) + ) + return false; + else return true; } } - + return false; -} +}; -export const checkIfUnread = (chatId:string,chat:IFeeds):boolean => { +export const checkIfUnread = (chatId: string, chat: IFeeds): boolean => { const tempChat = getData(chatId); - if(tempChat && tempChat?.msg && (tempChat.msg.timestamp!) < (chat.msg.timestamp!)) - return true; + if ( + tempChat && + tempChat?.msg && + tempChat.msg.timestamp! < chat.msg.timestamp! + ) + return true; return false; -} - +}; export const getChatId = ({ msg, @@ -201,22 +224,25 @@ export const getChatId = ({ return !isPCAIP(msg.toDID) ? msg.toDID : msg.fromDID; }; -export const appendUniqueMessages = (parentList:Messagetype,newlist:IMessageIPFS[],infront:boolean) =>{ +export const appendUniqueMessages = ( + parentList: Messagetype, + newlist: IMessageIPFS[], + infront: boolean +) => { const uniqueMap: { [timestamp: number]: IMessageIPFS } = {}; - const appendedArray = infront?[...newlist, ...parentList.messages]:[ ...parentList.messages,...newlist]; + const appendedArray = infront + ? [...newlist, ...parentList.messages] + : [...parentList.messages, ...newlist]; const newMessageList = Object.values( - appendedArray.reduce( - (uniqueMap, message) => { - if (message.timestamp && !uniqueMap[message.timestamp]) { - uniqueMap[message.timestamp] = message; - } - return uniqueMap; - }, - uniqueMap - ) + appendedArray.reduce((uniqueMap, message) => { + if (message.timestamp && !uniqueMap[message.timestamp]) { + uniqueMap[message.timestamp] = message; + } + return uniqueMap; + }, uniqueMap) ); - return newMessageList -} + return newMessageList; +}; export const checkIfSameChat = ( msg: IMessageIPFS, @@ -225,19 +251,26 @@ export const checkIfSameChat = ( ) => { if (ethers.utils.isAddress(chatId)) { chatId = walletToPCAIP10(chatId); + if ( + Object.keys(msg || {}).length && + (((chatId.toLowerCase() === msg.fromCAIP10?.toLowerCase()) && + ( walletToPCAIP10(account!).toLowerCase() === + msg.toCAIP10?.toLowerCase())) || + ((chatId.toLowerCase() === msg.toCAIP10?.toLowerCase()) && + (walletToPCAIP10(account!).toLowerCase() === + msg.fromCAIP10?.toLowerCase()))) + ) { + return true; + } + } else { + if ( + Object.keys(msg || {}).length && + (chatId.toLowerCase() === msg.toCAIP10?.toLowerCase()) + ) { + return true; + } } - if ( - Object.keys(msg || {}).length && - ((chatId.toLowerCase() === - msg.fromCAIP10?.toLowerCase() && - walletToPCAIP10(account!).toLowerCase() === - msg.toCAIP10?.toLowerCase()) || - (chatId.toLowerCase() === - msg.toCAIP10?.toLowerCase() && - walletToPCAIP10(account!).toLowerCase() === - msg.fromCAIP10?.toLowerCase())) - ) { - return true; - } + console.log(chatId); + return false; -}; \ No newline at end of file +}; diff --git a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts index 68778c0f7..676705a7f 100644 --- a/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts +++ b/packages/uiweb/src/lib/hooks/chat/useApproveChatRequest.ts @@ -17,7 +17,6 @@ const useApproveChatRequest = () => { } = options || {}; setLoading(true); try { - console.log(account) const response = await PushAPI.chat.approve({ status: 'Approved', account: account, @@ -35,7 +34,9 @@ const useApproveChatRequest = () => { return; } }, - [account,env,signer] + + [account,env,signer,pgpPrivateKey] + ); return { approveChatRequest, error, loading }; diff --git a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts index ac866a162..51aba7fbc 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts @@ -44,7 +44,7 @@ const usePushSendMessage = () => { return error.message; } }, - [pgpPrivateKey, account] + [pgpPrivateKey, account,env] ); return { sendMessage, error, loading }; From d93193f4341e17e6f287e79453fb07ba7cc61610 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 25 Aug 2023 22:20:16 +0530 Subject: [PATCH 223/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 0e5e25221..a79c19168 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.4...uiweb-0.0.1-alpha.5) (2023-08-25) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([292a8f9](https://github.com/ethereum-push-notification-service/push-sdk/commit/292a8f94fbe1c13c49aa2b07c633e10cad1f02bc)) + + + ## [0.0.1-alpha.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.3...uiweb-0.0.1-alpha.4) (2023-08-25) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 694894dc0..61e39d62a 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.4", + "version": "0.0.1-alpha.5", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From a7ed3c0955316da00739f114afe1a3d3a958c66e Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Fri, 25 Aug 2023 23:46:02 +0530 Subject: [PATCH 224/298] fix: fixed (#689) --- .../src/app/ChatUITest/ChatViewComponent.tsx | 2 +- packages/examples/sdk-frontend-react/src/app/app.tsx | 2 +- .../src/lib/components/chat/MessageInput/MessageInput.tsx | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 6f210c9b2..e90d52375 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -17,7 +17,7 @@ const ChatViewComponentTest = () => { {/* */} - console.log("BOIIII RETURNNNSSSSS")} chatId='24b029b8e07e60291bf9d8c0c48ff993fa1e0a99105459f7404c425c92e91bac' limit={10}/> + console.log("BOIIII RETURNNNSSSSS")} chatId='aee13144f79f0f2027875124fc9d7132420b0c1876061dced594ff30c2c33abc' limit={10}/> ); diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index 187401c5b..ff14f7237 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -215,7 +215,7 @@ const checkForWeb3Data = ({ export function App() { const { account, library, active, chainId } = useWeb3React(); - const [env, setEnv] = useState(ENV.STAGING); + const [env, setEnv] = useState(ENV.PROD); const [isCAIP, setIsCAIP] = useState(false); const [signer, setSigner] = useState(); diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 1e6315409..fcbc76bf0 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -243,7 +243,7 @@ export const MessageInput: React.FC = ({ if ( sendMessageResponse && typeof sendMessageResponse === 'string' && - sendMessageResponse.includes('400') + sendMessageResponse.includes('403') ) { setAccessControl(chatId, true); setVerified(false); @@ -489,7 +489,7 @@ export const MessageInput: React.FC = ({ Verification Failed @@ -512,7 +512,7 @@ export const MessageInput: React.FC = ({ {' '} {/* Added marginLeft */} @@ -521,7 +521,7 @@ export const MessageInput: React.FC = ({ You need to have{' '} Date: Fri, 25 Aug 2023 23:47:43 +0530 Subject: [PATCH 225/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 10 ++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index a79c19168..f355f5fb0 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.5...uiweb-0.0.1-alpha.6) (2023-08-25) + + +### Bug Fixes + +* fixed ([#689](https://github.com/ethereum-push-notification-service/push-sdk/issues/689)) ([a7ed3c0](https://github.com/ethereum-push-notification-service/push-sdk/commit/a7ed3c0955316da00739f114afe1a3d3a958c66e)) +* Merge branch 'alpha' into alpha-deployment ([af5a4a7](https://github.com/ethereum-push-notification-service/push-sdk/commit/af5a4a75bde324ef8552fb8a3d404e8c57f59f1c)) + + + ## [0.0.1-alpha.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.4...uiweb-0.0.1-alpha.5) (2023-08-25) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 61e39d62a..4857a07e4 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.5", + "version": "0.0.1-alpha.6", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 53688555656a3d324a576edd1c5a50c2004014b3 Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Sat, 26 Aug 2023 20:56:24 +0530 Subject: [PATCH 226/298] chat Load issue fixed (#690) * fix: fixed * fix: fixed minor issues --- .../src/app/ChatUITest/ChatViewComponent.tsx | 2 +- .../src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx | 2 +- .../src/lib/components/chat/ChatViewList/ChatViewList.tsx | 4 +++- .../src/lib/components/chat/MessageInput/MessageInput.tsx | 1 + 4 files changed, 6 insertions(+), 3 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index e90d52375..6b46cb2e3 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -17,7 +17,7 @@ const ChatViewComponentTest = () => { {/* */} - console.log("BOIIII RETURNNNSSSSS")} chatId='aee13144f79f0f2027875124fc9d7132420b0c1876061dced594ff30c2c33abc' limit={10}/> + console.log("BOIIII RETURNNNSSSSS")} chatId='0x0d73BfA82E7C4f8997b989bB44C4566FA4553776' limit={10}/> ); diff --git a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx index 00b9f4203..f5957d802 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx @@ -108,7 +108,7 @@ const MessageCard = ({ margin="5px 0" alignSelf={position ? 'end' : 'start'} justifyContent="start" - maxWidth="86%" + maxWidth="100%" minWidth="71px" position="relative" width="fit-content" diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx index e2037dc06..0ba47396f 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -168,7 +168,7 @@ export const ChatViewList: React.FC = ( await getMessagesCall(); })(); } - }, [conversationHash, pgpPrivateKey, account, env]); + }, [conversationHash, pgpPrivateKey, account, env,chatFeed]); useEffect(() => { scrollToBottom(null); @@ -260,11 +260,13 @@ export const ChatViewList: React.FC = ( } else { threadHash = messages?.lastThreadHash; } + if ( threadHash && ((account && pgpPrivateKey&& chatFeed && !chatFeed?.groupInformation) || (chatFeed && chatFeed?.groupInformation)) ) { + const chatHistory = await historyMessages({ limit: limit, threadHash, diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index fcbc76bf0..8f27b33b9 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -594,6 +594,7 @@ export const MessageInput: React.FC = ({
)} { if (event.key === 'Enter' && !event.shiftKey) { From 478308bfd32bdf47a979c793e5eee3c29b86b9dc Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 26 Aug 2023 20:59:15 +0530 Subject: [PATCH 227/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index f355f5fb0..2a2938b24 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.6...uiweb-0.0.1-alpha.7) (2023-08-26) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([45e6489](https://github.com/ethereum-push-notification-service/push-sdk/commit/45e6489eca403160d512f30fa6617c980e16a244)) + + + ## [0.0.1-alpha.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.5...uiweb-0.0.1-alpha.6) (2023-08-25) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 4857a07e4..15f0cb135 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.6", + "version": "0.0.1-alpha.7", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From c24a9e144110ad3c67decbc1364b5dd610f5f58a Mon Sep 17 00:00:00 2001 From: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Date: Mon, 28 Aug 2023 17:52:54 +0530 Subject: [PATCH 228/298] fix: fixed msg bubble width (#691) --- .../src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx index f5957d802..31139c110 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx @@ -92,6 +92,7 @@ const MessageCard = ({ justifyContent="start" gap="6px" width="fit-content" + maxWidth="70%" > {isGroup && }
@@ -108,7 +109,6 @@ const MessageCard = ({ margin="5px 0" alignSelf={position ? 'end' : 'start'} justifyContent="start" - maxWidth="100%" minWidth="71px" position="relative" width="fit-content" From 476e8641a39cff84dce49191d37b2cbe02b1c1e4 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 29 Aug 2023 08:34:58 +0530 Subject: [PATCH 229/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 10 ++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 2a2938b24..0fa60c43a 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.7...uiweb-0.0.1-alpha.8) (2023-08-29) + + +### Bug Fixes + +* fixed msg bubble width ([#691](https://github.com/ethereum-push-notification-service/push-sdk/issues/691)) ([c24a9e1](https://github.com/ethereum-push-notification-service/push-sdk/commit/c24a9e144110ad3c67decbc1364b5dd610f5f58a)) +* Merge branch 'alpha' into alpha-deployment ([a825667](https://github.com/ethereum-push-notification-service/push-sdk/commit/a825667be9380ec6e5b457f5751a8b6b6b5a6b23)) + + + ## [0.0.1-alpha.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.6...uiweb-0.0.1-alpha.7) (2023-08-26) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 15f0cb135..e640f506a 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.7", + "version": "0.0.1-alpha.8", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 7ca84a659c2a0728b2ff525e16a079b4f9464b4a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 1 Sep 2023 16:21:15 +0530 Subject: [PATCH 230/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.17?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 3f3e5fe92..f43f1acf3 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.17](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.16...restapi-1.4.17) (2023-09-01) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([7f424d5](https://github.com/ethereum-push-notification-service/push-sdk/commit/7f424d511ac854049044846e30810f773e8c89e1)) + + + ## [1.4.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.15...restapi-1.4.16) (2023-08-24) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index c04cf2647..fc4308c54 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.16", + "version": "1.4.17", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From eeefd3df013dd231d5100a14898a627f5a5071b7 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 4 Sep 2023 18:51:52 +0530 Subject: [PATCH 231/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.18?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index f43f1acf3..5e4f18e10 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.18](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.17...restapi-1.4.18) (2023-09-04) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([b8212e3](https://github.com/ethereum-push-notification-service/push-sdk/commit/b8212e3009457515fa37ae2f23d95ea891e2c771)) +* **video:** send initial message in request connect callback ([#698](https://github.com/ethereum-push-notification-service/push-sdk/issues/698)) ([e515ca7](https://github.com/ethereum-push-notification-service/push-sdk/commit/e515ca7758a31992d5b85a1af8949e438b088d3d)) + + + ## [1.4.17](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.16...restapi-1.4.17) (2023-09-01) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index fc4308c54..bbead835f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.17", + "version": "1.4.18", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 33616bcf137e570c953b5d231d4ec996c183b4b2 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 6 Sep 2023 14:26:33 +0530 Subject: [PATCH 232/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.19?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 5e4f18e10..5a02abe6d 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.19](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.18...restapi-1.4.19) (2023-09-06) + + +### Bug Fixes + +* merge main ([0dcf00f](https://github.com/ethereum-push-notification-service/push-sdk/commit/0dcf00f77e73d0ebb513adda826e8994cf6207c2)) +* Push API next set of functions ([#697](https://github.com/ethereum-push-notification-service/push-sdk/issues/697)) ([360e387](https://github.com/ethereum-push-notification-service/push-sdk/commit/360e3874e9e48cd0d4339faa1666afee7023c612)) + + + ## [1.4.18](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.17...restapi-1.4.18) (2023-09-04) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index bbead835f..a094d760f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.18", + "version": "1.4.19", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 8c4582db5ed67eb8e420f9f693eee8df033e7532 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 7 Sep 2023 20:00:02 +0530 Subject: [PATCH 233/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.33?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 364 ++++++++++++++++++++++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 365 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d0329d1d9..d80469550 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,370 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.33](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.19...restapi-0.0.1-alpha.33) (2023-09-07) + + +### Bug Fixes + +* merge alpha ([1783d45](https://github.com/ethereum-push-notification-service/push-sdk/commit/1783d45bb3ceab1cce3c6bb19dfbda38c3662a3e)) +* Merge branch 'alpha' into alpha-deployment ([84aaadf](https://github.com/ethereum-push-notification-service/push-sdk/commit/84aaadfb19e335e5806086fba2ad5e94c1bf3b7e)) +* merge main ([5f37942](https://github.com/ethereum-push-notification-service/push-sdk/commit/5f379427e8a517089758de776eab9f2409aa61f8)) +* merge main ([44e0d32](https://github.com/ethereum-push-notification-service/push-sdk/commit/44e0d324af1d4605129a5e129d3ab6481313c00c)) +* merge main ([9efdbe8](https://github.com/ethereum-push-notification-service/push-sdk/commit/9efdbe8c6f86eeb859075af493797575728cf902)) +* merge main ([93e3106](https://github.com/ethereum-push-notification-service/push-sdk/commit/93e31068bc48e9a271c376d2610e503f69499f8b)) + + + +## [0.0.1-alpha.32](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.31...restapi-0.0.1-alpha.32) (2023-08-17) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([8dd925c](https://github.com/ethereum-push-notification-service/push-sdk/commit/8dd925cd5e0a134e07735b5a3ef7382f4b1909de)) +* Read me fixes ([7c02c3a](https://github.com/ethereum-push-notification-service/push-sdk/commit/7c02c3adef593b59bde6c8dd4d23b760e99a5416)) +* Space rules ([2181074](https://github.com/ethereum-push-notification-service/push-sdk/commit/2181074811549a0c70aea189bc82a1acf1944ba1)) + + + +## [0.0.1-alpha.31](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.30...restapi-0.0.1-alpha.31) (2023-08-16) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([a4c170e](https://github.com/ethereum-push-notification-service/push-sdk/commit/a4c170edd7766c843412bd83f6ef7e5a9ab70247)) + + + +## [0.0.1-alpha.30](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.9...restapi-0.0.1-alpha.30) (2023-08-15) + + +### Bug Fixes + +* fixed subscribe and unsubscribe ([3f908a0](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f908a02ce7faee703340e17f6441f3ebe88fd58)) +* Merge branch 'alpha' into alpha-deployment ([984a80f](https://github.com/ethereum-push-notification-service/push-sdk/commit/984a80f178abc220a0243a5fce00413d4dd0aadb)) +* merge main ([f338fd4](https://github.com/ethereum-push-notification-service/push-sdk/commit/f338fd49707933c65bdcc7736cdd08d6784625ba)) +* **merged:** merged ([bb71789](https://github.com/ethereum-push-notification-service/push-sdk/commit/bb717897cec1e7d46d86be05b1d29ca9103272c5)) + + + +## [0.0.1-alpha.29](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.28...restapi-0.0.1-alpha.29) (2023-08-02) + + +### Bug Fixes + +* url correction ([26b6b73](https://github.com/ethereum-push-notification-service/push-sdk/commit/26b6b739d8b6b8a38ae10ae87270ca4d8782db51)) + + + +## [0.0.1-alpha.28](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.4...restapi-0.0.1-alpha.28) (2023-08-02) + + +### Bug Fixes + +* add: scw sig verification ([#593](https://github.com/ethereum-push-notification-service/push-sdk/issues/593)) ([6768065](https://github.com/ethereum-push-notification-service/push-sdk/commit/67680657981a847e23a4dbad6d2fd6a7bc127743)) +* Merge branch 'alpha' into alpha-deployment ([6c19940](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c19940b4d72d9443b8afd06ddc2a6f9e29582a7)) +* merged main ([c5533f8](https://github.com/ethereum-push-notification-service/push-sdk/commit/c5533f8dce7b88cb1f14aa72f83579a8e01dcf36)) + + + +## [0.0.1-alpha.27](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.3...restapi-0.0.1-alpha.27) (2023-07-24) + + +### Bug Fixes + +* merge alpha ([16a55af](https://github.com/ethereum-push-notification-service/push-sdk/commit/16a55af713da0394ab9d82e13fed6d64190b247d)) +* Merge branch 'alpha' into alpha-deployment ([6ea669a](https://github.com/ethereum-push-notification-service/push-sdk/commit/6ea669a5aa3cebe693de259c1ea28787c0407d2a)) +* signer compatibility with viem ([3df201c](https://github.com/ethereum-push-notification-service/push-sdk/commit/3df201c7474b88d270d6e868bc516f223539e74c)) + + + +## [0.0.1-alpha.26](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.2...restapi-0.0.1-alpha.26) (2023-07-21) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([3f3369a](https://github.com/ethereum-push-notification-service/push-sdk/commit/3f3369a1bda71a82cde8ef386901265a62a91a2c)) +* merge main ([c07ce16](https://github.com/ethereum-push-notification-service/push-sdk/commit/c07ce1628321dd3bae46d08e08bfc7986795bb64)) +* signer compatibility with viem and ethers ([1edea43](https://github.com/ethereum-push-notification-service/push-sdk/commit/1edea431ccf7f19cc0430deb2ce7a5c61390d99f)) +* signer compatibility with viem and ethers ([#567](https://github.com/ethereum-push-notification-service/push-sdk/issues/567)) ([c07c3fa](https://github.com/ethereum-push-notification-service/push-sdk/commit/c07c3fab76a095998b1eac830c941116ad1e9b4f)) +* space feed API path fix ([00d91b1](https://github.com/ethereum-push-notification-service/push-sdk/commit/00d91b1860525c15618f130970c9173100424a23)) +* use SpaceIFeeds ([5b7f2fc](https://github.com/ethereum-push-notification-service/push-sdk/commit/5b7f2fc2398a2203925059aa2721e855ea9f98d4)) + + + +## [0.0.1-alpha.25](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.1...restapi-0.0.1-alpha.25) (2023-07-19) + + +### Bug Fixes + +* fixed merge conflicts ([dfab492](https://github.com/ethereum-push-notification-service/push-sdk/commit/dfab492127e821219c5fd5dc08ed08a172bee31b)) +* Merge branch 'alpha' into alpha-deployment ([a71302b](https://github.com/ethereum-push-notification-service/push-sdk/commit/a71302b4a5066cb9d00ca5d14e55228c558eda85)) +* Merge branch 'main' into alpha-deployment ([fe93d43](https://github.com/ethereum-push-notification-service/push-sdk/commit/fe93d43a103d5067b16d8f7a5d01835be1d1f40a)) +* renamed spaces variables and removed some unused variables ([3519d39](https://github.com/ethereum-push-notification-service/push-sdk/commit/3519d3982be389711f48891896478b7a35a71b73)) +* space api ([064e10d](https://github.com/ethereum-push-notification-service/push-sdk/commit/064e10d9c66ab1d39f799fd64a39652862b2f074)) + + + +## [0.0.1-alpha.24](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.23...restapi-0.0.1-alpha.24) (2023-07-14) + + +### Bug Fixes + +* rename chats to spaces ([899eb21](https://github.com/ethereum-push-notification-service/push-sdk/commit/899eb212af29e3a65541686d98927e37b97927c5)) + + + +## [0.0.1-alpha.23](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.22...restapi-0.0.1-alpha.23) (2023-07-12) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([b120e30](https://github.com/ethereum-push-notification-service/push-sdk/commit/b120e302f6b9f8e360b43f80dcdd3248c1e4304b)) +* Merge branch 'alpha' into alpha-deployment ([54c5721](https://github.com/ethereum-push-notification-service/push-sdk/commit/54c57219c7f3f198a3f7578a0720895aff2d27f4)) +* Merge branch 'main' into alpha ([7b316ec](https://github.com/ethereum-push-notification-service/push-sdk/commit/7b316ec8e6f3178c02e7fce6d27884ba8ef1b4f4)) +* Merge branch 'main' into alpha ([d66202d](https://github.com/ethereum-push-notification-service/push-sdk/commit/d66202d0798b9ec731d7f5d30031b89ae29d72b4)) + + + +## [0.0.1-alpha.22](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.21...restapi-0.0.1-alpha.22) (2023-07-07) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([5c84e2f](https://github.com/ethereum-push-notification-service/push-sdk/commit/5c84e2f07667fe4e9d94561544807b11c103ac49)) +* merged maain ([942cc65](https://github.com/ethereum-push-notification-service/push-sdk/commit/942cc65a60aa043054cebb143990711fb6e2efdb)) + + + +## [0.0.1-alpha.21](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.20...restapi-0.0.1-alpha.21) (2023-07-07) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([c05d024](https://github.com/ethereum-push-notification-service/push-sdk/commit/c05d024415bb1cb9e1fe59714d7db5516d161c06)) +* merged main ([46cf04e](https://github.com/ethereum-push-notification-service/push-sdk/commit/46cf04e75c314065c77a5a77d9351d9ccc7e0a58)) +* spaces naming ([6db7fc0](https://github.com/ethereum-push-notification-service/push-sdk/commit/6db7fc09b680060f022040feb2a22aeed9c652d0)) + + + +## [0.0.1-alpha.20](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.19...restapi-0.0.1-alpha.20) (2023-07-03) + + +### Bug Fixes + +* new commit ([25f2725](https://github.com/ethereum-push-notification-service/push-sdk/commit/25f2725efb0e1017ee2a0460259b27f252471014)) + + + +## [0.0.1-alpha.19](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.9...restapi-0.0.1-alpha.19) (2023-07-03) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([a15e368](https://github.com/ethereum-push-notification-service/push-sdk/commit/a15e368241215e2e2219792afd718567d621bf2a)) +* merge main ([6998d35](https://github.com/ethereum-push-notification-service/push-sdk/commit/6998d35aa181f17a5ad8d9501943a6a867814650)) +* rename based on new convention ([0e34479](https://github.com/ethereum-push-notification-service/push-sdk/commit/0e34479b1581abd59e0f853d6547e23a0afb5e28)) + + + +## [0.0.1-alpha.18](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.8...restapi-0.0.1-alpha.18) (2023-06-20) + + +### Bug Fixes + +* add name to SpaceIFeeds ([9c22271](https://github.com/ethereum-push-notification-service/push-sdk/commit/9c222715d0f15ae912b90661f9d18d42bddc4c89)) +* Merge branch 'alpha' into alpha-deployment ([b521522](https://github.com/ethereum-push-notification-service/push-sdk/commit/b521522c3b147b789a03b2683da4b6cefac795fe)) +* Merge branch 'main' into alpha ([64de06f](https://github.com/ethereum-push-notification-service/push-sdk/commit/64de06fc3cfd4359cf0d7fb70212e775ce9e51b9)) +* merge main ([27105a2](https://github.com/ethereum-push-notification-service/push-sdk/commit/27105a247fe4bd4db78a41be06ef6a2d52fb6b21)) +* update path ([10d62b1](https://github.com/ethereum-push-notification-service/push-sdk/commit/10d62b1a017b3d0a5044a4ab33bdce183f795f51)) + + + +## [0.0.1-alpha.17](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.5...restapi-0.0.1-alpha.17) (2023-06-08) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([a9d8ff1](https://github.com/ethereum-push-notification-service/push-sdk/commit/a9d8ff18bcad950e40b966e5b4020e29b493aa28)) +* merge main ([78c020a](https://github.com/ethereum-push-notification-service/push-sdk/commit/78c020ac61decc2d3b78d3749c8ec5df7478842f)) +* **video:** fix error on repeated acceptRequest calls ([#442](https://github.com/ethereum-push-notification-service/push-sdk/issues/442)) ([f34bfa0](https://github.com/ethereum-push-notification-service/push-sdk/commit/f34bfa09cf88e812e07c0dcf7fabf792726c577f)) + + + +## [0.0.1-alpha.16](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.3...restapi-0.0.1-alpha.16) (2023-06-02) + + +### Bug Fixes + +* add spaces for functions ([#307](https://github.com/ethereum-push-notification-service/push-sdk/issues/307)) ([aea015a](https://github.com/ethereum-push-notification-service/push-sdk/commit/aea015ae478da77ebaa41a4e111ac213027b0b6a)) +* Merge branch 'alpha' into alpha-deployment ([ad6a56b](https://github.com/ethereum-push-notification-service/push-sdk/commit/ad6a56be24c326b7fb1f6eddb01b20b489eee27d)) +* merge main ([3959345](https://github.com/ethereum-push-notification-service/push-sdk/commit/39593456140e152e53f4bd7c10a19e0d8f05dfc9)) + + + +## [0.0.1-alpha.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.3.2...restapi-0.0.1-alpha.15) (2023-05-29) + + +### Bug Fixes + +* fix nft videocall ([#411](https://github.com/ethereum-push-notification-service/push-sdk/issues/411)) ([8cdb999](https://github.com/ethereum-push-notification-service/push-sdk/commit/8cdb999bc548caf67ec6fbe625253b5795a4e465)) +* Iuser structure changed ([#365](https://github.com/ethereum-push-notification-service/push-sdk/issues/365)) ([2fc6f54](https://github.com/ethereum-push-notification-service/push-sdk/commit/2fc6f549c80a65a5a6009b0c2fa9635d757bdf11)), closes [#390](https://github.com/ethereum-push-notification-service/push-sdk/issues/390) [#295](https://github.com/ethereum-push-notification-service/push-sdk/issues/295) +* Merge branch 'alpha' into alpha-deployment ([a66c9a4](https://github.com/ethereum-push-notification-service/push-sdk/commit/a66c9a4a3628700a450b8e2fb7a5f942d1d84095)) +* Merge branch 'alpha' into alpha-deployment ([f247665](https://github.com/ethereum-push-notification-service/push-sdk/commit/f2476650b650ade59721c30f6e8483e86c013cd4)) +* merged main to alpha ([067bc5d](https://github.com/ethereum-push-notification-service/push-sdk/commit/067bc5d358c5f218628a980ce23ab3b39615805f)) + + + +## [0.0.1-alpha.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.12...restapi-0.0.1-alpha.13) (2023-05-19) + + +### Bug Fixes + +* backward compatiblity fix ([fbf2463](https://github.com/ethereum-push-notification-service/push-sdk/commit/fbf246396a44513626fc1dda6e90c12d2f073ead)) +* Merge branch 'alpha' into alpha-deployment ([3b5a0f1](https://github.com/ethereum-push-notification-service/push-sdk/commit/3b5a0f160b72e775cf17031067fa7488171e1bbd)) + + + +## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.11...restapi-0.0.1-alpha.12) (2023-05-19) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([963cc02](https://github.com/ethereum-push-notification-service/push-sdk/commit/963cc02768862b6a9427519257ff9f9565f613ea)) +* **video:** fix enableAudio ([85ef733](https://github.com/ethereum-push-notification-service/push-sdk/commit/85ef733127bdfbae5c66c671ddc7700785d192c0)) + + + +## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.10...restapi-0.0.1-alpha.11) (2023-05-19) + + +### Bug Fixes + +* added enums ([f1880d8](https://github.com/ethereum-push-notification-service/push-sdk/commit/f1880d8f037fc640851af4311bd5e514de5cf3db)) +* changed additionalMeta structure ([#406](https://github.com/ethereum-push-notification-service/push-sdk/issues/406)) ([0cf573e](https://github.com/ethereum-push-notification-service/push-sdk/commit/0cf573e56165bf3164a42cbc4b41a3085801e90a)) +* fix versions ([05c8fa9](https://github.com/ethereum-push-notification-service/push-sdk/commit/05c8fa9f9286e78d706c6be53e7b8ae963105766)) +* Merge branch 'alpha' into alpha-deployment ([68f11eb](https://github.com/ethereum-push-notification-service/push-sdk/commit/68f11eb71d44423081000c00c36cb0a936558f2f)) +* Merge branch 'alpha' into alpha-deployment ([3700515](https://github.com/ethereum-push-notification-service/push-sdk/commit/3700515be010fdcab6062db0a039f7df612a7a6b)) +* Merge branch 'alpha' into alpha-deployment ([925b437](https://github.com/ethereum-push-notification-service/push-sdk/commit/925b4379aa7b7d2d061b23d5ccbc42d06829f100)) +* **sendvideonotifications:** modify additional meta acc to new std ([#407](https://github.com/ethereum-push-notification-service/push-sdk/issues/407)) ([9d2124a](https://github.com/ethereum-push-notification-service/push-sdk/commit/9d2124aa61f798a0b137636aac62397e1e52150e)) +* **types:** remove bad import ([5517200](https://github.com/ethereum-push-notification-service/push-sdk/commit/55172002a2cecb33407a3828c2debeca24e0c972)) +* **video:** remove stop audio/video logic from create function ([#404](https://github.com/ethereum-push-notification-service/push-sdk/issues/404)) ([983c896](https://github.com/ethereum-push-notification-service/push-sdk/commit/983c896a2c89463f117f5a4d8153ef95501f2124)) + + +### Reverts + +* **getverificationproof:** add wallet and env params to getVerificationProof ([#403](https://github.com/ethereum-push-notification-service/push-sdk/issues/403)) ([26f6fcb](https://github.com/ethereum-push-notification-service/push-sdk/commit/26f6fcb9b2992850cd33ea613cea13830bd48bc3)) + + + +## [0.0.1-alpha.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.9...restapi-0.0.1-alpha.10) (2023-05-17) + + +### Bug Fixes + +* added deprecated info to history ([#399](https://github.com/ethereum-push-notification-service/push-sdk/issues/399)) ([eda1a34](https://github.com/ethereum-push-notification-service/push-sdk/commit/eda1a345975141c5656891dbf919aacd2924d66b)) +* Merge branch 'alpha' into alpha-deployment ([46ebed2](https://github.com/ethereum-push-notification-service/push-sdk/commit/46ebed2b9d4b4ff0518429a091d0a37b1d3f022d)) + + + +## [0.0.1-alpha.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.8...restapi-0.0.1-alpha.9) (2023-05-16) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([469398d](https://github.com/ethereum-push-notification-service/push-sdk/commit/469398dc94df805257d6a6bb8e0707cebc5f7d8a)) +* **video:** turn off trickle while creating peer instance ([#398](https://github.com/ethereum-push-notification-service/push-sdk/issues/398)) ([ae5b38e](https://github.com/ethereum-push-notification-service/push-sdk/commit/ae5b38e702539eaf92a516b4e557c5a88de0f4c7)) + + + +## [0.0.1-alpha.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.7...restapi-0.0.1-alpha.8) (2023-05-16) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([549fd83](https://github.com/ethereum-push-notification-service/push-sdk/commit/549fd839867d84a98a10206a7f9945aeb1720e49)) +* Merge branch 'main' into alpha ([72464fd](https://github.com/ethereum-push-notification-service/push-sdk/commit/72464fd97260b612649035e3b241f946de8f9e92)) +* **video:** set trickle to true while creating peer instance ([#397](https://github.com/ethereum-push-notification-service/push-sdk/issues/397)) ([0b609be](https://github.com/ethereum-push-notification-service/push-sdk/commit/0b609bec87a6187d1e7cbf8052a2b9a36b9fcd7a)) + + + +## [0.0.1-alpha.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.6...restapi-0.0.1-alpha.7) (2023-05-15) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([37c1c8d](https://github.com/ethereum-push-notification-service/push-sdk/commit/37c1c8db579876f5835c2e5bb5e6baf073dc9208)) +* **video:** remove status change upon connect in request ([#394](https://github.com/ethereum-push-notification-service/push-sdk/issues/394)) ([7441ef0](https://github.com/ethereum-push-notification-service/push-sdk/commit/7441ef0fb2c9ed39e12a4f1819ade0ee7e0d6b10)) + + + +## [0.0.1-alpha.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.5...restapi-0.0.1-alpha.6) (2023-05-14) + + +### Bug Fixes + +* add video call retry logic upon error & doc: add video call in restapi/readme ([#391](https://github.com/ethereum-push-notification-service/push-sdk/issues/391)) ([9c8c86b](https://github.com/ethereum-push-notification-service/push-sdk/commit/9c8c86b35d1cb0300d0170e87931dd31a15f9342)) + + + +## [0.0.1-alpha.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.4...restapi-0.0.1-alpha.5) (2023-05-14) + + + +## [0.0.1-alpha.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.15...restapi-0.0.1-alpha.4) (2023-05-12) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([a1a8666](https://github.com/ethereum-push-notification-service/push-sdk/commit/a1a86661b1823c84328ec90ac9aafc6c57f574f3)) +* Merge branch 'main' into alpha ([5fc51db](https://github.com/ethereum-push-notification-service/push-sdk/commit/5fc51db1a336203048b4b42a5384cb37cf79c509)) +* **video:** separate react state from video class instance variable data ([#389](https://github.com/ethereum-push-notification-service/push-sdk/issues/389)) ([83bf445](https://github.com/ethereum-push-notification-service/push-sdk/commit/83bf4457332b127bf9e41a2f4c93fb851367724d)) + + + +## [0.0.1-alpha.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.2...restapi-0.0.1-alpha.3) (2023-05-11) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([e19b9b0](https://github.com/ethereum-push-notification-service/push-sdk/commit/e19b9b05b60174e68dc7bfe0e2349e20d8af2604)) +* Replace arrow functions with normal functions in the Video class ([#380](https://github.com/ethereum-push-notification-service/push-sdk/issues/380)) ([b90435a](https://github.com/ethereum-push-notification-service/push-sdk/commit/b90435a953b908899c92eb5b4d4c3677e47b1552)) + + + +## [0.0.1-alpha.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.2.13...restapi-0.0.1-alpha.2) (2023-05-10) + + +### Bug Fixes + +* merge alpha ([7f0642c](https://github.com/ethereum-push-notification-service/push-sdk/commit/7f0642c4c417390a5bb52d36d9493bd5b767b634)) +* merge main ([a5fdfe1](https://github.com/ethereum-push-notification-service/push-sdk/commit/a5fdfe10f18c857c32aa5fe5c5dd95db0f268cd1)) +* merge main to alpha ([4866a37](https://github.com/ethereum-push-notification-service/push-sdk/commit/4866a37ed0502c0d16ac91f088d3bb5e597b652a)) + + + +## [0.0.1-alpha.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.0...restapi-0.0.1-alpha.1) (2023-05-08) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([1223c60](https://github.com/ethereum-push-notification-service/push-sdk/commit/1223c60b0f179b26537992a776155aefffd7b5ef)) +* sendVideoNotification and end video call logic ([#367](https://github.com/ethereum-push-notification-service/push-sdk/issues/367)) ([d39c703](https://github.com/ethereum-push-notification-service/push-sdk/commit/d39c703bcda6d332717a5e9b1af6ab574be9d991)) + + + +## [0.0.1-alpha.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-beta.2...restapi-0.0.1-alpha.0) (2023-05-04) + + +### Bug Fixes + +* added pagination and deprecation tag ([#346](https://github.com/ethereum-push-notification-service/push-sdk/issues/346)) ([69763b8](https://github.com/ethereum-push-notification-service/push-sdk/commit/69763b8da2cf3e92bb85908e4f46a72b650c9dba)) +* changed Definitions for auth.update and upgrade ([#351](https://github.com/ethereum-push-notification-service/push-sdk/issues/351)) ([31daee3](https://github.com/ethereum-push-notification-service/push-sdk/commit/31daee3a5aa913705d1dec8210c0412cd89c94c9)) +* eip191v2 signatures for create and auth.update ([#353](https://github.com/ethereum-push-notification-service/push-sdk/issues/353)) ([008e6d0](https://github.com/ethereum-push-notification-service/push-sdk/commit/008e6d08d75fdacf19f1674cc2b8bd82091fa31f)) +* Merge branch 'main' into alpha ([477bae4](https://github.com/ethereum-push-notification-service/push-sdk/commit/477bae4fdc4e86374615f0f67c41c570a567b9fe)) + + + ## [0.0.1-alpha.32](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.31...restapi-0.0.1-alpha.32) (2023-08-17) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 91e9d8940..9e96e0e89 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.32", + "version": "0.0.1-alpha.33", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 92e8283eba87749fa17600f4b04ed63afd2912da Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 7 Sep 2023 20:00:28 +0530 Subject: [PATCH 234/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.33?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/src/lib/chat/helpers/payloadHelper.ts | 8 ++++---- packages/restapi/src/lib/pushapi/PushAPI.ts | 4 ++-- packages/restapi/src/lib/types/index.ts | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index 53319d91a..eeb318dff 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -258,7 +258,7 @@ export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { if (groupDto.rules) { spaceDto.rules = { - spaceAccess: groupDto.rules.groupAccess, + entry: groupDto.rules.entry, }; } @@ -267,20 +267,20 @@ export const groupDtoToSpaceDto = (groupDto: GroupDTO): SpaceDTO => { export const convertSpaceRulesToRules = (spaceRules: SpaceRules): Rules => { return { - groupAccess: spaceRules.spaceAccess, + entry: spaceRules.entry, chat: undefined, }; }; export const convertRulesToSpaceRules = (rules: Rules): SpaceRules => { return { - spaceAccess: rules.groupAccess, + entry: rules.entry, }; }; export const groupAccessToSpaceAccess = (group: GroupAccess): SpaceAccess => { const spaceAccess: SpaceAccess = { - spaceAccess: group.groupAccess, + entry: group.groupAccess, }; // If rules are present in the groupAccess, map them to the spaceAccess diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index a41d25b80..13e5f3a98 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -363,8 +363,8 @@ export class PushAPI { groupImage: options?.image, admins: options?.admins ? options.admins : [], rules: { - groupAccess: options?.rules?.entry, - chatAccess: options?.rules?.chat, + entry: options?.rules?.entry, + chat: options?.rules?.chat, }, isPublic: !options?.private, signer: this.signer, diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index bd8d6744f..b197b515b 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -336,7 +336,7 @@ export type Condition = ConditionBase & { }; export interface Rules { - groupAccess?: { + entry?: { conditions: Array; }; chat?: { @@ -345,7 +345,7 @@ export interface Rules { } export interface SpaceRules { - spaceAccess?: { + entry?: { conditions: Array; }; } @@ -357,7 +357,7 @@ export interface GroupAccess { } export interface SpaceAccess { - spaceAccess: boolean; + entry: boolean; rules?: SpaceRules; } From aff911b5abe67f37f4802c0306dc4b2d0edee036 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 8 Sep 2023 15:05:26 +0530 Subject: [PATCH 235/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 152 ++++++++++++++++++++++++++++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 153 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 0fa60c43a..6801607ed 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,158 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.8...uiweb-0.0.1-alpha.9) (2023-09-08) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([699706b](https://github.com/ethereum-push-notification-service/push-sdk/commit/699706bc0c2b05eebb11624f7b16411d4111a5cb)) +* merge main ([5f37942](https://github.com/ethereum-push-notification-service/push-sdk/commit/5f379427e8a517089758de776eab9f2409aa61f8)) + + + +## [1.1.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.2...uiweb-1.1.13) (2023-08-24) + + +### Bug Fixes + +* dummy change ([cbfbec0](https://github.com/ethereum-push-notification-service/push-sdk/commit/cbfbec0b17a460361b4b5ecef84aaa45b06ab7a2)) + + + +## [1.1.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.11...uiweb-1.1.12) (2023-08-23) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([64278ec](https://github.com/ethereum-push-notification-service/push-sdk/commit/64278eccd6fd51d02b123ec00e1d36fa94a23608)) + + + +## [1.1.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.10...uiweb-1.1.11) (2023-08-18) + + +### Bug Fixes + +* merge main ([f53a5e2](https://github.com/ethereum-push-notification-service/push-sdk/commit/f53a5e279e3780566b4e2a9242b3555ef50fb4a6)) + + + +## [1.1.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.1...uiweb-1.1.10) (2023-08-10) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([e504703](https://github.com/ethereum-push-notification-service/push-sdk/commit/e5047039c6ec668c0a2ad5950d7a5ba227c4f50a)) + + + +## [1.1.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.0...uiweb-1.1.9) (2023-08-10) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([843cd01](https://github.com/ethereum-push-notification-service/push-sdk/commit/843cd0169a270bbab69922021edf312616de3802)) + + + +## [1.1.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.7...uiweb-1.1.8) (2023-08-04) + + +### Bug Fixes + +* merge main ([b9e4440](https://github.com/ethereum-push-notification-service/push-sdk/commit/b9e44408fa4c97720b12217486e8d13ef3caeb00)) + + + +## [1.1.7](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.6...uiweb-1.1.7) (2023-07-31) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([9755baf](https://github.com/ethereum-push-notification-service/push-sdk/commit/9755baf3d4bcd3ab3fd365fad9d8fb7623fda58f)) + + + +## [1.1.6](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.5...uiweb-1.1.6) (2023-07-28) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([e33017a](https://github.com/ethereum-push-notification-service/push-sdk/commit/e33017afb2d4e9361d5df47e0f7e726ecdffbc32)) + + + +## [1.1.5](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.4...uiweb-1.1.5) (2023-07-27) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([90f51b9](https://github.com/ethereum-push-notification-service/push-sdk/commit/90f51b9009096ae8fcb1599d6fa8fe5cb74bbd5a)) +* merge main ([1bdc675](https://github.com/ethereum-push-notification-service/push-sdk/commit/1bdc6754bc67b489ca9e14597aa6c5d6197580e7)) + + + +## [1.1.4](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.3...uiweb-1.1.4) (2023-07-20) + + +### Bug Fixes + +* merge main ([24784e9](https://github.com/ethereum-push-notification-service/push-sdk/commit/24784e9ceca8f3757481f3be72efd0ca1ff3fba8)) + + + +## [1.1.3](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.2...uiweb-1.1.3) (2023-07-20) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([9f77f39](https://github.com/ethereum-push-notification-service/push-sdk/commit/9f77f391b26111006891c10a3cc8eab06e26f14f)) + + + +## [1.1.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.1...uiweb-1.1.2) (2023-07-18) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([8bc14a7](https://github.com/ethereum-push-notification-service/push-sdk/commit/8bc14a711f308fada706fb8fc228136e4ea24544)) + + + +## [1.1.1](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.0...uiweb-1.1.1) (2023-07-17) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([2e2c904](https://github.com/ethereum-push-notification-service/push-sdk/commit/2e2c904040260726d5c5087aed6e33d0d722a0f4)) + + + +# [1.1.0](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.2...uiweb-1.1.0) (2023-07-14) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([fc7a9dc](https://github.com/ethereum-push-notification-service/push-sdk/commit/fc7a9dc64b4bcfdaa96aed70344b0ce95a1e0a6f)) +* Merge branch 'main' into deployment ([89b72a7](https://github.com/ethereum-push-notification-service/push-sdk/commit/89b72a7898af285c35fa03c6fb73708112f5d94c)) +* Merge branch 'main' into deployment ([1d52d6b](https://github.com/ethereum-push-notification-service/push-sdk/commit/1d52d6ba5aaadd70d7ccfd3904100586ad74d0f0)) +* merge main ([b58d9d5](https://github.com/ethereum-push-notification-service/push-sdk/commit/b58d9d53bd91fa33200a854170fe7e3facff4371)) + + + +## [1.0.2](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.0.1...uiweb-1.0.2) (2023-05-13) + + +### Bug Fixes + +* merge main ([26377c3](https://github.com/ethereum-push-notification-service/push-sdk/commit/26377c322ad01737e40244f6a815308c3c003aca)) +* socket lib update ([1301f99](https://github.com/ethereum-push-notification-service/push-sdk/commit/1301f999fe37b8e801a3d3e24aa45cf012db158a)) +* update package json ([6c321c7](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c321c760055fa9aaebf1ee5f693bbbad16fb9c8)) +* updated socket version ([5052b6a](https://github.com/ethereum-push-notification-service/push-sdk/commit/5052b6ab721a942dcb7560bfe875296fa2d6a992)) + + + ## [0.0.1-alpha.8](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.7...uiweb-0.0.1-alpha.8) (2023-08-29) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index e640f506a..6aca233b5 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.8", + "version": "0.0.1-alpha.9", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 6742caf4d14f7edabbd27f999733c7b819af033a Mon Sep 17 00:00:00 2001 From: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Date: Sat, 9 Sep 2023 21:01:44 +0530 Subject: [PATCH 236/298] Onboarding blocknative (#702) * fix: added reusable folder * fix: fixed theme for modal * fix: removed reusables from export * fix: fixed fallback for message input * feat: replaced rainbowkit with blocknative * fix: removed unused code --------- Co-authored-by: Monalisha Mishra --- .../src/app/ChatUITest/ChatViewComponent.tsx | 7 +- .../src/app/ChatUITest/ChatViewListTest.tsx | 23 +- packages/uiweb/package.json | 6 +- .../ChatViewComponent/ChatViewComponent.tsx | 57 +- .../chat/ConnectButton/ConnectButton.tsx | 58 +- .../components/chat/ConnectButton/index.tsx | 136 +- .../chat/MessageInput/MessageInput.tsx | 2 +- .../chat/reusables/ChatSearchInput.tsx | 189 ++ .../lib/components/chat/reusables/index.ts | 1 + .../src/lib/components/chat/theme/index.ts | 53 + packages/uiweb/src/lib/config/constants.ts | 2 + packages/uiweb/yarn.lock | 1664 ++++++++++++++++- 12 files changed, 2061 insertions(+), 137 deletions(-) create mode 100644 packages/uiweb/src/lib/components/chat/reusables/ChatSearchInput.tsx create mode 100644 packages/uiweb/src/lib/components/chat/reusables/index.ts diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 6b46cb2e3..5b26347a3 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -13,11 +13,8 @@ const ChatViewComponentTest = () => { return (

Chat UI Test page

- - {/* */} - - - console.log("BOIIII RETURNNNSSSSS")} chatId='0x0d73BfA82E7C4f8997b989bB44C4566FA4553776' limit={10}/> + + console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} />
); diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx index ea12b0819..69a29c15c 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewListTest.tsx @@ -3,29 +3,32 @@ import styled from 'styled-components'; import * as PUSHAPI from '@pushprotocol/restapi'; import { Link } from 'react-router-dom'; import { Section } from '../components/StyledComponents'; -import { ChatViewList } from '@pushprotocol/uiweb'; +import { ChatViewList } from '@pushprotocol/uiweb'; import { EnvContext, Web3Context } from '../context'; import { usePushChatSocket } from '@pushprotocol/uiweb'; import { MessageInput } from '@pushprotocol/uiweb'; + const ChatViewListTest = () => { - const { account, pgpPrivateKey } = useContext(Web3Context) + // const { account, pgpPrivateKey } = useContext(Web3Context) - const { env } = useContext(EnvContext); + // const { env } = useContext(EnvContext); - usePushChatSocket(); + // usePushChatSocket(); + + return (

Chat UI Test page

{/* */} - - - + + + - + {/* */}
); }; @@ -33,7 +36,9 @@ const ChatViewListTest = () => { export default ChatViewListTest; -const ChatViewListCard = styled(Section)` +const ChatViewListCard = styled.div` height:40vh; background:black; +overflow: auto; +overflow-x: hidden; `; \ No newline at end of file diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index acb8160ac..2060761f2 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -9,6 +9,9 @@ "@pushprotocol/socket": "^0.5.0", "@rainbow-me/rainbowkit": "^1.0.8", "@unstoppabledomains/resolution": "^8.5.0", + "@web3-onboard/injected-wallets": "^2.10.5", + "@web3-onboard/react": "^2.8.11", + "@web3-onboard/walletconnect": "^2.4.6", "@web3-react/injected-connector": "^6.0.7", "date-fns": "^2.28.0", "emoji-picker-react": "^4.4.9", @@ -19,7 +22,8 @@ "react-icons": "^4.10.1", "react-toastify": "^9.1.3", "react-twitter-embed": "^4.0.4", - "wagmi": "^1.3.10" + "wagmi": "^1.3.10", + "ethers": "^5.6.8" }, "peerDependencies": { "@pushprotocol/restapi": "^1.2.15", diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx index 407ef477f..73db94254 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -1,7 +1,7 @@ -import React, { useContext} from 'react'; +import React, { useContext } from 'react'; import { IChatTheme, IChatViewComponentProps } from '../exportedTypes'; -import { Section, } from '../../reusables'; +import { Section, Span } from '../../reusables'; import { ChatViewList } from '../ChatViewList'; import { chatLimit, device } from '../../../config'; @@ -12,9 +12,6 @@ import { ChatProfile } from '../ChatProfile'; import styled from 'styled-components'; import useMediaQuery from '../../../hooks/useMediaQuery'; - - - /** * @interface IThemeProps * this interface is used for defining the props for styled components @@ -23,7 +20,6 @@ interface IThemeProps { theme?: IChatTheme; } - export const ChatViewComponent: React.FC = ( options: IChatViewComponentProps ) => { @@ -41,17 +37,14 @@ export const ChatViewComponent: React.FC = ( onClick, } = options || {}; - const {env } = useChatData(); + const { env, signer, account, pgpPrivateKey } = useChatData(); - // const [conversationHash, setConversationHash] = useState(); const theme = useContext(ThemeContext); const isMobile = useMediaQuery(device.mobileL); - - return ( = ( padding="13px" theme={theme} > - - {chatProfile && } + {chatProfile && }
- - - {chatId && chatViewList && } - + {chatId && chatViewList && ( + + )}
- {/* )} */} - - {messageInput && ( + {(!signer && !(!!account && !!pgpPrivateKey) && !isConnected) && (
- + + You need to either pass signer or isConnected to send + messages{' '} +
)} + {(messageInput && (!!signer || (!!account && !!pgpPrivateKey) || isConnected )) && ( +
+ +
+ )} +
); }; //styles const Conatiner = styled(Section)` -border:${(props) => props.theme.border?.chatViewComponent}; -backdrop-filter:${(props) => props.theme.backdropFilter}; -box-sizing:border-box; + border: ${(props) => props.theme.border?.chatViewComponent}; + backdrop-filter: ${(props) => props.theme.backdropFilter}; + box-sizing: border-box; `; diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx index cbdd7edb7..b88886b8b 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx @@ -2,16 +2,15 @@ import styled from 'styled-components'; import { IChatTheme } from '../theme'; import { useChatData } from '../../../hooks'; import * as PushAPI from '@pushprotocol/restapi'; -import { useContext, useEffect } from 'react'; +import { useContext, useEffect, useState } from 'react'; import { ConnectButton } from '@rainbow-me/rainbowkit'; - +import { init, useConnectWallet } from "@web3-onboard/react"; +import injectedModule from "@web3-onboard/injected-wallets"; +import { Signer, ethers } from 'ethers'; import './index.css'; - -import { useAccount } from 'wagmi'; - -import { useWalletClient } from 'wagmi'; import { ThemeContext } from '../theme/ThemeProvider'; import { device } from '../../../config'; +import { getAddressFromSigner } from '../../../helpers'; /** * @interface IThemeProps @@ -22,6 +21,8 @@ interface IThemeProps { } export const ConnectButtonSub = () => { + const [{ wallet, connecting }, connect, disconnect] = useConnectWallet(); + const { signer, pgpPrivateKey, @@ -31,16 +32,31 @@ export const ConnectButtonSub = () => { setAccount, setSigner, } = useChatData(); - const { address } = useAccount(); - const { data: walletClient } = useWalletClient(); const theme = useContext(ThemeContext); + const newFunc = () => { + console.log("wallet getting called") + if (wallet) { + (async () => { + console.log("Not sure what's happening lol") + const ethersProvider = new ethers.providers.Web3Provider(wallet.provider, 'any') + const signer = ethersProvider.getSigner() + const newAdd = await getAddressFromSigner(signer) + console.log(newAdd, "newAdd") + setSigner(signer) + setAccount(newAdd); + })() + } else if (!wallet) { + setAccount('') + setSigner(undefined) + setPgpPrivateKey(null) + } + } + useEffect(() => { - (async () => { - if (!account) setAccount(address as string); - if (!signer) setSigner(walletClient as PushAPI.SignerType); - })(); - }, [address, walletClient]); + newFunc() + }, [wallet]) + useEffect(() => { (async () => { @@ -76,7 +92,7 @@ export const ConnectButtonSub = () => { }; return !signer ? ( - + ) : ( <> @@ -89,10 +105,22 @@ const ConnectButtonDiv = styled.div` button{ background: ${(props) => `${props.theme.backgroundColor.buttonBackground}!important`}; - color: ${(props) => `${props.theme.backgroundColor.buttonText}!important`}; + // color: ${(props) => `${props.theme.backgroundColor.buttonText}!important`}; + color: #fff; text-align:center; + font-size: 1em; + border-radius: 10px; + padding: 10px 20px; + outline: none; + border: none; + cursor: pointer; + font-weight: 600; } + button:hover{ + scale: 1.05; + transition: 0.3s; + } @media ${device.mobileL} { font-size: 12px; } diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx index 9e4ee135a..3465bf8ba 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx @@ -1,27 +1,13 @@ -import styled from 'styled-components'; import { IChatTheme } from '../theme'; -import { useChatData } from '../../../hooks'; import { ConnectButtonSub } from './ConnectButton'; +import { InfuraAPIKey } from '../../../config'; +import { Web3OnboardProvider } from '@web3-onboard/react'; +import injectedModule from '@web3-onboard/injected-wallets'; +import walletConnectModule from '@web3-onboard/walletconnect' +import init from '@web3-onboard/core'; +import { ethers } from 'ethers'; -import { getDefaultWallets, RainbowKitProvider } from '@rainbow-me/rainbowkit'; -import { configureChains, createConfig, WagmiConfig } from 'wagmi'; -import { - mainnet, - polygon, - optimism, - arbitrum, - zora, - goerli, - polygonMumbai, - optimismGoerli, - arbitrumGoerli, - zoraTestnet, -} from 'wagmi/chains'; -import { alchemyProvider } from 'wagmi/providers/alchemy'; -import { publicProvider } from 'wagmi/providers/public'; -import { ALCHEMY_API_KEY, RAINBOW_APP_NAME, RAINBOW_PROJECT_ID } from '../../../config'; -import { useWalletClient } from 'wagmi'; /** * @interface IThemeProps @@ -31,45 +17,83 @@ interface IThemeProps { theme?: IChatTheme; } -export const ConnectButtonComp = () => { - const { chains, publicClient } = configureChains( - [ - mainnet, - polygon, - optimism, - arbitrum, - zora, - goerli, - polygonMumbai, - optimismGoerli, - arbitrumGoerli, - zoraTestnet, - ], - [alchemyProvider({ apiKey: ALCHEMY_API_KEY }), publicProvider()] - ); - const {signer} = useChatData() +const wcv2InitOptions = { + projectId: '64a44a0fb537407bfe97d24330e4109c', + requiredChains: [1, 56] +} - //for walletConnect - const { connectors } = getDefaultWallets({ - appName: RAINBOW_APP_NAME, - projectId: RAINBOW_PROJECT_ID, - chains, - }); +const walletConnect = walletConnectModule(wcv2InitOptions) +const chains = [ + { + id: '0x1', + token: 'ETH', + label: 'Ethereum Mainnet', + rpcUrl: `https://mainnet.infura.io/v3/${InfuraAPIKey}` + }, + { + id: '0x5', + token: 'ETH', + label: 'Goerli', + rpcUrl: `https://goerli.infura.io/v3/${InfuraAPIKey}` + }, + { + id: '0x13881', + token: 'MATIC', + label: 'Polygon - Mumbai', + rpcUrl: 'https://matic-mumbai.chainstacklabs.com' + }, + { + id: '0x38', + token: 'BNB', + label: 'Binance', + rpcUrl: 'https://bsc-dataseed.binance.org/' + }, + { + id: '0xA', + token: 'OETH', + label: 'Optimism', + rpcUrl: 'https://mainnet.optimism.io' + }, + { + id: '0xA4B1', + token: 'ARB-ETH', + label: 'Arbitrum', + rpcUrl: 'https://rpc.ankr.com/arbitrum' + } +] +const wallets = [injectedModule(), walletConnect] - const wagmiConfig = createConfig({ - autoConnect: true, - connectors, - publicClient, - }); +const appMetadata = { + name: 'Push Protocol', + icon: 'https://files.slack.com/files-pri/T011WQBLH39-F05QWQA0MSR/pushlogoblocknative.png', + description: 'Example showcasing how to connect a wallet.', + recommendedInjectedWallets: [ + { name: 'MetaMask', url: 'https://metamask.io' }, + ] +} +const web3OnBoard = init({ + wallets, + chains, + appMetadata, + accountCenter: { + desktop: { + enabled: false + }, + mobile: { + enabled: false + } + }, + connect: { + autoConnectLastWallet: true, + } +}) + +export const ConnectButtonComp = ({ pageProps }: any) => { return ( - - - - - + + + ); -}; - -//styles +}; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 8f27b33b9..3b5245157 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -363,7 +363,7 @@ export const MessageInput: React.FC = ({ return ( !Object.keys(chatFeed || {}).length? <> - {!pgpPrivateKey && isConnected && ( + {(!pgpPrivateKey && (isConnected || !!signer)) && ( void; + placeholder: string; + customStyle?: any; +}; + +export const ChatSearchInput: React.FC = ({ + handleSearch, + clearInput, + customStyle = null, + placeholder, +}) => { + const theme = useContext(ThemeContext); + const [searchedText, setSearchedText] = useState(''); + const [loading, setLoading] = useState(false); + const onChangeSearchText = (val: string) => { + setSearchedText(val); + }; + + React.useEffect(() => { + setLoading(true); + const getData = setTimeout(() => { + onSearch(); + setLoading(false); + }, 2000); + return () => clearTimeout(getData); + }, [searchedText]); + + const onSearch = () => { + if (searchedText.trim() !== '') { + handleSearch({ searchedText }); + } else { + clearInput(); + } + }; +console.log(theme.border?.searchInput) + return ( + + + onChangeSearchText(e.target.value)} + placeholder={placeholder} + onKeyDown={(event) => { + if (event.key === 'Enter') { + onSearch(); + } + }} + /> + + {!loading && !searchedText && ( +
onSearch()} + > + +
+ )} + {!loading && searchedText && ( +
{ + setSearchedText(''); + clearInput(); + }} + width="17.49px" + height="17.49px" + > + +
+ )} + {loading && } +
+
+
+ ); +}; + +//styles +const Container = styled(Section)` + border-radius: 4px; +`; + +const InputSection = styled(Section)` + border: ${(props) => + props.customStyle + ? props.customStyle.border + : props.theme.border?.searchInput}; + + &:focus-within { + outline: none; + background-image: linear-gradient( + #F4F5FA, + #F4F5FA + ), + linear-gradient( + to right, + rgba(182, 160, 245, 1), + rgba(244, 110, 246, 1), + rgba(255, 222, 211, 1), + rgba(255, 207, 197, 1) + ); + background-origin: border; + border: 1px solid transparent !important; + background-clip: padding-box, border-box; + } + +`; + +const Input = styled.input` + border: none; + background: ${(props) => + props.customStyle + ? props.customStyle.background + : props.theme.backgroundColor?.searchInputBackground}; + width: 100%; + flex: 1; + margin-left: 10px; + font-style: normal; + color: ${(props) => + props.customStyle + ? props.customStyle.color + : props.theme.textColor.searchInputText}; + font-weight: ${(props) => + props.customStyle + ? props.customStyle.fontWeight + : props.theme.fontWeight.searchInputText}; + font-size: ${(props) => + props.customStyle + ? props.customStyle.fontSize + : props.theme.fontSize.searchInputText}; + line-height: 24px; + &:focus { + outline: none; + background-origin: border; + background-clip: padding-box, border-box; + } + &::placeholder { + color: ${(props) => + props.customStyle + ? props.customStyle.placeholderColor + : props.theme.textColor.searchPlaceholderText}; + } + +`; + +//theme diff --git a/packages/uiweb/src/lib/components/chat/reusables/index.ts b/packages/uiweb/src/lib/components/chat/reusables/index.ts new file mode 100644 index 000000000..706a1c4bc --- /dev/null +++ b/packages/uiweb/src/lib/components/chat/reusables/index.ts @@ -0,0 +1 @@ +export * from './ChatSearchInput'; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/theme/index.ts b/packages/uiweb/src/lib/components/chat/theme/index.ts index 0f6e78dba..effd88077 100644 --- a/packages/uiweb/src/lib/components/chat/theme/index.ts +++ b/packages/uiweb/src/lib/components/chat/theme/index.ts @@ -8,11 +8,17 @@ interface IBorder { chatViewComponent?: string; chatProfile?: string; messageInput?: string; + searchInput?:string; + modal?:string; + modalInnerComponents?:string; } interface IBorderRadius { chatViewComponent?: string; chatProfile?: string; messageInput?: string; + searchInput?:string; + modal?:string; + modalInnerComponents?:string; } interface IBackgroundColor { chatViewComponentBackground?: string; @@ -22,6 +28,10 @@ interface IBackgroundColor { chatReceivedBubbleBackground?: string; encryptionMessageBackground?: string; buttonBackground?: string; + searchInputBackground?:string; + modalBackground?:string; + modalInputBackground?:string; + modalHoverBackground?:string; } interface ITextColor { @@ -35,6 +45,10 @@ interface ITextColor { chatReceivedBubbleAddressText?: string; chatReceivedBubbleTimestampText?: string; chatSentBubbleTimestampText?: string; + searchInputText?:string; + searchPlaceholderText?:string; + modalHeadingText?:string; + modalSubHeadingText?:string; } interface IFont { chatProfileText?: string; @@ -46,6 +60,8 @@ interface IFont { chatReceivedBubbleAddressText?: string; chatReceivedBubbleTimestampText?: string; chatSentBubbleTimestampText?: string; + searchInputText?:string; + searchPlaceholderText?:string; } interface IFontWeight { chatProfileText?: string; @@ -57,6 +73,8 @@ interface IFontWeight { chatReceivedBubbleAddressText?: string; chatReceivedBubbleTimestampText?: string; chatSentBubbleTimestampText?: string; + searchInputText?:string; + searchPlaceholderText?:string; } interface IIconColor { emoji?: string; @@ -116,6 +134,9 @@ export const lightChatTheme: IChatTheme = { chatViewComponent: '24px', chatProfile: '32px', messageInput: '13px', + searchInput: '99px', + modal: '16px', + modalInnerComponents:'12px' }, backgroundColor: { @@ -127,6 +148,10 @@ export const lightChatTheme: IChatTheme = { chatReceivedBubbleBackground: '#fff', encryptionMessageBackground: '#fff', buttonBackground: 'rgb(202, 89, 155)', + searchInputBackground: 'rgb(244, 245, 250)', + modalBackground:'#fff', + modalInputBackground:'transparent', + modalHoverBackground:'rgb(244, 245, 250)' }, fontSize: { @@ -139,6 +164,8 @@ export const lightChatTheme: IChatTheme = { chatReceivedBubbleAddressText: '16px', chatReceivedBubbleTimestampText: '12px', chatSentBubbleTimestampText: '12px', + searchInputText:'16px', + searchPlaceholderText:'16px' }, fontWeight: { @@ -151,6 +178,8 @@ export const lightChatTheme: IChatTheme = { chatReceivedBubbleAddressText: '300', chatReceivedBubbleTimestampText: '400', chatSentBubbleTimestampText: '400', + searchInputText:'400', + searchPlaceholderText:'400' }, fontFamily: 'inherit', @@ -159,6 +188,9 @@ export const lightChatTheme: IChatTheme = { chatViewComponent: 'none', chatProfile: 'none', messageInput: 'none', + searchInput:'1px solid transparent', + modal:'1px solid rgb(229, 232, 246)', + modalInnerComponents:'1px solid rgb(194, 203, 219)' }, iconColor: { @@ -178,6 +210,10 @@ export const lightChatTheme: IChatTheme = { chatReceivedBubbleAddressText: '#000', chatReceivedBubbleTimestampText: '#000', chatSentBubbleTimestampText: '#fff', + searchInputText:'#000', + searchPlaceholderText:'rgb(101, 119, 149)', + modalHeadingText:'#000', + modalSubHeadingText:'rgb(101, 119, 149)' }, backdropFilter: 'none', spinnerColor: 'rgb(202, 89, 155)', @@ -217,6 +253,9 @@ export const darkChatTheme: IChatTheme = { chatViewComponent: '24px', chatProfile: '32px', messageInput: '13px', + searchInput: '99px', + modal: '16px', + modalInnerComponents:'12px' }, backgroundColor: { @@ -227,6 +266,9 @@ export const darkChatTheme: IChatTheme = { chatReceivedBubbleBackground: 'rgb(64, 70, 80);', encryptionMessageBackground: 'rgb(64, 70, 80);', buttonBackground: 'rgb(202, 89, 155)', + modalBackground:'rgb(47, 49, 55)', + modalInputBackground:'rgb(40, 42, 46)', + modalHoverBackground:'rgb(64, 70, 80)' }, fontSize: { @@ -239,6 +281,8 @@ export const darkChatTheme: IChatTheme = { chatReceivedBubbleAddressText: '16px', chatReceivedBubbleTimestampText: '12px', chatSentBubbleTimestampText: '12px', + searchInputText:'16px', + searchPlaceholderText:'16px' }, fontWeight: { @@ -251,6 +295,8 @@ export const darkChatTheme: IChatTheme = { chatReceivedBubbleAddressText: '300', chatReceivedBubbleTimestampText: '400', chatSentBubbleTimestampText: '400', + searchInputText:'400', + searchPlaceholderText:'400' }, fontFamily: 'inherit', @@ -259,6 +305,9 @@ export const darkChatTheme: IChatTheme = { chatViewComponent: 'none', chatProfile: 'none', messageInput: 'none', + searchInput:'1px solid transparent', + modal:'1px solid rgb(74, 79, 103)', + modalInnerComponents:'1px solid rgb(74, 79, 103)' }, iconColor: { @@ -278,6 +327,10 @@ export const darkChatTheme: IChatTheme = { chatReceivedBubbleAddressText: 'rgb(182, 188, 214)', chatReceivedBubbleTimestampText: 'rgb(182, 188, 214)', chatSentBubbleTimestampText: '#fff', + searchInputText:'#fff', + searchPlaceholderText:'rgb(101, 119, 149)', + modalHeadingText:'#fff', + modalSubHeadingText:'rgb(182, 188, 214)' }, backdropFilter: 'none', spinnerColor: 'rgb(202, 89, 155)', diff --git a/packages/uiweb/src/lib/config/constants.ts b/packages/uiweb/src/lib/config/constants.ts index bc6c35ab0..068ca243b 100644 --- a/packages/uiweb/src/lib/config/constants.ts +++ b/packages/uiweb/src/lib/config/constants.ts @@ -73,6 +73,8 @@ export const allowedNetworks = { ] } +export const blockNativeApikey = 'f55f3a76-8510-4af8-9833-b7f85255de83' + export const InfuraAPIKey = '150f25623ae64d08ab7ec7dd0c6b6ee9'; export const PUBLIC_GOOGLE_TOKEN = 'AIzaSyBhUBnCia6zpxY7KcqjghRS1IphinAvKXs'; diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index 47ea13878..62ee7bdc6 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -49,7 +49,132 @@ resolved "https://registry.yarnpkg.com/@emotion/hash/-/hash-0.8.0.tgz#bbbff68978fefdbe68ccb533bc8cbe1d1afb5413" integrity sha512-kBJtf7PH6aWwZ6fka3zQ0p6SBYzx4fl1LoZXE2RrnYST9Xljm7WfKJrU4g/Xr3Beg72MLrp1AWNUmuYJTL7Cow== -"@ethersproject/abi@^5.0.1": +"@esbuild/android-arm64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.19.2.tgz#bc35990f412a749e948b792825eef7df0ce0e073" + integrity sha512-lsB65vAbe90I/Qe10OjkmrdxSX4UJDjosDgb8sZUKcg3oefEuW2OT2Vozz8ef7wrJbMcmhvCC+hciF8jY/uAkw== + +"@esbuild/android-arm@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/android-arm/-/android-arm-0.19.2.tgz#edd1c8f23ba353c197f5b0337123c58ff2a56999" + integrity sha512-tM8yLeYVe7pRyAu9VMi/Q7aunpLwD139EY1S99xbQkT4/q2qa6eA4ige/WJQYdJ8GBL1K33pPFhPfPdJ/WzT8Q== + +"@esbuild/android-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/android-x64/-/android-x64-0.19.2.tgz#2dcdd6e6f1f2d82ea1b746abd8da5b284960f35a" + integrity sha512-qK/TpmHt2M/Hg82WXHRc/W/2SGo/l1thtDHZWqFq7oi24AjZ4O/CpPSu6ZuYKFkEgmZlFoa7CooAyYmuvnaG8w== + +"@esbuild/darwin-arm64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-arm64/-/darwin-arm64-0.19.2.tgz#55b36bc06d76f5c243987c1f93a11a80d8fc3b26" + integrity sha512-Ora8JokrvrzEPEpZO18ZYXkH4asCdc1DLdcVy8TGf5eWtPO1Ie4WroEJzwI52ZGtpODy3+m0a2yEX9l+KUn0tA== + +"@esbuild/darwin-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/darwin-x64/-/darwin-x64-0.19.2.tgz#982524af33a6424a3b5cb44bbd52559623ad719c" + integrity sha512-tP+B5UuIbbFMj2hQaUr6EALlHOIOmlLM2FK7jeFBobPy2ERdohI4Ka6ZFjZ1ZYsrHE/hZimGuU90jusRE0pwDw== + +"@esbuild/freebsd-arm64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-arm64/-/freebsd-arm64-0.19.2.tgz#8e478a0856645265fe79eac4b31b52193011ee06" + integrity sha512-YbPY2kc0acfzL1VPVK6EnAlig4f+l8xmq36OZkU0jzBVHcOTyQDhnKQaLzZudNJQyymd9OqQezeaBgkTGdTGeQ== + +"@esbuild/freebsd-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/freebsd-x64/-/freebsd-x64-0.19.2.tgz#01b96604f2540db023c73809bb8ae6cd1692d6f3" + integrity sha512-nSO5uZT2clM6hosjWHAsS15hLrwCvIWx+b2e3lZ3MwbYSaXwvfO528OF+dLjas1g3bZonciivI8qKR/Hm7IWGw== + +"@esbuild/linux-arm64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm64/-/linux-arm64-0.19.2.tgz#7e5d2c7864c5c83ec789b59c77cd9c20d2594916" + integrity sha512-ig2P7GeG//zWlU0AggA3pV1h5gdix0MA3wgB+NsnBXViwiGgY77fuN9Wr5uoCrs2YzaYfogXgsWZbm+HGr09xg== + +"@esbuild/linux-arm@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-arm/-/linux-arm-0.19.2.tgz#c32ae97bc0246664a1cfbdb4a98e7b006d7db8ae" + integrity sha512-Odalh8hICg7SOD7XCj0YLpYCEc+6mkoq63UnExDCiRA2wXEmGlK5JVrW50vZR9Qz4qkvqnHcpH+OFEggO3PgTg== + +"@esbuild/linux-ia32@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ia32/-/linux-ia32-0.19.2.tgz#3fc4f0fa026057fe885e4a180b3956e704f1ceaa" + integrity sha512-mLfp0ziRPOLSTek0Gd9T5B8AtzKAkoZE70fneiiyPlSnUKKI4lp+mGEnQXcQEHLJAcIYDPSyBvsUbKUG2ri/XQ== + +"@esbuild/linux-loong64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-loong64/-/linux-loong64-0.19.2.tgz#633bcaea443f3505fb0ed109ab840c99ad3451a4" + integrity sha512-hn28+JNDTxxCpnYjdDYVMNTR3SKavyLlCHHkufHV91fkewpIyQchS1d8wSbmXhs1fiYDpNww8KTFlJ1dHsxeSw== + +"@esbuild/linux-mips64el@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-mips64el/-/linux-mips64el-0.19.2.tgz#e0bff2898c46f52be7d4dbbcca8b887890805823" + integrity sha512-KbXaC0Sejt7vD2fEgPoIKb6nxkfYW9OmFUK9XQE4//PvGIxNIfPk1NmlHmMg6f25x57rpmEFrn1OotASYIAaTg== + +"@esbuild/linux-ppc64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-ppc64/-/linux-ppc64-0.19.2.tgz#d75798da391f54a9674f8c143b9a52d1dbfbfdde" + integrity sha512-dJ0kE8KTqbiHtA3Fc/zn7lCd7pqVr4JcT0JqOnbj4LLzYnp+7h8Qi4yjfq42ZlHfhOCM42rBh0EwHYLL6LEzcw== + +"@esbuild/linux-riscv64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-riscv64/-/linux-riscv64-0.19.2.tgz#012409bd489ed1bb9b775541d4a46c5ded8e6dd8" + integrity sha512-7Z/jKNFufZ/bbu4INqqCN6DDlrmOTmdw6D0gH+6Y7auok2r02Ur661qPuXidPOJ+FSgbEeQnnAGgsVynfLuOEw== + +"@esbuild/linux-s390x@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-s390x/-/linux-s390x-0.19.2.tgz#ece3ed75c5a150de8a5c110f02e97d315761626b" + integrity sha512-U+RinR6aXXABFCcAY4gSlv4CL1oOVvSSCdseQmGO66H+XyuQGZIUdhG56SZaDJQcLmrSfRmx5XZOWyCJPRqS7g== + +"@esbuild/linux-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/linux-x64/-/linux-x64-0.19.2.tgz#dea187019741602d57aaf189a80abba261fbd2aa" + integrity sha512-oxzHTEv6VPm3XXNaHPyUTTte+3wGv7qVQtqaZCrgstI16gCuhNOtBXLEBkBREP57YTd68P0VgDgG73jSD8bwXQ== + +"@esbuild/netbsd-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/netbsd-x64/-/netbsd-x64-0.19.2.tgz#bbfd7cf9ab236a23ee3a41b26f0628c57623d92a" + integrity sha512-WNa5zZk1XpTTwMDompZmvQLHszDDDN7lYjEHCUmAGB83Bgs20EMs7ICD+oKeT6xt4phV4NDdSi/8OfjPbSbZfQ== + +"@esbuild/openbsd-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/openbsd-x64/-/openbsd-x64-0.19.2.tgz#fa5c4c6ee52a360618f00053652e2902e1d7b4a7" + integrity sha512-S6kI1aT3S++Dedb7vxIuUOb3oAxqxk2Rh5rOXOTYnzN8JzW1VzBd+IqPiSpgitu45042SYD3HCoEyhLKQcDFDw== + +"@esbuild/sunos-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/sunos-x64/-/sunos-x64-0.19.2.tgz#52a2ac8ac6284c02d25df22bb4cfde26fbddd68d" + integrity sha512-VXSSMsmb+Z8LbsQGcBMiM+fYObDNRm8p7tkUDMPG/g4fhFX5DEFmjxIEa3N8Zr96SjsJ1woAhF0DUnS3MF3ARw== + +"@esbuild/win32-arm64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/win32-arm64/-/win32-arm64-0.19.2.tgz#719ed5870855de8537aef8149694a97d03486804" + integrity sha512-5NayUlSAyb5PQYFAU9x3bHdsqB88RC3aM9lKDAz4X1mo/EchMIT1Q+pSeBXNgkfNmRecLXA0O8xP+x8V+g/LKg== + +"@esbuild/win32-ia32@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/win32-ia32/-/win32-ia32-0.19.2.tgz#24832223880b0f581962c8660f8fb8797a1e046a" + integrity sha512-47gL/ek1v36iN0wL9L4Q2MFdujR0poLZMJwhO2/N3gA89jgHp4MR8DKCmwYtGNksbfJb9JoTtbkoe6sDhg2QTA== + +"@esbuild/win32-x64@0.19.2": + version "0.19.2" + resolved "https://registry.yarnpkg.com/@esbuild/win32-x64/-/win32-x64-0.19.2.tgz#1205014625790c7ff0e471644a878a65d1e34ab0" + integrity sha512-tcuhV7ncXBqbt/Ybf0IyrMcwVOAPDckMK9rXNHtF17UTK18OKLpg08glminN06pt2WCoALhXdLfSPbVvK/6fxw== + +"@ethersproject/abi@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/abi/-/abi-5.5.0.tgz#fb52820e22e50b854ff15ce1647cc508d6660613" + integrity sha512-loW7I4AohP5KycATvc0MgujU6JyCHPqHdeoo9z3Nr9xEiNioxa65ccdm1+fsoJhkuhdRtfcL8cfyGamz2AxZ5w== + dependencies: + "@ethersproject/address" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/hash" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + +"@ethersproject/abi@5.7.0", "@ethersproject/abi@^5.0.1", "@ethersproject/abi@^5.5.0", "@ethersproject/abi@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz" integrity sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA== @@ -64,7 +189,20 @@ "@ethersproject/properties" "^5.7.0" "@ethersproject/strings" "^5.7.0" -"@ethersproject/abstract-provider@^5.7.0": +"@ethersproject/abstract-provider@5.5.1": + version "5.5.1" + resolved "https://registry.yarnpkg.com/@ethersproject/abstract-provider/-/abstract-provider-5.5.1.tgz#2f1f6e8a3ab7d378d8ad0b5718460f85649710c5" + integrity sha512-m+MA/ful6eKbxpr99xUYeRvLkfnlqzrF8SZ46d/xFB1A7ZVknYc/sXJG0RcufF52Qn2jeFj1hhcoQ7IXjNKUqg== + dependencies: + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/networks" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + "@ethersproject/web" "^5.5.0" + +"@ethersproject/abstract-provider@5.7.0", "@ethersproject/abstract-provider@^5.5.0", "@ethersproject/abstract-provider@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz" integrity sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw== @@ -77,7 +215,18 @@ "@ethersproject/transactions" "^5.7.0" "@ethersproject/web" "^5.7.0" -"@ethersproject/abstract-signer@^5.7.0": +"@ethersproject/abstract-signer@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/abstract-signer/-/abstract-signer-5.5.0.tgz#590ff6693370c60ae376bf1c7ada59eb2a8dd08d" + integrity sha512-lj//7r250MXVLKI7sVarXAbZXbv9P50lgmJQGr2/is82EwEb8r7HrxsmMqAjTsztMYy7ohrIhGMIml+Gx4D3mA== + dependencies: + "@ethersproject/abstract-provider" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + +"@ethersproject/abstract-signer@5.7.0", "@ethersproject/abstract-signer@^5.5.0", "@ethersproject/abstract-signer@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz" integrity sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ== @@ -88,7 +237,18 @@ "@ethersproject/logger" "^5.7.0" "@ethersproject/properties" "^5.7.0" -"@ethersproject/address@^5.7.0": +"@ethersproject/address@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/address/-/address-5.5.0.tgz#bcc6f576a553f21f3dd7ba17248f81b473c9c78f" + integrity sha512-l4Nj0eWlTUh6ro5IbPTgbpT4wRbdH5l8CQf7icF7sb/SI3Nhd9Y9HzhonTSTi6CefI0necIw7LJqQPopPLZyWw== + dependencies: + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/rlp" "^5.5.0" + +"@ethersproject/address@5.7.0", "@ethersproject/address@^5.5.0", "@ethersproject/address@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz" integrity sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA== @@ -99,14 +259,46 @@ "@ethersproject/logger" "^5.7.0" "@ethersproject/rlp" "^5.7.0" -"@ethersproject/base64@^5.7.0": +"@ethersproject/base64@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/base64/-/base64-5.5.0.tgz#881e8544e47ed976930836986e5eb8fab259c090" + integrity sha512-tdayUKhU1ljrlHzEWbStXazDpsx4eg1dBXUSI6+mHlYklOXoXF6lZvw8tnD6oVaWfnMxAgRSKROg3cVKtCcppA== + dependencies: + "@ethersproject/bytes" "^5.5.0" + +"@ethersproject/base64@5.7.0", "@ethersproject/base64@^5.5.0", "@ethersproject/base64@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz" integrity sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ== dependencies: "@ethersproject/bytes" "^5.7.0" -"@ethersproject/bignumber@^5.7.0": +"@ethersproject/basex@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/basex/-/basex-5.5.0.tgz#e40a53ae6d6b09ab4d977bd037010d4bed21b4d3" + integrity sha512-ZIodwhHpVJ0Y3hUCfUucmxKsWQA5TMnavp5j/UOuDdzZWzJlRmuOjcTMIGgHCYuZmHt36BfiSyQPSRskPxbfaQ== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + +"@ethersproject/basex@5.7.0", "@ethersproject/basex@^5.5.0", "@ethersproject/basex@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/basex/-/basex-5.7.0.tgz#97034dc7e8938a8ca943ab20f8a5e492ece4020b" + integrity sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + +"@ethersproject/bignumber@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/bignumber/-/bignumber-5.5.0.tgz#875b143f04a216f4f8b96245bde942d42d279527" + integrity sha512-6Xytlwvy6Rn3U3gKEc1vP7nR92frHkv6wtVr95LFR3jREXiCPzdWxKQ1cx4JGQBXxcguAwjA8murlYN2TSiEbg== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + bn.js "^4.11.9" + +"@ethersproject/bignumber@5.7.0", "@ethersproject/bignumber@^5.5.0", "@ethersproject/bignumber@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz" integrity sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw== @@ -115,21 +307,81 @@ "@ethersproject/logger" "^5.7.0" bn.js "^5.2.1" -"@ethersproject/bytes@^5.7.0": +"@ethersproject/bytes@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/bytes/-/bytes-5.5.0.tgz#cb11c526de657e7b45d2e0f0246fb3b9d29a601c" + integrity sha512-ABvc7BHWhZU9PNM/tANm/Qx4ostPGadAuQzWTr3doklZOhDlmcBqclrQe/ZXUIj3K8wC28oYeuRa+A37tX9kog== + dependencies: + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/bytes@5.7.0", "@ethersproject/bytes@^5.5.0", "@ethersproject/bytes@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz" integrity sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A== dependencies: "@ethersproject/logger" "^5.7.0" -"@ethersproject/constants@^5.7.0": +"@ethersproject/constants@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/constants/-/constants-5.5.0.tgz#d2a2cd7d94bd1d58377d1d66c4f53c9be4d0a45e" + integrity sha512-2MsRRVChkvMWR+GyMGY4N1sAX9Mt3J9KykCsgUFd/1mwS0UH1qw+Bv9k1UJb3X3YJYFco9H20pjSlOIfCG5HYQ== + dependencies: + "@ethersproject/bignumber" "^5.5.0" + +"@ethersproject/constants@5.7.0", "@ethersproject/constants@^5.5.0", "@ethersproject/constants@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz" integrity sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA== dependencies: "@ethersproject/bignumber" "^5.7.0" -"@ethersproject/hash@^5.7.0": +"@ethersproject/contracts@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/contracts/-/contracts-5.5.0.tgz#b735260d4bd61283a670a82d5275e2a38892c197" + integrity sha512-2viY7NzyvJkh+Ug17v7g3/IJC8HqZBDcOjYARZLdzRxrfGlRgmYgl6xPRKVbEzy1dWKw/iv7chDcS83pg6cLxg== + dependencies: + "@ethersproject/abi" "^5.5.0" + "@ethersproject/abstract-provider" "^5.5.0" + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + +"@ethersproject/contracts@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/contracts/-/contracts-5.7.0.tgz#c305e775abd07e48aa590e1a877ed5c316f8bd1e" + integrity sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg== + dependencies: + "@ethersproject/abi" "^5.7.0" + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + +"@ethersproject/hash@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/hash/-/hash-5.5.0.tgz#7cee76d08f88d1873574c849e0207dcb32380cc9" + integrity sha512-dnGVpK1WtBjmnp3mUT0PlU2MpapnwWI0PibldQEq1408tQBAbZpPidkWoVVuNMOl/lISO3+4hXZWCL3YV7qzfg== + dependencies: + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + +"@ethersproject/hash@5.7.0", "@ethersproject/hash@^5.5.0", "@ethersproject/hash@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz" integrity sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g== @@ -144,7 +396,89 @@ "@ethersproject/properties" "^5.7.0" "@ethersproject/strings" "^5.7.0" -"@ethersproject/keccak256@^5.7.0": +"@ethersproject/hdnode@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/hdnode/-/hdnode-5.5.0.tgz#4a04e28f41c546f7c978528ea1575206a200ddf6" + integrity sha512-mcSOo9zeUg1L0CoJH7zmxwUG5ggQHU1UrRf8jyTYy6HxdZV+r0PBoL1bxr+JHIPXRzS6u/UW4mEn43y0tmyF8Q== + dependencies: + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/basex" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/pbkdf2" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/sha2" "^5.5.0" + "@ethersproject/signing-key" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + "@ethersproject/wordlists" "^5.5.0" + +"@ethersproject/hdnode@5.7.0", "@ethersproject/hdnode@^5.5.0", "@ethersproject/hdnode@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/hdnode/-/hdnode-5.7.0.tgz#e627ddc6b466bc77aebf1a6b9e47405ca5aef9cf" + integrity sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg== + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/basex" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/pbkdf2" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/wordlists" "^5.7.0" + +"@ethersproject/json-wallets@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/json-wallets/-/json-wallets-5.5.0.tgz#dd522d4297e15bccc8e1427d247ec8376b60e325" + integrity sha512-9lA21XQnCdcS72xlBn1jfQdj2A1VUxZzOzi9UkNdnokNKke/9Ya2xA9aIK1SC3PQyBDLt4C+dfps7ULpkvKikQ== + dependencies: + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/hdnode" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/pbkdf2" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/random" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + aes-js "3.0.0" + scrypt-js "3.0.1" + +"@ethersproject/json-wallets@5.7.0", "@ethersproject/json-wallets@^5.5.0", "@ethersproject/json-wallets@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz#5e3355287b548c32b368d91014919ebebddd5360" + integrity sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g== + dependencies: + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hdnode" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/pbkdf2" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + aes-js "3.0.0" + scrypt-js "3.0.1" + +"@ethersproject/keccak256@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/keccak256/-/keccak256-5.5.0.tgz#e4b1f9d7701da87c564ffe336f86dcee82983492" + integrity sha512-5VoFCTjo2rYbBe1l2f4mccaRFN/4VQEYFwwn04aJV2h7qf4ZvI2wFxUE1XOX+snbwCLRzIeikOqtAoPwMza9kg== + dependencies: + "@ethersproject/bytes" "^5.5.0" + js-sha3 "0.8.0" + +"@ethersproject/keccak256@5.7.0", "@ethersproject/keccak256@^5.5.0", "@ethersproject/keccak256@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz" integrity sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg== @@ -152,26 +486,186 @@ "@ethersproject/bytes" "^5.7.0" js-sha3 "0.8.0" -"@ethersproject/logger@^5.7.0": +"@ethersproject/logger@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/logger/-/logger-5.5.0.tgz#0c2caebeff98e10aefa5aef27d7441c7fd18cf5d" + integrity sha512-rIY/6WPm7T8n3qS2vuHTUBPdXHl+rGxWxW5okDfo9J4Z0+gRRZT0msvUdIJkE4/HS29GUMziwGaaKO2bWONBrg== + +"@ethersproject/logger@5.7.0", "@ethersproject/logger@^5.5.0", "@ethersproject/logger@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz" integrity sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig== -"@ethersproject/networks@^5.7.0": +"@ethersproject/networks@5.5.2": + version "5.5.2" + resolved "https://registry.yarnpkg.com/@ethersproject/networks/-/networks-5.5.2.tgz#784c8b1283cd2a931114ab428dae1bd00c07630b" + integrity sha512-NEqPxbGBfy6O3x4ZTISb90SjEDkWYDUbEeIFhJly0F7sZjoQMnj5KYzMSkMkLKZ+1fGpx00EDpHQCy6PrDupkQ== + dependencies: + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/networks@5.7.1", "@ethersproject/networks@^5.5.0", "@ethersproject/networks@^5.7.0": version "5.7.1" resolved "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz" integrity sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ== dependencies: "@ethersproject/logger" "^5.7.0" -"@ethersproject/properties@^5.7.0": +"@ethersproject/pbkdf2@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/pbkdf2/-/pbkdf2-5.5.0.tgz#e25032cdf02f31505d47afbf9c3e000d95c4a050" + integrity sha512-SaDvQFvXPnz1QGpzr6/HToLifftSXGoXrbpZ6BvoZhmx4bNLHrxDe8MZisuecyOziP1aVEwzC2Hasj+86TgWVg== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/sha2" "^5.5.0" + +"@ethersproject/pbkdf2@5.7.0", "@ethersproject/pbkdf2@^5.5.0", "@ethersproject/pbkdf2@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz#d2267d0a1f6e123f3771007338c47cccd83d3102" + integrity sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + +"@ethersproject/properties@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/properties/-/properties-5.5.0.tgz#61f00f2bb83376d2071baab02245f92070c59995" + integrity sha512-l3zRQg3JkD8EL3CPjNK5g7kMx4qSwiR60/uk5IVjd3oq1MZR5qUg40CNOoEJoX5wc3DyY5bt9EbMk86C7x0DNA== + dependencies: + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/properties@5.7.0", "@ethersproject/properties@^5.5.0", "@ethersproject/properties@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz" integrity sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw== dependencies: "@ethersproject/logger" "^5.7.0" -"@ethersproject/rlp@^5.7.0": +"@ethersproject/providers@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/providers/-/providers-5.5.0.tgz#bc2876a8fe5e0053ed9828b1f3767ae46e43758b" + integrity sha512-xqMbDnS/FPy+J/9mBLKddzyLLAQFjrVff5g00efqxPzcAwXiR+SiCGVy6eJ5iAIirBOATjx7QLhDNPGV+AEQsw== + dependencies: + "@ethersproject/abstract-provider" "^5.5.0" + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/basex" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/hash" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/networks" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/random" "^5.5.0" + "@ethersproject/rlp" "^5.5.0" + "@ethersproject/sha2" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + "@ethersproject/web" "^5.5.0" + bech32 "1.1.4" + ws "7.4.6" + +"@ethersproject/providers@5.5.2": + version "5.5.2" + resolved "https://registry.yarnpkg.com/@ethersproject/providers/-/providers-5.5.2.tgz#131ccf52dc17afd0ab69ed444b8c0e3a27297d99" + integrity sha512-hkbx7x/MKcRjyrO4StKXCzCpWer6s97xnm34xkfPiarhtEUVAN4TBBpamM+z66WcTt7H5B53YwbRj1n7i8pZoQ== + dependencies: + "@ethersproject/abstract-provider" "^5.5.0" + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/basex" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/hash" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/networks" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/random" "^5.5.0" + "@ethersproject/rlp" "^5.5.0" + "@ethersproject/sha2" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + "@ethersproject/web" "^5.5.0" + bech32 "1.1.4" + ws "7.4.6" + +"@ethersproject/providers@5.5.3": + version "5.5.3" + resolved "https://registry.yarnpkg.com/@ethersproject/providers/-/providers-5.5.3.tgz#56c2b070542ac44eb5de2ed3cf6784acd60a3130" + integrity sha512-ZHXxXXXWHuwCQKrgdpIkbzMNJMvs+9YWemanwp1fA7XZEv7QlilseysPvQe0D7Q7DlkJX/w/bGA1MdgK2TbGvA== + dependencies: + "@ethersproject/abstract-provider" "^5.5.0" + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/basex" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/hash" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/networks" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/random" "^5.5.0" + "@ethersproject/rlp" "^5.5.0" + "@ethersproject/sha2" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + "@ethersproject/web" "^5.5.0" + bech32 "1.1.4" + ws "7.4.6" + +"@ethersproject/providers@5.7.2": + version "5.7.2" + resolved "https://registry.yarnpkg.com/@ethersproject/providers/-/providers-5.7.2.tgz#f8b1a4f275d7ce58cf0a2eec222269a08beb18cb" + integrity sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg== + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/base64" "^5.7.0" + "@ethersproject/basex" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/networks" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/rlp" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/web" "^5.7.0" + bech32 "1.1.4" + ws "7.4.6" + +"@ethersproject/random@5.5.1": + version "5.5.1" + resolved "https://registry.yarnpkg.com/@ethersproject/random/-/random-5.5.1.tgz#7cdf38ea93dc0b1ed1d8e480ccdaf3535c555415" + integrity sha512-YaU2dQ7DuhL5Au7KbcQLHxcRHfgyNgvFV4sQOo0HrtW3Zkrc9ctWNz8wXQ4uCSfSDsqX2vcjhroxU5RQRV0nqA== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/random@5.7.0", "@ethersproject/random@^5.5.0", "@ethersproject/random@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/random/-/random-5.7.0.tgz#af19dcbc2484aae078bb03656ec05df66253280c" + integrity sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/rlp@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/rlp/-/rlp-5.5.0.tgz#530f4f608f9ca9d4f89c24ab95db58ab56ab99a0" + integrity sha512-hLv8XaQ8PTI9g2RHoQGf/WSxBfTB/NudRacbzdxmst5VHAqd1sMibWG7SENzT5Dj3yZ3kJYx+WiRYEcQTAkcYA== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/rlp@5.7.0", "@ethersproject/rlp@^5.5.0", "@ethersproject/rlp@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz" integrity sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w== @@ -179,7 +673,37 @@ "@ethersproject/bytes" "^5.7.0" "@ethersproject/logger" "^5.7.0" -"@ethersproject/signing-key@^5.7.0": +"@ethersproject/sha2@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/sha2/-/sha2-5.5.0.tgz#a40a054c61f98fd9eee99af2c3cc6ff57ec24db7" + integrity sha512-B5UBoglbCiHamRVPLA110J+2uqsifpZaTmid2/7W5rbtYVz6gus6/hSDieIU/6gaKIDcOj12WnOdiymEUHIAOA== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + hash.js "1.1.7" + +"@ethersproject/sha2@5.7.0", "@ethersproject/sha2@^5.5.0", "@ethersproject/sha2@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/sha2/-/sha2-5.7.0.tgz#9a5f7a7824ef784f7f7680984e593a800480c9fb" + integrity sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + hash.js "1.1.7" + +"@ethersproject/signing-key@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/signing-key/-/signing-key-5.5.0.tgz#2aa37169ce7e01e3e80f2c14325f624c29cedbe0" + integrity sha512-5VmseH7qjtNmDdZBswavhotYbWB0bOwKIlOTSlX14rKn5c11QmJwGt4GHeo7NrL/Ycl7uo9AHvEqs5xZgFBTng== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + bn.js "^4.11.9" + elliptic "6.5.4" + hash.js "1.1.7" + +"@ethersproject/signing-key@5.7.0", "@ethersproject/signing-key@^5.5.0", "@ethersproject/signing-key@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz" integrity sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q== @@ -191,7 +715,40 @@ elliptic "6.5.4" hash.js "1.1.7" -"@ethersproject/strings@^5.7.0": +"@ethersproject/solidity@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/solidity/-/solidity-5.5.0.tgz#2662eb3e5da471b85a20531e420054278362f93f" + integrity sha512-9NgZs9LhGMj6aCtHXhtmFQ4AN4sth5HuFXVvAQtzmm0jpSCNOTGtrHZJAeYTh7MBjRR8brylWZxBZR9zDStXbw== + dependencies: + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/sha2" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + +"@ethersproject/solidity@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/solidity/-/solidity-5.7.0.tgz#5e9c911d8a2acce2a5ebb48a5e2e0af20b631cb8" + integrity sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/sha2" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + +"@ethersproject/strings@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/strings/-/strings-5.5.0.tgz#e6784d00ec6c57710755699003bc747e98c5d549" + integrity sha512-9fy3TtF5LrX/wTrBaT8FGE6TDJyVjOvXynXJz5MT5azq+E6D92zuKNx7i29sWW2FjVOaWjAsiZ1ZWznuduTIIQ== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/strings@5.7.0", "@ethersproject/strings@^5.5.0", "@ethersproject/strings@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz" integrity sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg== @@ -200,7 +757,22 @@ "@ethersproject/constants" "^5.7.0" "@ethersproject/logger" "^5.7.0" -"@ethersproject/transactions@^5.7.0": +"@ethersproject/transactions@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/transactions/-/transactions-5.5.0.tgz#7e9bf72e97bcdf69db34fe0d59e2f4203c7a2908" + integrity sha512-9RZYSKX26KfzEd/1eqvv8pLauCKzDTub0Ko4LfIgaERvRuwyaNV78mJs7cpIgZaDl6RJui4o49lHwwCM0526zA== + dependencies: + "@ethersproject/address" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/rlp" "^5.5.0" + "@ethersproject/signing-key" "^5.5.0" + +"@ethersproject/transactions@5.7.0", "@ethersproject/transactions@^5.5.0", "@ethersproject/transactions@^5.7.0": version "5.7.0" resolved "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz" integrity sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ== @@ -215,7 +787,78 @@ "@ethersproject/rlp" "^5.7.0" "@ethersproject/signing-key" "^5.7.0" -"@ethersproject/web@^5.7.0": +"@ethersproject/units@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/units/-/units-5.5.0.tgz#104d02db5b5dc42cc672cc4587bafb87a95ee45e" + integrity sha512-7+DpjiZk4v6wrikj+TCyWWa9dXLNU73tSTa7n0TSJDxkYbV3Yf1eRh9ToMLlZtuctNYu9RDNNy2USq3AdqSbag== + dependencies: + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/constants" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + +"@ethersproject/units@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/units/-/units-5.7.0.tgz#637b563d7e14f42deeee39245275d477aae1d8b1" + integrity sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg== + dependencies: + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/constants" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + +"@ethersproject/wallet@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/wallet/-/wallet-5.5.0.tgz#322a10527a440ece593980dca6182f17d54eae75" + integrity sha512-Mlu13hIctSYaZmUOo7r2PhNSd8eaMPVXe1wxrz4w4FCE4tDYBywDH+bAR1Xz2ADyXGwqYMwstzTrtUVIsKDO0Q== + dependencies: + "@ethersproject/abstract-provider" "^5.5.0" + "@ethersproject/abstract-signer" "^5.5.0" + "@ethersproject/address" "^5.5.0" + "@ethersproject/bignumber" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/hash" "^5.5.0" + "@ethersproject/hdnode" "^5.5.0" + "@ethersproject/json-wallets" "^5.5.0" + "@ethersproject/keccak256" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/random" "^5.5.0" + "@ethersproject/signing-key" "^5.5.0" + "@ethersproject/transactions" "^5.5.0" + "@ethersproject/wordlists" "^5.5.0" + +"@ethersproject/wallet@5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/wallet/-/wallet-5.7.0.tgz#4e5d0790d96fe21d61d38fb40324e6c7ef350b2d" + integrity sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA== + dependencies: + "@ethersproject/abstract-provider" "^5.7.0" + "@ethersproject/abstract-signer" "^5.7.0" + "@ethersproject/address" "^5.7.0" + "@ethersproject/bignumber" "^5.7.0" + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/hdnode" "^5.7.0" + "@ethersproject/json-wallets" "^5.7.0" + "@ethersproject/keccak256" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/random" "^5.7.0" + "@ethersproject/signing-key" "^5.7.0" + "@ethersproject/transactions" "^5.7.0" + "@ethersproject/wordlists" "^5.7.0" + +"@ethersproject/web@5.5.1": + version "5.5.1" + resolved "https://registry.yarnpkg.com/@ethersproject/web/-/web-5.5.1.tgz#cfcc4a074a6936c657878ac58917a61341681316" + integrity sha512-olvLvc1CB12sREc1ROPSHTdFCdvMh0J5GSJYiQg2D0hdD4QmJDy8QYDb1CvoqD/bF1c++aeKv2sR5uduuG9dQg== + dependencies: + "@ethersproject/base64" "^5.5.0" + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + +"@ethersproject/web@5.7.1", "@ethersproject/web@^5.5.0", "@ethersproject/web@^5.7.0": version "5.7.1" resolved "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz" integrity sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w== @@ -226,6 +869,28 @@ "@ethersproject/properties" "^5.7.0" "@ethersproject/strings" "^5.7.0" +"@ethersproject/wordlists@5.5.0": + version "5.5.0" + resolved "https://registry.yarnpkg.com/@ethersproject/wordlists/-/wordlists-5.5.0.tgz#aac74963aa43e643638e5172353d931b347d584f" + integrity sha512-bL0UTReWDiaQJJYOC9sh/XcRu/9i2jMrzf8VLRmPKx58ckSlOJiohODkECCO50dtLZHcGU6MLXQ4OOrgBwP77Q== + dependencies: + "@ethersproject/bytes" "^5.5.0" + "@ethersproject/hash" "^5.5.0" + "@ethersproject/logger" "^5.5.0" + "@ethersproject/properties" "^5.5.0" + "@ethersproject/strings" "^5.5.0" + +"@ethersproject/wordlists@5.7.0", "@ethersproject/wordlists@^5.5.0", "@ethersproject/wordlists@^5.7.0": + version "5.7.0" + resolved "https://registry.yarnpkg.com/@ethersproject/wordlists/-/wordlists-5.7.0.tgz#8fb2c07185d68c3e09eb3bfd6e779ba2774627f5" + integrity sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA== + dependencies: + "@ethersproject/bytes" "^5.7.0" + "@ethersproject/hash" "^5.7.0" + "@ethersproject/logger" "^5.7.0" + "@ethersproject/properties" "^5.7.0" + "@ethersproject/strings" "^5.7.0" + "@floating-ui/core@^1.4.1": version "1.4.1" resolved "https://registry.npmjs.org/@floating-ui/core/-/core-1.4.1.tgz" @@ -253,6 +918,57 @@ resolved "https://registry.npmjs.org/@floating-ui/utils/-/utils-0.1.1.tgz" integrity sha512-m0G6wlnhm/AX0H12IOWtK8gASEMffnX08RtKkCgTdHb9JpHKGloI7icFfLg9ZmQeavcvR0PKmzxClyuFPSjKWw== +"@formatjs/ecma402-abstract@1.11.4": + version "1.11.4" + resolved "https://registry.yarnpkg.com/@formatjs/ecma402-abstract/-/ecma402-abstract-1.11.4.tgz#b962dfc4ae84361f9f08fbce411b4e4340930eda" + integrity sha512-EBikYFp2JCdIfGEb5G9dyCkTGDmC57KSHhRQOC3aYxoPWVZvfWCDjZwkGYHN7Lis/fmuWl906bnNTJifDQ3sXw== + dependencies: + "@formatjs/intl-localematcher" "0.2.25" + tslib "^2.1.0" + +"@formatjs/fast-memoize@1.2.1": + version "1.2.1" + resolved "https://registry.yarnpkg.com/@formatjs/fast-memoize/-/fast-memoize-1.2.1.tgz#e6f5aee2e4fd0ca5edba6eba7668e2d855e0fc21" + integrity sha512-Rg0e76nomkz3vF9IPlKeV+Qynok0r7YZjL6syLz4/urSg0IbjPZCB/iYUMNsYA643gh4mgrX3T7KEIFIxJBQeg== + dependencies: + tslib "^2.1.0" + +"@formatjs/icu-messageformat-parser@2.1.0": + version "2.1.0" + resolved "https://registry.yarnpkg.com/@formatjs/icu-messageformat-parser/-/icu-messageformat-parser-2.1.0.tgz#a54293dd7f098d6a6f6a084ab08b6d54a3e8c12d" + integrity sha512-Qxv/lmCN6hKpBSss2uQ8IROVnta2r9jd3ymUEIjm2UyIkUCHVcbUVRGL/KS/wv7876edvsPe+hjHVJ4z8YuVaw== + dependencies: + "@formatjs/ecma402-abstract" "1.11.4" + "@formatjs/icu-skeleton-parser" "1.3.6" + tslib "^2.1.0" + +"@formatjs/icu-skeleton-parser@1.3.6": + version "1.3.6" + resolved "https://registry.yarnpkg.com/@formatjs/icu-skeleton-parser/-/icu-skeleton-parser-1.3.6.tgz#4ce8c0737d6f07b735288177049e97acbf2e8964" + integrity sha512-I96mOxvml/YLrwU2Txnd4klA7V8fRhb6JG/4hm3VMNmeJo1F03IpV2L3wWt7EweqNLES59SZ4d6hVOPCSf80Bg== + dependencies: + "@formatjs/ecma402-abstract" "1.11.4" + tslib "^2.1.0" + +"@formatjs/intl-localematcher@0.2.25": + version "0.2.25" + resolved "https://registry.yarnpkg.com/@formatjs/intl-localematcher/-/intl-localematcher-0.2.25.tgz#60892fe1b271ec35ba07a2eb018a2dd7bca6ea3a" + integrity sha512-YmLcX70BxoSopLFdLr1Ds99NdlTI2oWoLbaUW2M406lxOIPzE1KQhRz2fPUkq34xVZQaihCoU29h0KK7An3bhA== + dependencies: + tslib "^2.1.0" + +"@hapi/hoek@^9.0.0": + version "9.3.0" + resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-9.3.0.tgz#8368869dcb735be2e7f5cb7647de78e167a251fb" + integrity sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ== + +"@hapi/topo@^5.0.0": + version "5.1.0" + resolved "https://registry.yarnpkg.com/@hapi/topo/-/topo-5.1.0.tgz#dc448e332c6c6e37a4dc02fd84ba8d44b9afb012" + integrity sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg== + dependencies: + "@hapi/hoek" "^9.0.0" + "@ledgerhq/connect-kit-loader@^1.1.0": version "1.1.2" resolved "https://registry.yarnpkg.com/@ledgerhq/connect-kit-loader/-/connect-kit-loader-1.1.2.tgz#d550e3c1f046e4c796f32a75324b03606b7e226a" @@ -769,6 +1485,23 @@ "@noble/hashes" "~1.3.0" "@scure/base" "~1.1.0" +"@sideway/address@^4.1.3": + version "4.1.4" + resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.4.tgz#03dccebc6ea47fdc226f7d3d1ad512955d4783f0" + integrity sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw== + dependencies: + "@hapi/hoek" "^9.0.0" + +"@sideway/formula@^3.0.1": + version "3.0.1" + resolved "https://registry.yarnpkg.com/@sideway/formula/-/formula-3.0.1.tgz#80fcbcbaf7ce031e0ef2dd29b1bfc7c3f583611f" + integrity sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg== + +"@sideway/pinpoint@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@sideway/pinpoint/-/pinpoint-2.0.0.tgz#cff8ffadc372ad29fd3f78277aeb29e632cc70df" + integrity sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ== + "@socket.io/component-emitter@~3.1.0": version "3.1.0" resolved "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz" @@ -1144,6 +1877,49 @@ eventemitter3 "^4.0.7" zustand "^4.3.1" +"@walletconnect/browser-utils@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/browser-utils/-/browser-utils-1.8.0.tgz#33c10e777aa6be86c713095b5206d63d32df0951" + integrity sha512-Wcqqx+wjxIo9fv6eBUFHPsW1y/bGWWRboni5dfD8PtOmrihrEpOCmvRJe4rfl7xgJW8Ea9UqKEaq0bIRLHlK4A== + dependencies: + "@walletconnect/safe-json" "1.0.0" + "@walletconnect/types" "^1.8.0" + "@walletconnect/window-getters" "1.0.0" + "@walletconnect/window-metadata" "1.0.0" + detect-browser "5.2.0" + +"@walletconnect/client@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/client/-/client-1.8.0.tgz#6f46b5499c7c861c651ff1ebe5da5b66225ca696" + integrity sha512-svyBQ14NHx6Cs2j4TpkQaBI/2AF4+LXz64FojTjMtV4VMMhl81jSO1vNeg+yYhQzvjcGH/GpSwixjyCW0xFBOQ== + dependencies: + "@walletconnect/core" "^1.8.0" + "@walletconnect/iso-crypto" "^1.8.0" + "@walletconnect/types" "^1.8.0" + "@walletconnect/utils" "^1.8.0" + +"@walletconnect/core@2.10.0": + version "2.10.0" + resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.10.0.tgz#b659de4dfb374becd938964abd4f2150d410e617" + integrity sha512-Z8pdorfIMueuiBXLdnf7yloiO9JIiobuxN3j0OTal+MYc4q5/2O7d+jdD1DAXbLi1taJx3x60UXT/FPVkjIqIQ== + dependencies: + "@walletconnect/heartbeat" "1.2.1" + "@walletconnect/jsonrpc-provider" "1.0.13" + "@walletconnect/jsonrpc-types" "1.0.3" + "@walletconnect/jsonrpc-utils" "1.0.8" + "@walletconnect/jsonrpc-ws-connection" "1.0.13" + "@walletconnect/keyvaluestorage" "^1.0.2" + "@walletconnect/logger" "^2.0.1" + "@walletconnect/relay-api" "^1.0.9" + "@walletconnect/relay-auth" "^1.0.4" + "@walletconnect/safe-json" "^1.0.2" + "@walletconnect/time" "^1.0.2" + "@walletconnect/types" "2.10.0" + "@walletconnect/utils" "2.10.0" + events "^3.3.0" + lodash.isequal "4.5.0" + uint8arrays "^3.1.0" + "@walletconnect/core@2.9.2": version "2.9.2" resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.9.2.tgz#c46734ca63771b28fd77606fd521930b7ecfc5e1" @@ -1166,7 +1942,16 @@ lodash.isequal "4.5.0" uint8arrays "^3.1.0" -"@walletconnect/crypto@^1.0.3": +"@walletconnect/core@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-1.8.0.tgz#6b2748b90c999d9d6a70e52e26a8d5e8bfeaa81e" + integrity sha512-aFTHvEEbXcZ8XdWBw6rpQDte41Rxwnuk3SgTD8/iKGSRTni50gI9S3YEzMj05jozSiOBxQci4pJDMVhIUMtarw== + dependencies: + "@walletconnect/socket-transport" "^1.8.0" + "@walletconnect/types" "^1.8.0" + "@walletconnect/utils" "^1.8.0" + +"@walletconnect/crypto@^1.0.2", "@walletconnect/crypto@^1.0.3": version "1.0.3" resolved "https://registry.yarnpkg.com/@walletconnect/crypto/-/crypto-1.0.3.tgz#7b8dd4d7e2884fe3543c7c07aea425eef5ef9dd4" integrity sha512-+2jdORD7XQs76I2Odgr3wwrtyuLUXD/kprNVsjWRhhhdO9Mt6WqVzOPu0/t7OHSmgal8k7SoBQzUc5hu/8zL/g== @@ -1178,7 +1963,7 @@ hash.js "^1.1.7" tslib "1.14.1" -"@walletconnect/encoding@^1.0.2": +"@walletconnect/encoding@^1.0.1", "@walletconnect/encoding@^1.0.2": version "1.0.2" resolved "https://registry.yarnpkg.com/@walletconnect/encoding/-/encoding-1.0.2.tgz#cb3942ad038d6a6bf01158f66773062dd25724da" integrity sha512-CrwSBrjqJ7rpGQcTL3kU+Ief+Bcuu9PH6JLOb+wM6NITX1GTxR/MfNwnQfhLKK6xpRAyj2/nM04OOH6wS8Imag== @@ -1209,6 +1994,21 @@ "@walletconnect/utils" "2.9.2" events "^3.3.0" +"@walletconnect/ethereum-provider@^2.10.0": + version "2.10.0" + resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.10.0.tgz#eebde38674222a48be35bb4aa3f6a74247ba059b" + integrity sha512-NyTm7RcrtAiSaYQPh6G4sOtr1kg/pL5Z3EDE6rBTV3Se5pMsYvtuwMiSol7MidsQpf4ux9HFhthTO3imcoWImw== + dependencies: + "@walletconnect/jsonrpc-http-connection" "^1.0.7" + "@walletconnect/jsonrpc-provider" "^1.0.13" + "@walletconnect/jsonrpc-types" "^1.0.3" + "@walletconnect/jsonrpc-utils" "^1.0.8" + "@walletconnect/sign-client" "2.10.0" + "@walletconnect/types" "2.10.0" + "@walletconnect/universal-provider" "2.10.0" + "@walletconnect/utils" "2.10.0" + events "^3.3.0" + "@walletconnect/events@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@walletconnect/events/-/events-1.0.1.tgz#2b5f9c7202019e229d7ccae1369a9e86bda7816c" @@ -1226,6 +2026,15 @@ "@walletconnect/time" "^1.0.2" tslib "1.14.1" +"@walletconnect/iso-crypto@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/iso-crypto/-/iso-crypto-1.8.0.tgz#44ddf337c4f02837c062dbe33fa7ab36789df451" + integrity sha512-pWy19KCyitpfXb70hA73r9FcvklS+FvO9QUIttp3c2mfW8frxgYeRXfxLRCIQTkaYueRKvdqPjbyhPLam508XQ== + dependencies: + "@walletconnect/crypto" "^1.0.2" + "@walletconnect/types" "^1.8.0" + "@walletconnect/utils" "^1.8.0" + "@walletconnect/jsonrpc-http-connection@^1.0.4", "@walletconnect/jsonrpc-http-connection@^1.0.7": version "1.0.7" resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-http-connection/-/jsonrpc-http-connection-1.0.7.tgz#a6973569b8854c22da707a759d241e4f5c2d5a98" @@ -1253,7 +2062,7 @@ keyvaluestorage-interface "^1.0.0" tslib "1.14.1" -"@walletconnect/jsonrpc-utils@1.0.8", "@walletconnect/jsonrpc-utils@^1.0.4", "@walletconnect/jsonrpc-utils@^1.0.6", "@walletconnect/jsonrpc-utils@^1.0.7", "@walletconnect/jsonrpc-utils@^1.0.8": +"@walletconnect/jsonrpc-utils@1.0.8", "@walletconnect/jsonrpc-utils@^1.0.3", "@walletconnect/jsonrpc-utils@^1.0.4", "@walletconnect/jsonrpc-utils@^1.0.6", "@walletconnect/jsonrpc-utils@^1.0.7", "@walletconnect/jsonrpc-utils@^1.0.8": version "1.0.8" resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-utils/-/jsonrpc-utils-1.0.8.tgz#82d0cc6a5d6ff0ecc277cb35f71402c91ad48d72" integrity sha512-vdeb03bD8VzJUL6ZtzRYsFMq1eZQcM3EAzT0a3st59dyLfJ0wq+tKMpmGH7HlB7waD858UWgfIcudbPFsbzVdw== @@ -1349,6 +2158,11 @@ pino "7.11.0" tslib "1.14.1" +"@walletconnect/mobile-registry@^1.4.0": + version "1.4.0" + resolved "https://registry.yarnpkg.com/@walletconnect/mobile-registry/-/mobile-registry-1.4.0.tgz#502cf8ab87330841d794819081e748ebdef7aee5" + integrity sha512-ZtKRio4uCZ1JUF7LIdecmZt7FOLnX72RPSY7aUVu7mj7CSfxDwUn6gBuK6WGtH+NZCldBqDl5DenI5fFSvkKYw== + "@walletconnect/modal-core@2.6.1": version "2.6.1" resolved "https://registry.yarnpkg.com/@walletconnect/modal-core/-/modal-core-2.6.1.tgz#bc76055d0b644a2d4b98024324825c108a700905" @@ -1374,6 +2188,18 @@ "@walletconnect/modal-core" "2.6.1" "@walletconnect/modal-ui" "2.6.1" +"@walletconnect/qrcode-modal@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/qrcode-modal/-/qrcode-modal-1.8.0.tgz#ddd6f5c9b7ee52c16adf9aacec2a3eac4994caea" + integrity sha512-BueaFefaAi8mawE45eUtztg3ZFbsAH4DDXh1UNwdUlsvFMjqcYzLUG0xZvDd6z2eOpbgDg2N3bl6gF0KONj1dg== + dependencies: + "@walletconnect/browser-utils" "^1.8.0" + "@walletconnect/mobile-registry" "^1.4.0" + "@walletconnect/types" "^1.8.0" + copy-to-clipboard "^3.3.1" + preact "10.4.1" + qrcode "1.4.4" + "@walletconnect/randombytes@^1.0.3": version "1.0.3" resolved "https://registry.yarnpkg.com/@walletconnect/randombytes/-/randombytes-1.0.3.tgz#e795e4918367fd1e6a2215e075e64ab93e23985b" @@ -1404,6 +2230,11 @@ tslib "1.14.1" uint8arrays "^3.0.0" +"@walletconnect/safe-json@1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/safe-json/-/safe-json-1.0.0.tgz#12eeb11d43795199c045fafde97e3c91646683b2" + integrity sha512-QJzp/S/86sUAgWY6eh5MKYmSfZaRpIlmCJdi5uG4DJlKkZrHEF7ye7gA+VtbVzvTtpM/gRwO2plQuiooIeXjfg== + "@walletconnect/safe-json@^1.0.1", "@walletconnect/safe-json@^1.0.2": version "1.0.2" resolved "https://registry.yarnpkg.com/@walletconnect/safe-json/-/safe-json-1.0.2.tgz#7237e5ca48046e4476154e503c6d3c914126fa77" @@ -1411,6 +2242,21 @@ dependencies: tslib "1.14.1" +"@walletconnect/sign-client@2.10.0": + version "2.10.0" + resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.10.0.tgz#0fee8f12821e37783099f0c7bd64e6efdfbd9d86" + integrity sha512-hbDljDS53kR/It3oXD91UkcOsT6diNnW5+Zzksm0YEfwww5dop/YfNlcdnc8+jKUhWOL/YDPNQCjzsCSNlVzbw== + dependencies: + "@walletconnect/core" "2.10.0" + "@walletconnect/events" "^1.0.1" + "@walletconnect/heartbeat" "1.2.1" + "@walletconnect/jsonrpc-utils" "1.0.8" + "@walletconnect/logger" "^2.0.1" + "@walletconnect/time" "^1.0.2" + "@walletconnect/types" "2.10.0" + "@walletconnect/utils" "2.10.0" + events "^3.3.0" + "@walletconnect/sign-client@2.9.2": version "2.9.2" resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.9.2.tgz#ff4c81c082c2078878367d07f24bcb20b1f7ab9e" @@ -1426,6 +2272,15 @@ "@walletconnect/utils" "2.9.2" events "^3.3.0" +"@walletconnect/socket-transport@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/socket-transport/-/socket-transport-1.8.0.tgz#9a1128a249628a0be11a0979b522fe82b44afa1b" + integrity sha512-5DyIyWrzHXTcVp0Vd93zJ5XMW61iDM6bcWT4p8DTRfFsOtW46JquruMhxOLeCOieM4D73kcr3U7WtyR4JUsGuQ== + dependencies: + "@walletconnect/types" "^1.8.0" + "@walletconnect/utils" "^1.8.0" + ws "7.5.3" + "@walletconnect/time@^1.0.2": version "1.0.2" resolved "https://registry.yarnpkg.com/@walletconnect/time/-/time-1.0.2.tgz#6c5888b835750ecb4299d28eecc5e72c6d336523" @@ -1433,6 +2288,18 @@ dependencies: tslib "1.14.1" +"@walletconnect/types@2.10.0": + version "2.10.0" + resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.10.0.tgz#5d63235b49e03d609521402a4b49627dbc4ed514" + integrity sha512-kSTA/WZnbKdEbvbXSW16Ty6dOSzOZCHnGg6JH7q1MuraalD2HuNg00lVVu7QAZ/Rj1Gn9DAkrgP5Wd5a8Xq//Q== + dependencies: + "@walletconnect/events" "^1.0.1" + "@walletconnect/heartbeat" "1.2.1" + "@walletconnect/jsonrpc-types" "1.0.3" + "@walletconnect/keyvaluestorage" "^1.0.2" + "@walletconnect/logger" "^2.0.1" + events "^3.3.0" + "@walletconnect/types@2.9.2": version "2.9.2" resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.9.2.tgz#d5fd5a61dc0f41cbdca59d1885b85207ac7bf8c5" @@ -1445,6 +2312,26 @@ "@walletconnect/logger" "^2.0.1" events "^3.3.0" +"@walletconnect/types@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-1.8.0.tgz#3f5e85b2d6b149337f727ab8a71b8471d8d9a195" + integrity sha512-Cn+3I0V0vT9ghMuzh1KzZvCkiAxTq+1TR2eSqw5E5AVWfmCtECFkVZBP6uUJZ8YjwLqXheI+rnjqPy7sVM4Fyg== + +"@walletconnect/universal-provider@2.10.0": + version "2.10.0" + resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.10.0.tgz#565d6478dcb5cc66955e5f03d6a00f51c9bcac14" + integrity sha512-jtVWf+AeTCqBcB3lCmWkv3bvSmdRCkQdo67GNoT5y6/pvVHMxfjgrJNBOUsWQMxpREpWDpZ993X0JRjsYVsMcA== + dependencies: + "@walletconnect/jsonrpc-http-connection" "^1.0.7" + "@walletconnect/jsonrpc-provider" "1.0.13" + "@walletconnect/jsonrpc-types" "^1.0.2" + "@walletconnect/jsonrpc-utils" "^1.0.7" + "@walletconnect/logger" "^2.0.1" + "@walletconnect/sign-client" "2.10.0" + "@walletconnect/types" "2.10.0" + "@walletconnect/utils" "2.10.0" + events "^3.3.0" + "@walletconnect/universal-provider@2.9.2": version "2.9.2" resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.9.2.tgz#40e54e98bc48b1f2f5f77eb5b7f05462093a8506" @@ -1460,6 +2347,26 @@ "@walletconnect/utils" "2.9.2" events "^3.3.0" +"@walletconnect/utils@2.10.0": + version "2.10.0" + resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.10.0.tgz#6918d12180d797b8bd4a19fb2ff128e394e181d6" + integrity sha512-9GRyEz/7CJW+G04RvrjPET5k7hOEsB9b3fF9cWDk/iDCxSWpbkU/hv/urRB36C+gvQMAZgIZYX3dHfzJWkY/2g== + dependencies: + "@stablelib/chacha20poly1305" "1.0.1" + "@stablelib/hkdf" "1.0.1" + "@stablelib/random" "^1.0.2" + "@stablelib/sha256" "1.0.1" + "@stablelib/x25519" "^1.0.3" + "@walletconnect/relay-api" "^1.0.9" + "@walletconnect/safe-json" "^1.0.2" + "@walletconnect/time" "^1.0.2" + "@walletconnect/types" "2.10.0" + "@walletconnect/window-getters" "^1.0.1" + "@walletconnect/window-metadata" "^1.0.1" + detect-browser "5.3.0" + query-string "7.1.3" + uint8arrays "^3.1.0" + "@walletconnect/utils@2.9.2": version "2.9.2" resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.9.2.tgz#035bdb859ee81a4bcc6420f56114cc5ec3e30afb" @@ -1480,13 +2387,38 @@ query-string "7.1.3" uint8arrays "^3.1.0" -"@walletconnect/window-getters@^1.0.1": +"@walletconnect/utils@^1.8.0": + version "1.8.0" + resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-1.8.0.tgz#2591a197c1fa7429941fe428876088fda6632060" + integrity sha512-zExzp8Mj1YiAIBfKNm5u622oNw44WOESzo6hj+Q3apSMIb0Jph9X3GDIdbZmvVZsNPxWDL7uodKgZcCInZv2vA== + dependencies: + "@walletconnect/browser-utils" "^1.8.0" + "@walletconnect/encoding" "^1.0.1" + "@walletconnect/jsonrpc-utils" "^1.0.3" + "@walletconnect/types" "^1.8.0" + bn.js "4.11.8" + js-sha3 "0.8.0" + query-string "6.13.5" + +"@walletconnect/window-getters@1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/window-getters/-/window-getters-1.0.0.tgz#1053224f77e725dfd611c83931b5f6c98c32bfc8" + integrity sha512-xB0SQsLaleIYIkSsl43vm8EwETpBzJ2gnzk7e0wMF3ktqiTGS6TFHxcprMl5R44KKh4tCcHCJwolMCaDSwtAaA== + +"@walletconnect/window-getters@^1.0.0", "@walletconnect/window-getters@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@walletconnect/window-getters/-/window-getters-1.0.1.tgz#f36d1c72558a7f6b87ecc4451fc8bd44f63cbbdc" integrity sha512-vHp+HqzGxORPAN8gY03qnbTMnhqIwjeRJNOMOAzePRg4xVEEE2WvYsI9G2NMjOknA8hnuYbU3/hwLcKbjhc8+Q== dependencies: tslib "1.14.1" +"@walletconnect/window-metadata@1.0.0": + version "1.0.0" + resolved "https://registry.yarnpkg.com/@walletconnect/window-metadata/-/window-metadata-1.0.0.tgz#93b1cc685e6b9b202f29c26be550fde97800c4e5" + integrity sha512-9eFvmJxIKCC3YWOL97SgRkKhlyGXkrHwamfechmqszbypFspaSk+t2jQXAEU7YClHF6Qjw5eYOmy1//zFi9/GA== + dependencies: + "@walletconnect/window-getters" "^1.0.0" + "@walletconnect/window-metadata@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@walletconnect/window-metadata/-/window-metadata-1.0.1.tgz#2124f75447b7e989e4e4e1581d55d25bc75f7be5" @@ -1495,6 +2427,66 @@ "@walletconnect/window-getters" "^1.0.1" tslib "1.14.1" +"@web3-onboard/common@^2.3.3": + version "2.3.3" + resolved "https://registry.yarnpkg.com/@web3-onboard/common/-/common-2.3.3.tgz#02096e967dbed272c0637cda955902b96a0fce06" + integrity sha512-Ytppszqe77VY8WglRdr/Lfx+HmcZ2hXQEkBA23JaVYmzKvP/mC6j+sjGUD8CgXDpRRxyKoiRj6nz95GRABie6Q== + dependencies: + bignumber.js "^9.1.0" + ethers "5.5.4" + joi "17.9.1" + +"@web3-onboard/core@^2.21.0": + version "2.21.0" + resolved "https://registry.yarnpkg.com/@web3-onboard/core/-/core-2.21.0.tgz#9055a9320f862911453010ba9a430a361c66202c" + integrity sha512-owxmSbCILFV0nQA46OGxcRrVdeZGL8SabBXll/PR0GAGsrZBYqNSE608ISd0luPt2Npy+dT8f8xUruFau+k/BA== + dependencies: + "@web3-onboard/common" "^2.3.3" + bignumber.js "^9.0.0" + bnc-sdk "^4.6.7" + bowser "^2.11.0" + ethers "5.5.3" + eventemitter3 "^4.0.7" + joi "17.9.1" + lodash.merge "^4.6.2" + lodash.partition "^4.6.0" + nanoid "^4.0.0" + rxjs "^7.5.5" + svelte "^3.49.0" + svelte-i18n "^3.3.13" + +"@web3-onboard/injected-wallets@^2.10.5": + version "2.10.5" + resolved "https://registry.yarnpkg.com/@web3-onboard/injected-wallets/-/injected-wallets-2.10.5.tgz#dde00818d184ba5d75034ef425676e8dfe01739b" + integrity sha512-pbjCrGHs2ydrGJ3gzm1mf6mhqNpnptWpbEr3hUOwyUZVnnQNGiWOP0bZHVSNqG2Xj061z2jhprugmjO4kenqBQ== + dependencies: + "@web3-onboard/common" "^2.3.3" + joi "17.9.1" + lodash.uniqby "^4.7.0" + +"@web3-onboard/react@^2.8.11": + version "2.8.11" + resolved "https://registry.yarnpkg.com/@web3-onboard/react/-/react-2.8.11.tgz#ce364bf11f09933baa609908a6bbff91be6537ca" + integrity sha512-wTvDQaIXKxe0xE++iykEzJ2Y9bY4XeJzptE23cgkZBQhlWbJZmVUKDBQrCbkdIM0+5Qq2AZYN6UMNgdoB3myxg== + dependencies: + "@web3-onboard/common" "^2.3.3" + "@web3-onboard/core" "^2.21.0" + use-sync-external-store "1.0.0" + +"@web3-onboard/walletconnect@^2.4.6": + version "2.4.6" + resolved "https://registry.yarnpkg.com/@web3-onboard/walletconnect/-/walletconnect-2.4.6.tgz#305b16a022f915356fd8b7547c89858bbd10498c" + integrity sha512-HsJHC++1/RSZIbYWGLCKkkmdu+8ITV3hkBeSQxvrnO9bcCBMY//+SBo2N7hPZqqSiRFvv2/UW4r4hELmhR4pdQ== + dependencies: + "@ethersproject/providers" "5.5.0" + "@walletconnect/client" "^1.8.0" + "@walletconnect/ethereum-provider" "^2.10.0" + "@walletconnect/modal" "2.6.1" + "@walletconnect/qrcode-modal" "^1.8.0" + "@web3-onboard/common" "^2.3.3" + joi "17.9.1" + rxjs "^7.5.2" + "@web3-react/abstract-connector@^6.0.7": version "6.0.7" resolved "https://registry.yarnpkg.com/@web3-react/abstract-connector/-/abstract-connector-6.0.7.tgz#401b3c045f1e0fab04256311be49d5144e9badc6" @@ -1534,6 +2526,11 @@ abitype@0.9.3: resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.3.tgz#294d25288ee683d72baf4e1fed757034e3c8c277" integrity sha512-dz4qCQLurx97FQhnb/EIYTk/ldQ+oafEDUqC0VVIeQS1Q48/YWt/9YNfMmp9SLFqN41ktxny3c8aYxHjmFIB/w== +aes-js@3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.0.0.tgz#e21df10ad6c2053295bcbb8dab40b09dbea87e4d" + integrity sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw== + aes-js@^3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.1.2.tgz#db9aabde85d5caabbfc0d4f2a4446960f627146a" @@ -1551,11 +2548,23 @@ ahocorasick@1.0.2: resolved "https://registry.yarnpkg.com/ahocorasick/-/ahocorasick-1.0.2.tgz#9eee93aef9d02bfb476d9b648d9b7a40ef2fd500" integrity sha512-hCOfMzbFx5IDutmWLAt6MZwOUjIfSM9G9FyVxytmE4Rs/5YDPWQrD/+IR1w+FweD9H2oOZEnv36TmkjhNURBVA== +ansi-regex@^4.1.0: + version "4.1.1" + resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.1.tgz#164daac87ab2d6f6db3a29875e2d1766582dabed" + integrity sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g== + ansi-regex@^5.0.1: version "5.0.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-5.0.1.tgz#082cb2c89c9fe8659a311a53bd6a4dc5301db304" integrity sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ== +ansi-styles@^3.2.0: + version "3.2.1" + resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d" + integrity sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA== + dependencies: + color-convert "^1.9.0" + ansi-styles@^4.0.0, ansi-styles@^4.1.0: version "4.3.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" @@ -1599,6 +2608,11 @@ base64-js@^1.3.1: resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" integrity sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA== +bech32@1.1.4: + version "1.1.4" + resolved "https://registry.yarnpkg.com/bech32/-/bech32-1.1.4.tgz#e38c9f37bf179b8eb16ae3a772b40c356d4832e9" + integrity sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ== + bigint-buffer@^1.1.5: version "1.1.5" resolved "https://registry.yarnpkg.com/bigint-buffer/-/bigint-buffer-1.1.5.tgz#d038f31c8e4534c1f8d0015209bf34b4fa6dd442" @@ -1606,6 +2620,11 @@ bigint-buffer@^1.1.5: dependencies: bindings "^1.3.0" +bignumber.js@^9.0.0, bignumber.js@^9.1.0: + version "9.1.2" + resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.1.2.tgz#b7c4242259c008903b13707983b5f4bbd31eda0c" + integrity sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug== + bind-decorator@^1.0.11: version "1.0.11" resolved "https://registry.yarnpkg.com/bind-decorator/-/bind-decorator-1.0.11.tgz#e41bc06a1f65dd9cec476c91c5daf3978488252f" @@ -1618,6 +2637,11 @@ bindings@^1.3.0: dependencies: file-uri-to-path "1.0.0" +bn.js@4.11.8: + version "4.11.8" + resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" + integrity sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA== + bn.js@^4.11.9, bn.js@^4.4.0: version "4.12.0" resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" @@ -1628,6 +2652,16 @@ bn.js@^5.1.1, bn.js@^5.2.0, bn.js@^5.2.1: resolved "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== +bnc-sdk@^4.6.7: + version "4.6.7" + resolved "https://registry.yarnpkg.com/bnc-sdk/-/bnc-sdk-4.6.7.tgz#138a22e04c95c2c697fb836092358d21957e2114" + integrity sha512-jIQ6cmeRBgvH/YDLuYRr2+kxDGcAAi0SOvjlO5nQ5cWdbslw+ASWftd1HmxiVLNCiwEH5bSc/t8a0agZ5njTUQ== + dependencies: + crypto-es "^1.2.2" + nanoid "^3.3.1" + rxjs "^6.6.3" + sturdy-websocket "^0.1.12" + borsh@^0.7.0: version "0.7.0" resolved "https://registry.yarnpkg.com/borsh/-/borsh-0.7.0.tgz#6e9560d719d86d90dc589bca60ffc8a6c51fec2a" @@ -1637,6 +2671,11 @@ borsh@^0.7.0: bs58 "^4.0.0" text-encoding-utf-8 "^1.0.2" +bowser@^2.11.0: + version "2.11.0" + resolved "https://registry.yarnpkg.com/bowser/-/bowser-2.11.0.tgz#5ca3c35757a7aa5771500c70a73a9f91ef420a8f" + integrity sha512-AlcaJBi/pqqJBIQ8U9Mcpc9i8Aqxn88Skv5d+xBX006BY5u8N3mGLHa5Lgppa7L/HfwgwLgZ6NYs+Ag6uUmJRA== + brorand@^1.1.0: version "1.1.0" resolved "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" @@ -1649,7 +2688,25 @@ bs58@^4.0.0, bs58@^4.0.1: dependencies: base-x "^3.0.2" -buffer-from@^1.1.2: +buffer-alloc-unsafe@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/buffer-alloc-unsafe/-/buffer-alloc-unsafe-1.1.0.tgz#bd7dc26ae2972d0eda253be061dba992349c19f0" + integrity sha512-TEM2iMIEQdJ2yjPJoSIsldnleVaAk1oW3DBVUykyOLsEsFmEc9kn+SFFPz+gl54KQNxlDnAwCXosOS9Okx2xAg== + +buffer-alloc@^1.2.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/buffer-alloc/-/buffer-alloc-1.2.0.tgz#890dd90d923a873e08e10e5fd51a57e5b7cce0ec" + integrity sha512-CFsHQgjtW1UChdXgbyJGtnm+O/uLQeZdtbDo8mfUgYXCHSM1wgrVxXm6bSyrUuErEb+4sYVGCzASBRot7zyrow== + dependencies: + buffer-alloc-unsafe "^1.1.0" + buffer-fill "^1.0.0" + +buffer-fill@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/buffer-fill/-/buffer-fill-1.0.0.tgz#f8f78b76789888ef39f205cd637f68e702122b2c" + integrity sha512-T7zexNBwiiaCOGDg9xNX9PBmjrubblRkENuptryuI64URkXDFum9il/JGL8Lm8wYfAXpredVXXZz7eMHilimiQ== + +buffer-from@^1.1.1, buffer-from@^1.1.2: version "1.1.2" resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== @@ -1662,6 +2719,14 @@ buffer@6.0.3, buffer@^6.0.3, buffer@~6.0.3: base64-js "^1.3.1" ieee754 "^1.2.1" +buffer@^5.4.3: + version "5.7.1" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.7.1.tgz#ba62e7c13133053582197160851a8f648e99eed0" + integrity sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ== + dependencies: + base64-js "^1.3.1" + ieee754 "^1.1.13" + bufferutil@^4.0.1: version "4.0.7" resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.7.tgz#60c0d19ba2c992dd8273d3f73772ffc894c153ad" @@ -1690,6 +2755,26 @@ chalk@^4.1.1: ansi-styles "^4.1.0" supports-color "^7.1.0" +cli-color@^2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/cli-color/-/cli-color-2.0.3.tgz#73769ba969080629670f3f2ef69a4bf4e7cc1879" + integrity sha512-OkoZnxyC4ERN3zLzZaY9Emb7f/MhBOIpePv0Ycok0fJYT+Ouo00UBEIwsVsr0yoow++n5YWlSUgST9GKhNHiRQ== + dependencies: + d "^1.0.1" + es5-ext "^0.10.61" + es6-iterator "^2.0.3" + memoizee "^0.4.15" + timers-ext "^0.1.7" + +cliui@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/cliui/-/cliui-5.0.0.tgz#deefcfdb2e800784aa34f46fa08e06851c7bbbc5" + integrity sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA== + dependencies: + string-width "^3.1.0" + strip-ansi "^5.2.0" + wrap-ansi "^5.1.0" + cliui@^6.0.0: version "6.0.0" resolved "https://registry.yarnpkg.com/cliui/-/cliui-6.0.0.tgz#511d702c0c4e41ca156d7d0e96021f23e13225b1" @@ -1709,6 +2794,13 @@ clsx@^1.1.0, clsx@^1.1.1, clsx@^1.2.1: resolved "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== +color-convert@^1.9.0: + version "1.9.3" + resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-1.9.3.tgz#bb71850690e1f136567de629d2d5471deda4c1e8" + integrity sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg== + dependencies: + color-name "1.1.3" + color-convert@^2.0.1: version "2.0.1" resolved "https://registry.yarnpkg.com/color-convert/-/color-convert-2.0.1.tgz#72d3a68d598c9bdb3af2ad1e84f21d896abd4de3" @@ -1716,6 +2808,11 @@ color-convert@^2.0.1: dependencies: color-name "~1.1.4" +color-name@1.1.3: + version "1.1.3" + resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.3.tgz#a7d0558bd89c42f795dd42328f740831ca53bc25" + integrity sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw== + color-name@~1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.4.tgz#c2a09a87acbde69543de6f63fa3995c826c536a2" @@ -1734,7 +2831,7 @@ commander@^2.20.3: resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== -copy-to-clipboard@^3.3.3: +copy-to-clipboard@^3.3.1, copy-to-clipboard@^3.3.3: version "3.3.3" resolved "https://registry.yarnpkg.com/copy-to-clipboard/-/copy-to-clipboard-3.3.3.tgz#55ac43a1db8ae639a4bd99511c148cdd1b83a1b0" integrity sha512-2KV8NhB5JqC3ky0r9PMCAZKbUHSwtEo4CwCs0KXgruG43gX5PMqDEBbVU4OUzw2MuAWUfsuFmWvEKG5QRfSnJA== @@ -1760,6 +2857,11 @@ cross-fetch@^4.0.0: dependencies: node-fetch "^2.6.12" +crypto-es@^1.2.2: + version "1.2.7" + resolved "https://registry.yarnpkg.com/crypto-es/-/crypto-es-1.2.7.tgz#754a6d52319a94fb4eb1f119297f17196b360f88" + integrity sha512-UUqiVJ2gUuZFmbFsKmud3uuLcNP2+Opt+5ysmljycFCyhA0+T16XJmo1ev/t5kMChMqWh7IEvURNCqsg+SjZGQ== + crypto-js@^4.1.1: version "4.1.1" resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" @@ -1785,6 +2887,14 @@ custom-error-instance@2.1.1: resolved "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz" integrity sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg== +d@1, d@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/d/-/d-1.0.1.tgz#8698095372d58dbee346ffd0c7093f99f8f9eb5a" + integrity sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA== + dependencies: + es5-ext "^0.10.50" + type "^1.0.1" + date-fns@^2.28.0: version "2.30.0" resolved "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz" @@ -1824,6 +2934,11 @@ delay@^5.0.0: resolved "https://registry.yarnpkg.com/delay/-/delay-5.0.0.tgz#137045ef1b96e5071060dd5be60bf9334436bd1d" integrity sha512-ReEBKkIfe4ya47wlPYf/gu5ib6yUG0/Aez0JQZQz94kiWtRQvZIQbTiehsnwHvLSWJnQdhVeqYue7Id1dKr0qw== +detect-browser@5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/detect-browser/-/detect-browser-5.2.0.tgz#c9cd5afa96a6a19fda0bbe9e9be48a6b6e1e9c97" + integrity sha512-tr7XntDAu50BVENgQfajMLzacmSe34D+qZc4zjnniz0ZVuw/TZcLcyxHQjYpJTM36sGEkZZlYLnIM1hH7alTMA== + detect-browser@5.3.0, detect-browser@^5.3.0: version "5.3.0" resolved "https://registry.yarnpkg.com/detect-browser/-/detect-browser-5.3.0.tgz#9705ef2bddf46072d0f7265a1fe300e36fe7ceca" @@ -1899,6 +3014,11 @@ emoji-picker-react@^4.4.9: dependencies: clsx "^1.2.1" +emoji-regex@^7.0.1: + version "7.0.3" + resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-7.0.3.tgz#933a04052860c85e83c122479c4748a8e4c72156" + integrity sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA== + emoji-regex@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" @@ -1942,6 +3062,24 @@ entities@^3.0.1: resolved "https://registry.npmjs.org/entities/-/entities-3.0.1.tgz" integrity sha512-WiyBqoomrwMdFG1e0kqvASYfnlb0lp8M5o5Fw2OFq1hNZxxcNk8Ik0Xm7LxzBhuidnZB/UtBqVCgUz3kBOP51Q== +es5-ext@^0.10.35, es5-ext@^0.10.46, es5-ext@^0.10.50, es5-ext@^0.10.53, es5-ext@^0.10.61, es5-ext@~0.10.14, es5-ext@~0.10.2, es5-ext@~0.10.46: + version "0.10.62" + resolved "https://registry.yarnpkg.com/es5-ext/-/es5-ext-0.10.62.tgz#5e6adc19a6da524bf3d1e02bbc8960e5eb49a9a5" + integrity sha512-BHLqn0klhEpnOKSrzn/Xsz2UIW8j+cGmo9JLzr8BiUapV8hPL9+FliFqjwr9ngW7jWdnxv6eO+/LqyhJVqgrjA== + dependencies: + es6-iterator "^2.0.3" + es6-symbol "^3.1.3" + next-tick "^1.1.0" + +es6-iterator@^2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/es6-iterator/-/es6-iterator-2.0.3.tgz#a7de889141a05a94b0854403b2d0a0fbfa98f3b7" + integrity sha512-zw4SRzoUkd+cl+ZoE15A9o1oQd920Bb0iOJMQkQhl3jNc03YqVjAhG7scf9C5KWRU/R13Orf588uCC6525o02g== + dependencies: + d "1" + es5-ext "^0.10.35" + es6-symbol "^3.1.1" + es6-promise@^4.0.3: version "4.2.8" resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" @@ -1954,6 +3092,57 @@ es6-promisify@^5.0.0: dependencies: es6-promise "^4.0.3" +es6-symbol@^3.1.1, es6-symbol@^3.1.3: + version "3.1.3" + resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" + integrity sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA== + dependencies: + d "^1.0.1" + ext "^1.1.2" + +es6-weak-map@^2.0.3: + version "2.0.3" + resolved "https://registry.yarnpkg.com/es6-weak-map/-/es6-weak-map-2.0.3.tgz#b6da1f16cc2cc0d9be43e6bdbfc5e7dfcdf31d53" + integrity sha512-p5um32HOTO1kP+w7PRnB+5lQ43Z6muuMuIMffvDN8ZB4GcnjLBV6zGStpbASIMk4DCAvEaamhe2zhyCb/QXXsA== + dependencies: + d "1" + es5-ext "^0.10.46" + es6-iterator "^2.0.3" + es6-symbol "^3.1.1" + +esbuild@^0.19.2: + version "0.19.2" + resolved "https://registry.yarnpkg.com/esbuild/-/esbuild-0.19.2.tgz#b1541828a89dfb6f840d38538767c6130dca2aac" + integrity sha512-G6hPax8UbFakEj3hWO0Vs52LQ8k3lnBhxZWomUJDxfz3rZTLqF5k/FCzuNdLx2RbpBiQQF9H9onlDDH1lZsnjg== + optionalDependencies: + "@esbuild/android-arm" "0.19.2" + "@esbuild/android-arm64" "0.19.2" + "@esbuild/android-x64" "0.19.2" + "@esbuild/darwin-arm64" "0.19.2" + "@esbuild/darwin-x64" "0.19.2" + "@esbuild/freebsd-arm64" "0.19.2" + "@esbuild/freebsd-x64" "0.19.2" + "@esbuild/linux-arm" "0.19.2" + "@esbuild/linux-arm64" "0.19.2" + "@esbuild/linux-ia32" "0.19.2" + "@esbuild/linux-loong64" "0.19.2" + "@esbuild/linux-mips64el" "0.19.2" + "@esbuild/linux-ppc64" "0.19.2" + "@esbuild/linux-riscv64" "0.19.2" + "@esbuild/linux-s390x" "0.19.2" + "@esbuild/linux-x64" "0.19.2" + "@esbuild/netbsd-x64" "0.19.2" + "@esbuild/openbsd-x64" "0.19.2" + "@esbuild/sunos-x64" "0.19.2" + "@esbuild/win32-arm64" "0.19.2" + "@esbuild/win32-ia32" "0.19.2" + "@esbuild/win32-x64" "0.19.2" + +estree-walker@^2: + version "2.0.2" + resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" + integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== + eth-block-tracker@6.1.0: version "6.1.0" resolved "https://registry.yarnpkg.com/eth-block-tracker/-/eth-block-tracker-6.1.0.tgz#0481f97bbb88a100b9d45806fe7e37af741cbefc" @@ -1997,6 +3186,122 @@ eth-rpc-errors@^4.0.2: dependencies: fast-safe-stringify "^2.0.6" +ethers@5.5.3: + version "5.5.3" + resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.5.3.tgz#1e361516711c0c3244b6210e7e3ecabf0c75fca0" + integrity sha512-fTT4WT8/hTe/BLwRUtl7I5zlpF3XC3P/Xwqxc5AIP2HGlH15qpmjs0Ou78az93b1rLITzXLFxoNX63B8ZbUd7g== + dependencies: + "@ethersproject/abi" "5.5.0" + "@ethersproject/abstract-provider" "5.5.1" + "@ethersproject/abstract-signer" "5.5.0" + "@ethersproject/address" "5.5.0" + "@ethersproject/base64" "5.5.0" + "@ethersproject/basex" "5.5.0" + "@ethersproject/bignumber" "5.5.0" + "@ethersproject/bytes" "5.5.0" + "@ethersproject/constants" "5.5.0" + "@ethersproject/contracts" "5.5.0" + "@ethersproject/hash" "5.5.0" + "@ethersproject/hdnode" "5.5.0" + "@ethersproject/json-wallets" "5.5.0" + "@ethersproject/keccak256" "5.5.0" + "@ethersproject/logger" "5.5.0" + "@ethersproject/networks" "5.5.2" + "@ethersproject/pbkdf2" "5.5.0" + "@ethersproject/properties" "5.5.0" + "@ethersproject/providers" "5.5.2" + "@ethersproject/random" "5.5.1" + "@ethersproject/rlp" "5.5.0" + "@ethersproject/sha2" "5.5.0" + "@ethersproject/signing-key" "5.5.0" + "@ethersproject/solidity" "5.5.0" + "@ethersproject/strings" "5.5.0" + "@ethersproject/transactions" "5.5.0" + "@ethersproject/units" "5.5.0" + "@ethersproject/wallet" "5.5.0" + "@ethersproject/web" "5.5.1" + "@ethersproject/wordlists" "5.5.0" + +ethers@5.5.4: + version "5.5.4" + resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.5.4.tgz#e1155b73376a2f5da448e4a33351b57a885f4352" + integrity sha512-N9IAXsF8iKhgHIC6pquzRgPBJEzc9auw3JoRkaKe+y4Wl/LFBtDDunNe7YmdomontECAcC5APaAgWZBiu1kirw== + dependencies: + "@ethersproject/abi" "5.5.0" + "@ethersproject/abstract-provider" "5.5.1" + "@ethersproject/abstract-signer" "5.5.0" + "@ethersproject/address" "5.5.0" + "@ethersproject/base64" "5.5.0" + "@ethersproject/basex" "5.5.0" + "@ethersproject/bignumber" "5.5.0" + "@ethersproject/bytes" "5.5.0" + "@ethersproject/constants" "5.5.0" + "@ethersproject/contracts" "5.5.0" + "@ethersproject/hash" "5.5.0" + "@ethersproject/hdnode" "5.5.0" + "@ethersproject/json-wallets" "5.5.0" + "@ethersproject/keccak256" "5.5.0" + "@ethersproject/logger" "5.5.0" + "@ethersproject/networks" "5.5.2" + "@ethersproject/pbkdf2" "5.5.0" + "@ethersproject/properties" "5.5.0" + "@ethersproject/providers" "5.5.3" + "@ethersproject/random" "5.5.1" + "@ethersproject/rlp" "5.5.0" + "@ethersproject/sha2" "5.5.0" + "@ethersproject/signing-key" "5.5.0" + "@ethersproject/solidity" "5.5.0" + "@ethersproject/strings" "5.5.0" + "@ethersproject/transactions" "5.5.0" + "@ethersproject/units" "5.5.0" + "@ethersproject/wallet" "5.5.0" + "@ethersproject/web" "5.5.1" + "@ethersproject/wordlists" "5.5.0" + +ethers@^5.6.8: + version "5.7.2" + resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.7.2.tgz#3a7deeabbb8c030d4126b24f84e525466145872e" + integrity sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg== + dependencies: + "@ethersproject/abi" "5.7.0" + "@ethersproject/abstract-provider" "5.7.0" + "@ethersproject/abstract-signer" "5.7.0" + "@ethersproject/address" "5.7.0" + "@ethersproject/base64" "5.7.0" + "@ethersproject/basex" "5.7.0" + "@ethersproject/bignumber" "5.7.0" + "@ethersproject/bytes" "5.7.0" + "@ethersproject/constants" "5.7.0" + "@ethersproject/contracts" "5.7.0" + "@ethersproject/hash" "5.7.0" + "@ethersproject/hdnode" "5.7.0" + "@ethersproject/json-wallets" "5.7.0" + "@ethersproject/keccak256" "5.7.0" + "@ethersproject/logger" "5.7.0" + "@ethersproject/networks" "5.7.1" + "@ethersproject/pbkdf2" "5.7.0" + "@ethersproject/properties" "5.7.0" + "@ethersproject/providers" "5.7.2" + "@ethersproject/random" "5.7.0" + "@ethersproject/rlp" "5.7.0" + "@ethersproject/sha2" "5.7.0" + "@ethersproject/signing-key" "5.7.0" + "@ethersproject/solidity" "5.7.0" + "@ethersproject/strings" "5.7.0" + "@ethersproject/transactions" "5.7.0" + "@ethersproject/units" "5.7.0" + "@ethersproject/wallet" "5.7.0" + "@ethersproject/web" "5.7.1" + "@ethersproject/wordlists" "5.7.0" + +event-emitter@^0.3.5: + version "0.3.5" + resolved "https://registry.yarnpkg.com/event-emitter/-/event-emitter-0.3.5.tgz#df8c69eef1647923c7157b9ce83840610b02cc39" + integrity sha512-D9rRn9y7kLPnJ+hMq7S/nhvoKwwvVJahBi2BPmx3bvbsEdK3W9ii8cBSGjP+72/LnM4n6fo3+dkCX5FeTQruXA== + dependencies: + d "1" + es5-ext "~0.10.14" + eventemitter3@^4.0.7: version "4.0.7" resolved "https://registry.yarnpkg.com/eventemitter3/-/eventemitter3-4.0.7.tgz#2de9b68f6528d5644ef5c59526a1b4a07306169f" @@ -2007,6 +3312,13 @@ events@^3.3.0: resolved "https://registry.yarnpkg.com/events/-/events-3.3.0.tgz#31a95ad0a924e2d2c419a813aeb2c4e878ea7400" integrity sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q== +ext@^1.1.2: + version "1.7.0" + resolved "https://registry.yarnpkg.com/ext/-/ext-1.7.0.tgz#0ea4383c0103d60e70be99e9a7f11027a33c4f5f" + integrity sha512-6hxeJYaL110a9b5TEJSj0gojyHQAmA2ch5Os+ySCiA1QGdS697XWY1pzsrSjqA9LDEEgdB/KypIlR59RcLuHYw== + dependencies: + type "^2.7.2" + eyes@^0.1.8: version "0.1.8" resolved "https://registry.yarnpkg.com/eyes/-/eyes-0.1.8.tgz#62cf120234c683785d902348a800ef3e0cc20bc0" @@ -2037,6 +3349,13 @@ filter-obj@^1.1.0: resolved "https://registry.yarnpkg.com/filter-obj/-/filter-obj-1.1.0.tgz#9b311112bc6c6127a16e016c6c5d7f19e0805c5b" integrity sha512-8rXg1ZnX7xzy2NGDVkBVaAy+lSlPNwad13BtgSlLuxfIslyt5Vg64U7tFcCt4WS1R0hvtnQybT/IyCkGZ3DpXQ== +find-up@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/find-up/-/find-up-3.0.0.tgz#49169f1d7993430646da61ecc5ae355c21c97b73" + integrity sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg== + dependencies: + locate-path "^3.0.0" + find-up@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/find-up/-/find-up-4.1.0.tgz#97afe7d6cdc0bc5928584b7c8d7b16e8a9aa5d19" @@ -2087,6 +3406,16 @@ gif-picker-react@^1.1.0: resolved "https://registry.npmjs.org/gif-picker-react/-/gif-picker-react-1.3.0.tgz" integrity sha512-IYDmx9iEouC84JCrOt/HSaiRgHD8o7/catZCspUVpNEXoIunq7CF65JcmyTyoPkVJZcQz0ofjU5Gp5C2bqwOlQ== +globalyzer@0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/globalyzer/-/globalyzer-0.1.0.tgz#cb76da79555669a1519d5a8edf093afaa0bf1465" + integrity sha512-40oNTM9UfG6aBmuKxk/giHn5nQ8RVz/SS4Ir6zgzOv9/qC3kKZ9v4etGTcJbEl/NyVQH7FGU7d+X1egr57Md2Q== + +globrex@^0.1.2: + version "0.1.2" + resolved "https://registry.yarnpkg.com/globrex/-/globrex-0.1.2.tgz#dd5d9ec826232730cd6793a5e33a9302985e6098" + integrity sha512-uHJgbwAMwNFf5mLst7IWLNg14x1CkeqglJb/K3doi4dw6q2IvAAmM/Y81kevy83wP+Sst+nutFTYOGg3d1lsxg== + gopd@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" @@ -2190,7 +3519,7 @@ humanize-ms@^1.2.1: dependencies: ms "^2.0.0" -ieee754@^1.2.1: +ieee754@^1.1.13, ieee754@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== @@ -2205,6 +3534,16 @@ inline-style-parser@0.1.1: resolved "https://registry.npmjs.org/inline-style-parser/-/inline-style-parser-0.1.1.tgz" integrity sha512-7NXolsK4CAS5+xvdj5OMMbI962hU/wvwoxk+LWR9Ek9bVtyuuYScDN6eS0rUm6TxApFpw7CX1o4uJzcd4AyD3Q== +intl-messageformat@^9.13.0: + version "9.13.0" + resolved "https://registry.yarnpkg.com/intl-messageformat/-/intl-messageformat-9.13.0.tgz#97360b73bd82212e4f6005c712a4a16053165468" + integrity sha512-7sGC7QnSQGa5LZP7bXLDhVDtQOeKGeBFGHF2Y8LVBwYZoQZCgWeKoPGTa5GMG8g/TzDgeXuYJQis7Ggiw2xTOw== + dependencies: + "@formatjs/ecma402-abstract" "1.11.4" + "@formatjs/fast-memoize" "1.2.1" + "@formatjs/icu-messageformat-parser" "2.1.0" + tslib "^2.1.0" + invariant@^2.2.4: version "2.2.4" resolved "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz" @@ -2225,6 +3564,11 @@ is-callable@^1.1.3: resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== +is-fullwidth-code-point@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" + integrity sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w== + is-fullwidth-code-point@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" @@ -2237,6 +3581,11 @@ is-generator-function@^1.0.7: dependencies: has-tostringtag "^1.0.0" +is-promise@^2.2.2: + version "2.2.2" + resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1" + integrity sha512-+lP4/6lKUBfQjZ2pdxThZvLUAafmZb8OAxFb8XXtiQmS35INgr85hdOGoEs124ez1FCnZJt6jau/T+alh58QFQ== + is-stream@^2.0.0: version "2.0.1" resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" @@ -2254,6 +3603,11 @@ is-typedarray@1.0.0, is-typedarray@^1.0.0: resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" integrity sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA== +isarray@^2.0.1: + version "2.0.5" + resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723" + integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== + isomorphic-ws@5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-5.0.0.tgz#e5529148912ecb9b451b46ed44d53dae1ce04bbf" @@ -2282,6 +3636,17 @@ jayson@^4.1.0: uuid "^8.3.2" ws "^7.4.5" +joi@17.9.1: + version "17.9.1" + resolved "https://registry.yarnpkg.com/joi/-/joi-17.9.1.tgz#74899b9fa3646904afa984a11df648eca66c9018" + integrity sha512-FariIi9j6QODKATGBrEX7HZcja8Bsh3rfdGYy/Sb65sGlZWK/QWesU1ghk7aJWDj95knjXlQfSmzFSPPkLVsfw== + dependencies: + "@hapi/hoek" "^9.0.0" + "@hapi/topo" "^5.0.0" + "@sideway/address" "^4.1.3" + "@sideway/formula" "^3.0.1" + "@sideway/pinpoint" "^2.0.0" + js-base64@^3.7.2: version "3.7.5" resolved "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz" @@ -2373,6 +3738,14 @@ livepeer@2.8.0: tus-js-client "^3.1.0" zustand "^4.3.9" +locate-path@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-3.0.0.tgz#dbec3b3ab759758071b58fe59fc41871af21400e" + integrity sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A== + dependencies: + p-locate "^3.0.0" + path-exists "^3.0.0" + locate-path@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/locate-path/-/locate-path-5.0.0.tgz#1afba396afd676a6d42504d0a67a3a7eb9f62aa0" @@ -2417,11 +3790,26 @@ lodash._stringtopath@~4.8.0: dependencies: lodash._basetostring "~4.12.0" +lodash.defaults@^4.2.0: + version "4.2.0" + resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c" + integrity sha512-qjxPLHd3r5DnsdGacqOMU6pb/avJzdh9tFX2ymgoZE27BmjXrNy/y4LoaiTeAb+O3gL8AfpJGtqfX/ae2leYYQ== + lodash.isequal@4.5.0: version "4.5.0" resolved "https://registry.yarnpkg.com/lodash.isequal/-/lodash.isequal-4.5.0.tgz#415c4478f2bcc30120c22ce10ed3226f7d3e18e0" integrity sha512-pDo3lu8Jhfjqls6GkMgpahsF9kCyayhgykjyLMNFTKWrpVdAQtYyB4muAMWozBB4ig/dtWAmsMxLEI8wuz+DYQ== +lodash.merge@^4.6.2: + version "4.6.2" + resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.2.tgz#558aa53b43b661e1925a0afdfa36a9a1085fe57a" + integrity sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ== + +lodash.partition@^4.6.0: + version "4.6.0" + resolved "https://registry.yarnpkg.com/lodash.partition/-/lodash.partition-4.6.0.tgz#a38e46b73469e0420b0da1212e66d414be364ba4" + integrity sha512-35L3dSF3Q6V1w5j6V3NhNlQjzsRDC/pYKCTdYTmwqSib+Q8ponkAmt/PwEOq3EmI38DSCl+SkIVwLd+uSlVdrg== + lodash.throttle@^4.1.1: version "4.1.1" resolved "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz" @@ -2435,6 +3823,11 @@ lodash.uniqby@4.5.0: lodash._baseiteratee "~4.7.0" lodash._baseuniq "~4.6.0" +lodash.uniqby@^4.7.0: + version "4.7.0" + resolved "https://registry.yarnpkg.com/lodash.uniqby/-/lodash.uniqby-4.7.0.tgz#d99c07a669e9e6d24e1362dfe266c67616af1302" + integrity sha512-e/zcLx6CSbmaEgFHCA7BnoQKyCtKMxnuWrJygbwPs/AIn+IMKl66L8/s+wBUn5LRw2pZx3bUHibiV1b6aTWIww== + loose-envify@^1.0.0: version "1.4.0" resolved "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz" @@ -2449,6 +3842,13 @@ lru-cache@^6.0.0: dependencies: yallist "^4.0.0" +lru-queue@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/lru-queue/-/lru-queue-0.1.0.tgz#2738bd9f0d3cf4f84490c5736c48699ac632cda3" + integrity sha512-BpdYkt9EvGl8OfWHDQPISVpcl5xZthb+XPsbELj5AQXxIC8IriDZIQYjBJPEm5rS420sjZ0TLEzRcq5KdBhYrQ== + dependencies: + es5-ext "~0.10.2" + media-query-parser@^2.0.2: version "2.0.2" resolved "https://registry.yarnpkg.com/media-query-parser/-/media-query-parser-2.0.2.tgz#ff79e56cee92615a304a1c2fa4f2bd056c0a1d29" @@ -2456,6 +3856,20 @@ media-query-parser@^2.0.2: dependencies: "@babel/runtime" "^7.12.5" +memoizee@^0.4.15: + version "0.4.15" + resolved "https://registry.yarnpkg.com/memoizee/-/memoizee-0.4.15.tgz#e6f3d2da863f318d02225391829a6c5956555b72" + integrity sha512-UBWmJpLZd5STPm7PMUlOw/TSy972M+z8gcyQ5veOnSDRREz/0bmpyTfKt3/51DhEBqCZQn1udM/5flcSPYhkdQ== + dependencies: + d "^1.0.1" + es5-ext "^0.10.53" + es6-weak-map "^2.0.3" + event-emitter "^0.3.5" + is-promise "^2.2.2" + lru-queue "^0.1.0" + next-tick "^1.1.0" + timers-ext "^0.1.7" + minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" resolved "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz" @@ -2483,6 +3897,11 @@ motion@10.16.2: "@motionone/utils" "^10.15.1" "@motionone/vue" "^10.16.2" +mri@^1.1.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/mri/-/mri-1.2.0.tgz#6721480fec2a11a4889861115a48b6cbe7cc8f0b" + integrity sha512-tzzskb3bG8LvYGFF/mDTpq3jpI6Q9wc3LEmBaghu+DdCssd1FakN7Bc0hVNmEyGq1bq3RgfkCb3cmQLpNPOroA== + ms@2.1.2: version "2.1.2" resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" @@ -2503,6 +3922,21 @@ multiformats@9.9.0, multiformats@^9.4.2: resolved "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz" integrity sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg== +nanoid@^3.3.1: + version "3.3.6" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-3.3.6.tgz#443380c856d6e9f9824267d960b4236ad583ea4c" + integrity sha512-BGcqMMJuToF7i1rt+2PWSNVnWIkGCU78jBG3RxO/bZlnZPK2Cmi2QaffxGO/2RvWi9sL+FAiRiXMgsyxQ1DIDA== + +nanoid@^4.0.0: + version "4.0.2" + resolved "https://registry.yarnpkg.com/nanoid/-/nanoid-4.0.2.tgz#140b3c5003959adbebf521c170f282c5e7f9fb9e" + integrity sha512-7ZtY5KTCNheRGfEFxnedV5zFiORN1+Y1N6zvPTnHQd8ENUvfaDBeuJDZb2bN/oXwXxu3qkTXDzy57W5vAmDTBw== + +next-tick@1, next-tick@^1.1.0: + version "1.1.0" + resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.1.0.tgz#1836ee30ad56d67ef281b22bd199f709449b35eb" + integrity sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ== + node-addon-api@^2.0.0: version "2.0.2" resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-2.0.2.tgz#432cfa82962ce494b132e9d72a15b29f71ff5d32" @@ -2542,13 +3976,20 @@ outdent@^0.8.0: resolved "https://registry.yarnpkg.com/outdent/-/outdent-0.8.0.tgz#2ebc3e77bf49912543f1008100ff8e7f44428eb0" integrity sha512-KiOAIsdpUTcAXuykya5fnVVT+/5uS0Q1mrkRHcF89tpieSmY33O/tmc54CqwA+bfhbtEfZUNLHaPUiB9X3jt1A== -p-limit@^2.2.0: +p-limit@^2.0.0, p-limit@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" integrity sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w== dependencies: p-try "^2.0.0" +p-locate@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-3.0.0.tgz#322d69a05c0264b25997d9f40cd8a891ab0064a4" + integrity sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ== + dependencies: + p-limit "^2.0.0" + p-locate@^4.1.0: version "4.1.0" resolved "https://registry.yarnpkg.com/p-locate/-/p-locate-4.1.0.tgz#a3428bb7088b3a60292f66919278b7c297ad4f07" @@ -2561,6 +4002,11 @@ p-try@^2.0.0: resolved "https://registry.yarnpkg.com/p-try/-/p-try-2.2.0.tgz#cb2868540e313d61de58fafbe35ce9004d5540e6" integrity sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ== +path-exists@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" + integrity sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ== + path-exists@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" @@ -2606,11 +4052,21 @@ pino@7.11.0: sonic-boom "^2.2.1" thread-stream "^0.15.1" +pngjs@^3.3.0: + version "3.4.0" + resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-3.4.0.tgz#99ca7d725965fb655814eaf65f38f12bbdbf555f" + integrity sha512-NCrCHhWmnQklfH4MtJMRjZ2a8c80qXeMlQMv2uVp9ISJMTt562SbGd6n2oq0PaPgKm7Z6pL9E2UlLIhC+SHL3w== + pngjs@^5.0.0: version "5.0.0" resolved "https://registry.yarnpkg.com/pngjs/-/pngjs-5.0.0.tgz#e79dd2b215767fd9c04561c01236df960bce7fbb" integrity sha512-40QW5YalBNfQo5yRYmiw7Yz6TKKVr3h6970B2YE+3fQpsWcrbj1PzJgxeJ19DRQjhMbKPIuMY8rFaXc8moolVw== +preact@10.4.1: + version "10.4.1" + resolved "https://registry.yarnpkg.com/preact/-/preact-10.4.1.tgz#9b3ba020547673a231c6cf16f0fbaef0e8863431" + integrity sha512-WKrRpCSwL2t3tpOOGhf2WfTpcmbpxaWtDbdJdKdjd0aEiTkvOmS4NBkG6kzlaAHI9AkQ3iVqbFWM3Ei7mZ4o1Q== + preact@^10.12.0, preact@^10.5.9: version "10.17.0" resolved "https://registry.yarnpkg.com/preact/-/preact-10.17.0.tgz#77c0e3402767c999ac0f1ba39bd43cd85beab06b" @@ -2635,6 +4091,19 @@ proxy-compare@2.5.1: resolved "https://registry.yarnpkg.com/proxy-compare/-/proxy-compare-2.5.1.tgz#17818e33d1653fbac8c2ec31406bce8a2966f600" integrity sha512-oyfc0Tx87Cpwva5ZXezSp5V9vht1c7dZBhvuV/y3ctkgMVUmiAGDVeeB0dKhGSyT0v1ZTEQYpe/RXlBVBNuCLA== +qrcode@1.4.4: + version "1.4.4" + resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.4.4.tgz#f0c43568a7e7510a55efc3b88d9602f71963ea83" + integrity sha512-oLzEC5+NKFou9P0bMj5+v6Z40evexeE29Z9cummZXZ9QXyMr3lphkURzxjXgPJC5azpxcshoDWV1xE46z+/c3Q== + dependencies: + buffer "^5.4.3" + buffer-alloc "^1.2.0" + buffer-from "^1.1.1" + dijkstrajs "^1.0.1" + isarray "^2.0.1" + pngjs "^3.3.0" + yargs "^13.2.4" + qrcode@1.5.0: version "1.5.0" resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.0.tgz#95abb8a91fdafd86f8190f2836abbfc500c72d1b" @@ -2662,6 +4131,15 @@ qs@^6.10.3: dependencies: side-channel "^1.0.4" +query-string@6.13.5: + version "6.13.5" + resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.13.5.tgz#99e95e2fb7021db90a6f373f990c0c814b3812d8" + integrity sha512-svk3xg9qHR39P3JlHuD7g3nRnyay5mHbrPctEBDUxUkHRifPHXJDhBUycdCC0NBjXoDf44Gb+IsOZL1Uwn8M/Q== + dependencies: + decode-uri-component "^0.2.0" + split-on-first "^1.0.0" + strict-uri-encode "^2.0.0" + query-string@7.1.3: version "7.1.3" resolved "https://registry.yarnpkg.com/query-string/-/query-string-7.1.3.tgz#a1cf90e994abb113a325804a972d98276fe02328" @@ -2826,6 +4304,20 @@ rxjs@^6.6.3: dependencies: tslib "^1.9.0" +rxjs@^7.5.2, rxjs@^7.5.5: + version "7.8.1" + resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-7.8.1.tgz#6f6f3d99ea8044291efd92e7c7fcf562c4057543" + integrity sha512-AA3TVj+0A2iuIoQkWEK/tqFjBq2j+6PO6Y0zJcvzLAFhEFIO3HL0vls9hWLncZbAAbK0mar7oZ4V079I/qPMxg== + dependencies: + tslib "^2.1.0" + +sade@^1.8.1: + version "1.8.1" + resolved "https://registry.yarnpkg.com/sade/-/sade-1.8.1.tgz#0a78e81d658d394887be57d2a409bf703a3b2701" + integrity sha512-xal3CZX1Xlo/k4ApwCFrHVACi9fBqJ7V+mwhBsuf/1IOKbBy098Fex+Wa/5QMubw09pSZ/u8EY8PWgevJsXp1A== + dependencies: + mri "^1.1.0" + safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" @@ -2846,6 +4338,11 @@ scriptjs@^2.5.9: resolved "https://registry.npmjs.org/scriptjs/-/scriptjs-2.5.9.tgz" integrity sha512-qGVDoreyYiP1pkQnbnFAUIS5AjenNwwQBdl7zeos9etl+hYKWahjRTfzAZZYBv5xNHx7vNKCmaLDQZ6Fr2AEXg== +scrypt-js@3.0.1: + version "3.0.1" + resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-3.0.1.tgz#d314a57c2aef69d1ad98a138a21fe9eafa9ee312" + integrity sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA== + semver@^7.3.8: version "7.5.4" resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" @@ -2933,6 +4430,15 @@ strict-uri-encode@^2.0.0: resolved "https://registry.yarnpkg.com/strict-uri-encode/-/strict-uri-encode-2.0.0.tgz#b9c7330c7042862f6b142dc274bbcc5866ce3546" integrity sha512-QwiXZgpRcKkhTj2Scnn++4PKtWsH0kpzZ62L2R6c/LUVYv7hVnZqcg2+sMuT6R7Jusu1vviK/MFsu6kNJfWlEQ== +string-width@^3.0.0, string-width@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/string-width/-/string-width-3.1.0.tgz#22767be21b62af1081574306f69ac51b62203961" + integrity sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w== + dependencies: + emoji-regex "^7.0.1" + is-fullwidth-code-point "^2.0.0" + strip-ansi "^5.1.0" + string-width@^4.1.0, string-width@^4.2.0: version "4.2.3" resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010" @@ -2949,6 +4455,13 @@ string_decoder@^1.1.1: dependencies: safe-buffer "~5.2.0" +strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0: + version "5.2.0" + resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-5.2.0.tgz#8c9a536feb6afc962bdfa5b104a5091c1ad9c0ae" + integrity sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA== + dependencies: + ansi-regex "^4.1.0" + strip-ansi@^6.0.0, strip-ansi@^6.0.1: version "6.0.1" resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9" @@ -2956,6 +4469,13 @@ strip-ansi@^6.0.0, strip-ansi@^6.0.1: dependencies: ansi-regex "^5.0.1" +sturdy-websocket@^0.1.12: + version "0.1.12" + resolved "https://registry.yarnpkg.com/sturdy-websocket/-/sturdy-websocket-0.1.12.tgz#84bb779f948b585a695f76961dc7d1c4a5e87629" + integrity sha512-PA7h8LdjaMoIlC5HAwLVzae4raGWgyroscV4oUpEiTtEFINcNa47/CKYT3e98o+FfsJgrclI2pYpaJrz0aaoew== + dependencies: + lodash.defaults "^4.2.0" + style-to-js@1.1.1: version "1.1.1" resolved "https://registry.npmjs.org/style-to-js/-/style-to-js-1.1.1.tgz" @@ -2987,6 +4507,24 @@ supports-color@^7.1.0: dependencies: has-flag "^4.0.0" +svelte-i18n@^3.3.13: + version "3.7.4" + resolved "https://registry.yarnpkg.com/svelte-i18n/-/svelte-i18n-3.7.4.tgz#6cf2c86075fd748bd8ca2de5762e43a596c7d189" + integrity sha512-yGRCNo+eBT4cPuU7IVsYTYjxB7I2V8qgUZPlHnNctJj5IgbJgV78flsRzpjZ/8iUYZrS49oCt7uxlU3AZv/N5Q== + dependencies: + cli-color "^2.0.3" + deepmerge "^4.2.2" + esbuild "^0.19.2" + estree-walker "^2" + intl-messageformat "^9.13.0" + sade "^1.8.1" + tiny-glob "^0.2.9" + +svelte@^3.49.0: + version "3.59.2" + resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.59.2.tgz#a137b28e025a181292b2ae2e3dca90bf8ec73aec" + integrity sha512-vzSyuGr3eEoAtT/A6bmajosJZIUWySzY2CzB3w2pgPvnkUjGqlDnsNnA0PMO+mMAhuyMul6C2uuZzY6ELSkzyA== + text-encoding-utf-8@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/text-encoding-utf-8/-/text-encoding-utf-8-1.0.2.tgz#585b62197b0ae437e3c7b5d0af27ac1021e10d13" @@ -3004,6 +4542,22 @@ thread-stream@^0.15.1: resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== +timers-ext@^0.1.7: + version "0.1.7" + resolved "https://registry.yarnpkg.com/timers-ext/-/timers-ext-0.1.7.tgz#6f57ad8578e07a3fb9f91d9387d65647555e25c6" + integrity sha512-b85NUNzTSdodShTIbky6ZF02e8STtVVfD+fu4aXXShEELpozH+bCpJLYMPZbsABN2wDH7fJpqIoXxJpzbf0NqQ== + dependencies: + es5-ext "~0.10.46" + next-tick "1" + +tiny-glob@^0.2.9: + version "0.2.9" + resolved "https://registry.yarnpkg.com/tiny-glob/-/tiny-glob-0.2.9.tgz#2212d441ac17928033b110f8b3640683129d31e2" + integrity sha512-g/55ssRPUjShh+xkfx9UPDXqhckHEsHr4Vd9zX55oSdGZc/MD0m3sferOkwWtp98bv+kcVfEHtRJgBVJzelrzg== + dependencies: + globalyzer "0.1.0" + globrex "^0.1.2" + tiny-warning@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/tiny-warning/-/tiny-warning-1.0.3.tgz#94a30db453df4c643d0fd566060d60a875d84754" @@ -3047,6 +4601,16 @@ tus-js-client@^3.1.0: proper-lockfile "^4.1.2" url-parse "^1.5.7" +type@^1.0.1: + version "1.2.0" + resolved "https://registry.yarnpkg.com/type/-/type-1.2.0.tgz#848dd7698dafa3e54a6c479e759c4bc3f18847a0" + integrity sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg== + +type@^2.7.2: + version "2.7.2" + resolved "https://registry.yarnpkg.com/type/-/type-2.7.2.tgz#2376a15a3a28b1efa0f5350dcf72d24df6ef98d0" + integrity sha512-dzlvlNlt6AXU7EBSfpAscydQ7gXB+pPGsPnfJnZpiNJBDj7IaJzQlBZYGdEi4R9HmPdBv2XmWJ6YUtoTa7lmCw== + typedarray-to-buffer@3.1.5: version "3.1.5" resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz#a97ee7a9ff42691b9f783ff1bc5112fe3fca9080" @@ -3084,6 +4648,11 @@ use-sidecar@^1.1.2: detect-node-es "^1.1.0" tslib "^2.0.0" +use-sync-external-store@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/use-sync-external-store/-/use-sync-external-store-1.0.0.tgz#d98f4a9c2e73d0f958e7e2d2c2bfb5f618cbd8fd" + integrity sha512-AFVsxg5GkFg8GDcxnl+Z0lMAz9rE8DGJCc28qnBuQF7lac57B5smLcT37aXpXIIPz75rW4g3eXHPjhHwdGskOw== + use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: version "1.2.0" resolved "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz" @@ -3182,6 +4751,15 @@ which-typed-array@^1.1.11, which-typed-array@^1.1.2: gopd "^1.0.1" has-tostringtag "^1.0.0" +wrap-ansi@^5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09" + integrity sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q== + dependencies: + ansi-styles "^3.2.0" + string-width "^3.0.0" + strip-ansi "^5.0.0" + wrap-ansi@^6.2.0: version "6.2.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-6.2.0.tgz#e9393ba07102e6c91a3b221478f0257cd2856e53" @@ -3196,6 +4774,16 @@ wrappy@1: resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f" integrity sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ== +ws@7.4.6: + version "7.4.6" + resolved "https://registry.yarnpkg.com/ws/-/ws-7.4.6.tgz#5654ca8ecdeee47c33a9a4bf6d28e2be2980377c" + integrity sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A== + +ws@7.5.3: + version "7.5.3" + resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.3.tgz#160835b63c7d97bfab418fc1b8a9fced2ac01a74" + integrity sha512-kQ/dHIzuLrS6Je9+uv81ueZomEwH0qVYstcAQ4/Z93K8zeko9gtAbttJWzoC5ukqXY1PpoouV3+VSOqEAFt5wg== + ws@8.12.0: version "8.12.0" resolved "https://registry.yarnpkg.com/ws/-/ws-8.12.0.tgz#485074cc392689da78e1828a9ff23585e06cddd8" @@ -3236,6 +4824,14 @@ yallist@^4.0.0: resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== +yargs-parser@^13.1.2: + version "13.1.2" + resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" + integrity sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg== + dependencies: + camelcase "^5.0.0" + decamelize "^1.2.0" + yargs-parser@^18.1.2: version "18.1.3" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-18.1.3.tgz#be68c4975c6b2abf469236b0c870362fab09a7b0" @@ -3244,6 +4840,22 @@ yargs-parser@^18.1.2: camelcase "^5.0.0" decamelize "^1.2.0" +yargs@^13.2.4: + version "13.3.2" + resolved "https://registry.yarnpkg.com/yargs/-/yargs-13.3.2.tgz#ad7ffefec1aa59565ac915f82dccb38a9c31a2dd" + integrity sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw== + dependencies: + cliui "^5.0.0" + find-up "^3.0.0" + get-caller-file "^2.0.1" + require-directory "^2.1.1" + require-main-filename "^2.0.0" + set-blocking "^2.0.0" + string-width "^3.0.0" + which-module "^2.0.0" + y18n "^4.0.0" + yargs-parser "^13.1.2" + yargs@^15.3.1: version "15.4.1" resolved "https://registry.yarnpkg.com/yargs/-/yargs-15.4.1.tgz#0d87a16de01aee9d8bec2bfbf74f67851730f4f8" From 17b82f331a4ec8bdc35d679719e267e4d6571b10 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 9 Sep 2023 21:12:52 +0530 Subject: [PATCH 237/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.10?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 6801607ed..0a785bc63 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.9...uiweb-0.0.1-alpha.10) (2023-09-09) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([f410046](https://github.com/ethereum-push-notification-service/push-sdk/commit/f410046d871bb34f3ec7a7eecd9f500d50fc0fbf)) + + + ## [0.0.1-alpha.9](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.8...uiweb-0.0.1-alpha.9) (2023-09-08) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index c778e1218..f9bfb8774 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.9", + "version": "0.0.1-alpha.10", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 1f234649a6624d9c1015f08245c2edb1b458dfd4 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Sat, 9 Sep 2023 21:14:04 +0530 Subject: [PATCH 238/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.33?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 3b5245157..8d3dca165 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -349,7 +349,7 @@ export const MessageInput: React.FC = ({ }); if (chatFeed?.groupInformation?.rules && - (chatFeed?.groupInformation?.rules?.groupAccess || + (chatFeed?.groupInformation?.rules?.entry || chatFeed?.groupInformation?.rules?.chat) ) { setIsRules(true); From 5021ca57ae3f26643f41d22fc84c2e84d5cc0a43 Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Thu, 14 Sep 2023 23:32:36 +0530 Subject: [PATCH 239/298] Fix connect button issue (#710) * fix: fixed connect button blocknative * fix: fixed message fetching * fix: removed console --- packages/uiweb/package.json | 9 +- .../chat/ChatViewBubble/ChatViewBubble.tsx | 23 +- .../ChatViewList/ApproveRequestBubble.tsx | 15 +- .../chat/ChatViewList/ChatViewList.tsx | 151 +- .../chat/ConnectButton/ConnectButton.tsx | 7 +- .../components/chat/ConnectButton/index.css | 2131 ----------------- .../chat/MessageInput/MessageInput.tsx | 811 +++---- .../src/lib/hooks/chat/usePushSendMessage.ts | 1 - packages/uiweb/yarn.lock | 1177 +-------- 9 files changed, 522 insertions(+), 3803 deletions(-) delete mode 100644 packages/uiweb/src/lib/components/chat/ConnectButton/index.css diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index f9bfb8774..97cde6404 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -7,23 +7,22 @@ "dependencies": { "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", - "@rainbow-me/rainbowkit": "^1.0.8", "@unstoppabledomains/resolution": "^8.5.0", + "@web3-onboard/core": "^2.21.1", "@web3-onboard/injected-wallets": "^2.10.5", - "@web3-onboard/react": "^2.8.11", + "@web3-onboard/react": "^2.8.9", "@web3-onboard/walletconnect": "^2.4.6", "@web3-react/injected-connector": "^6.0.7", "date-fns": "^2.28.0", "emoji-picker-react": "^4.4.9", + "ethers": "^5.6.8", "font-awesome": "^4.7.0", "gif-picker-react": "^1.1.0", "html-react-parser": "^1.4.13", "moment": "^2.29.4", "react-icons": "^4.10.1", "react-toastify": "^9.1.3", - "react-twitter-embed": "^4.0.4", - "wagmi": "^1.3.10", - "ethers": "^5.6.8" + "react-twitter-embed": "^4.0.4" }, "peerDependencies": { "@pushprotocol/restapi": "^1.2.15", diff --git a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx index 31139c110..f527c883b 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewBubble/ChatViewBubble.tsx @@ -8,7 +8,6 @@ import { formatFileSize, getPfp, pCAIP10ToWallet, - setPfp, shortenText, } from '../../../helpers'; import { checkTwitterUrl } from '../helpers/twitter'; @@ -40,7 +39,7 @@ const SenderMessageAddress = ({ chat }: { chat: IMessagePayload }) => { ); }; -const SenderMessafeProfilePicture = ({ chat }: { chat: IMessagePayload }) => { +const SenderMessageProfilePicture = ({ chat }: { chat: IMessagePayload }) => { const { account, env } = useContext(ChatDataContext); const [pfp, setPfp] = useState(''); const getUserPfp = async () => { @@ -74,6 +73,8 @@ const SenderMessafeProfilePicture = ({ chat }: { chat: IMessagePayload }) => { ); }; + +//can create a wrapper for till the senderMessageAddress and use it for all cards(types of messages) const MessageCard = ({ chat, position, @@ -94,7 +95,7 @@ const MessageCard = ({ width="fit-content" maxWidth="70%" > - {isGroup && } + {isGroup && }
{isGroup && }
- {isGroup && } + {isGroup && }
{isGroup && }
{ return (
- {isGroup && } + {isGroup && }
{isGroup && }
- {isGroup && } + {isGroup && }
{isGroup && }
- {isGroup && } + {isGroup && }
{isGroup && }
{ - const { account, setAccount, pgpPrivateKey, setPgpPrivateKey, env, setEnv } = + const { account} = useChatData(); const position = pCAIP10ToWallet(chat.fromDID).toLowerCase() !== account?.toLowerCase() @@ -366,11 +367,7 @@ export const ChatViewBubble = ({ chat }: { chat: IMessagePayload }) => { } }, [chat.toDID, isGroup]); - // useEffect(() => { - // setAccount(""); - // setPgpPrivateKey(""); - // setEnv(env); - // }, [account, env, pgpPrivateKey]) + if (messageType === 'TwitterFeedLink') { chat.messageType = 'TwitterFeedLink'; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx index 41a006d74..6df0a560b 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ApproveRequestBubble.tsx @@ -1,10 +1,9 @@ import { IFeeds } from '@pushprotocol/restapi'; import { ThemeContext } from '../theme/ThemeProvider'; import { Dispatch, useContext } from 'react'; -import { Div, Section, Span, Spinner } from '../../reusables'; +import { Section, Span, Spinner } from '../../reusables'; import useApproveChatRequest from '../../../hooks/chat/useApproveChatRequest'; import { useChatData } from '../../../hooks'; -import { TickSvg } from '../../../icons/Tick'; import styled from 'styled-components'; import { IChatTheme } from '../theme'; @@ -21,17 +20,19 @@ export interface IApproveRequestBubbleProps { setChatFeed: Dispatch; } + export const ApproveRequestBubble = ({ chatFeed, chatId, setChatFeed, }: IApproveRequestBubbleProps) => { - const { account, pgpPrivateKey, env } = useChatData(); + const { pgpPrivateKey } = useChatData(); const ApproveRequestText = { GROUP: `You were invited to the group ${chatFeed?.groupInformation?.groupName}. Please accept to continue messaging in this group.`, W2W: ` Please accept to enable push chat from this wallet`, }; + const theme = useContext(ThemeContext); const { approveChatRequest, loading: approveLoading } = useApproveChatRequest(); @@ -88,13 +89,7 @@ export const ApproveRequestBubble = ({ > {approveLoading ? : 'Accept'} - {/*
(!approveLoading ? handleApproveChatRequest() : null)} - > - {approveLoading ? : } -
*/} +
); }; diff --git a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx index 0ba47396f..a7011cd74 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewList/ChatViewList.tsx @@ -1,16 +1,17 @@ import React, { useContext, useEffect, useRef, useState } from 'react'; -import { ChatDataContext } from '../../../context'; -import { IChatViewListProps } from '../exportedTypes'; -import { chatLimit } from '../../../config'; + import { IFeeds, IMessageIPFS, IMessageIPFSWithCID, } from '@pushprotocol/restapi'; -import useFetchHistoryMessages from '../../../hooks/chat/useFetchHistoryMessages'; -import styled from 'styled-components'; -import { Div, Section, Span, Spinner } from '../../reusables'; import moment from 'moment'; +import styled from 'styled-components'; + +import { IChatViewListProps } from '../exportedTypes'; +import { chatLimit } from '../../../config'; +import useFetchHistoryMessages from '../../../hooks/chat/useFetchHistoryMessages'; +import { Section, Span, Spinner } from '../../reusables'; import { ChatViewBubble } from '../ChatViewBubble'; import { appendUniqueMessages, @@ -26,7 +27,6 @@ import { useChatData, usePushChatSocket } from '../../../hooks'; import { Messagetype } from '../../../types'; import { ThemeContext } from '../theme/ThemeProvider'; import { IChatTheme } from '../theme'; -import useFetchConversationHash from '../../../hooks/chat/useFetchConversationHash'; import { ENCRYPTION_KEYS, EncryptionMessage } from './MessageEncryption'; import useGetGroup from '../../../hooks/chat/useGetGroup'; @@ -62,15 +62,12 @@ export const ChatViewList: React.FC = ( useFetchHistoryMessages(); const listInnerRef = useRef(null); const [isMember, setIsMember] = useState(false); - - // const bottomRef = useRef(null); const { fetchChat } = useFetchChat(); const { fetchChatProfile } = useGetChatProfile(); const { getGroup } = useGetGroup(); const { messagesSinceLastConnection, groupInformationSinceLastConnection } = usePushChatSocket(); - const { fetchConversationHash } = useFetchConversationHash(); const theme = useContext(ThemeContext); const dates = new Set(); const { env } = useChatData(); @@ -79,6 +76,7 @@ export const ChatViewList: React.FC = ( setChatStatusText(''); }, [chatId, account, env]); + //need to do something about fetching connectedUser in every component useEffect(() => { (async () => { if (!connectedProfile && account) { @@ -93,11 +91,15 @@ export const ChatViewList: React.FC = ( setConversationHash(undefined); }, [chatId, account, pgpPrivateKey, env]); + //need to make a common method for fetching chatFeed to ruse in messageInput useEffect(() => { (async () => { if (!account && !env) return; const chat = await fetchChat({ chatId }); - if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); + if (Object.keys(chat || {}).length) { + setConversationHash(chat?.threadhash as string); + setChatFeed(chat as IFeeds); + } else { let newChatFeed; let group; @@ -118,6 +120,7 @@ export const ChatViewList: React.FC = ( if (!newChatFeed?.groupInformation) { setChatStatusText(ChatStatus.FIRST_CHAT); } + setConversationHash(newChatFeed.threadhash as string); setChatFeed(newChatFeed); } else { setChatStatusText(ChatStatus.INVALID_CHAT); @@ -126,17 +129,16 @@ export const ChatViewList: React.FC = ( setLoading(false); })(); }, [chatId, pgpPrivateKey, account, env]); - + //moniters socket changes useEffect(() => { if (checkIfSameChat(messagesSinceLastConnection, account!, chatId)) { + const updatedChatFeed = chatFeed; + updatedChatFeed.msg = messagesSinceLastConnection; if (!Object.keys(messages || {}).length) { setFilteredMessages([ messagesSinceLastConnection, ] as IMessageIPFSWithCID[]); - // setMessages({ - // messages: [messagesSinceLastConnection], - // lastThreadHash: messagesSinceLastConnection.cid, - // }); + setConversationHash(messagesSinceLastConnection.cid); } else { const newChatViewList = appendUniqueMessages( @@ -145,22 +147,41 @@ export const ChatViewList: React.FC = ( false ); setFilteredMessages(newChatViewList as IMessageIPFSWithCID[]); - // setMessages({ - // messages: newChatViewList, - // lastThreadHash: messages!.lastThreadHash, - // }); } - scrollToBottom(null); + setChatStatusText(''); + setChatFeed(updatedChatFeed); + scrollToBottom(); } }, [messagesSinceLastConnection]); useEffect(() => { - (async function () { - if (!account && !env && !chatId) return; - const hash = await fetchConversationHash({ conversationId: chatId }); - setConversationHash(hash?.threadHash); - })(); - }, [chatId, account, env, pgpPrivateKey]); + if (Object.keys(groupInformationSinceLastConnection || {}).length) { + if ( + chatFeed?.groupInformation?.chatId.toLowerCase() === + groupInformationSinceLastConnection.chatId.toLowerCase() + ) { + const updateChatFeed = chatFeed; + updateChatFeed.groupInformation = groupInformationSinceLastConnection; + setChatFeed(updateChatFeed); + } + } + }, [groupInformationSinceLastConnection]); + // useEffect(() => { + // if ( + // Object.keys(messagesSinceLastConnection || {}).length && + // Object.keys(chatFeed || {}).length && + // checkIfSameChat(messagesSinceLastConnection, account!, chatId) + // ) { + + // } + // }, [messagesSinceLastConnection]); + // useEffect(() => { + // (async function () { + // if (!account && !env && !chatId) return; + // const hash = await fetchConversationHash({ conversationId: chatId }); + // setConversationHash(hash?.threadHash); + // })(); + // }, [chatId, account, env, pgpPrivateKey]); useEffect(() => { if (conversationHash) { @@ -171,7 +192,7 @@ export const ChatViewList: React.FC = ( }, [conversationHash, pgpPrivateKey, account, env,chatFeed]); useEffect(() => { - scrollToBottom(null); + scrollToBottom(); }, [conversationHash]); useEffect(() => { @@ -182,34 +203,10 @@ export const ChatViewList: React.FC = ( messages?.messages.length <= limit ) { setChatStatusText(''); - scrollToBottom(null); + scrollToBottom(); } }, [messages]); - useEffect(() => { - if ( - Object.keys(messagesSinceLastConnection || {}).length && - Object.keys(chatFeed || {}).length && - checkIfSameChat(messagesSinceLastConnection, account!, chatId) - ) { - const updatedChatFeed = chatFeed; - updatedChatFeed.msg = messagesSinceLastConnection; - - setChatStatusText(''); - setChatFeed(updatedChatFeed); - } - }, [messagesSinceLastConnection]); - - const scrollToBottom = (behavior?: string | null) => { - setTimeout(()=>{ - if (listInnerRef.current) { - listInnerRef.current.scrollTop = listInnerRef.current.scrollHeight +100000; - - } - },0) - - }; - useEffect(()=>{ if(chatFeed && !chatFeed?.groupInformation?.isPublic && account) @@ -224,18 +221,16 @@ export const ChatViewList: React.FC = ( } },[account,chatFeed]) - useEffect(() => { - if (Object.keys(groupInformationSinceLastConnection || {}).length) { - if ( - chatFeed?.groupInformation?.chatId.toLowerCase() === - groupInformationSinceLastConnection.chatId.toLowerCase() - ) { - const updateChatFeed = chatFeed; - updateChatFeed.groupInformation = groupInformationSinceLastConnection; - setChatFeed(updateChatFeed); + //methods + const scrollToBottom = () => { + setTimeout(()=>{ + if (listInnerRef.current) { + listInnerRef.current.scrollTop = listInnerRef.current.scrollHeight +100; + } - } - }, [groupInformationSinceLastConnection]); + },0) + + }; const onScroll = async () => { if (listInnerRef.current) { @@ -287,11 +282,6 @@ export const ChatViewList: React.FC = ( } }; - type RenderDataType = { - chat: IMessageIPFS; - dateNum: string; - }; - const setFilteredMessages = (messageList: Array) => { const updatedMessageList = messageList.filter( (msg) => !chatFilterList.includes(msg.cid) @@ -304,6 +294,20 @@ export const ChatViewList: React.FC = ( }); } }; + + const ifBlurChat = () =>{ + return !!( + chatFeed && + chatFeed?.groupInformation && + !chatFeed?.groupInformation?.isPublic && + ((!isMember && pgpPrivateKey) || (!pgpPrivateKey)) + ); + } + + type RenderDataType = { + chat: IMessageIPFS; + dateNum: string; + }; const renderDate = ({ chat, dateNum }: RenderDataType) => { const timestampDate = dateToFromNowDaily(chat.timestamp as number); dates.add(dateNum); @@ -329,12 +333,7 @@ export const ChatViewList: React.FC = ( padding="0 2px" theme={theme} blur={ - !!( - chatFeed && - chatFeed?.groupInformation && - !chatFeed?.groupInformation?.isPublic && - ((!isMember && pgpPrivateKey) || (!pgpPrivateKey)) - ) + ifBlurChat() } onScroll={(e) => { e.stopPropagation(); @@ -403,7 +402,6 @@ export const ChatViewList: React.FC = ( ); } )} - {/*
*/}
{chatFeed && account && @@ -444,4 +442,3 @@ const ChatViewListCard = styled(Section)` scroll-behavior: smooth; `; -const Overlay = styled.div``; diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx index b88886b8b..a67c40b4d 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx @@ -3,11 +3,10 @@ import { IChatTheme } from '../theme'; import { useChatData } from '../../../hooks'; import * as PushAPI from '@pushprotocol/restapi'; import { useContext, useEffect, useState } from 'react'; -import { ConnectButton } from '@rainbow-me/rainbowkit'; import { init, useConnectWallet } from "@web3-onboard/react"; import injectedModule from "@web3-onboard/injected-wallets"; import { Signer, ethers } from 'ethers'; -import './index.css'; + import { ThemeContext } from '../theme/ThemeProvider'; import { device } from '../../../config'; import { getAddressFromSigner } from '../../../helpers'; @@ -35,14 +34,12 @@ export const ConnectButtonSub = () => { const theme = useContext(ThemeContext); const newFunc = () => { - console.log("wallet getting called") if (wallet) { (async () => { - console.log("Not sure what's happening lol") + const ethersProvider = new ethers.providers.Web3Provider(wallet.provider, 'any') const signer = ethersProvider.getSigner() const newAdd = await getAddressFromSigner(signer) - console.log(newAdd, "newAdd") setSigner(signer) setAccount(newAdd); })() diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.css b/packages/uiweb/src/lib/components/chat/ConnectButton/index.css deleted file mode 100644 index d9edb6893..000000000 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/index.css +++ /dev/null @@ -1,2131 +0,0 @@ -/* @import '/packages/uiweb/node_modules/@rainbow-me/rainbowkit/dist/index.css'; */ -/* vanilla-extract-css-ns:src/css/reset.css.ts.vanilla.css?source=Lmlla2JjYzAgewogIGJvcmRlcjogMDsKICBib3gtc2l6aW5nOiBib3JkZXItYm94OwogIGZvbnQtc2l6ZTogMTAwJTsKICBsaW5lLWhlaWdodDogbm9ybWFsOwogIG1hcmdpbjogMDsKICBwYWRkaW5nOiAwOwogIHRleHQtYWxpZ246IGxlZnQ7CiAgdmVydGljYWwtYWxpZ246IGJhc2VsaW5lOwogIC13ZWJraXQtdGFwLWhpZ2hsaWdodC1jb2xvcjogdHJhbnNwYXJlbnQ7Cn0KLmlla2JjYzEgewogIGxpc3Qtc3R5bGU6IG5vbmU7Cn0KLmlla2JjYzIgewogIHF1b3Rlczogbm9uZTsKfQouaWVrYmNjMjpiZWZvcmUsIC5pZWtiY2MyOmFmdGVyIHsKICBjb250ZW50OiAnJzsKfQouaWVrYmNjMyB7CiAgYm9yZGVyLWNvbGxhcHNlOiBjb2xsYXBzZTsKICBib3JkZXItc3BhY2luZzogMDsKfQouaWVrYmNjNCB7CiAgYXBwZWFyYW5jZTogbm9uZTsKfQouaWVrYmNjNSB7CiAgb3V0bGluZTogbm9uZTsKfQouaWVrYmNjNTo6cGxhY2Vob2xkZXIgewogIG9wYWNpdHk6IDE7Cn0KLmlla2JjYzYgewogIGJhY2tncm91bmQtY29sb3I6IHRyYW5zcGFyZW50OwogIGNvbG9yOiBpbmhlcml0Owp9Ci5pZWtiY2M3OmRpc2FibGVkIHsKICBvcGFjaXR5OiAxOwp9Ci5pZWtiY2M3OjotbXMtZXhwYW5kIHsKICBkaXNwbGF5OiBub25lOwp9Ci5pZWtiY2M4OjotbXMtY2xlYXIgewogIGRpc3BsYXk6IG5vbmU7Cn0KLmlla2JjYzg6Oi13ZWJraXQtc2VhcmNoLWNhbmNlbC1idXR0b24gewogIC13ZWJraXQtYXBwZWFyYW5jZTogbm9uZTsKfQouaWVrYmNjOSB7CiAgYmFja2dyb3VuZDogbm9uZTsKICBjdXJzb3I6IHBvaW50ZXI7CiAgdGV4dC1hbGlnbjogbGVmdDsKfQouaWVrYmNjYSB7CiAgY29sb3I6IGluaGVyaXQ7CiAgdGV4dC1kZWNvcmF0aW9uOiBub25lOwp9 */ -[data-rk] .iekbcc0 { - border: 0; - box-sizing: border-box; - font-size: 100%; - line-height: normal; - margin: 0; - padding: 0; - text-align: left; - vertical-align: baseline; - -webkit-tap-highlight-color: transparent; -} -[data-rk] .iekbcc1 { - list-style: none; -} -[data-rk] .iekbcc2 { - quotes: none; -} -[data-rk] .iekbcc2:before, -[data-rk] .iekbcc2:after { - content: ""; -} -[data-rk] .iekbcc3 { - border-collapse: collapse; - border-spacing: 0; -} -[data-rk] .iekbcc4 { - -webkit-appearance: none; - -moz-appearance: none; - appearance: none; -} -[data-rk] .iekbcc5 { - outline: none; -} -[data-rk] .iekbcc5::-moz-placeholder { - opacity: 1; -} -[data-rk] .iekbcc5::placeholder { - opacity: 1; -} -[data-rk] .iekbcc6 { - background-color: transparent; - color: inherit; -} -[data-rk] .iekbcc7:disabled { - opacity: 1; -} -[data-rk] .iekbcc7::-ms-expand { - display: none; -} -[data-rk] .iekbcc8::-ms-clear { - display: none; -} -[data-rk] .iekbcc8::-webkit-search-cancel-button { - -webkit-appearance: none; -} -[data-rk] .iekbcc9 { - background: none; - cursor: pointer; - text-align: left; -} -[data-rk] .iekbcca { - color: inherit; - text-decoration: none; -} - -/* vanilla-extract-css-ns:src/css/sprinkles.css.ts.vanilla.css?source=#H4sIAAAAAAAAE6Vdy5LjxhG86yt4cYR0oIIECRAcX+yV7LAi7PDBivAZxIsYggAHAIfkOPTv5mMeqKzq7gJWpxUrK7uyu9BMoLHLn5+Pi2D1Opv874fJJCqLvJoWXbpvnyZZmZ6nbRc13Z9/+OOHnx84z4BLq6SHWnJUnFZd2vQwwR2TFO2hjC5Pk6qu0l40pNFNWce7Xjii4VsJvWhMo0VVFoQ87ZXXpmVm0JrJMCo1ZyCmdHuHbKJ4lzf1sUqmbfGWXnH1K4EVD1jdJGkzbaKkOF6nbX7oC3uWIAGB7ESWGcGUImZBMHsJ8xo1P06nze7+QTGN4q6oq2/Hrqurn3q5lSI3rqsqjTueXCuS92l15JkHTWadRGU/6UWb9K96U5RpP7WRUj3/Tz1IK0HW1//IXHd9VNtdymt3tHVZ9Pvs2MeciqTbPk3oqr4KCNo+JwHhEcRZQCwJ4nJHxMemrZunyaEuoNnf7vH7hZIUTXrvkKdJU596mPlMBMV1edxXfdz8gaurbppF+6K89Jbm9mk73dTJpb8mc+8r5XGZze8KJ5PbHjDdpkW+7a4fhkTUfMGyFoqsJctaKrJ8lhUIWR5d3HnAskIpiy7WfIVZD1pHVsiypNnwaBPP119Zp3fIcjbrIyKO8CliwxEBRcQcsaKIhCNCinjs/3l0uF5C/c+zr8/phTPPvyL0gplvvyJ0A50XXxGY3+eviE8ju68I3dbn5VcE+mnfqxqapuqFoO66F4LyDr0QVPHSC0EZTW+KoIy2F4Kxul4ICI+9mYXiX3shqPDUm3UY69ybXAhdvkJTWPrHhvZ5MZOgNyNBWqU3J0E6oueRIJXuLeiYwLukg9LJ9nwahWEDGoVxVyS6AOaQRqGqNY3CuBGN0kXzNnSmYNyYRoE5oVFQlJKoD7kZiQYwbg7zDOEtXaTZrP/F7xUkuo/ON8fTXa1hH/TYCJ6PbVdklw+AyXnvLGDqSb1ShjJn6u1lYHuI4nS6SbtTmva/kL3Kho/u7rYPf2wyXXrupneH/DQp04yIOjAEL/KFYYpqmzYFIXpsP/uoyYvq6gqu3nBPd3evlRBwPXcSBhr9KGHo3u+9ShhovpOEod8H3lnCwMVzkTBwGbyJ2mlDL2YiiKpfzEUQlbbwRBCte7EQQbTwxVJcECjcF0FQUyCCYLiVuLYwBaEIAnVrsQOgpkhcXgBtJBB8Sy3iPuh2kdHmXyQ8DgwpR4DujCNo2y9yjgAxW46gLb8oOAKm9pkjYBl3glromVKAgN69AAE5lQCBamsBAuUehKmHcl8ECNTSCBAYqBVWEER3AgQUHYVVhlpehUUEyIlDsKnJ7tc8vklJV18EAHC8CRAqeTkTILSxl3MBQvUsPQFCW3u5ECB0bpdLAUIXcelLomm7LAMJA7JXEgZEhRIGSl5LGKg5klYBat5IGKgnljAwViItJ2hPJQzoyqQ1h3pyaUUBsxUw0OlLsul1NdyYLp9ZGPJ3DACCSwaADt8zAMioGAC6u2YAmNADA8DKvXCZ0CMNR4DQliNASMcRUOiRI6DSVz7fUOmJI6COM0fAKBe+aKD2jSOoFn/G15XW4c/5ugHCYwjoX/9jZzvLDx79JcapDt/HOFQQYJzOlL9i48MAISuArpe/ZgAoIWIAqGGDALh/9mMGgCITBoAaUgaA1c7YPEINOQPAEFsGAJkFAuCm2n9GANxX+zu+FoAo2XLSu2t/jwD5Btt/37SubSv3ZY1xWJEDxkHrC8Zhsho2PgzQsgJgKjoGgBKODAA1vCIA+/LEAFDkmQGghgsDQF++sXmkNQQzBqBDBHMGoDIDDwHQl8ECAdCXwZKvBSB8tpy0L4MAAXJfBo/96nYAmJX16WmyLZKEPGkJHhvWIUqSosrFBxrBWoTQDg8iEUQXONiIIOoQglgEwSQnIog6hSAVQbRlgkwEwaLn8hTAsm1lFExCIaNA4LOMguJ3MgqqL+W1ger3MgrqqmQUjFjLCw0zcZBRoPFF7geoq5HXGlCtiAKXEXQExZ9yBEcBAByvAgTknwQIXAtnAQKSLgIEroM3AUIneTUTIHRNV3NJNO2hlSdhqOzVQsJQUaulhIGSfQkDNQfSKkDNKwkD9YQSBsZaS8sJ2iMJA7o20ppDPbG0ooBJBAx0+orukMKjj1UmIYAllzCgfCthaLevCgkDqp4lDO331U7CwCyXEgZWdC9qh/apRBCor0UQSDuIIKj7RQRB4Y24IFB4K4Kgpk4EwXBHcW1hCl5FEKg7iR0ANZ3F5QXQRQJh+9ONkT0PCWc8ThnCOUdQ3aHHEbTtwwVHUDHhkiNoy4c+R9CpDQOOoMsYrgS1tGfCUICA3rUAATmRAIFqNwIEyo2FqYdyEwECtaQCBAbKhBUE0bkAAUVbYZWhlkJYRIA8cwg0dfi++9Vt8XjdKdq0dXnsyFuPJWCy4pz2T1TDPQCatIy64pWQPHY+4UsjfD+PbaLqI3/289y73oSmUUsoDgx4/3NWN3tTymMDPLa3V9jSMo07/k7nY/sT78TDth+DVez6MZj4Yz8GDfJKxgPSExkQGvRMgjDkhQRhzLd+EO601zMSpAWt5yRIx1x7JEhbeL0g8wNjLkkQaH0SpFLWQT8Id9PrVT8Id9LrkM4tRNdkWegd9DrqB+W75/VjE7q9UJs09WGaFWWXNr1XAzflsWkfb23++3qLXUbkFcF1/Jn+eB+3lxnXZX1NjeLbWwi/3P6HZCZP29s9++j89On2yuz7+8djCLIhmX+vm/QBIxz5cBEGpu0IOQaqQsHx9bLxt/sLqoTgWa3KSrPTS7LylCMI+BvG6/1oVQJZNV6bwFYPovlPer2Ok6i5fPtMIGyHEUJdnC9j9LpI3SXGZd2m/O30dauUaMrvtHJMBMchmQb5r8NFGJhOI+QYqM5ujv7fNjCwXLTSFFxvanFusmg2luVvTUO/P6L592nkhN53CuWMi2FUv13/3BgmbjlGrY3QH6XWxhgMo/o9PXckfzVGImMJR+liNOvh+Xz9o7GKONVmtCzO5TaN7yTFbcGTIo46YNCaRxeP2kS6iNxmMqlPVVlHybf7A/lfoiYxtLHWU6oJ1dZSzeh2mB9Uv9cHC4/WaOrY1H5TR+e2nSnrbK3H5JlqQ8lT3e4xT6+7ZlRybx1pvaKZQe0MzRQDh/+12JN0rRm0kqgdoZXFbQtvf93yty7dG5pO6wkdNGpD6OBxu8H7k4Fv748PSK7WA5oZ1M7PSLFx+73PXC5/o7V4Ng61q7ORuI3cI5tdWxutbzPlq22aicDtyu6ZaIA2WjcmZ6tdmJzudl+febAFbLSey0igdlpGBre/+kz9vEUnBFp75aBRuysHj9tcHZo6K8r0r3eHRnK1bsrMoLZPZgq3XyK5/7hVTAi0RslBo3ZIDh63NXonkJ9QbrQ2yc6itkx2Grd9epzBpMm/D/dnW3yP07ooJ5HaTDmZFMV0UZVs6JWmtVJSrtpBScnkn2S449QP8jfEM41ioHZpFMV5WK6hFy9jpBi43kaJksnimYrF9hg/ng/QZiXyhgizMi1GUfAH+PHyO7QJdP73KBT4goFEjgf38WqUXBdrOE61i3at4DM85o8jtVATw0YvykQRD8s1TEMyRoqBKx0lykCWaVjcj/bjXC9QwbYdIFFBV4znYc9P4+fvVcopd98tl3OWQ8ksD/fj/TjNNspqpGYbZz2UDG8948M4oYznZaQ6RjSqFN4N7XhdnKz7DnGcTWM+HQcAsd6EupgGmFEXlcaUah/6x3pvqqYcYFG1nInGqaoOABK9YdXxDfCtOkKNfWXHBYneq/LcAcaUJ2tcqPGQINF7TjPHAIdpJtH4SdshQaI3lVaaAc7SyqOxl/ZjgkTvLR1EA4ylg0njKo3HBoneS5o5BjhIM4nGN1oODhK9VbSxDHCHNhqNITQcIyR6/2diGGD3TBQadyceKCR6VyfnD3BzMsGgoXGL0Hs3I8UAx2bk0Pg0+1FCordpDqIBLs3BpDFpxqOFRO/KzBwDbJiRJNX4LvuxQqo3XA6iAU7LwaSxWNbjhVRvt+w8A6yXnUhjw1zHC6nejTmpBpgyJ5fGmwnHD6nekknZA5yYlP5hwM7Tdhslt3/C4DPr8QHcxJJkar1GUYDpGsWRuZOTIirrnGTl2uKF3K26aiG5cGe9X0S/pl1UlK2w4T1ri3cy7dRSnFSlm4NeRCR7r5Vk4ajUYiwktT77v1FZpsTrpIehMgSOl8EyBBJFCad71j/rvCaZrVaCIb9Tl28geHgtwy5mOARN++5qYCrxUwNzz8okwxfiZVDVBpK3YfXLLNnMnm47zMzmGhlWBk+lwUqxGJbLzyqz5RgZAo8/SoxAFGgZHAeR2WqYMhddOFCgi29tIzKcTWaRW5MpdaOo35QbK5MMUpNBVRtI0mH1G1gya7r7ZDHLFVoUNFuNGgVPMYKAnchkz6NFca7deGWcrFSzWE4Js/1AeTauaqg8G1mtZsEHTNlhoCZG8DJUCGMYNjhf3HaEBM7SjdHBaawGzHHwlymMmItCY8hcHFZjpj3RyxT+TM2lsWlastzq1lRHeLnCtOmINN5Nx2S1cOxUL1f4NZ6kMWc8y+rEjAd2ucJ3mZM1LsucbfVUtlO5XGGsrPkad2UlsFos++FbrvBXDgaNuXJQWJ2V8cQtV/gpc7LGRZmzrd7JcrCWK+ySLV3jkGz5VlNkOEvLFR7IlKqxPKZcq8MRj85yhbOREzWORs7UDYaXrMK/GHM1rsWYbPUq9uOvXGFVHAwap+KgsBoV45lXrnAm5mSNFTFmb63ew36otVWYDgeDxm04KKw2w3qCtVVYDjuBxn7YGaxWxHVMtVU4EieHxpg4Saz+RDir2ipsiZSmcSP9vL/s06SIJm3cpGk1uX4++bH3D4GvgvBw/unO9T7A4997s/zo8mTyxxd6YUTff/uNYH0J+/G7agS5ekfCzzATzBox7z/GTEAbBD1+kplgEsR8/DDzDfXH/wG2t/GriXoAAA== */ -[data-rk] .ju367v0 { - align-items: flex-start; -} -[data-rk] .ju367v2 { - align-items: flex-end; -} -[data-rk] .ju367v4 { - align-items: center; -} -[data-rk] .ju367v6 { - display: none; -} -[data-rk] .ju367v8 { - display: block; -} -[data-rk] .ju367va { - display: flex; -} -[data-rk] .ju367vc { - display: inline; -} -[data-rk] .ju367ve { - align-self: flex-start; -} -[data-rk] .ju367vf { - align-self: flex-end; -} -[data-rk] .ju367vg { - align-self: center; -} -[data-rk] .ju367vh { - background-size: cover; -} -[data-rk] .ju367vi { - border-radius: 1px; -} -[data-rk] .ju367vj { - border-radius: 6px; -} -[data-rk] .ju367vk { - border-radius: 10px; -} -[data-rk] .ju367vl { - border-radius: 13px; -} -[data-rk] .ju367vm { - border-radius: var(--rk-radii-actionButton); -} -[data-rk] .ju367vn { - border-radius: var(--rk-radii-connectButton); -} -[data-rk] .ju367vo { - border-radius: var(--rk-radii-menuButton); -} -[data-rk] .ju367vp { - border-radius: var(--rk-radii-modal); -} -[data-rk] .ju367vq { - border-radius: var(--rk-radii-modalMobile); -} -[data-rk] .ju367vr { - border-radius: 25%; -} -[data-rk] .ju367vs { - border-radius: 9999px; -} -[data-rk] .ju367vt { - border-style: solid; -} -[data-rk] .ju367vu { - border-width: 0px; -} -[data-rk] .ju367vv { - border-width: 1px; -} -[data-rk] .ju367vw { - border-width: 2px; -} -[data-rk] .ju367vx { - border-width: 4px; -} -[data-rk] .ju367vy { - cursor: pointer; -} -[data-rk] .ju367vz { - flex-direction: row; -} -[data-rk] .ju367v10 { - flex-direction: column; -} -[data-rk] .ju367v11 { - font-family: var(--rk-fonts-body); -} -[data-rk] .ju367v12 { - font-size: 12px; - line-height: 18px; -} -[data-rk] .ju367v13 { - font-size: 13px; - line-height: 18px; -} -[data-rk] .ju367v14 { - font-size: 14px; - line-height: 18px; -} -[data-rk] .ju367v15 { - font-size: 16px; - line-height: 20px; -} -[data-rk] .ju367v16 { - font-size: 18px; - line-height: 24px; -} -[data-rk] .ju367v17 { - font-size: 20px; - line-height: 24px; -} -[data-rk] .ju367v18 { - font-size: 23px; - line-height: 29px; -} -[data-rk] .ju367v19 { - font-weight: 400; -} -[data-rk] .ju367v1a { - font-weight: 500; -} -[data-rk] .ju367v1b { - font-weight: 600; -} -[data-rk] .ju367v1c { - font-weight: 700; -} -[data-rk] .ju367v1d { - font-weight: 800; -} -[data-rk] .ju367v1e { - gap: 0; -} -[data-rk] .ju367v1f { - gap: 1px; -} -[data-rk] .ju367v1g { - gap: 2px; -} -[data-rk] .ju367v1h { - gap: 3px; -} -[data-rk] .ju367v1i { - gap: 4px; -} -[data-rk] .ju367v1j { - gap: 5px; -} -[data-rk] .ju367v1k { - gap: 6px; -} -[data-rk] .ju367v1l { - gap: 8px; -} -[data-rk] .ju367v1m { - gap: 10px; -} -[data-rk] .ju367v1n { - gap: 12px; -} -[data-rk] .ju367v1o { - gap: 14px; -} -[data-rk] .ju367v1p { - gap: 16px; -} -[data-rk] .ju367v1q { - gap: 18px; -} -[data-rk] .ju367v1r { - gap: 20px; -} -[data-rk] .ju367v1s { - gap: 24px; -} -[data-rk] .ju367v1t { - gap: 28px; -} -[data-rk] .ju367v1u { - gap: 32px; -} -[data-rk] .ju367v1v { - gap: 36px; -} -[data-rk] .ju367v1w { - gap: 44px; -} -[data-rk] .ju367v1x { - gap: 64px; -} -[data-rk] .ju367v1y { - gap: -1px; -} -[data-rk] .ju367v1z { - height: 1px; -} -[data-rk] .ju367v20 { - height: 2px; -} -[data-rk] .ju367v21 { - height: 4px; -} -[data-rk] .ju367v22 { - height: 8px; -} -[data-rk] .ju367v23 { - height: 12px; -} -[data-rk] .ju367v24 { - height: 20px; -} -[data-rk] .ju367v25 { - height: 24px; -} -[data-rk] .ju367v26 { - height: 28px; -} -[data-rk] .ju367v27 { - height: 30px; -} -[data-rk] .ju367v28 { - height: 32px; -} -[data-rk] .ju367v29 { - height: 34px; -} -[data-rk] .ju367v2a { - height: 36px; -} -[data-rk] .ju367v2b { - height: 40px; -} -[data-rk] .ju367v2c { - height: 44px; -} -[data-rk] .ju367v2d { - height: 48px; -} -[data-rk] .ju367v2e { - height: 54px; -} -[data-rk] .ju367v2f { - height: 60px; -} -[data-rk] .ju367v2g { - height: 200px; -} -[data-rk] .ju367v2h { - height: 100%; -} -[data-rk] .ju367v2i { - height: -moz-max-content; - height: max-content; -} -[data-rk] .ju367v2j { - justify-content: flex-start; -} -[data-rk] .ju367v2k { - justify-content: flex-end; -} -[data-rk] .ju367v2l { - justify-content: center; -} -[data-rk] .ju367v2m { - justify-content: space-between; -} -[data-rk] .ju367v2n { - justify-content: space-around; -} -[data-rk] .ju367v2o { - text-align: left; -} -[data-rk] .ju367v2p { - text-align: center; -} -[data-rk] .ju367v2q { - text-align: inherit; -} -[data-rk] .ju367v2r { - margin-bottom: 0; -} -[data-rk] .ju367v2s { - margin-bottom: 1px; -} -[data-rk] .ju367v2t { - margin-bottom: 2px; -} -[data-rk] .ju367v2u { - margin-bottom: 3px; -} -[data-rk] .ju367v2v { - margin-bottom: 4px; -} -[data-rk] .ju367v2w { - margin-bottom: 5px; -} -[data-rk] .ju367v2x { - margin-bottom: 6px; -} -[data-rk] .ju367v2y { - margin-bottom: 8px; -} -[data-rk] .ju367v2z { - margin-bottom: 10px; -} -[data-rk] .ju367v30 { - margin-bottom: 12px; -} -[data-rk] .ju367v31 { - margin-bottom: 14px; -} -[data-rk] .ju367v32 { - margin-bottom: 16px; -} -[data-rk] .ju367v33 { - margin-bottom: 18px; -} -[data-rk] .ju367v34 { - margin-bottom: 20px; -} -[data-rk] .ju367v35 { - margin-bottom: 24px; -} -[data-rk] .ju367v36 { - margin-bottom: 28px; -} -[data-rk] .ju367v37 { - margin-bottom: 32px; -} -[data-rk] .ju367v38 { - margin-bottom: 36px; -} -[data-rk] .ju367v39 { - margin-bottom: 44px; -} -[data-rk] .ju367v3a { - margin-bottom: 64px; -} -[data-rk] .ju367v3b { - margin-bottom: -1px; -} -[data-rk] .ju367v3c { - margin-left: 0; -} -[data-rk] .ju367v3d { - margin-left: 1px; -} -[data-rk] .ju367v3e { - margin-left: 2px; -} -[data-rk] .ju367v3f { - margin-left: 3px; -} -[data-rk] .ju367v3g { - margin-left: 4px; -} -[data-rk] .ju367v3h { - margin-left: 5px; -} -[data-rk] .ju367v3i { - margin-left: 6px; -} -[data-rk] .ju367v3j { - margin-left: 8px; -} -[data-rk] .ju367v3k { - margin-left: 10px; -} -[data-rk] .ju367v3l { - margin-left: 12px; -} -[data-rk] .ju367v3m { - margin-left: 14px; -} -[data-rk] .ju367v3n { - margin-left: 16px; -} -[data-rk] .ju367v3o { - margin-left: 18px; -} -[data-rk] .ju367v3p { - margin-left: 20px; -} -[data-rk] .ju367v3q { - margin-left: 24px; -} -[data-rk] .ju367v3r { - margin-left: 28px; -} -[data-rk] .ju367v3s { - margin-left: 32px; -} -[data-rk] .ju367v3t { - margin-left: 36px; -} -[data-rk] .ju367v3u { - margin-left: 44px; -} -[data-rk] .ju367v3v { - margin-left: 64px; -} -[data-rk] .ju367v3w { - margin-left: -1px; -} -[data-rk] .ju367v3x { - margin-right: 0; -} -[data-rk] .ju367v3y { - margin-right: 1px; -} -[data-rk] .ju367v3z { - margin-right: 2px; -} -[data-rk] .ju367v40 { - margin-right: 3px; -} -[data-rk] .ju367v41 { - margin-right: 4px; -} -[data-rk] .ju367v42 { - margin-right: 5px; -} -[data-rk] .ju367v43 { - margin-right: 6px; -} -[data-rk] .ju367v44 { - margin-right: 8px; -} -[data-rk] .ju367v45 { - margin-right: 10px; -} -[data-rk] .ju367v46 { - margin-right: 12px; -} -[data-rk] .ju367v47 { - margin-right: 14px; -} -[data-rk] .ju367v48 { - margin-right: 16px; -} -[data-rk] .ju367v49 { - margin-right: 18px; -} -[data-rk] .ju367v4a { - margin-right: 20px; -} -[data-rk] .ju367v4b { - margin-right: 24px; -} -[data-rk] .ju367v4c { - margin-right: 28px; -} -[data-rk] .ju367v4d { - margin-right: 32px; -} -[data-rk] .ju367v4e { - margin-right: 36px; -} -[data-rk] .ju367v4f { - margin-right: 44px; -} -[data-rk] .ju367v4g { - margin-right: 64px; -} -[data-rk] .ju367v4h { - margin-right: -1px; -} -[data-rk] .ju367v4i { - margin-top: 0; -} -[data-rk] .ju367v4j { - margin-top: 1px; -} -[data-rk] .ju367v4k { - margin-top: 2px; -} -[data-rk] .ju367v4l { - margin-top: 3px; -} -[data-rk] .ju367v4m { - margin-top: 4px; -} -[data-rk] .ju367v4n { - margin-top: 5px; -} -[data-rk] .ju367v4o { - margin-top: 6px; -} -[data-rk] .ju367v4p { - margin-top: 8px; -} -[data-rk] .ju367v4q { - margin-top: 10px; -} -[data-rk] .ju367v4r { - margin-top: 12px; -} -[data-rk] .ju367v4s { - margin-top: 14px; -} -[data-rk] .ju367v4t { - margin-top: 16px; -} -[data-rk] .ju367v4u { - margin-top: 18px; -} -[data-rk] .ju367v4v { - margin-top: 20px; -} -[data-rk] .ju367v4w { - margin-top: 24px; -} -[data-rk] .ju367v4x { - margin-top: 28px; -} -[data-rk] .ju367v4y { - margin-top: 32px; -} -[data-rk] .ju367v4z { - margin-top: 36px; -} -[data-rk] .ju367v50 { - margin-top: 44px; -} -[data-rk] .ju367v51 { - margin-top: 64px; -} -[data-rk] .ju367v52 { - margin-top: -1px; -} -[data-rk] .ju367v53 { - max-width: 1px; -} -[data-rk] .ju367v54 { - max-width: 2px; -} -[data-rk] .ju367v55 { - max-width: 4px; -} -[data-rk] .ju367v56 { - max-width: 8px; -} -[data-rk] .ju367v57 { - max-width: 12px; -} -[data-rk] .ju367v58 { - max-width: 20px; -} -[data-rk] .ju367v59 { - max-width: 24px; -} -[data-rk] .ju367v5a { - max-width: 28px; -} -[data-rk] .ju367v5b { - max-width: 30px; -} -[data-rk] .ju367v5c { - max-width: 32px; -} -[data-rk] .ju367v5d { - max-width: 34px; -} -[data-rk] .ju367v5e { - max-width: 36px; -} -[data-rk] .ju367v5f { - max-width: 40px; -} -[data-rk] .ju367v5g { - max-width: 44px; -} -[data-rk] .ju367v5h { - max-width: 48px; -} -[data-rk] .ju367v5i { - max-width: 54px; -} -[data-rk] .ju367v5j { - max-width: 60px; -} -[data-rk] .ju367v5k { - max-width: 200px; -} -[data-rk] .ju367v5l { - max-width: 100%; -} -[data-rk] .ju367v5m { - max-width: -moz-max-content; - max-width: max-content; -} -[data-rk] .ju367v5n { - min-width: 1px; -} -[data-rk] .ju367v5o { - min-width: 2px; -} -[data-rk] .ju367v5p { - min-width: 4px; -} -[data-rk] .ju367v5q { - min-width: 8px; -} -[data-rk] .ju367v5r { - min-width: 12px; -} -[data-rk] .ju367v5s { - min-width: 20px; -} -[data-rk] .ju367v5t { - min-width: 24px; -} -[data-rk] .ju367v5u { - min-width: 28px; -} -[data-rk] .ju367v5v { - min-width: 30px; -} -[data-rk] .ju367v5w { - min-width: 32px; -} -[data-rk] .ju367v5x { - min-width: 34px; -} -[data-rk] .ju367v5y { - min-width: 36px; -} -[data-rk] .ju367v5z { - min-width: 40px; -} -[data-rk] .ju367v60 { - min-width: 44px; -} -[data-rk] .ju367v61 { - min-width: 48px; -} -[data-rk] .ju367v62 { - min-width: 54px; -} -[data-rk] .ju367v63 { - min-width: 60px; -} -[data-rk] .ju367v64 { - min-width: 200px; -} -[data-rk] .ju367v65 { - min-width: 100%; -} -[data-rk] .ju367v66 { - min-width: -moz-max-content; - min-width: max-content; -} -[data-rk] .ju367v67 { - overflow: hidden; -} -[data-rk] .ju367v68 { - padding-bottom: 0; -} -[data-rk] .ju367v69 { - padding-bottom: 1px; -} -[data-rk] .ju367v6a { - padding-bottom: 2px; -} -[data-rk] .ju367v6b { - padding-bottom: 3px; -} -[data-rk] .ju367v6c { - padding-bottom: 4px; -} -[data-rk] .ju367v6d { - padding-bottom: 5px; -} -[data-rk] .ju367v6e { - padding-bottom: 6px; -} -[data-rk] .ju367v6f { - padding-bottom: 8px; -} -[data-rk] .ju367v6g { - padding-bottom: 10px; -} -[data-rk] .ju367v6h { - padding-bottom: 12px; -} -[data-rk] .ju367v6i { - padding-bottom: 14px; -} -[data-rk] .ju367v6j { - padding-bottom: 16px; -} -[data-rk] .ju367v6k { - padding-bottom: 18px; -} -[data-rk] .ju367v6l { - padding-bottom: 20px; -} -[data-rk] .ju367v6m { - padding-bottom: 24px; -} -[data-rk] .ju367v6n { - padding-bottom: 28px; -} -[data-rk] .ju367v6o { - padding-bottom: 32px; -} -[data-rk] .ju367v6p { - padding-bottom: 36px; -} -[data-rk] .ju367v6q { - padding-bottom: 44px; -} -[data-rk] .ju367v6r { - padding-bottom: 64px; -} -[data-rk] .ju367v6s { - padding-bottom: -1px; -} -[data-rk] .ju367v6t { - padding-left: 0; -} -[data-rk] .ju367v6u { - padding-left: 1px; -} -[data-rk] .ju367v6v { - padding-left: 2px; -} -[data-rk] .ju367v6w { - padding-left: 3px; -} -[data-rk] .ju367v6x { - padding-left: 4px; -} -[data-rk] .ju367v6y { - padding-left: 5px; -} -[data-rk] .ju367v6z { - padding-left: 6px; -} -[data-rk] .ju367v70 { - padding-left: 8px; -} -[data-rk] .ju367v71 { - padding-left: 10px; -} -[data-rk] .ju367v72 { - padding-left: 12px; -} -[data-rk] .ju367v73 { - padding-left: 14px; -} -[data-rk] .ju367v74 { - padding-left: 16px; -} -[data-rk] .ju367v75 { - padding-left: 18px; -} -[data-rk] .ju367v76 { - padding-left: 20px; -} -[data-rk] .ju367v77 { - padding-left: 24px; -} -[data-rk] .ju367v78 { - padding-left: 28px; -} -[data-rk] .ju367v79 { - padding-left: 32px; -} -[data-rk] .ju367v7a { - padding-left: 36px; -} -[data-rk] .ju367v7b { - padding-left: 44px; -} -[data-rk] .ju367v7c { - padding-left: 64px; -} -[data-rk] .ju367v7d { - padding-left: -1px; -} -[data-rk] .ju367v7e { - padding-right: 0; -} -[data-rk] .ju367v7f { - padding-right: 1px; -} -[data-rk] .ju367v7g { - padding-right: 2px; -} -[data-rk] .ju367v7h { - padding-right: 3px; -} -[data-rk] .ju367v7i { - padding-right: 4px; -} -[data-rk] .ju367v7j { - padding-right: 5px; -} -[data-rk] .ju367v7k { - padding-right: 6px; -} -[data-rk] .ju367v7l { - padding-right: 8px; -} -[data-rk] .ju367v7m { - padding-right: 10px; -} -[data-rk] .ju367v7n { - padding-right: 12px; -} -[data-rk] .ju367v7o { - padding-right: 14px; -} -[data-rk] .ju367v7p { - padding-right: 16px; -} -[data-rk] .ju367v7q { - padding-right: 18px; -} -[data-rk] .ju367v7r { - padding-right: 20px; -} -[data-rk] .ju367v7s { - padding-right: 24px; -} -[data-rk] .ju367v7t { - padding-right: 28px; -} -[data-rk] .ju367v7u { - padding-right: 32px; -} -[data-rk] .ju367v7v { - padding-right: 36px; -} -[data-rk] .ju367v7w { - padding-right: 44px; -} -[data-rk] .ju367v7x { - padding-right: 64px; -} -[data-rk] .ju367v7y { - padding-right: -1px; -} -[data-rk] .ju367v7z { - padding-top: 0; -} -[data-rk] .ju367v80 { - padding-top: 1px; -} -[data-rk] .ju367v81 { - padding-top: 2px; -} -[data-rk] .ju367v82 { - padding-top: 3px; -} -[data-rk] .ju367v83 { - padding-top: 4px; -} -[data-rk] .ju367v84 { - padding-top: 5px; -} -[data-rk] .ju367v85 { - padding-top: 6px; -} -[data-rk] .ju367v86 { - padding-top: 8px; -} -[data-rk] .ju367v87 { - padding-top: 10px; -} -[data-rk] .ju367v88 { - padding-top: 12px; -} -[data-rk] .ju367v89 { - padding-top: 14px; -} -[data-rk] .ju367v8a { - padding-top: 16px; -} -[data-rk] .ju367v8b { - padding-top: 18px; -} -[data-rk] .ju367v8c { - padding-top: 20px; -} -[data-rk] .ju367v8d { - padding-top: 24px; -} -[data-rk] .ju367v8e { - padding-top: 28px; -} -[data-rk] .ju367v8f { - padding-top: 32px; -} -[data-rk] .ju367v8g { - padding-top: 36px; -} -[data-rk] .ju367v8h { - padding-top: 44px; -} -[data-rk] .ju367v8i { - padding-top: 64px; -} -[data-rk] .ju367v8j { - padding-top: -1px; -} -[data-rk] .ju367v8k { - position: absolute; -} -[data-rk] .ju367v8l { - position: fixed; -} -[data-rk] .ju367v8m { - position: relative; -} -[data-rk] .ju367v8n { - right: 0; -} -[data-rk] .ju367v8o { - transition: 0.125s ease; -} -[data-rk] .ju367v8p { - transition: transform 0.125s ease; -} -[data-rk] .ju367v8q { - -webkit-user-select: none; - -moz-user-select: none; - user-select: none; -} -[data-rk] .ju367v8r { - width: 1px; -} -[data-rk] .ju367v8s { - width: 2px; -} -[data-rk] .ju367v8t { - width: 4px; -} -[data-rk] .ju367v8u { - width: 8px; -} -[data-rk] .ju367v8v { - width: 12px; -} -[data-rk] .ju367v8w { - width: 20px; -} -[data-rk] .ju367v8x { - width: 24px; -} -[data-rk] .ju367v8y { - width: 28px; -} -[data-rk] .ju367v8z { - width: 30px; -} -[data-rk] .ju367v90 { - width: 32px; -} -[data-rk] .ju367v91 { - width: 34px; -} -[data-rk] .ju367v92 { - width: 36px; -} -[data-rk] .ju367v93 { - width: 40px; -} -[data-rk] .ju367v94 { - width: 44px; -} -[data-rk] .ju367v95 { - width: 48px; -} -[data-rk] .ju367v96 { - width: 54px; -} -[data-rk] .ju367v97 { - width: 60px; -} -[data-rk] .ju367v98 { - width: 200px; -} -[data-rk] .ju367v99 { - width: 100%; -} -[data-rk] .ju367v9a { - width: -moz-max-content; - width: max-content; -} -[data-rk] .ju367v9b { - -webkit-backdrop-filter: var(--rk-blurs-modalOverlay); - backdrop-filter: var(--rk-blurs-modalOverlay); -} -[data-rk] .ju367v9c { - background: var(--rk-colors-accentColor); -} -[data-rk] .ju367v9d:hover { - background: var(--rk-colors-accentColor); -} -[data-rk] .ju367v9e:active { - background: var(--rk-colors-accentColor); -} -[data-rk] .ju367v9f { - background: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367v9g:hover { - background: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367v9h:active { - background: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367v9i { - background: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367v9j:hover { - background: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367v9k:active { - background: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367v9l { - background: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367v9m:hover { - background: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367v9n:active { - background: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367v9o { - background: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367v9p:hover { - background: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367v9q:active { - background: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367v9r { - background: var(--rk-colors-closeButton); -} -[data-rk] .ju367v9s:hover { - background: var(--rk-colors-closeButton); -} -[data-rk] .ju367v9t:active { - background: var(--rk-colors-closeButton); -} -[data-rk] .ju367v9u { - background: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367v9v:hover { - background: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367v9w:active { - background: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367v9x { - background: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367v9y:hover { - background: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367v9z:active { - background: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367va0 { - background: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367va1:hover { - background: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367va2:active { - background: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367va3 { - background: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367va4:hover { - background: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367va5:active { - background: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367va6 { - background: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367va7:hover { - background: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367va8:active { - background: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367va9 { - background: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vaa:hover { - background: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vab:active { - background: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vac { - background: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vad:hover { - background: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vae:active { - background: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vaf { - background: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vag:hover { - background: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vah:active { - background: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vai { - background: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vaj:hover { - background: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vak:active { - background: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367val { - background: var(--rk-colors-error); -} -[data-rk] .ju367vam:hover { - background: var(--rk-colors-error); -} -[data-rk] .ju367van:active { - background: var(--rk-colors-error); -} -[data-rk] .ju367vao { - background: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vap:hover { - background: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vaq:active { - background: var(--rk-colors-generalBorder); -} -[data-rk] .ju367var { - background: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vas:hover { - background: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vat:active { - background: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vau { - background: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vav:hover { - background: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vaw:active { - background: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vax { - background: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vay:hover { - background: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vaz:active { - background: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vb0 { - background: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vb1:hover { - background: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vb2:active { - background: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vb3 { - background: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vb4:hover { - background: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vb5:active { - background: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vb6 { - background: var(--rk-colors-modalText); -} -[data-rk] .ju367vb7:hover { - background: var(--rk-colors-modalText); -} -[data-rk] .ju367vb8:active { - background: var(--rk-colors-modalText); -} -[data-rk] .ju367vb9 { - background: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vba:hover { - background: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vbb:active { - background: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vbc { - background: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vbd:hover { - background: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vbe:active { - background: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vbf { - background: var(--rk-colors-profileAction); -} -[data-rk] .ju367vbg:hover { - background: var(--rk-colors-profileAction); -} -[data-rk] .ju367vbh:active { - background: var(--rk-colors-profileAction); -} -[data-rk] .ju367vbi { - background: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367vbj:hover { - background: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367vbk:active { - background: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367vbl { - background: var(--rk-colors-profileForeground); -} -[data-rk] .ju367vbm:hover { - background: var(--rk-colors-profileForeground); -} -[data-rk] .ju367vbn:active { - background: var(--rk-colors-profileForeground); -} -[data-rk] .ju367vbo { - background: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367vbp:hover { - background: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367vbq:active { - background: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367vbr { - background: var(--rk-colors-standby); -} -[data-rk] .ju367vbs:hover { - background: var(--rk-colors-standby); -} -[data-rk] .ju367vbt:active { - background: var(--rk-colors-standby); -} -[data-rk] .ju367vbu { - border-color: var(--rk-colors-accentColor); -} -[data-rk] .ju367vbv:hover { - border-color: var(--rk-colors-accentColor); -} -[data-rk] .ju367vbw:active { - border-color: var(--rk-colors-accentColor); -} -[data-rk] .ju367vbx { - border-color: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367vby:hover { - border-color: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367vbz:active { - border-color: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367vc0 { - border-color: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367vc1:hover { - border-color: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367vc2:active { - border-color: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367vc3 { - border-color: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367vc4:hover { - border-color: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367vc5:active { - border-color: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367vc6 { - border-color: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367vc7:hover { - border-color: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367vc8:active { - border-color: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367vc9 { - border-color: var(--rk-colors-closeButton); -} -[data-rk] .ju367vca:hover { - border-color: var(--rk-colors-closeButton); -} -[data-rk] .ju367vcb:active { - border-color: var(--rk-colors-closeButton); -} -[data-rk] .ju367vcc { - border-color: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367vcd:hover { - border-color: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367vce:active { - border-color: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367vcf { - border-color: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367vcg:hover { - border-color: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367vch:active { - border-color: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367vci { - border-color: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367vcj:hover { - border-color: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367vck:active { - border-color: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367vcl { - border-color: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367vcm:hover { - border-color: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367vcn:active { - border-color: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367vco { - border-color: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367vcp:hover { - border-color: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367vcq:active { - border-color: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367vcr { - border-color: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vcs:hover { - border-color: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vct:active { - border-color: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vcu { - border-color: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vcv:hover { - border-color: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vcw:active { - border-color: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vcx { - border-color: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vcy:hover { - border-color: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vcz:active { - border-color: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vd0 { - border-color: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vd1:hover { - border-color: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vd2:active { - border-color: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vd3 { - border-color: var(--rk-colors-error); -} -[data-rk] .ju367vd4:hover { - border-color: var(--rk-colors-error); -} -[data-rk] .ju367vd5:active { - border-color: var(--rk-colors-error); -} -[data-rk] .ju367vd6 { - border-color: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vd7:hover { - border-color: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vd8:active { - border-color: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vd9 { - border-color: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vda:hover { - border-color: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vdb:active { - border-color: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vdc { - border-color: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vdd:hover { - border-color: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vde:active { - border-color: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vdf { - border-color: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vdg:hover { - border-color: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vdh:active { - border-color: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vdi { - border-color: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vdj:hover { - border-color: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vdk:active { - border-color: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vdl { - border-color: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vdm:hover { - border-color: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vdn:active { - border-color: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vdo { - border-color: var(--rk-colors-modalText); -} -[data-rk] .ju367vdp:hover { - border-color: var(--rk-colors-modalText); -} -[data-rk] .ju367vdq:active { - border-color: var(--rk-colors-modalText); -} -[data-rk] .ju367vdr { - border-color: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vds:hover { - border-color: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vdt:active { - border-color: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vdu { - border-color: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vdv:hover { - border-color: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vdw:active { - border-color: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vdx { - border-color: var(--rk-colors-profileAction); -} -[data-rk] .ju367vdy:hover { - border-color: var(--rk-colors-profileAction); -} -[data-rk] .ju367vdz:active { - border-color: var(--rk-colors-profileAction); -} -[data-rk] .ju367ve0 { - border-color: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367ve1:hover { - border-color: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367ve2:active { - border-color: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367ve3 { - border-color: var(--rk-colors-profileForeground); -} -[data-rk] .ju367ve4:hover { - border-color: var(--rk-colors-profileForeground); -} -[data-rk] .ju367ve5:active { - border-color: var(--rk-colors-profileForeground); -} -[data-rk] .ju367ve6 { - border-color: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367ve7:hover { - border-color: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367ve8:active { - border-color: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367ve9 { - border-color: var(--rk-colors-standby); -} -[data-rk] .ju367vea:hover { - border-color: var(--rk-colors-standby); -} -[data-rk] .ju367veb:active { - border-color: var(--rk-colors-standby); -} -[data-rk] .ju367vec { - box-shadow: var(--rk-shadows-connectButton); -} -[data-rk] .ju367ved:hover { - box-shadow: var(--rk-shadows-connectButton); -} -[data-rk] .ju367vee:active { - box-shadow: var(--rk-shadows-connectButton); -} -[data-rk] .ju367vef { - box-shadow: var(--rk-shadows-dialog); -} -[data-rk] .ju367veg:hover { - box-shadow: var(--rk-shadows-dialog); -} -[data-rk] .ju367veh:active { - box-shadow: var(--rk-shadows-dialog); -} -[data-rk] .ju367vei { - box-shadow: var(--rk-shadows-profileDetailsAction); -} -[data-rk] .ju367vej:hover { - box-shadow: var(--rk-shadows-profileDetailsAction); -} -[data-rk] .ju367vek:active { - box-shadow: var(--rk-shadows-profileDetailsAction); -} -[data-rk] .ju367vel { - box-shadow: var(--rk-shadows-selectedOption); -} -[data-rk] .ju367vem:hover { - box-shadow: var(--rk-shadows-selectedOption); -} -[data-rk] .ju367ven:active { - box-shadow: var(--rk-shadows-selectedOption); -} -[data-rk] .ju367veo { - box-shadow: var(--rk-shadows-selectedWallet); -} -[data-rk] .ju367vep:hover { - box-shadow: var(--rk-shadows-selectedWallet); -} -[data-rk] .ju367veq:active { - box-shadow: var(--rk-shadows-selectedWallet); -} -[data-rk] .ju367ver { - box-shadow: var(--rk-shadows-walletLogo); -} -[data-rk] .ju367ves:hover { - box-shadow: var(--rk-shadows-walletLogo); -} -[data-rk] .ju367vet:active { - box-shadow: var(--rk-shadows-walletLogo); -} -[data-rk] .ju367veu { - color: var(--rk-colors-accentColor); -} -[data-rk] .ju367vev:hover { - color: var(--rk-colors-accentColor); -} -[data-rk] .ju367vew:active { - color: var(--rk-colors-accentColor); -} -[data-rk] .ju367vex { - color: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367vey:hover { - color: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367vez:active { - color: var(--rk-colors-accentColorForeground); -} -[data-rk] .ju367vf0 { - color: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367vf1:hover { - color: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367vf2:active { - color: var(--rk-colors-actionButtonBorder); -} -[data-rk] .ju367vf3 { - color: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367vf4:hover { - color: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367vf5:active { - color: var(--rk-colors-actionButtonBorderMobile); -} -[data-rk] .ju367vf6 { - color: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367vf7:hover { - color: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367vf8:active { - color: var(--rk-colors-actionButtonSecondaryBackground); -} -[data-rk] .ju367vf9 { - color: var(--rk-colors-closeButton); -} -[data-rk] .ju367vfa:hover { - color: var(--rk-colors-closeButton); -} -[data-rk] .ju367vfb:active { - color: var(--rk-colors-closeButton); -} -[data-rk] .ju367vfc { - color: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367vfd:hover { - color: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367vfe:active { - color: var(--rk-colors-closeButtonBackground); -} -[data-rk] .ju367vff { - color: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367vfg:hover { - color: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367vfh:active { - color: var(--rk-colors-connectButtonBackground); -} -[data-rk] .ju367vfi { - color: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367vfj:hover { - color: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367vfk:active { - color: var(--rk-colors-connectButtonBackgroundError); -} -[data-rk] .ju367vfl { - color: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367vfm:hover { - color: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367vfn:active { - color: var(--rk-colors-connectButtonInnerBackground); -} -[data-rk] .ju367vfo { - color: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367vfp:hover { - color: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367vfq:active { - color: var(--rk-colors-connectButtonText); -} -[data-rk] .ju367vfr { - color: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vfs:hover { - color: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vft:active { - color: var(--rk-colors-connectButtonTextError); -} -[data-rk] .ju367vfu { - color: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vfv:hover { - color: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vfw:active { - color: var(--rk-colors-connectionIndicator); -} -[data-rk] .ju367vfx { - color: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vfy:hover { - color: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vfz:active { - color: var(--rk-colors-downloadBottomCardBackground); -} -[data-rk] .ju367vg0 { - color: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vg1:hover { - color: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vg2:active { - color: var(--rk-colors-downloadTopCardBackground); -} -[data-rk] .ju367vg3 { - color: var(--rk-colors-error); -} -[data-rk] .ju367vg4:hover { - color: var(--rk-colors-error); -} -[data-rk] .ju367vg5:active { - color: var(--rk-colors-error); -} -[data-rk] .ju367vg6 { - color: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vg7:hover { - color: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vg8:active { - color: var(--rk-colors-generalBorder); -} -[data-rk] .ju367vg9 { - color: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vga:hover { - color: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vgb:active { - color: var(--rk-colors-generalBorderDim); -} -[data-rk] .ju367vgc { - color: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vgd:hover { - color: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vge:active { - color: var(--rk-colors-menuItemBackground); -} -[data-rk] .ju367vgf { - color: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vgg:hover { - color: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vgh:active { - color: var(--rk-colors-modalBackdrop); -} -[data-rk] .ju367vgi { - color: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vgj:hover { - color: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vgk:active { - color: var(--rk-colors-modalBackground); -} -[data-rk] .ju367vgl { - color: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vgm:hover { - color: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vgn:active { - color: var(--rk-colors-modalBorder); -} -[data-rk] .ju367vgo { - color: var(--rk-colors-modalText); -} -[data-rk] .ju367vgp:hover { - color: var(--rk-colors-modalText); -} -[data-rk] .ju367vgq:active { - color: var(--rk-colors-modalText); -} -[data-rk] .ju367vgr { - color: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vgs:hover { - color: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vgt:active { - color: var(--rk-colors-modalTextDim); -} -[data-rk] .ju367vgu { - color: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vgv:hover { - color: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vgw:active { - color: var(--rk-colors-modalTextSecondary); -} -[data-rk] .ju367vgx { - color: var(--rk-colors-profileAction); -} -[data-rk] .ju367vgy:hover { - color: var(--rk-colors-profileAction); -} -[data-rk] .ju367vgz:active { - color: var(--rk-colors-profileAction); -} -[data-rk] .ju367vh0 { - color: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367vh1:hover { - color: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367vh2:active { - color: var(--rk-colors-profileActionHover); -} -[data-rk] .ju367vh3 { - color: var(--rk-colors-profileForeground); -} -[data-rk] .ju367vh4:hover { - color: var(--rk-colors-profileForeground); -} -[data-rk] .ju367vh5:active { - color: var(--rk-colors-profileForeground); -} -[data-rk] .ju367vh6 { - color: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367vh7:hover { - color: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367vh8:active { - color: var(--rk-colors-selectedOptionBorder); -} -[data-rk] .ju367vh9 { - color: var(--rk-colors-standby); -} -[data-rk] .ju367vha:hover { - color: var(--rk-colors-standby); -} -[data-rk] .ju367vhb:active { - color: var(--rk-colors-standby); -} -@media screen and (min-width: 768px) { - [data-rk] .ju367v1 { - align-items: flex-start; - } - [data-rk] .ju367v3 { - align-items: flex-end; - } - [data-rk] .ju367v5 { - align-items: center; - } - [data-rk] .ju367v7 { - display: none; - } - [data-rk] .ju367v9 { - display: block; - } - [data-rk] .ju367vb { - display: flex; - } - [data-rk] .ju367vd { - display: inline; - } -} - -/* vanilla-extract-css-ns:src/css/touchableStyles.css.ts.vanilla.css?source=Ll8xMmNibzhpMywuXzEyY2JvOGkzOjphZnRlciB7CiAgLS1fMTJjYm84aTA6IDE7CiAgLS1fMTJjYm84aTE6IDE7Cn0KLl8xMmNibzhpMzpob3ZlciB7CiAgdHJhbnNmb3JtOiBzY2FsZSh2YXIoLS1fMTJjYm84aTApKTsKfQouXzEyY2JvOGkzOmFjdGl2ZSB7CiAgdHJhbnNmb3JtOiBzY2FsZSh2YXIoLS1fMTJjYm84aTEpKTsKfQouXzEyY2JvOGkzOmFjdGl2ZTo6YWZ0ZXIgewogIGNvbnRlbnQ6ICIiOwogIGJvdHRvbTogLTFweDsKICBkaXNwbGF5OiBibG9jazsKICBsZWZ0OiAtMXB4OwogIHBvc2l0aW9uOiBhYnNvbHV0ZTsKICByaWdodDogLTFweDsKICB0b3A6IC0xcHg7CiAgdHJhbnNmb3JtOiBzY2FsZShjYWxjKCgxIC8gdmFyKC0tXzEyY2JvOGkxKSkgKiB2YXIoLS1fMTJjYm84aTApKSk7Cn0KLl8xMmNibzhpNCwuXzEyY2JvOGk0OjphZnRlciB7CiAgLS1fMTJjYm84aTA6IDEuMDI1Owp9Ci5fMTJjYm84aTUsLl8xMmNibzhpNTo6YWZ0ZXIgewogIC0tXzEyY2JvOGkwOiAxLjE7Cn0KLl8xMmNibzhpNiwuXzEyY2JvOGk2OjphZnRlciB7CiAgLS1fMTJjYm84aTE6IDAuOTU7Cn0KLl8xMmNibzhpNywuXzEyY2JvOGk3OjphZnRlciB7CiAgLS1fMTJjYm84aTE6IDAuOTsKfQ== */ -[data-rk] ._12cbo8i3, -[data-rk] ._12cbo8i3::after { - --_12cbo8i0: 1; - --_12cbo8i1: 1; -} -[data-rk] ._12cbo8i3:hover { - transform: scale(var(--_12cbo8i0)); -} -[data-rk] ._12cbo8i3:active { - transform: scale(var(--_12cbo8i1)); -} -[data-rk] ._12cbo8i3:active::after { - content: ""; - bottom: -1px; - display: block; - left: -1px; - position: absolute; - right: -1px; - top: -1px; - transform: scale(calc((1 / var(--_12cbo8i1)) * var(--_12cbo8i0))); -} -[data-rk] ._12cbo8i4, -[data-rk] ._12cbo8i4::after { - --_12cbo8i0: 1.025; -} -[data-rk] ._12cbo8i5, -[data-rk] ._12cbo8i5::after { - --_12cbo8i0: 1.1; -} -[data-rk] ._12cbo8i6, -[data-rk] ._12cbo8i6::after { - --_12cbo8i1: 0.95; -} -[data-rk] ._12cbo8i7, -[data-rk] ._12cbo8i7::after { - --_12cbo8i1: 0.9; -} - -/* vanilla-extract-css-ns:src/components/Icons/Icons.css.ts.vanilla.css?source=QGtleWZyYW1lcyBfMWx1dWxlNDEgewogIDAlIHsKICAgIHRyYW5zZm9ybTogcm90YXRlKDBkZWcpOwogIH0KICAxMDAlIHsKICAgIHRyYW5zZm9ybTogcm90YXRlKDM2MGRlZyk7CiAgfQp9Ci5fMWx1dWxlNDIgewogIGFuaW1hdGlvbjogXzFsdXVsZTQxIDNzIGluZmluaXRlIGxpbmVhcjsKfQouXzFsdXVsZTQzIHsKICBiYWNrZ3JvdW5kOiBjb25pYy1ncmFkaWVudChmcm9tIDE4MGRlZyBhdCA1MCUgNTAlLCByZ2JhKDcyLCAxNDYsIDI1NCwgMCkgMGRlZywgY3VycmVudENvbG9yIDI4Mi4wNGRlZywgcmdiYSg3MiwgMTQ2LCAyNTQsIDApIDMxOS44NmRlZywgcmdiYSg3MiwgMTQ2LCAyNTQsIDApIDM2MGRlZyk7CiAgaGVpZ2h0OiAyMXB4OwogIHdpZHRoOiAyMXB4Owp9 */ -@keyframes _1luule41 { - 0% { - transform: rotate(0deg); - } - 100% { - transform: rotate(360deg); - } -} -[data-rk] ._1luule42 { - animation: _1luule41 3s infinite linear; -} -[data-rk] ._1luule43 { - background: conic-gradient(from 180deg at 50% 50%, rgba(72, 146, 254, 0) 0deg, currentColor 282.04deg, rgba(72, 146, 254, 0) 319.86deg, rgba(72, 146, 254, 0) 360deg); - height: 21px; - width: 21px; -} - -/* vanilla-extract-css-ns:src/components/Dialog/Dialog.css.ts.vanilla.css?source=QGtleWZyYW1lcyBfOXBtNGtpMCB7CiAgMCUgewogICAgdHJhbnNmb3JtOiB0cmFuc2xhdGVZKDEwMCUpOwogIH0KICAxMDAlIHsKICAgIHRyYW5zZm9ybTogdHJhbnNsYXRlWSgwKTsKICB9Cn0KQGtleWZyYW1lcyBfOXBtNGtpMSB7CiAgMCUgewogICAgb3BhY2l0eTogMDsKICB9CiAgMTAwJSB7CiAgICBvcGFjaXR5OiAxOwogIH0KfQouXzlwbTRraTMgewogIGFuaW1hdGlvbjogXzlwbTRraTEgMTUwbXMgZWFzZTsKICBib3R0b206IC0yMDBweDsKICBsZWZ0OiAtMjAwcHg7CiAgcGFkZGluZzogMjAwcHg7CiAgcmlnaHQ6IC0yMDBweDsKICB0b3A6IC0yMDBweDsKICB0cmFuc2Zvcm06IHRyYW5zbGF0ZVooMCk7CiAgei1pbmRleDogMjE0NzQ4MzY0NjsKfQouXzlwbTRraTUgewogIGFuaW1hdGlvbjogXzlwbTRraTAgMzUwbXMgY3ViaWMtYmV6aWVyKC4xNSwxLjE1LDAuNiwxLjAwKSwgXzlwbTRraTEgMTUwbXMgZWFzZTsKICBtYXgtd2lkdGg6IDEwMHZ3Owp9 */ -@keyframes _9pm4ki0 { - 0% { - transform: translateY(100%); - } - 100% { - transform: translateY(0); - } -} -@keyframes _9pm4ki1 { - 0% { - opacity: 0; - } - 100% { - opacity: 1; - } -} -[data-rk] ._9pm4ki3 { - animation: _9pm4ki1 150ms ease; - bottom: -200px; - left: -200px; - padding: 200px; - right: -200px; - top: -200px; - transform: translateZ(0); - z-index: 2147483646; -} -[data-rk] ._9pm4ki5 { - animation: _9pm4ki0 350ms cubic-bezier(.15, 1.15, 0.6, 1.00), _9pm4ki1 150ms ease; - max-width: 100vw; -} - -/* vanilla-extract-css-ns:src/components/Dialog/DialogContent.css.ts.vanilla.css?source=Ll8xY2tqcG9rMSB7CiAgYm94LXNpemluZzogY29udGVudC1ib3g7CiAgbWF4LXdpZHRoOiAxMDB2dzsKICB3aWR0aDogMzYwcHg7Cn0KLl8xY2tqcG9rMiB7CiAgd2lkdGg6IDEwMHZ3Owp9Ci5fMWNranBvazMgewogIHdpZHRoOiA3NjhweDsKfQouXzFja2pwb2s0IHsKICBtaW4td2lkdGg6IDM2OHB4OwogIHdpZHRoOiAzNjhweDsKfQouXzFja2pwb2s2IHsKICBib3JkZXItd2lkdGg6IDBweDsKICBib3gtc2l6aW5nOiBib3JkZXItYm94OwogIHdpZHRoOiAxMDB2dzsKfQpAbWVkaWEgc2NyZWVuIGFuZCAobWluLXdpZHRoOiA3NjhweCkgewogIC5fMWNranBvazEgewogICAgd2lkdGg6IDM2MHB4OwogIH0KICAuXzFja2pwb2syIHsKICAgIHdpZHRoOiA0ODBweDsKICB9CiAgLl8xY2tqcG9rMyB7CiAgICB3aWR0aDogNzIwcHg7CiAgfQogIC5fMWNranBvazQgewogICAgbWluLXdpZHRoOiAzNjhweDsKICAgIHdpZHRoOiAzNjhweDsKICB9Cn0KQG1lZGlhIHNjcmVlbiBhbmQgKG1heC13aWR0aDogNzY3cHgpIHsKICAuXzFja2pwb2s3IHsKICAgIGJvcmRlci1ib3R0b20tbGVmdC1yYWRpdXM6IDA7CiAgICBib3JkZXItYm90dG9tLXJpZ2h0LXJhZGl1czogMDsKICAgIG1hcmdpbi10b3A6IC0yMDBweDsKICAgIHBhZGRpbmctYm90dG9tOiAyMDBweDsKICAgIHRvcDogMjAwcHg7CiAgfQp9 */ -[data-rk] ._1ckjpok1 { - box-sizing: content-box; - max-width: 100vw; - width: 360px; -} -[data-rk] ._1ckjpok2 { - width: 100vw; -} -[data-rk] ._1ckjpok3 { - width: 768px; -} -[data-rk] ._1ckjpok4 { - min-width: 368px; - width: 368px; -} -[data-rk] ._1ckjpok6 { - border-width: 0px; - box-sizing: border-box; - width: 100vw; -} -@media screen and (min-width: 768px) { - [data-rk] ._1ckjpok1 { - width: 360px; - } - [data-rk] ._1ckjpok2 { - width: 480px; - } - [data-rk] ._1ckjpok3 { - width: 720px; - } - [data-rk] ._1ckjpok4 { - min-width: 368px; - width: 368px; - } -} -@media screen and (max-width: 767px) { - [data-rk] ._1ckjpok7 { - border-bottom-left-radius: 0; - border-bottom-right-radius: 0; - margin-top: -200px; - padding-bottom: 200px; - top: 200px; - } -} - -/* vanilla-extract-css-ns:src/components/MenuButton/MenuButton.css.ts.vanilla.css?source=LnY5aG9yYjA6aG92ZXIgewogIGJhY2tncm91bmQ6IHVuc2V0Owp9 */ -[data-rk] .v9horb0:hover { - background: unset; -} - -/* vanilla-extract-css-ns:src/components/ModalSelection/ModalSelection.css.ts.vanilla.css?source=Lmc1a2wwbDAgewogIGJvcmRlci1jb2xvcjogdHJhbnNwYXJlbnQ7Cn0= */ -[data-rk] .g5kl0l0 { - border-color: transparent; -} - -/* vanilla-extract-css-ns:src/components/ConnectOptions/DesktopOptions.css.ts.vanilla.css?source=Ll8xdnd0MGNnMCB7CiAgYmFja2dyb3VuZDogd2hpdGU7Cn0KLl8xdnd0MGNnMiB7CiAgbWF4LWhlaWdodDogNDU0cHg7CiAgb3ZlcmZsb3cteTogYXV0bzsKfQouXzF2d3QwY2czIHsKICBtaW4td2lkdGg6IDI0NnB4Owp9Ci5fMXZ3dDBjZzQgewogIG1pbi13aWR0aDogMTAwJTsKfQpAbWVkaWEgc2NyZWVuIGFuZCAobWluLXdpZHRoOiA3NjhweCkgewogIC5fMXZ3dDBjZzMgewogICAgbWluLXdpZHRoOiAyODdweDsKICB9Cn0= */ -[data-rk] ._1vwt0cg0 { - background: white; -} -[data-rk] ._1vwt0cg2 { - max-height: 454px; - overflow-y: auto; -} -[data-rk] ._1vwt0cg3 { - min-width: 246px; -} -[data-rk] ._1vwt0cg4 { - min-width: 100%; -} -@media screen and (min-width: 768px) { - [data-rk] ._1vwt0cg3 { - min-width: 287px; - } -} - -/* vanilla-extract-css-ns:src/components/ConnectOptions/MobileOptions.css.ts.vanilla.css?source=Ll8xYW0xNDQxMCB7CiAgb3ZlcmZsb3c6IGF1dG87CiAgc2Nyb2xsYmFyLXdpZHRoOiBub25lOwogIHRyYW5zZm9ybTogdHJhbnNsYXRlWigwKTsKfQouXzFhbTE0NDEwOjotd2Via2l0LXNjcm9sbGJhciB7CiAgZGlzcGxheTogbm9uZTsKfQ== */ -[data-rk] ._1am14410 { - overflow: auto; - scrollbar-width: none; - transform: translateZ(0); -} -[data-rk] ._1am14410::-webkit-scrollbar { - display: none; -} diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 8d3dca165..34c6842af 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -4,8 +4,7 @@ import { useDeviceWidthCheck, usePushChatSocket, } from '../../../hooks'; -import type { FileMessageContent, IGroup } from '../../../types'; -import type { ChatMainStateContextType } from '../../../context/chatAndNotification/chat/chatMainStateContext'; +import type { FileMessageContent } from '../../../types'; import { ChangeEvent, useContext, useEffect, useRef, useState } from 'react'; import { GIFType, IChatTheme, MessageInputProps } from '../exportedTypes'; import styled from 'styled-components'; @@ -13,7 +12,6 @@ import { PUBLIC_GOOGLE_TOKEN, device } from '../../../config'; import { Section, Div, Span } from '../../reusables'; import { EmojiIcon } from '../../../icons/Emoji'; import EmojiPicker, { EmojiClickData } from 'emoji-picker-react'; -import * as PUSHAPI from '@pushprotocol/restapi'; import { GifIcon } from '../../../icons/Gif'; import GifPicker from 'gif-picker-react'; import { AttachmentIcon } from '../../../icons/Attachment'; @@ -28,13 +26,10 @@ import { Modal } from '../helpers/Modal'; import { Image } from '../../reusables'; import { ConnectButtonComp } from '../ConnectButton'; import useGetGroupByID from '../../../hooks/chat/useGetGroupByID'; -import { ethers } from 'ethers'; import { checkIfIntent, - checkIfSameChat, getDefaultFeedObject, getNewChatUser, - pCAIP10ToWallet, setAccessControl, walletToPCAIP10, } from '../../../helpers'; @@ -65,7 +60,6 @@ export const MessageInput: React.FC = ({ const [typedMessage, setTypedMessage] = useState(''); const [showEmojis, setShowEmojis] = useState(false); const [gifOpen, setGifOpen] = useState(false); - const [newChat, setNewChat] = useState(false); const modalRef = useRef(null); const fileUploadInputRef = useRef(null); const [fileUploading, setFileUploading] = useState(false); @@ -73,7 +67,6 @@ export const MessageInput: React.FC = ({ const [isMember, setIsMember] = useState(false); const { approveChatRequest, loading: approveLoading } = useApproveChatRequest(); - // const [groupInformation, setGroupInformation] = useState(undefined); const onChangeTypedMessage = (val: string) => { setTypedMessage(val); }; @@ -91,18 +84,25 @@ export const MessageInput: React.FC = ({ setVerified, loading: accessLoading, } = useVerifyAccessControl(); - const { account, env ,connectedProfile,setConnectedProfile,pgpPrivateKey, signer,} = useChatData(); + const { + account, + env, + connectedProfile, + setConnectedProfile, + pgpPrivateKey, + signer, + } = useChatData(); const { fetchChat } = useFetchChat(); const { fetchChatProfile } = useGetChatProfile(); - const { getGroupByID } = useGetGroupByID(); const { getGroup } = useGetGroup(); const statusToast = useToast(); + const textAreaRef = useRef(null); useClickAway(modalRef, () => { setShowEmojis(false); setGifOpen(false); }); - const textAreaRef = useRef(null); + useEffect(() => { if (textAreaRef?.current?.style) { textAreaRef.current.style.height = 25 + 'px'; @@ -111,6 +111,97 @@ export const MessageInput: React.FC = ({ } }, [textAreaRef, typedMessage]); + //need to do something about fetching connectedUser in every component + useEffect(() => { + (async () => { + if (!connectedProfile && account) { + const user = await fetchChatProfile({ profileId: account!, env }); + if (user) setConnectedProfile(user); + } + })(); + }, [account]); + + useEffect(() => { + const storedTimestampJSON = localStorage.getItem(chatId); + + if (storedTimestampJSON) { + const storedTimestamp = JSON.parse(storedTimestampJSON); + const currentTimestamp = new Date().getTime(); + const twentyFourHoursInMilliseconds = 24 * 60 * 60 * 1000; + + if ( + Math.abs(currentTimestamp - storedTimestamp) < + twentyFourHoursInMilliseconds + ) { + setVerified(true); + } else { + setVerified(false); + setAccessControl(chatId, true); + } + } + }, [chatId, verified, isMember, account, env]); + + useEffect(() => { + if (Object.keys(groupInformationSinceLastConnection || {}).length) { + if ( + chatFeed?.groupInformation?.chatId.toLowerCase() === + groupInformationSinceLastConnection.chatId.toLowerCase() + ) { + const updateChatFeed = chatFeed; + updateChatFeed.groupInformation = groupInformationSinceLastConnection; + setChatFeed(updateChatFeed); + } + } + }, [groupInformationSinceLastConnection]); + + useEffect(() => { + (async () => { + if ( + Object.keys(acceptedRequestMessage || {}).length && + Object.keys(chatFeed || {}).length + ) { + await updateChatFeed(); + } + })(); + }, [acceptedRequestMessage]); + + //need to makea common method for fetching chatFeed to ruse in messageInput + useEffect(() => { + (async () => { + if (!account && !env) return; + if (account && env) { + const chat = await fetchChat({ chatId }); + if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); + else { + let newChatFeed; + let group; + const result = await getNewChatUser({ + searchText: chatId, + fetchChatProfile, + env, + }); + if (result) { + newChatFeed = getDefaultFeedObject({ user: result }); + } else { + group = await getGroup({ searchText: chatId }); + if (group) { + newChatFeed = getDefaultFeedObject({ groupInformation: group }); + } + } + if (newChatFeed) { + setChatFeed(newChatFeed); + } + } + } + })(); + }, [chatId, pgpPrivateKey, account, env]); + + useEffect(() => { + if (!account && !env && !chatId) return; + if (account && env && chatId && chatFeed && chatFeed?.groupInformation) + checkIfrules(); + }, [chatId, chatFeed, account, env]); + const addEmoji = (emojiData: EmojiClickData, event: MouseEvent): void => { setTypedMessage(typedMessage + emojiData.emoji); setShowEmojis(false); @@ -131,8 +222,7 @@ export const MessageInput: React.FC = ({ const response = await approveChatRequest({ chatId, }); - if(response) - await updateChatFeed(); + if (response) await updateChatFeed(); } else { const sendTextMessage = await sendMessage({ message: `Hello, please let me join this group, my wallet address is ${account}`, @@ -144,49 +234,19 @@ export const MessageInput: React.FC = ({ toastTitle: 'Success', toastMessage: 'Request sent successfully', toastType: 'SUCCESS', - getToastIcon: (size) => ( - - ), - }) + getToastIcon: (size) => , + }); } else { statusToast.showMessageToast({ toastTitle: 'Error', toastMessage: 'Unable to send request', toastType: 'ERROR', - getToastIcon: (size) => ( - - ), - }) + getToastIcon: (size) => , + }); } } }; - useEffect(() => { - const storedTimestampJSON = localStorage.getItem(chatId); - - if (storedTimestampJSON) { - const storedTimestamp = JSON.parse(storedTimestampJSON); - const currentTimestamp = new Date().getTime(); - const twentyFourHoursInMilliseconds = 24 * 60 * 60 * 1000; - - if ( - Math.abs(currentTimestamp - storedTimestamp) < - twentyFourHoursInMilliseconds - ) { - setVerified(true); - } else { - setVerified(false); - setAccessControl(chatId, true); - } - } - }, [chatId, verified, isMember, account, env]); - const uploadFile = async ( e: ChangeEvent ): Promise => { @@ -254,15 +314,6 @@ export const MessageInput: React.FC = ({ } }; - useEffect(() => { - (async () => { - if (!connectedProfile && account) { - const user = await fetchChatProfile({ profileId: account!, env }); - if (user) setConnectedProfile(user); - } - })(); - }, [account]); - const sendTextMsg = async () => { if (typedMessage.trim() !== '') { await sendPushMessage(typedMessage as string, 'Text'); @@ -275,67 +326,14 @@ export const MessageInput: React.FC = ({ setGifOpen(false); }; - useEffect(() => { - if (Object.keys(groupInformationSinceLastConnection || {}).length) { - if ( - chatFeed?.groupInformation?.chatId.toLowerCase() === - groupInformationSinceLastConnection.chatId.toLowerCase() - ) { - const updateChatFeed = chatFeed; - updateChatFeed.groupInformation = groupInformationSinceLastConnection; - setChatFeed(updateChatFeed); - } - } - }, [groupInformationSinceLastConnection]); - - const updateChatFeed = async() => { + const updateChatFeed = async () => { const chat = await fetchChat({ chatId }); if (Object.keys(chat || {}).length) { setChatFeed(chat as IFeeds); } }; - useEffect(() => { - (async () => { - if ( - Object.keys(acceptedRequestMessage || {}).length && - Object.keys(chatFeed || {}).length - ) { - await updateChatFeed(); - } - })(); - }, [acceptedRequestMessage]); - - useEffect(() => { - (async () => { - if (!account && !env) return; - if (account && env) { - const chat = await fetchChat({ chatId }); - if (Object.keys(chat || {}).length) setChatFeed(chat as IFeeds); - else { - let newChatFeed; - let group; - const result = await getNewChatUser({ - searchText: chatId, - fetchChatProfile, - env, - }); - if (result) { - newChatFeed = getDefaultFeedObject({ user: result }); - } else { - group = await getGroup({ searchText: chatId }); - if (group) { - newChatFeed = getDefaultFeedObject({ groupInformation: group }); - } - } - if (newChatFeed) { - setChatFeed(newChatFeed); - } - } - } - })(); - }, [chatId, pgpPrivateKey, account, env]); - + //shift to helpers const checkIfrules = async () => { const members = chatFeed?.groupInformation?.members || []; const pendingMembers = chatFeed?.groupInformation?.pendingMembers || []; @@ -348,63 +346,21 @@ export const MessageInput: React.FC = ({ } }); - if (chatFeed?.groupInformation?.rules && + if ( + chatFeed?.groupInformation?.rules && (chatFeed?.groupInformation?.rules?.entry || - chatFeed?.groupInformation?.rules?.chat) + chatFeed?.groupInformation?.rules?.chat) ) { setIsRules(true); } }; - useEffect(() => { - if (!account && !env && !chatId) return; - if (account && env && chatId && chatFeed && chatFeed?.groupInformation) - checkIfrules(); - }, [chatId, chatFeed, account, env]); - return ( - !Object.keys(chatFeed || {}).length? <> - {(!pgpPrivateKey && (isConnected || !!signer)) && ( - -
- {!signer && ( - - You need to connect your wallet to get started - - )} - -
-
- )} - - : - !checkIfIntent({ chat: chatFeed, account: account! }) && - Object.keys(chatFeed || {}).length ? ( - - {/* {isConnected && ( - - )} */} + //break into different components(connect button, join group and verification, typebar input) + return !Object.keys(chatFeed || {}).length ? ( + <> + {!pgpPrivateKey && (isConnected || !!signer) && ( = ({ alignItems="center" justifyContent="space-between" > - - {Object.keys(chatFeed || {}).length && chatFeed?.groupInformation ? ( - <> - {pgpPrivateKey && !isMember && ( -
+ {!signer && ( + + You need to connect your wallet to get started + + )} + +
+
+ )} + + ) : !checkIfIntent({ chat: chatFeed, account: account! }) && + Object.keys(chatFeed || {}).length ? ( + + + {Object.keys(chatFeed || {}).length && chatFeed?.groupInformation ? ( + <> + {pgpPrivateKey && !isMember && ( +
+ - + + handleJoinGroup()}> + {approveLoading ? ( + + ) : ( + ' Join Group ' + )} + + +
+ )} + {pgpPrivateKey && !verified && isMember && isRules && ( +
+ + Sending messages requires{' '} + + 1 PUSH Token + {' '} + for participation.{' '} + - Click on the button to join the group - - - handleJoinGroup()}> - {approveLoading ? ( - - ) : ( - ' Join Group ' - )} - - -
- )} - {pgpPrivateKey && !verified && isMember && isRules && ( + Learn More + + + + checkVerification()}> + {accessLoading ? ( + + ) : ( + 'Verify Access' + )} + + +
+ )} + {pgpPrivateKey && !verificationSuccessfull && ( +
- Sending messages requires{' '} - - 1 PUSH Token - {' '} - for participation.{' '} - - Learn More - + Verification Failed - - checkVerification()}> - {accessLoading ? ( - - ) : ( - 'Verify Access' - )} - - -
- )} - {pgpPrivateKey && !verificationSuccessfull && ( - -
- - Verification Failed - - - Please ensure the following conditions are met to - participate and send messages. - -
- token-gated -
- {' '} - {/* Added marginLeft */} - - Token Gated - - - You need to have{' '} - - 1 PUSH Token - {' '} - in your wallet to be able to send messages. - -
-
-
- { - if (onClick) { - onClick(); - } - setVerificationSuccessfull(true); - }} + Please ensure the following conditions are met to + participate and send messages. + +
+ token-gated +
+ {' '} + {/* Added marginLeft */} + - - Get Free Tokens - - - - { - setVerificationSuccessfull(true); - }} + Token Gated + + - Close - + You need to have{' '} + + 1 PUSH Token + {' '} + in your wallet to be able to send messages. +
- - )} - - ) : null} - {pgpPrivateKey && - (((isRules ? verified : true) && isMember) || - (chatFeed && !chatFeed?.groupInformation)) && ( - <> -
- {Emoji && ( -
setShowEmojis(!showEmojis)} +
+ { + if (onClick) { + onClick(); + } + setVerificationSuccessfull(true); + }} > - -
- )} - {showEmojis && ( -
+ Get Free Tokens + + + + { + setVerificationSuccessfull(true); + }} > - -
- )} - { - if (event.key === 'Enter' && !event.shiftKey) { - event.preventDefault(); - sendTextMsg(); - } - }} - placeholder="Type your message..." - onChange={(e) => onChangeTypedMessage(e.target.value)} - value={typedMessage} - ref={textAreaRef} - rows={1} - /> + Close + +
- - {GIF && ( -
setGifOpen(!gifOpen)} - > - -
- )} - {gifOpen && ( -
- + )} + + ) : null} + {pgpPrivateKey && + (((isRules ? verified : true) && isMember) || + (chatFeed && !chatFeed?.groupInformation)) && ( + <> +
+ {Emoji && ( +
setShowEmojis(!showEmojis)} + > + +
+ )} + {showEmojis && ( +
+ +
+ )} + { + if (event.key === 'Enter' && !event.shiftKey) { + event.preventDefault(); + sendTextMsg(); + } + }} + placeholder="Type your message..." + onChange={(e) => onChangeTypedMessage(e.target.value)} + value={typedMessage} + ref={textAreaRef} + rows={1} + /> +
+ + {GIF && ( +
setGifOpen(!gifOpen)} + > + +
+ )} + {gifOpen && ( +
+ +
+ )} +
+ {!fileUploading && File && ( + <> +
+ +
+ uploadFile(e)} /> -
+ )} -
- {!fileUploading && File && ( - <> -
setNewChat(true)} - > - -
- uploadFile(e)} - /> - - )} +
+ {!(loading || fileUploading) && ( +
sendTextMsg()} + > +
- {!(loading || fileUploading) && ( -
sendTextMsg()} - > - -
- )} - - {(loading || fileUploading) && ( -
- -
- )} -
- - )} - - - ) : ( - <> - ) - + )} + + {(loading || fileUploading) && ( +
+ +
+ )} + + + )} + + + ) : ( + <> ); }; @@ -750,7 +735,7 @@ const ConnectWrapper = styled.div` display: flex; align-items: center; flex-direction: column; - cursor:pointer; + cursor: pointer; `; const StyledButton = styled.button` diff --git a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts index 51aba7fbc..d19f692d3 100644 --- a/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts +++ b/packages/uiweb/src/lib/hooks/chat/usePushSendMessage.ts @@ -31,7 +31,6 @@ const usePushSendMessage = () => { env: env, }); setLoading(false); - console.log(response); if (!response) { return false; } diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index 62ee7bdc6..9c6b1b231 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -2,18 +2,6 @@ # yarn lockfile v1 -"@adraffy/ens-normalize@1.9.0": - version "1.9.0" - resolved "https://registry.yarnpkg.com/@adraffy/ens-normalize/-/ens-normalize-1.9.0.tgz#223572538f6bea336750039bb43a4016dcc8182d" - integrity sha512-iowxq3U30sghZotgl4s/oJRci6WPBfNO5YYgk2cIOMCHr3LeGPcsZjCEr+33Q4N+oV3OABDAtA+pyvWjbvBifQ== - -"@babel/runtime@^7.12.5", "@babel/runtime@^7.17.2", "@babel/runtime@^7.22.6": - version "7.22.10" - resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.10.tgz#ae3e9631fd947cb7e3610d3e9d8fef5f76696682" - integrity sha512-21t/fkKLMZI4pqP2wlmsQAWnYW1PDyKyyUV4vCi+B25ydmdaYTKXPwCj0BzSUnZf4seIiYvSA3jcZ3gdsMFkLQ== - dependencies: - regenerator-runtime "^0.14.0" - "@babel/runtime@^7.13.10", "@babel/runtime@^7.21.0": version "7.21.5" resolved "https://registry.npmjs.org/@babel/runtime/-/runtime-7.21.5.tgz" @@ -21,34 +9,6 @@ dependencies: regenerator-runtime "^0.13.11" -"@coinbase/wallet-sdk@^3.6.6": - version "3.7.1" - resolved "https://registry.yarnpkg.com/@coinbase/wallet-sdk/-/wallet-sdk-3.7.1.tgz#44b3b7a925ff5cc974e4cbf7a44199ffdcf03541" - integrity sha512-LjyoDCB+7p0waQXfK+fUgcAs3Ezk6S6e+LYaoFjpJ6c9VTop3NyZF40Pi7df4z7QJohCwzuIDjz0Rhtig6Y7Pg== - dependencies: - "@metamask/safe-event-emitter" "2.0.0" - "@solana/web3.js" "^1.70.1" - bind-decorator "^1.0.11" - bn.js "^5.1.1" - buffer "^6.0.3" - clsx "^1.1.0" - eth-block-tracker "6.1.0" - eth-json-rpc-filters "5.1.0" - eth-rpc-errors "4.0.2" - json-rpc-engine "6.1.0" - keccak "^3.0.1" - preact "^10.5.9" - qs "^6.10.3" - rxjs "^6.6.3" - sha.js "^2.4.11" - stream-browserify "^3.0.0" - util "^0.12.4" - -"@emotion/hash@^0.8.0": - version "0.8.0" - resolved "https://registry.yarnpkg.com/@emotion/hash/-/hash-0.8.0.tgz#bbbff68978fefdbe68ccb533bc8cbe1d1afb5413" - integrity sha512-kBJtf7PH6aWwZ6fka3zQ0p6SBYzx4fl1LoZXE2RrnYST9Xljm7WfKJrU4g/Xr3Beg72MLrp1AWNUmuYJTL7Cow== - "@esbuild/android-arm64@0.19.2": version "0.19.2" resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.19.2.tgz#bc35990f412a749e948b792825eef7df0ce0e073" @@ -969,11 +929,6 @@ dependencies: "@hapi/hoek" "^9.0.0" -"@ledgerhq/connect-kit-loader@^1.1.0": - version "1.1.2" - resolved "https://registry.yarnpkg.com/@ledgerhq/connect-kit-loader/-/connect-kit-loader-1.1.2.tgz#d550e3c1f046e4c796f32a75324b03606b7e226a" - integrity sha512-mscwGroSJQrCTjtNGBu+18FQbZYA4+q6Tyx6K7CXHl6AwgZKbWfZYdgP2F+fyZcRUdGRsMX8QtvU61VcGGtO1A== - "@lit-labs/ssr-dom-shim@^1.0.0", "@lit-labs/ssr-dom-shim@^1.1.0": version "1.1.1" resolved "https://registry.yarnpkg.com/@lit-labs/ssr-dom-shim/-/ssr-dom-shim-1.1.1.tgz#64df34e2f12e68e78ac57e571d25ec07fa460ca9" @@ -1024,21 +979,6 @@ livepeer "2.8.0" zustand "^4.3.9" -"@metamask/safe-event-emitter@2.0.0", "@metamask/safe-event-emitter@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@metamask/safe-event-emitter/-/safe-event-emitter-2.0.0.tgz#af577b477c683fad17c619a78208cede06f9605c" - integrity sha512-/kSXhY692qiV1MXu6EeOZvg5nECLclxNXcKCxJ3cXQgYuRymRHpdx/t7JXfsK+JLjwA1e1c1/SBrlQYpusC29Q== - -"@metamask/utils@^3.0.1": - version "3.6.0" - resolved "https://registry.yarnpkg.com/@metamask/utils/-/utils-3.6.0.tgz#b218b969a05ca7a8093b5d1670f6625061de707d" - integrity sha512-9cIRrfkWvHblSiNDVXsjivqa9Ak0RYo/1H6tqTqTbAx+oBK2Sva0lWDHxGchOqA7bySGUJKAWSNJvH6gdHZ0gQ== - dependencies: - "@types/debug" "^4.1.7" - debug "^4.3.4" - semver "^7.3.8" - superstruct "^1.0.3" - "@motionone/animation@^10.15.1": version "10.15.1" resolved "https://registry.yarnpkg.com/@motionone/animation/-/animation-10.15.1.tgz#4a85596c31cbc5100ae8eb8b34c459fb0ccf6807" @@ -1108,30 +1048,6 @@ "@motionone/dom" "^10.16.2" tslib "^2.3.1" -"@noble/curves@1.1.0", "@noble/curves@^1.0.0": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.1.0.tgz#f13fc667c89184bc04cccb9b11e8e7bae27d8c3d" - integrity sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA== - dependencies: - "@noble/hashes" "1.3.1" - -"@noble/curves@~1.0.0": - version "1.0.0" - resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.0.0.tgz#e40be8c7daf088aaf291887cbc73f43464a92932" - integrity sha512-2upgEu0iLiDVDZkNLeFV2+ht0BAVgQnEmCk6JsOch9Rp8xfkMCbvbAZlA2pBHQc73dbl+vFOXfqkf4uemdn0bw== - dependencies: - "@noble/hashes" "1.3.0" - -"@noble/hashes@1.3.0": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.0.tgz#085fd70f6d7d9d109671090ccae1d3bec62554a1" - integrity sha512-ilHEACi9DwqJB0pw7kv+Apvh50jiiSyR/cQ3y4W7lOR5mhvn/50FLUfsnfJz0BDZtl/RR16kXvptiv6q1msYZg== - -"@noble/hashes@1.3.1", "@noble/hashes@^1.3.1", "@noble/hashes@~1.3.0": - version "1.3.1" - resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.1.tgz#8831ef002114670c603c458ab8b11328406953a9" - integrity sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA== - "@pushprotocol/socket@^0.5.0": version "0.5.0" resolved "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz" @@ -1420,71 +1336,6 @@ dependencies: "@babel/runtime" "^7.13.10" -"@rainbow-me/rainbowkit@^1.0.8": - version "1.0.8" - resolved "https://registry.yarnpkg.com/@rainbow-me/rainbowkit/-/rainbowkit-1.0.8.tgz#280b3c572118957cdcfd6e54bc5bea12f969d980" - integrity sha512-m1B9/X3p8MLmj4fDfs2NpJlFRmKz7vOR0jmcdBw2SMFzXqP1FQFQc4pjvtLEeyfEUGSNNceGrecFZRVS0Qk//A== - dependencies: - "@vanilla-extract/css" "1.9.1" - "@vanilla-extract/dynamic" "2.0.2" - "@vanilla-extract/sprinkles" "1.5.0" - clsx "1.1.1" - qrcode "1.5.0" - react-remove-scroll "2.5.4" - -"@safe-global/safe-apps-provider@^0.17.1": - version "0.17.1" - resolved "https://registry.yarnpkg.com/@safe-global/safe-apps-provider/-/safe-apps-provider-0.17.1.tgz#72df2a66be5343940ed505efe594ed3b0f2f7015" - integrity sha512-lYfRqrbbK1aKU1/UGkYWc/X7PgySYcumXKc5FB2uuwAs2Ghj8uETuW5BrwPqyjBknRxutFbTv+gth/JzjxAhdQ== - dependencies: - "@safe-global/safe-apps-sdk" "8.0.0" - events "^3.3.0" - -"@safe-global/safe-apps-sdk@8.0.0": - version "8.0.0" - resolved "https://registry.yarnpkg.com/@safe-global/safe-apps-sdk/-/safe-apps-sdk-8.0.0.tgz#9bdfe0e0d85e1b2d279bb840f40c4b930aaf8bc1" - integrity sha512-gYw0ki/EAuV1oSyMxpqandHjnthZjYYy+YWpTAzf8BqfXM3ItcZLpjxfg+3+mXW8HIO+3jw6T9iiqEXsqHaMMw== - dependencies: - "@safe-global/safe-gateway-typescript-sdk" "^3.5.3" - viem "^1.0.0" - -"@safe-global/safe-apps-sdk@^8.0.0": - version "8.1.0" - resolved "https://registry.yarnpkg.com/@safe-global/safe-apps-sdk/-/safe-apps-sdk-8.1.0.tgz#d1d0c69cd2bf4eef8a79c5d677d16971926aa64a" - integrity sha512-XJbEPuaVc7b9n23MqlF6c+ToYIS3f7P2Sel8f3cSBQ9WORE4xrSuvhMpK9fDSFqJ7by/brc+rmJR/5HViRr0/w== - dependencies: - "@safe-global/safe-gateway-typescript-sdk" "^3.5.3" - viem "^1.0.0" - -"@safe-global/safe-gateway-typescript-sdk@^3.5.3": - version "3.9.0" - resolved "https://registry.yarnpkg.com/@safe-global/safe-gateway-typescript-sdk/-/safe-gateway-typescript-sdk-3.9.0.tgz#5aa36c05b865f6fe754d1d460f83bc9bf3a0145e" - integrity sha512-DxRM/sBBQhv955dPtdo0z2Bf2fXxrzoRUnGyTa3+4Z0RAhcyiqnffRP1Bt3tyuvlyfZnFL0RsvkqDcAIKzq3RQ== - dependencies: - cross-fetch "^3.1.5" - -"@scure/base@~1.1.0": - version "1.1.1" - resolved "https://registry.yarnpkg.com/@scure/base/-/base-1.1.1.tgz#ebb651ee52ff84f420097055f4bf46cfba403938" - integrity sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA== - -"@scure/bip32@1.3.0": - version "1.3.0" - resolved "https://registry.yarnpkg.com/@scure/bip32/-/bip32-1.3.0.tgz#6c8d980ef3f290987736acd0ee2e0f0d50068d87" - integrity sha512-bcKpo1oj54hGholplGLpqPHRbIsnbixFtc06nwuNM5/dwSXOq/AAYoIBRsBmnZJSdfeNW5rnff7NTAz3ZCqR9Q== - dependencies: - "@noble/curves" "~1.0.0" - "@noble/hashes" "~1.3.0" - "@scure/base" "~1.1.0" - -"@scure/bip39@1.2.0": - version "1.2.0" - resolved "https://registry.yarnpkg.com/@scure/bip39/-/bip39-1.2.0.tgz#a207e2ef96de354de7d0002292ba1503538fc77b" - integrity sha512-SX/uKq52cuxm4YFXWFaVByaSHJh2w3BnokVSeUJVCv6K7WulT9u2BuNRBhuFl8vAuYnzx9bEu9WgpcNYTrYieg== - dependencies: - "@noble/hashes" "~1.3.0" - "@scure/base" "~1.1.0" - "@sideway/address@^4.1.3": version "4.1.4" resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.4.tgz#03dccebc6ea47fdc226f7d3d1ad512955d4783f0" @@ -1507,34 +1358,6 @@ resolved "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz" integrity sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg== -"@solana/buffer-layout@^4.0.0": - version "4.0.1" - resolved "https://registry.yarnpkg.com/@solana/buffer-layout/-/buffer-layout-4.0.1.tgz#b996235eaec15b1e0b5092a8ed6028df77fa6c15" - integrity sha512-E1ImOIAD1tBZFRdjeM4/pzTiTApC0AOBGwyAMS4fwIodCWArzJ3DWdoh8cKxeFM2fElkxBh2Aqts1BPC373rHA== - dependencies: - buffer "~6.0.3" - -"@solana/web3.js@^1.70.1": - version "1.78.4" - resolved "https://registry.yarnpkg.com/@solana/web3.js/-/web3.js-1.78.4.tgz#e8ca9abe4ec2af5fc540c1d272efee24aaffedb3" - integrity sha512-up5VG1dK+GPhykmuMIozJZBbVqpm77vbOG6/r5dS7NBGZonwHfTLdBbsYc3rjmaQ4DpCXUa3tUc4RZHRORvZrw== - dependencies: - "@babel/runtime" "^7.22.6" - "@noble/curves" "^1.0.0" - "@noble/hashes" "^1.3.1" - "@solana/buffer-layout" "^4.0.0" - agentkeepalive "^4.3.0" - bigint-buffer "^1.1.5" - bn.js "^5.2.1" - borsh "^0.7.0" - bs58 "^4.0.1" - buffer "6.0.3" - fast-stable-stringify "^1.0.0" - jayson "^4.1.0" - node-fetch "^2.6.12" - rpc-websockets "^7.5.1" - superstruct "^0.14.2" - "@stablelib/aead@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@stablelib/aead/-/aead-1.0.1.tgz#c4b1106df9c23d1b867eb9b276d8f42d5fc4c0c3" @@ -1691,11 +1514,6 @@ resolved "https://registry.npmjs.org/@tanstack/query-core/-/query-core-4.29.23.tgz" integrity sha512-4BMHPrkfYmLP+NvqbbkV7Mk1nnphu+bNmxhhuB0+EMjKA7VfyFCfiyiTf55RRDgLaevyb9LrFK16lHW2owF52w== -"@tanstack/query-core@4.32.6": - version "4.32.6" - resolved "https://registry.yarnpkg.com/@tanstack/query-core/-/query-core-4.32.6.tgz#cf7df91ab1542e67a82624fefb12a55f580b4c01" - integrity sha512-YVB+mVWENQwPyv+40qO7flMgKZ0uI41Ph7qXC2Zf1ft5AIGfnXnMZyifB2ghhZ27u+5wm5mlzO4Y6lwwadzxCA== - "@tanstack/query-persist-client-core@4.29.23": version "4.29.23" resolved "https://registry.npmjs.org/@tanstack/query-persist-client-core/-/query-persist-client-core-4.29.23.tgz" @@ -1703,20 +1521,6 @@ dependencies: "@tanstack/query-core" "4.29.23" -"@tanstack/query-persist-client-core@4.32.6": - version "4.32.6" - resolved "https://registry.yarnpkg.com/@tanstack/query-persist-client-core/-/query-persist-client-core-4.32.6.tgz#8dbe10c3e86246a708f2a8725a5596c55fe57d7e" - integrity sha512-MJJ7CldvT5HOel50h/3wOZZwVlIcroFD5Vxn8vPsfo2C0qQ208ilmN/81JWutm/lWy4n2BjnCrrWv6HvVI7S0w== - dependencies: - "@tanstack/query-core" "4.32.6" - -"@tanstack/query-sync-storage-persister@^4.27.1": - version "4.32.6" - resolved "https://registry.yarnpkg.com/@tanstack/query-sync-storage-persister/-/query-sync-storage-persister-4.32.6.tgz#f9fe8284372f9e15a7beb2913189dc4779063b60" - integrity sha512-hTwNo5O5EvydbfdVvwnwY0nIrNg1BxKEV4WAA8A+0NP9yc/9xoWy8RxbIkcz1p4JN2JhagaTKek8Fa5h5KitsA== - dependencies: - "@tanstack/query-persist-client-core" "4.32.6" - "@tanstack/react-query-persist-client@4.29.23": version "4.29.23" resolved "https://registry.npmjs.org/@tanstack/react-query-persist-client/-/react-query-persist-client-4.29.23.tgz" @@ -1724,13 +1528,6 @@ dependencies: "@tanstack/query-persist-client-core" "4.29.23" -"@tanstack/react-query-persist-client@^4.28.0": - version "4.32.6" - resolved "https://registry.yarnpkg.com/@tanstack/react-query-persist-client/-/react-query-persist-client-4.32.6.tgz#f8c539e8119461e4901dd6f212608ef8cfd4d117" - integrity sha512-EmNnYpvFYpxS4j5WFeNmfVVBxqq4RDnEFDBZwNKRfb4pzukcx/hcWtwqFk7Qj0EI4Dk8QGl239MEYwJbAc83tQ== - dependencies: - "@tanstack/query-persist-client-core" "4.32.6" - "@tanstack/react-query@4.29.23": version "4.29.23" resolved "https://registry.npmjs.org/@tanstack/react-query/-/react-query-4.29.23.tgz" @@ -1739,62 +1536,11 @@ "@tanstack/query-core" "4.29.23" use-sync-external-store "^1.2.0" -"@tanstack/react-query@^4.28.0": - version "4.32.6" - resolved "https://registry.yarnpkg.com/@tanstack/react-query/-/react-query-4.32.6.tgz#f88c2d57f423d4cd295c501df2edeb3285a301bd" - integrity sha512-AITu/IKJJJXsHHeXNBy5bclu12t08usMCY0vFC2dh9SP/w6JAk5U9GwfjOIPj3p+ATADZvxQPe8UiCtMLNeQbg== - dependencies: - "@tanstack/query-core" "4.32.6" - use-sync-external-store "^1.2.0" - -"@types/connect@^3.4.33": - version "3.4.35" - resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.35.tgz#5fcf6ae445e4021d1fc2219a4873cc73a3bb2ad1" - integrity sha512-cdeYyv4KWoEgpBISTxWvqYsVy444DOqehiF3fM3ne10AmJ62RSyNkUnxMJXHQWRQQX2eR94m5y1IZyDwBjV9FQ== - dependencies: - "@types/node" "*" - -"@types/debug@^4.1.7": - version "4.1.8" - resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.8.tgz#cef723a5d0a90990313faec2d1e22aee5eecb317" - integrity sha512-/vPO1EPOs306Cvhwv7KfVfYvOJqA/S/AXjaHQiJboCZzcNDb+TIJFN9/2C9DZ//ijSKWioNyUxD792QmDJ+HKQ== - dependencies: - "@types/ms" "*" - -"@types/ms@*": - version "0.7.31" - resolved "https://registry.yarnpkg.com/@types/ms/-/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" - integrity sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA== - -"@types/node@*": - version "20.5.0" - resolved "https://registry.yarnpkg.com/@types/node/-/node-20.5.0.tgz#7fc8636d5f1aaa3b21e6245e97d56b7f56702313" - integrity sha512-Mgq7eCtoTjT89FqNoTzzXg2XvCi5VMhRV6+I2aYanc6kQCBImeNaAYRs/DyoVqk1YEUJK5gN9VO7HRIdz4Wo3Q== - -"@types/node@^12.12.54": - version "12.20.55" - resolved "https://registry.yarnpkg.com/@types/node/-/node-12.20.55.tgz#c329cbd434c42164f846b909bd6f85b5537f6240" - integrity sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ== - "@types/trusted-types@^2.0.2": version "2.0.3" resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.3.tgz#a136f83b0758698df454e328759dbd3d44555311" integrity sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g== -"@types/ws@^7.4.4": - version "7.4.7" - resolved "https://registry.yarnpkg.com/@types/ws/-/ws-7.4.7.tgz#f7c390a36f7a0679aa69de2d501319f4f8d9b702" - integrity sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww== - dependencies: - "@types/node" "*" - -"@types/ws@^8.5.4": - version "8.5.5" - resolved "https://registry.yarnpkg.com/@types/ws/-/ws-8.5.5.tgz#af587964aa06682702ee6dcbc7be41a80e4b28eb" - integrity sha512-lwhs8hktwxSjf9UaZ9tG5M03PGogvFaH8gUgLNbN9HKIg0dvv6q+gkSuJ8HN4/VbyxkuLzCjlN7GquQ0gUJfIg== - dependencies: - "@types/node" "*" - "@unstoppabledomains/resolution@^8.5.0": version "8.5.0" resolved "https://registry.npmjs.org/@unstoppabledomains/resolution/-/resolution-8.5.0.tgz" @@ -1806,77 +1552,6 @@ crypto-js "^4.1.1" elliptic "^6.5.4" -"@vanilla-extract/css@1.9.1": - version "1.9.1" - resolved "https://registry.yarnpkg.com/@vanilla-extract/css/-/css-1.9.1.tgz#337b79faa5f8f98915a90c3fe3c30b54be746c09" - integrity sha512-pu2SFiff5jRhPwvGoj8cM5l/qIyLvigOmy22ss5DGjwV5pJYezRjDLxWumi2luIwioMWvh9EozCjyfH8nq+7fQ== - dependencies: - "@emotion/hash" "^0.8.0" - "@vanilla-extract/private" "^1.0.3" - ahocorasick "1.0.2" - chalk "^4.1.1" - css-what "^5.0.1" - cssesc "^3.0.0" - csstype "^3.0.7" - deep-object-diff "^1.1.0" - deepmerge "^4.2.2" - media-query-parser "^2.0.2" - outdent "^0.8.0" - -"@vanilla-extract/dynamic@2.0.2": - version "2.0.2" - resolved "https://registry.yarnpkg.com/@vanilla-extract/dynamic/-/dynamic-2.0.2.tgz#13a3e461964c8029a52e6b6b631009ca6a8b27f5" - integrity sha512-U4nKaEQ8Kuz+exXEr51DUpyaOuzo24/S/k1YbDPQR06cYcNjQqvwFRnwWtZ+9ImocqM1wTKtzrdUgSTtLGIwAg== - dependencies: - "@vanilla-extract/private" "^1.0.3" - -"@vanilla-extract/private@^1.0.3": - version "1.0.3" - resolved "https://registry.yarnpkg.com/@vanilla-extract/private/-/private-1.0.3.tgz#7ec72bc2ff6fe51f9d650f962e8d1989b073690f" - integrity sha512-17kVyLq3ePTKOkveHxXuIJZtGYs+cSoev7BlP+Lf4916qfDhk/HBjvlYDe8egrea7LNPHKwSZJK/bzZC+Q6AwQ== - -"@vanilla-extract/sprinkles@1.5.0": - version "1.5.0" - resolved "https://registry.yarnpkg.com/@vanilla-extract/sprinkles/-/sprinkles-1.5.0.tgz#c921183ae518bb484299c2dc81f2acefd91c3dbe" - integrity sha512-W58f2Rzz5lLmk0jbhgStVlZl5wEiPB1Ur3fRvUaBM+MrifZ3qskmFq/CiH//fEYeG5Dh9vF1qRviMMH46cX9Nw== - -"@wagmi/chains@1.6.0": - version "1.6.0" - resolved "https://registry.yarnpkg.com/@wagmi/chains/-/chains-1.6.0.tgz#eb992ad28dbaaab729b5bcab3e5b461e8a035656" - integrity sha512-5FRlVxse5P4ZaHG3GTvxwVANSmYJas1eQrTBHhjxVtqXoorm0aLmCHbhmN8Xo1yu09PaWKlleEvfE98yH4AgIw== - -"@wagmi/chains@1.7.0": - version "1.7.0" - resolved "https://registry.yarnpkg.com/@wagmi/chains/-/chains-1.7.0.tgz#8f6ad81cf867e1788417f7c978ca92bc083ecaf6" - integrity sha512-TKVeHv0GqP5sV1yQ8BDGYToAFezPnCexbbBpeH14x7ywi5a1dDStPffpt9x+ytE6LJWkZ6pAMs/HNWXBQ5Nqmw== - -"@wagmi/connectors@2.7.0": - version "2.7.0" - resolved "https://registry.yarnpkg.com/@wagmi/connectors/-/connectors-2.7.0.tgz#547972502cbe6719217043fe5b610ac48534dc93" - integrity sha512-1KOL0HTJl5kzSC/YdKwFwiokr6poUQn1V/tcT0TpG3iH2x0lSM7FTkvCjVVY/6lKzTXrLlo9y2aE7AsOPnkvqg== - dependencies: - "@coinbase/wallet-sdk" "^3.6.6" - "@ledgerhq/connect-kit-loader" "^1.1.0" - "@safe-global/safe-apps-provider" "^0.17.1" - "@safe-global/safe-apps-sdk" "^8.0.0" - "@walletconnect/ethereum-provider" "2.9.2" - "@walletconnect/legacy-provider" "^2.0.0" - "@walletconnect/modal" "2.6.1" - "@walletconnect/utils" "2.9.2" - abitype "0.8.7" - eventemitter3 "^4.0.7" - -"@wagmi/core@1.3.9": - version "1.3.9" - resolved "https://registry.yarnpkg.com/@wagmi/core/-/core-1.3.9.tgz#16bac164fe74203fde68abe7991b947d3a26e6ab" - integrity sha512-SrnABCrsDvhiMCLLLyzyHnZbEumsFT/XWlJJQZeyEDcixL95R7XQwOaaoRI4MpNilCtMtu3jzN57tA5Z2iA+kw== - dependencies: - "@wagmi/chains" "1.7.0" - "@wagmi/connectors" "2.7.0" - abitype "0.8.7" - eventemitter3 "^4.0.7" - zustand "^4.3.1" - "@walletconnect/browser-utils@^1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@walletconnect/browser-utils/-/browser-utils-1.8.0.tgz#33c10e777aa6be86c713095b5206d63d32df0951" @@ -1920,28 +1595,6 @@ lodash.isequal "4.5.0" uint8arrays "^3.1.0" -"@walletconnect/core@2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-2.9.2.tgz#c46734ca63771b28fd77606fd521930b7ecfc5e1" - integrity sha512-VARMPAx8sIgodeyngDHbealP3B621PQqjqKsByFUTOep8ZI1/R/20zU+cmq6j9RCrL+kLKZcrZqeVzs8Z7OlqQ== - dependencies: - "@walletconnect/heartbeat" "1.2.1" - "@walletconnect/jsonrpc-provider" "1.0.13" - "@walletconnect/jsonrpc-types" "1.0.3" - "@walletconnect/jsonrpc-utils" "1.0.8" - "@walletconnect/jsonrpc-ws-connection" "1.0.13" - "@walletconnect/keyvaluestorage" "^1.0.2" - "@walletconnect/logger" "^2.0.1" - "@walletconnect/relay-api" "^1.0.9" - "@walletconnect/relay-auth" "^1.0.4" - "@walletconnect/safe-json" "^1.0.2" - "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.9.2" - "@walletconnect/utils" "2.9.2" - events "^3.3.0" - lodash.isequal "4.5.0" - uint8arrays "^3.1.0" - "@walletconnect/core@^1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@walletconnect/core/-/core-1.8.0.tgz#6b2748b90c999d9d6a70e52e26a8d5e8bfeaa81e" @@ -1951,7 +1604,7 @@ "@walletconnect/types" "^1.8.0" "@walletconnect/utils" "^1.8.0" -"@walletconnect/crypto@^1.0.2", "@walletconnect/crypto@^1.0.3": +"@walletconnect/crypto@^1.0.2": version "1.0.3" resolved "https://registry.yarnpkg.com/@walletconnect/crypto/-/crypto-1.0.3.tgz#7b8dd4d7e2884fe3543c7c07aea425eef5ef9dd4" integrity sha512-+2jdORD7XQs76I2Odgr3wwrtyuLUXD/kprNVsjWRhhhdO9Mt6WqVzOPu0/t7OHSmgal8k7SoBQzUc5hu/8zL/g== @@ -1979,21 +1632,6 @@ dependencies: tslib "1.14.1" -"@walletconnect/ethereum-provider@2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.9.2.tgz#fb3a6fca279bb4e98e75baa2fb9730545d41bb99" - integrity sha512-eO1dkhZffV1g7vpG19XUJTw09M/bwGUwwhy1mJ3AOPbOSbMPvwiCuRz2Kbtm1g9B0Jv15Dl+TvJ9vTgYF8zoZg== - dependencies: - "@walletconnect/jsonrpc-http-connection" "^1.0.7" - "@walletconnect/jsonrpc-provider" "^1.0.13" - "@walletconnect/jsonrpc-types" "^1.0.3" - "@walletconnect/jsonrpc-utils" "^1.0.8" - "@walletconnect/sign-client" "2.9.2" - "@walletconnect/types" "2.9.2" - "@walletconnect/universal-provider" "2.9.2" - "@walletconnect/utils" "2.9.2" - events "^3.3.0" - "@walletconnect/ethereum-provider@^2.10.0": version "2.10.0" resolved "https://registry.yarnpkg.com/@walletconnect/ethereum-provider/-/ethereum-provider-2.10.0.tgz#eebde38674222a48be35bb4aa3f6a74247ba059b" @@ -2035,7 +1673,7 @@ "@walletconnect/types" "^1.8.0" "@walletconnect/utils" "^1.8.0" -"@walletconnect/jsonrpc-http-connection@^1.0.4", "@walletconnect/jsonrpc-http-connection@^1.0.7": +"@walletconnect/jsonrpc-http-connection@^1.0.7": version "1.0.7" resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-http-connection/-/jsonrpc-http-connection-1.0.7.tgz#a6973569b8854c22da707a759d241e4f5c2d5a98" integrity sha512-qlfh8fCfu8LOM9JRR9KE0s0wxP6ZG9/Jom8M0qsoIQeKF3Ni0FyV4V1qy/cc7nfI46SLQLSl4tgWSfLiE1swyQ== @@ -2045,7 +1683,7 @@ cross-fetch "^3.1.4" tslib "1.14.1" -"@walletconnect/jsonrpc-provider@1.0.13", "@walletconnect/jsonrpc-provider@^1.0.13", "@walletconnect/jsonrpc-provider@^1.0.6": +"@walletconnect/jsonrpc-provider@1.0.13", "@walletconnect/jsonrpc-provider@^1.0.13": version "1.0.13" resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-provider/-/jsonrpc-provider-1.0.13.tgz#9a74da648d015e1fffc745f0c7d629457f53648b" integrity sha512-K73EpThqHnSR26gOyNEL+acEex3P7VWZe6KE12ZwKzAt2H4e5gldZHbjsu2QR9cLeJ8AXuO7kEMOIcRv1QEc7g== @@ -2062,7 +1700,7 @@ keyvaluestorage-interface "^1.0.0" tslib "1.14.1" -"@walletconnect/jsonrpc-utils@1.0.8", "@walletconnect/jsonrpc-utils@^1.0.3", "@walletconnect/jsonrpc-utils@^1.0.4", "@walletconnect/jsonrpc-utils@^1.0.6", "@walletconnect/jsonrpc-utils@^1.0.7", "@walletconnect/jsonrpc-utils@^1.0.8": +"@walletconnect/jsonrpc-utils@1.0.8", "@walletconnect/jsonrpc-utils@^1.0.3", "@walletconnect/jsonrpc-utils@^1.0.6", "@walletconnect/jsonrpc-utils@^1.0.7", "@walletconnect/jsonrpc-utils@^1.0.8": version "1.0.8" resolved "https://registry.yarnpkg.com/@walletconnect/jsonrpc-utils/-/jsonrpc-utils-1.0.8.tgz#82d0cc6a5d6ff0ecc277cb35f71402c91ad48d72" integrity sha512-vdeb03bD8VzJUL6ZtzRYsFMq1eZQcM3EAzT0a3st59dyLfJ0wq+tKMpmGH7HlB7waD858UWgfIcudbPFsbzVdw== @@ -2090,66 +1728,6 @@ safe-json-utils "^1.1.1" tslib "1.14.1" -"@walletconnect/legacy-client@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@walletconnect/legacy-client/-/legacy-client-2.0.0.tgz#9f2c09694789fd4b6c5d68d6423b44bac55aed30" - integrity sha512-v5L7rYk9loVnfvUf0mF+76bUPFaU5/Vh7mzL6/950CD/yoGdzYZ3Kj+L7mkC6HPMEGeQsBP1+sqBuiVGZ/aODA== - dependencies: - "@walletconnect/crypto" "^1.0.3" - "@walletconnect/encoding" "^1.0.2" - "@walletconnect/jsonrpc-utils" "^1.0.4" - "@walletconnect/legacy-types" "^2.0.0" - "@walletconnect/legacy-utils" "^2.0.0" - "@walletconnect/safe-json" "^1.0.1" - "@walletconnect/window-getters" "^1.0.1" - "@walletconnect/window-metadata" "^1.0.1" - detect-browser "^5.3.0" - query-string "^6.13.5" - -"@walletconnect/legacy-modal@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@walletconnect/legacy-modal/-/legacy-modal-2.0.0.tgz#d0fab01a1337a8f5d88cdb1430cbef2d46072bbf" - integrity sha512-jckNd8lMhm4X7dX9TDdxM3bXKJnaqkRs6K2Mo5j6GmbIF9Eyx40jZ5+q457RVxvM6ciZEDT5s1wBHWdWoOo+9Q== - dependencies: - "@walletconnect/legacy-types" "^2.0.0" - "@walletconnect/legacy-utils" "^2.0.0" - copy-to-clipboard "^3.3.3" - preact "^10.12.0" - qrcode "^1.5.1" - -"@walletconnect/legacy-provider@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@walletconnect/legacy-provider/-/legacy-provider-2.0.0.tgz#08e2db1e4c234743b2f30422bc8100bc42e8fc44" - integrity sha512-A8xPebMI1A+50HbWwTpFCbwP7G+1NGKdTKyg8BUUg3h3Y9JucpC1W6w/x0v1Xw7qFEqQnz74LoIN/A3ytH9xrQ== - dependencies: - "@walletconnect/jsonrpc-http-connection" "^1.0.4" - "@walletconnect/jsonrpc-provider" "^1.0.6" - "@walletconnect/legacy-client" "^2.0.0" - "@walletconnect/legacy-modal" "^2.0.0" - "@walletconnect/legacy-types" "^2.0.0" - "@walletconnect/legacy-utils" "^2.0.0" - -"@walletconnect/legacy-types@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@walletconnect/legacy-types/-/legacy-types-2.0.0.tgz#224278ae2874c6a2ca805c2d1d062a511dcf7227" - integrity sha512-sOVrA7HUdbI1OwKyPOQU0/DdvTSVFlsXWpAk2K2WvP2erTkBWPMTJq6cv2BmKdoJ3p6gLApT7sd+jHi3OF71uw== - dependencies: - "@walletconnect/jsonrpc-types" "^1.0.2" - -"@walletconnect/legacy-utils@^2.0.0": - version "2.0.0" - resolved "https://registry.yarnpkg.com/@walletconnect/legacy-utils/-/legacy-utils-2.0.0.tgz#e3a637c00783f9cd2ae139b640f82223ab78ed9d" - integrity sha512-CPWxSVVXw0kgNCxvU126g4GiV3mzXmC8IPJ15twE46aJ1FX+RHEIfAzFMFz2F2+fEhBxL63A7dwNQKDXorRPcQ== - dependencies: - "@walletconnect/encoding" "^1.0.2" - "@walletconnect/jsonrpc-utils" "^1.0.4" - "@walletconnect/legacy-types" "^2.0.0" - "@walletconnect/safe-json" "^1.0.1" - "@walletconnect/window-getters" "^1.0.1" - "@walletconnect/window-metadata" "^1.0.1" - detect-browser "^5.3.0" - query-string "^6.13.5" - "@walletconnect/logger@^2.0.1": version "2.0.1" resolved "https://registry.yarnpkg.com/@walletconnect/logger/-/logger-2.0.1.tgz#7f489b96e9a1ff6bf3e58f0fbd6d69718bf844a8" @@ -2257,21 +1835,6 @@ "@walletconnect/utils" "2.10.0" events "^3.3.0" -"@walletconnect/sign-client@2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@walletconnect/sign-client/-/sign-client-2.9.2.tgz#ff4c81c082c2078878367d07f24bcb20b1f7ab9e" - integrity sha512-anRwnXKlR08lYllFMEarS01hp1gr6Q9XUgvacr749hoaC/AwGVlxYFdM8+MyYr3ozlA+2i599kjbK/mAebqdXg== - dependencies: - "@walletconnect/core" "2.9.2" - "@walletconnect/events" "^1.0.1" - "@walletconnect/heartbeat" "1.2.1" - "@walletconnect/jsonrpc-utils" "1.0.8" - "@walletconnect/logger" "^2.0.1" - "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.9.2" - "@walletconnect/utils" "2.9.2" - events "^3.3.0" - "@walletconnect/socket-transport@^1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@walletconnect/socket-transport/-/socket-transport-1.8.0.tgz#9a1128a249628a0be11a0979b522fe82b44afa1b" @@ -2300,18 +1863,6 @@ "@walletconnect/logger" "^2.0.1" events "^3.3.0" -"@walletconnect/types@2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-2.9.2.tgz#d5fd5a61dc0f41cbdca59d1885b85207ac7bf8c5" - integrity sha512-7Rdn30amnJEEal4hk83cdwHUuxI1SWQ+K7fFFHBMqkuHLGi3tpMY6kpyfDxnUScYEZXqgRps4Jo5qQgnRqVM7A== - dependencies: - "@walletconnect/events" "^1.0.1" - "@walletconnect/heartbeat" "1.2.1" - "@walletconnect/jsonrpc-types" "1.0.3" - "@walletconnect/keyvaluestorage" "^1.0.2" - "@walletconnect/logger" "^2.0.1" - events "^3.3.0" - "@walletconnect/types@^1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@walletconnect/types/-/types-1.8.0.tgz#3f5e85b2d6b149337f727ab8a71b8471d8d9a195" @@ -2332,21 +1883,6 @@ "@walletconnect/utils" "2.10.0" events "^3.3.0" -"@walletconnect/universal-provider@2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@walletconnect/universal-provider/-/universal-provider-2.9.2.tgz#40e54e98bc48b1f2f5f77eb5b7f05462093a8506" - integrity sha512-JmaolkO8D31UdRaQCHwlr8uIFUI5BYhBzqYFt54Mc6gbIa1tijGOmdyr6YhhFO70LPmS6gHIjljwOuEllmlrxw== - dependencies: - "@walletconnect/jsonrpc-http-connection" "^1.0.7" - "@walletconnect/jsonrpc-provider" "1.0.13" - "@walletconnect/jsonrpc-types" "^1.0.2" - "@walletconnect/jsonrpc-utils" "^1.0.7" - "@walletconnect/logger" "^2.0.1" - "@walletconnect/sign-client" "2.9.2" - "@walletconnect/types" "2.9.2" - "@walletconnect/utils" "2.9.2" - events "^3.3.0" - "@walletconnect/utils@2.10.0": version "2.10.0" resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.10.0.tgz#6918d12180d797b8bd4a19fb2ff128e394e181d6" @@ -2367,26 +1903,6 @@ query-string "7.1.3" uint8arrays "^3.1.0" -"@walletconnect/utils@2.9.2": - version "2.9.2" - resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-2.9.2.tgz#035bdb859ee81a4bcc6420f56114cc5ec3e30afb" - integrity sha512-D44hwXET/8JhhIjqljY6qxSu7xXnlPrf63UN/Qfl98vDjWlYVcDl2+JIQRxD9GPastw0S8XZXdRq59XDXLuZBg== - dependencies: - "@stablelib/chacha20poly1305" "1.0.1" - "@stablelib/hkdf" "1.0.1" - "@stablelib/random" "^1.0.2" - "@stablelib/sha256" "1.0.1" - "@stablelib/x25519" "^1.0.3" - "@walletconnect/relay-api" "^1.0.9" - "@walletconnect/safe-json" "^1.0.2" - "@walletconnect/time" "^1.0.2" - "@walletconnect/types" "2.9.2" - "@walletconnect/window-getters" "^1.0.1" - "@walletconnect/window-metadata" "^1.0.1" - detect-browser "5.3.0" - query-string "7.1.3" - uint8arrays "^3.1.0" - "@walletconnect/utils@^1.8.0": version "1.8.0" resolved "https://registry.yarnpkg.com/@walletconnect/utils/-/utils-1.8.0.tgz#2591a197c1fa7429941fe428876088fda6632060" @@ -2436,10 +1952,10 @@ ethers "5.5.4" joi "17.9.1" -"@web3-onboard/core@^2.21.0": - version "2.21.0" - resolved "https://registry.yarnpkg.com/@web3-onboard/core/-/core-2.21.0.tgz#9055a9320f862911453010ba9a430a361c66202c" - integrity sha512-owxmSbCILFV0nQA46OGxcRrVdeZGL8SabBXll/PR0GAGsrZBYqNSE608ISd0luPt2Npy+dT8f8xUruFau+k/BA== +"@web3-onboard/core@^2.21.1": + version "2.21.1" + resolved "https://registry.yarnpkg.com/@web3-onboard/core/-/core-2.21.1.tgz#addb6c07c376cbbed3ae1d9ea6aabf05b15a8309" + integrity sha512-2ETfh+MIcRdEq1fY3+hc4KDTVelJLzNK9SpiH58kZ43/G5ky5IuTRS22e0xpsn/4pq5a1Y0Pgc1tHQncyZpndw== dependencies: "@web3-onboard/common" "^2.3.3" bignumber.js "^9.0.0" @@ -2464,13 +1980,13 @@ joi "17.9.1" lodash.uniqby "^4.7.0" -"@web3-onboard/react@^2.8.11": - version "2.8.11" - resolved "https://registry.yarnpkg.com/@web3-onboard/react/-/react-2.8.11.tgz#ce364bf11f09933baa609908a6bbff91be6537ca" - integrity sha512-wTvDQaIXKxe0xE++iykEzJ2Y9bY4XeJzptE23cgkZBQhlWbJZmVUKDBQrCbkdIM0+5Qq2AZYN6UMNgdoB3myxg== +"@web3-onboard/react@^2.8.9": + version "2.8.12" + resolved "https://registry.yarnpkg.com/@web3-onboard/react/-/react-2.8.12.tgz#5ab28aa2a038d3a4ba66d4178b87fc27f2f5be92" + integrity sha512-OqG24441XLf+hisy2KkHR3ZmLnleVmRRXeCpa4KHf9j7LtcBhGWOZlIjwFpVq/tk+r6/9piteweOxiqANObAIA== dependencies: "@web3-onboard/common" "^2.3.3" - "@web3-onboard/core" "^2.21.0" + "@web3-onboard/core" "^2.21.1" use-sync-external-store "1.0.0" "@web3-onboard/walletconnect@^2.4.6": @@ -2508,24 +2024,6 @@ resolved "https://registry.yarnpkg.com/@web3-react/types/-/types-6.0.7.tgz#34a6204224467eedc6123abaf55fbb6baeb2809f" integrity sha512-ofGmfDhxmNT1/P/MgVa8IKSkCStFiyvXe+U5tyZurKdrtTDFU+wJ/LxClPDtFerWpczNFPUSrKcuhfPX1sI6+A== -JSONStream@^1.3.5: - version "1.3.5" - resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.5.tgz#3208c1f08d3a4d99261ab64f92302bc15e111ca0" - integrity sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ== - dependencies: - jsonparse "^1.2.0" - through ">=2.2.7 <3" - -abitype@0.8.7: - version "0.8.7" - resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.8.7.tgz#e4b3f051febd08111f486c0cc6a98fa72d033622" - integrity sha512-wQ7hV8Yg/yKmGyFpqrNZufCxbszDe5es4AZGYPBitocfSqXtjrTG9JMWFcc4N30ukl2ve48aBTwt7NJxVQdU3w== - -abitype@0.9.3: - version "0.9.3" - resolved "https://registry.yarnpkg.com/abitype/-/abitype-0.9.3.tgz#294d25288ee683d72baf4e1fed757034e3c8c277" - integrity sha512-dz4qCQLurx97FQhnb/EIYTk/ldQ+oafEDUqC0VVIeQS1Q48/YWt/9YNfMmp9SLFqN41ktxny3c8aYxHjmFIB/w== - aes-js@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.0.0.tgz#e21df10ad6c2053295bcbb8dab40b09dbea87e4d" @@ -2536,18 +2034,6 @@ aes-js@^3.1.2: resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.1.2.tgz#db9aabde85d5caabbfc0d4f2a4446960f627146a" integrity sha512-e5pEa2kBnBOgR4Y/p20pskXI74UEz7de8ZGVo58asOtvSVG5YAbJeELPZxOmt+Bnz3rX753YKhfIn4X4l1PPRQ== -agentkeepalive@^4.3.0: - version "4.5.0" - resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.5.0.tgz#2673ad1389b3c418c5a20c5d7364f93ca04be923" - integrity sha512-5GG/5IbQQpC9FpkRGsSvZI5QYeSCzlJHdpBQntCsuTOxhKD8lqKhrleg2Yi7yvMIf82Ycmmqln9U8V9qwEiJew== - dependencies: - humanize-ms "^1.2.1" - -ahocorasick@1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/ahocorasick/-/ahocorasick-1.0.2.tgz#9eee93aef9d02bfb476d9b648d9b7a40ef2fd500" - integrity sha512-hCOfMzbFx5IDutmWLAt6MZwOUjIfSM9G9FyVxytmE4Rs/5YDPWQrD/+IR1w+FweD9H2oOZEnv36TmkjhNURBVA== - ansi-regex@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.1.tgz#164daac87ab2d6f6db3a29875e2d1766582dabed" @@ -2565,7 +2051,7 @@ ansi-styles@^3.2.0: dependencies: color-convert "^1.9.0" -ansi-styles@^4.0.0, ansi-styles@^4.1.0: +ansi-styles@^4.0.0: version "4.3.0" resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-4.3.0.tgz#edd803628ae71c04c85ae7a0906edad34b648937" integrity sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg== @@ -2579,30 +2065,11 @@ aria-hidden@^1.1.1: dependencies: tslib "^2.0.0" -async-mutex@^0.2.6: - version "0.2.6" - resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.2.6.tgz#0d7a3deb978bc2b984d5908a2038e1ae2e54ff40" - integrity sha512-Hs4R+4SPgamu6rSGW8C7cV9gaWUKEHykfzCCvIRuaVv636Ju10ZdeUbvb4TBEW0INuq2DHZqXbK4Nd3yG4RaRw== - dependencies: - tslib "^2.0.0" - atomic-sleep@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/atomic-sleep/-/atomic-sleep-1.0.0.tgz#eb85b77a601fc932cfe432c5acd364a9e2c9075b" integrity sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ== -available-typed-arrays@^1.0.5: - version "1.0.5" - resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz#92f95616501069d07d10edb2fc37d3e1c65123b7" - integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== - -base-x@^3.0.2: - version "3.0.9" - resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.9.tgz#6349aaabb58526332de9f60995e548a53fe21320" - integrity sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ== - dependencies: - safe-buffer "^5.0.1" - base64-js@^1.3.1: version "1.5.1" resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" @@ -2613,30 +2080,11 @@ bech32@1.1.4: resolved "https://registry.yarnpkg.com/bech32/-/bech32-1.1.4.tgz#e38c9f37bf179b8eb16ae3a772b40c356d4832e9" integrity sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ== -bigint-buffer@^1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/bigint-buffer/-/bigint-buffer-1.1.5.tgz#d038f31c8e4534c1f8d0015209bf34b4fa6dd442" - integrity sha512-trfYco6AoZ+rKhKnxA0hgX0HAbVP/s808/EuDSe2JDzUnCp/xAsli35Orvk67UrTEcwuxZqYZDmfA2RXJgxVvA== - dependencies: - bindings "^1.3.0" - bignumber.js@^9.0.0, bignumber.js@^9.1.0: version "9.1.2" resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.1.2.tgz#b7c4242259c008903b13707983b5f4bbd31eda0c" integrity sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug== -bind-decorator@^1.0.11: - version "1.0.11" - resolved "https://registry.yarnpkg.com/bind-decorator/-/bind-decorator-1.0.11.tgz#e41bc06a1f65dd9cec476c91c5daf3978488252f" - integrity sha512-yzkH0uog6Vv/vQ9+rhSKxecnqGUZHYncg7qS7voz3Q76+TAi1SGiOKk2mlOvusQnFz9Dc4BC/NMkeXu11YgjJg== - -bindings@^1.3.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" - integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== - dependencies: - file-uri-to-path "1.0.0" - bn.js@4.11.8: version "4.11.8" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" @@ -2647,7 +2095,7 @@ bn.js@^4.11.9, bn.js@^4.4.0: resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== -bn.js@^5.1.1, bn.js@^5.2.0, bn.js@^5.2.1: +bn.js@^5.2.1: version "5.2.1" resolved "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== @@ -2662,15 +2110,6 @@ bnc-sdk@^4.6.7: rxjs "^6.6.3" sturdy-websocket "^0.1.12" -borsh@^0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/borsh/-/borsh-0.7.0.tgz#6e9560d719d86d90dc589bca60ffc8a6c51fec2a" - integrity sha512-CLCsZGIBCFnPtkNnieW/a8wmreDmfUtjU2m9yHrzPXIlNbqVs0AQrSatSG6vdNYUqdc83tkQi2eHfF98ubzQLA== - dependencies: - bn.js "^5.2.0" - bs58 "^4.0.0" - text-encoding-utf-8 "^1.0.2" - bowser@^2.11.0: version "2.11.0" resolved "https://registry.yarnpkg.com/bowser/-/bowser-2.11.0.tgz#5ca3c35757a7aa5771500c70a73a9f91ef420a8f" @@ -2681,13 +2120,6 @@ brorand@^1.1.0: resolved "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== -bs58@^4.0.0, bs58@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/bs58/-/bs58-4.0.1.tgz#be161e76c354f6f788ae4071f63f34e8c4f0a42a" - integrity sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw== - dependencies: - base-x "^3.0.2" - buffer-alloc-unsafe@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/buffer-alloc-unsafe/-/buffer-alloc-unsafe-1.1.0.tgz#bd7dc26ae2972d0eda253be061dba992349c19f0" @@ -2711,14 +2143,6 @@ buffer-from@^1.1.1, buffer-from@^1.1.2: resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== -buffer@6.0.3, buffer@^6.0.3, buffer@~6.0.3: - version "6.0.3" - resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" - integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== - dependencies: - base64-js "^1.3.1" - ieee754 "^1.2.1" - buffer@^5.4.3: version "5.7.1" resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.7.1.tgz#ba62e7c13133053582197160851a8f648e99eed0" @@ -2727,34 +2151,11 @@ buffer@^5.4.3: base64-js "^1.3.1" ieee754 "^1.1.13" -bufferutil@^4.0.1: - version "4.0.7" - resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.7.tgz#60c0d19ba2c992dd8273d3f73772ffc894c153ad" - integrity sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw== - dependencies: - node-gyp-build "^4.3.0" - -call-bind@^1.0.0, call-bind@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" - integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== - dependencies: - function-bind "^1.1.1" - get-intrinsic "^1.0.2" - camelcase@^5.0.0: version "5.3.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" integrity sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg== -chalk@^4.1.1: - version "4.1.2" - resolved "https://registry.yarnpkg.com/chalk/-/chalk-4.1.2.tgz#aac4e2b7734a740867aeb16bf02aad556a1e7a01" - integrity sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA== - dependencies: - ansi-styles "^4.1.0" - supports-color "^7.1.0" - cli-color@^2.0.3: version "2.0.3" resolved "https://registry.yarnpkg.com/cli-color/-/cli-color-2.0.3.tgz#73769ba969080629670f3f2ef69a4bf4e7cc1879" @@ -2784,12 +2185,7 @@ cliui@^6.0.0: strip-ansi "^6.0.0" wrap-ansi "^6.2.0" -clsx@1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/clsx/-/clsx-1.1.1.tgz#98b3134f9abbdf23b2663491ace13c5c03a73188" - integrity sha512-6/bPho624p3S2pMyvP5kKBPXnI3ufHLObBFCfgx+LkeR5lg2XYy2hqZqUf45ypD8COn2bhgGJSUE+l5dhNBieA== - -clsx@^1.1.0, clsx@^1.1.1, clsx@^1.2.1: +clsx@^1.1.1, clsx@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== @@ -2826,12 +2222,7 @@ combine-errors@^3.0.3: custom-error-instance "2.1.1" lodash.uniqby "4.5.0" -commander@^2.20.3: - version "2.20.3" - resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" - integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== - -copy-to-clipboard@^3.3.1, copy-to-clipboard@^3.3.3: +copy-to-clipboard@^3.3.1: version "3.3.3" resolved "https://registry.yarnpkg.com/copy-to-clipboard/-/copy-to-clipboard-3.3.3.tgz#55ac43a1db8ae639a4bd99511c148cdd1b83a1b0" integrity sha512-2KV8NhB5JqC3ky0r9PMCAZKbUHSwtEo4CwCs0KXgruG43gX5PMqDEBbVU4OUzw2MuAWUfsuFmWvEKG5QRfSnJA== @@ -2843,7 +2234,7 @@ core-js@^3.31.1: resolved "https://registry.npmjs.org/core-js/-/core-js-3.32.0.tgz" integrity sha512-rd4rYZNlF3WuoYuRIDEmbR/ga9CeuWX9U05umAvgrrZoHY4Z++cp/xwPQMvUpBB4Ag6J8KfD80G0zwCyaSxDww== -cross-fetch@^3.1.4, cross-fetch@^3.1.5: +cross-fetch@^3.1.4: version "3.1.8" resolved "https://registry.npmjs.org/cross-fetch/-/cross-fetch-3.1.8.tgz" integrity sha512-cvA+JwZoU0Xq+h6WkMvAUqPEYy92Obet6UdKLfW60qn99ftItKjB5T+BkyWOFWe2pUyfQ+IJHmpOTznqk1M6Kg== @@ -2867,21 +2258,6 @@ crypto-js@^4.1.1: resolved "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz" integrity sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw== -css-what@^5.0.1: - version "5.1.0" - resolved "https://registry.yarnpkg.com/css-what/-/css-what-5.1.0.tgz#3f7b707aadf633baf62c2ceb8579b545bb40f7fe" - integrity sha512-arSMRWIIFY0hV8pIxZMEfmMI47Wj3R/aWpZDDxWYCPEiOMv6tfOrnpDtgxBYPEQD4V0Y/958+1TdC3iWTFcUPw== - -cssesc@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/cssesc/-/cssesc-3.0.0.tgz#37741919903b868565e1c09ea747445cd18983ee" - integrity sha512-/Tb/JcjK111nNScGob5MNtsntNM1aCNUDipB/TkwZFhyDrrE47SOx/18wF2bbjgc3ZzCSKW1T5nt5EbFoAz/Vg== - -csstype@^3.0.7: - version "3.1.2" - resolved "https://registry.yarnpkg.com/csstype/-/csstype-3.1.2.tgz#1d4bf9d572f11c14031f0436e1c10bc1f571f50b" - integrity sha512-I7K1Uu0MBPzaFKg4nI5Q7Vs2t+3gWWW648spaF+Rg7pI9ds18Ugn+lvg4SHczUdKlHI5LWBXyqfS8+DufyBsgQ== - custom-error-instance@2.1.1: version "2.1.1" resolved "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz" @@ -2902,7 +2278,7 @@ date-fns@^2.28.0: dependencies: "@babel/runtime" "^7.21.0" -debug@^4.3.4, debug@~4.3.1, debug@~4.3.2: +debug@~4.3.1, debug@~4.3.2: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== @@ -2919,27 +2295,17 @@ decode-uri-component@^0.2.0, decode-uri-component@^0.2.2: resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.2.tgz#e69dbe25d37941171dd540e024c444cd5188e1e9" integrity sha512-FqUYQ+8o158GyGTrMFJms9qh3CqTKvAqgqsTnkLI8sKu0028orqBhxNMFkFen0zGyg6epACD32pjVk58ngIErQ== -deep-object-diff@^1.1.0: - version "1.1.9" - resolved "https://registry.yarnpkg.com/deep-object-diff/-/deep-object-diff-1.1.9.tgz#6df7ef035ad6a0caa44479c536ed7b02570f4595" - integrity sha512-Rn+RuwkmkDwCi2/oXOFS9Gsr5lJZu/yTGpK7wAaAIE75CC+LCGEZHpY6VQJa/RoJcrmaA/docWJZvYohlNkWPA== - deepmerge@^4.2.2: version "4.3.1" resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.3.1.tgz#44b5f2147cd3b00d4b56137685966f26fd25dd4a" integrity sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A== -delay@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/delay/-/delay-5.0.0.tgz#137045ef1b96e5071060dd5be60bf9334436bd1d" - integrity sha512-ReEBKkIfe4ya47wlPYf/gu5ib6yUG0/Aez0JQZQz94kiWtRQvZIQbTiehsnwHvLSWJnQdhVeqYue7Id1dKr0qw== - detect-browser@5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/detect-browser/-/detect-browser-5.2.0.tgz#c9cd5afa96a6a19fda0bbe9e9be48a6b6e1e9c97" integrity sha512-tr7XntDAu50BVENgQfajMLzacmSe34D+qZc4zjnniz0ZVuw/TZcLcyxHQjYpJTM36sGEkZZlYLnIM1hH7alTMA== -detect-browser@5.3.0, detect-browser@^5.3.0: +detect-browser@5.3.0: version "5.3.0" resolved "https://registry.yarnpkg.com/detect-browser/-/detect-browser-5.3.0.tgz#9705ef2bddf46072d0f7265a1fe300e36fe7ceca" integrity sha512-53rsFbGdwMwlF7qvCt0ypLM5V5/Mbl0szB7GPN8y9NCcbknYOeVVXdrXEq+90IwAfrrzt6Hd+u2E2ntakICU8w== @@ -3080,18 +2446,6 @@ es6-iterator@^2.0.3: es5-ext "^0.10.35" es6-symbol "^3.1.1" -es6-promise@^4.0.3: - version "4.2.8" - resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" - integrity sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w== - -es6-promisify@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/es6-promisify/-/es6-promisify-5.0.0.tgz#5109d62f3e56ea967c4b63505aef08291c8a5203" - integrity sha512-C+d6UdsYDk0lMebHNR4S2NybQMMngAOnOwYBQjTOiv0MkoJMP0Myw2mgpDLBcpfCmRLxyFqYhS/CfOENq4SJhQ== - dependencies: - es6-promise "^4.0.3" - es6-symbol@^3.1.1, es6-symbol@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" @@ -3143,49 +2497,6 @@ estree-walker@^2: resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== -eth-block-tracker@6.1.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/eth-block-tracker/-/eth-block-tracker-6.1.0.tgz#0481f97bbb88a100b9d45806fe7e37af741cbefc" - integrity sha512-K9SY8+/xMBi4M5HHTDdxnpEqEEGjbNpzHFqvxyjMZej8InV/B+CkFRKM6W+uvrFJ7m8Zd1E0qUkseU3vdIDFYQ== - dependencies: - "@metamask/safe-event-emitter" "^2.0.0" - "@metamask/utils" "^3.0.1" - json-rpc-random-id "^1.0.1" - pify "^3.0.0" - -eth-json-rpc-filters@5.1.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/eth-json-rpc-filters/-/eth-json-rpc-filters-5.1.0.tgz#f0c2aeaec2a45e2dc6ca1b9843d8e85447821427" - integrity sha512-fos+9xmoa1A2Ytsc9eYof17r81BjdJOUcGcgZn4K/tKdCCTb+a8ytEtwlu1op5qsXFDlgGmstTELFrDEc89qEQ== - dependencies: - "@metamask/safe-event-emitter" "^2.0.0" - async-mutex "^0.2.6" - eth-query "^2.1.2" - json-rpc-engine "^6.1.0" - pify "^5.0.0" - -eth-query@^2.1.2: - version "2.1.2" - resolved "https://registry.yarnpkg.com/eth-query/-/eth-query-2.1.2.tgz#d6741d9000106b51510c72db92d6365456a6da5e" - integrity sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA== - dependencies: - json-rpc-random-id "^1.0.0" - xtend "^4.0.1" - -eth-rpc-errors@4.0.2: - version "4.0.2" - resolved "https://registry.yarnpkg.com/eth-rpc-errors/-/eth-rpc-errors-4.0.2.tgz#11bc164e25237a679061ac05b7da7537b673d3b7" - integrity sha512-n+Re6Gu8XGyfFy1it0AwbD1x0MUzspQs0D5UiPs1fFPCr6WAwZM+vbIhXheBFrpgosqN9bs5PqlB4Q61U/QytQ== - dependencies: - fast-safe-stringify "^2.0.6" - -eth-rpc-errors@^4.0.2: - version "4.0.3" - resolved "https://registry.yarnpkg.com/eth-rpc-errors/-/eth-rpc-errors-4.0.3.tgz#6ddb6190a4bf360afda82790bb7d9d5e724f423a" - integrity sha512-Z3ymjopaoft7JDoxZcEb3pwdGh7yiYMhOwm2doUt6ASXlMavpNlK6Cre0+IMl2VSGyEU9rkiperQhp5iRxn5Pg== - dependencies: - fast-safe-stringify "^2.0.6" - ethers@5.5.3: version "5.5.3" resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.5.3.tgz#1e361516711c0c3244b6210e7e3ecabf0c75fca0" @@ -3319,31 +2630,11 @@ ext@^1.1.2: dependencies: type "^2.7.2" -eyes@^0.1.8: - version "0.1.8" - resolved "https://registry.yarnpkg.com/eyes/-/eyes-0.1.8.tgz#62cf120234c683785d902348a800ef3e0cc20bc0" - integrity sha512-GipyPsXO1anza0AOZdy69Im7hGFCNB7Y/NGjDlZGJ3GJJLtwNSb2vrzYrTYJRrRloVx7pl+bhUaTB8yiccPvFQ== - fast-redact@^3.0.0: version "3.3.0" resolved "https://registry.yarnpkg.com/fast-redact/-/fast-redact-3.3.0.tgz#7c83ce3a7be4898241a46560d51de10f653f7634" integrity sha512-6T5V1QK1u4oF+ATxs1lWUmlEk6P2T9HqJG3e2DnHOdVgZy2rFJBoEnrIedcTXlkAHU/zKC+7KETJ+KGGKwxgMQ== -fast-safe-stringify@^2.0.6: - version "2.1.1" - resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz#c406a83b6e70d9e35ce3b30a81141df30aeba884" - integrity sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA== - -fast-stable-stringify@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/fast-stable-stringify/-/fast-stable-stringify-1.0.0.tgz#5c5543462b22aeeefd36d05b34e51c78cb86d313" - integrity sha512-wpYMUmFu5f00Sm0cj2pfivpmawLZ0NKdviQ4w9zJeR8JVtOpOxHmLaJuj0vxvGqMJQWyP/COUkF75/57OKyRag== - -file-uri-to-path@1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" - integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== - filter-obj@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/filter-obj/-/filter-obj-1.1.0.tgz#9b311112bc6c6127a16e016c6c5d7f19e0805c5b" @@ -3369,33 +2660,11 @@ font-awesome@^4.7.0: resolved "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz" integrity sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg== -for-each@^0.3.3: - version "0.3.3" - resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" - integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== - dependencies: - is-callable "^1.1.3" - -function-bind@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" - integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== - get-caller-file@^2.0.1: version "2.0.5" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -get-intrinsic@^1.0.2, get-intrinsic@^1.1.3: - version "1.2.1" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" - integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== - dependencies: - function-bind "^1.1.1" - has "^1.0.3" - has-proto "^1.0.1" - has-symbols "^1.0.3" - get-nonce@^1.0.0: version "1.0.1" resolved "https://registry.npmjs.org/get-nonce/-/get-nonce-1.0.1.tgz" @@ -3416,47 +2685,11 @@ globrex@^0.1.2: resolved "https://registry.yarnpkg.com/globrex/-/globrex-0.1.2.tgz#dd5d9ec826232730cd6793a5e33a9302985e6098" integrity sha512-uHJgbwAMwNFf5mLst7IWLNg14x1CkeqglJb/K3doi4dw6q2IvAAmM/Y81kevy83wP+Sst+nutFTYOGg3d1lsxg== -gopd@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" - integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== - dependencies: - get-intrinsic "^1.1.3" - graceful-fs@^4.2.4: version "4.2.11" resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== -has-flag@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/has-flag/-/has-flag-4.0.0.tgz#944771fd9c81c81265c4d6941860da06bb59479b" - integrity sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ== - -has-proto@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" - integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== - -has-symbols@^1.0.2, has-symbols@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" - integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== - -has-tostringtag@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" - integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== - dependencies: - has-symbols "^1.0.2" - -has@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" - integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== - dependencies: - function-bind "^1.1.1" - hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3, hash.js@^1.1.7: version "1.1.7" resolved "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" @@ -3512,19 +2745,12 @@ htmlparser2@7.2.0: domutils "^2.8.0" entities "^3.0.1" -humanize-ms@^1.2.1: - version "1.2.1" - resolved "https://registry.yarnpkg.com/humanize-ms/-/humanize-ms-1.2.1.tgz#c46e3159a293f6b896da29316d8b6fe8bb79bbed" - integrity sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ== - dependencies: - ms "^2.0.0" - -ieee754@^1.1.13, ieee754@^1.2.1: +ieee754@^1.1.13: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== -inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.4: +inherits@^2.0.3, inherits@^2.0.4: version "2.0.4" resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -3551,19 +2777,6 @@ invariant@^2.2.4: dependencies: loose-envify "^1.0.0" -is-arguments@^1.0.4: - version "1.1.1" - resolved "https://registry.yarnpkg.com/is-arguments/-/is-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" - integrity sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA== - dependencies: - call-bind "^1.0.2" - has-tostringtag "^1.0.0" - -is-callable@^1.1.3: - version "1.2.7" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" - integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== - is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" @@ -3574,13 +2787,6 @@ is-fullwidth-code-point@^3.0.0: resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== -is-generator-function@^1.0.7: - version "1.0.10" - resolved "https://registry.yarnpkg.com/is-generator-function/-/is-generator-function-1.0.10.tgz#f1558baf1ac17e0deea7c0415c438351ff2b3c72" - integrity sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A== - dependencies: - has-tostringtag "^1.0.0" - is-promise@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1" @@ -3591,13 +2797,6 @@ is-stream@^2.0.0: resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== -is-typed-array@^1.1.3: - version "1.1.12" - resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.12.tgz#d0bab5686ef4a76f7a73097b95470ab199c57d4a" - integrity sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg== - dependencies: - which-typed-array "^1.1.11" - is-typedarray@1.0.0, is-typedarray@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -3608,34 +2807,6 @@ isarray@^2.0.1: resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723" integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== -isomorphic-ws@5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-5.0.0.tgz#e5529148912ecb9b451b46ed44d53dae1ce04bbf" - integrity sha512-muId7Zzn9ywDsyXgTIafTry2sV3nySZeUDe6YedVd1Hvuuep5AsIlqK+XefWpYTyJG5e503F2xIuT2lcU6rCSw== - -isomorphic-ws@^4.0.1: - version "4.0.1" - resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-4.0.1.tgz#55fd4cd6c5e6491e76dc125938dd863f5cd4f2dc" - integrity sha512-BhBvN2MBpWTaSHdWRb/bwdZJ1WaehQ2L1KngkCkfLUGF0mAWAT1sQUQacEmQ0jXkFw/czDXPNQSL5u2/Krsz1w== - -jayson@^4.1.0: - version "4.1.0" - resolved "https://registry.yarnpkg.com/jayson/-/jayson-4.1.0.tgz#60dc946a85197317f2b1439d672a8b0a99cea2f9" - integrity sha512-R6JlbyLN53Mjku329XoRT2zJAE6ZgOQ8f91ucYdMCD4nkGCF9kZSrcGXpHIU4jeKj58zUZke2p+cdQchU7Ly7A== - dependencies: - "@types/connect" "^3.4.33" - "@types/node" "^12.12.54" - "@types/ws" "^7.4.4" - JSONStream "^1.3.5" - commander "^2.20.3" - delay "^5.0.0" - es6-promisify "^5.0.0" - eyes "^0.1.8" - isomorphic-ws "^4.0.1" - json-stringify-safe "^5.0.1" - uuid "^8.3.2" - ws "^7.4.5" - joi@17.9.1: version "17.9.1" resolved "https://registry.yarnpkg.com/joi/-/joi-17.9.1.tgz#74899b9fa3646904afa984a11df648eca66c9018" @@ -3662,38 +2833,6 @@ js-sha3@0.8.0: resolved "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== -json-rpc-engine@6.1.0, json-rpc-engine@^6.1.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/json-rpc-engine/-/json-rpc-engine-6.1.0.tgz#bf5ff7d029e1c1bf20cb6c0e9f348dcd8be5a393" - integrity sha512-NEdLrtrq1jUZyfjkr9OCz9EzCNhnRyWtt1PAnvnhwy6e8XETS0Dtc+ZNCO2gvuAoKsIn2+vCSowXTYE4CkgnAQ== - dependencies: - "@metamask/safe-event-emitter" "^2.0.0" - eth-rpc-errors "^4.0.2" - -json-rpc-random-id@^1.0.0, json-rpc-random-id@^1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/json-rpc-random-id/-/json-rpc-random-id-1.0.1.tgz#ba49d96aded1444dbb8da3d203748acbbcdec8c8" - integrity sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA== - -json-stringify-safe@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" - integrity sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA== - -jsonparse@^1.2.0: - version "1.3.1" - resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" - integrity sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg== - -keccak@^3.0.1: - version "3.0.3" - resolved "https://registry.yarnpkg.com/keccak/-/keccak-3.0.3.tgz#4bc35ad917be1ef54ff246f904c2bbbf9ac61276" - integrity sha512-JZrLIAJWuZxKbCilMpNz5Vj7Vtb4scDG3dMXLOsbzBmQGyjwE61BbW7bJkfKKCShXiQZt3T6sBgALRtmd+nZaQ== - dependencies: - node-addon-api "^2.0.0" - node-gyp-build "^4.2.0" - readable-stream "^3.6.0" - keyvaluestorage-interface@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/keyvaluestorage-interface/-/keyvaluestorage-interface-1.0.0.tgz#13ebdf71f5284ad54be94bd1ad9ed79adad515ff" @@ -3835,13 +2974,6 @@ loose-envify@^1.0.0: dependencies: js-tokens "^3.0.0 || ^4.0.0" -lru-cache@^6.0.0: - version "6.0.0" - resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" - integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== - dependencies: - yallist "^4.0.0" - lru-queue@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/lru-queue/-/lru-queue-0.1.0.tgz#2738bd9f0d3cf4f84490c5736c48699ac632cda3" @@ -3849,13 +2981,6 @@ lru-queue@^0.1.0: dependencies: es5-ext "~0.10.2" -media-query-parser@^2.0.2: - version "2.0.2" - resolved "https://registry.yarnpkg.com/media-query-parser/-/media-query-parser-2.0.2.tgz#ff79e56cee92615a304a1c2fa4f2bd056c0a1d29" - integrity sha512-1N4qp+jE0pL5Xv4uEcwVUhIkwdUO3S/9gML90nqKA7v7FcOS5vUtatfzok9S9U1EJU8dHWlcv95WLnKmmxZI9w== - dependencies: - "@babel/runtime" "^7.12.5" - memoizee@^0.4.15: version "0.4.15" resolved "https://registry.yarnpkg.com/memoizee/-/memoizee-0.4.15.tgz#e6f3d2da863f318d02225391829a6c5956555b72" @@ -3907,11 +3032,6 @@ ms@2.1.2: resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -ms@^2.0.0: - version "2.1.3" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" - integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== - ms@^3.0.0-canary.1: version "3.0.0-canary.1" resolved "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz" @@ -3937,11 +3057,6 @@ next-tick@1, next-tick@^1.1.0: resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.1.0.tgz#1836ee30ad56d67ef281b22bd199f709449b35eb" integrity sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ== -node-addon-api@^2.0.0: - version "2.0.2" - resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-2.0.2.tgz#432cfa82962ce494b132e9d72a15b29f71ff5d32" - integrity sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA== - node-fetch@^2.6.12: version "2.6.12" resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz" @@ -3949,16 +3064,6 @@ node-fetch@^2.6.12: dependencies: whatwg-url "^5.0.0" -node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: - version "4.6.0" - resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.6.0.tgz#0c52e4cbf54bbd28b709820ef7b6a3c2d6209055" - integrity sha512-NTZVKn9IylLwUzaKjkas1e4u2DLNcV4rdYagA4PWdPwW87Bi7z+BznyKSRwS/761tV/lzCGXplWsiaMjLqP2zQ== - -object-inspect@^1.9.0: - version "1.12.3" - resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" - integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== - on-exit-leak-free@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/on-exit-leak-free/-/on-exit-leak-free-0.2.0.tgz#b39c9e3bf7690d890f4861558b0d7b90a442d209" @@ -3971,11 +3076,6 @@ once@^1.4.0: dependencies: wrappy "1" -outdent@^0.8.0: - version "0.8.0" - resolved "https://registry.yarnpkg.com/outdent/-/outdent-0.8.0.tgz#2ebc3e77bf49912543f1008100ff8e7f44428eb0" - integrity sha512-KiOAIsdpUTcAXuykya5fnVVT+/5uS0Q1mrkRHcF89tpieSmY33O/tmc54CqwA+bfhbtEfZUNLHaPUiB9X3jt1A== - p-limit@^2.0.0, p-limit@^2.2.0: version "2.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-2.3.0.tgz#3dd33c647a214fdfffd835933eb086da0dc21db1" @@ -4012,16 +3112,6 @@ path-exists@^4.0.0: resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== -pify@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" - integrity sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg== - -pify@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/pify/-/pify-5.0.0.tgz#1f5eca3f5e87ebec28cc6d54a0e4aaf00acc127f" - integrity sha512-eW/gHNMlxdSP6dmG6uJip6FXN0EQBwm2clYYd8Wul42Cwu/DK8HEftzsapcNdYe2MfLiIwZqsDk2RDEsTE79hA== - pino-abstract-transport@v0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/pino-abstract-transport/-/pino-abstract-transport-0.5.0.tgz#4b54348d8f73713bfd14e3dc44228739aa13d9c0" @@ -4067,11 +3157,6 @@ preact@10.4.1: resolved "https://registry.yarnpkg.com/preact/-/preact-10.4.1.tgz#9b3ba020547673a231c6cf16f0fbaef0e8863431" integrity sha512-WKrRpCSwL2t3tpOOGhf2WfTpcmbpxaWtDbdJdKdjd0aEiTkvOmS4NBkG6kzlaAHI9AkQ3iVqbFWM3Ei7mZ4o1Q== -preact@^10.12.0, preact@^10.5.9: - version "10.17.0" - resolved "https://registry.yarnpkg.com/preact/-/preact-10.17.0.tgz#77c0e3402767c999ac0f1ba39bd43cd85beab06b" - integrity sha512-SNsI8cbaCcUS5tbv9nlXuCfIXnJ9ysBMWk0WnB6UWwcVA3qZ2O6FxqDFECMAMttvLQcW/HaNZUe2BLidyvrVYw== - process-warning@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/process-warning/-/process-warning-1.0.0.tgz#980a0b25dc38cd6034181be4b7726d89066b4616" @@ -4104,17 +3189,7 @@ qrcode@1.4.4: pngjs "^3.3.0" yargs "^13.2.4" -qrcode@1.5.0: - version "1.5.0" - resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.0.tgz#95abb8a91fdafd86f8190f2836abbfc500c72d1b" - integrity sha512-9MgRpgVc+/+47dFvQeD6U2s0Z92EsKzcHogtum4QB+UNd025WOJSHvn/hjk9xmzj7Stj95CyUAs31mrjxliEsQ== - dependencies: - dijkstrajs "^1.0.1" - encode-utf8 "^1.0.3" - pngjs "^5.0.0" - yargs "^15.3.1" - -qrcode@1.5.3, qrcode@^1.5.1: +qrcode@1.5.3: version "1.5.3" resolved "https://registry.yarnpkg.com/qrcode/-/qrcode-1.5.3.tgz#03afa80912c0dccf12bc93f615a535aad1066170" integrity sha512-puyri6ApkEHYiVl4CFzo1tDkAZ+ATcnbJrJ6RiBM1Fhctdn/ix9MTE3hRph33omisEbC/2fcfemsseiKgBPKZg== @@ -4124,13 +3199,6 @@ qrcode@1.5.3, qrcode@^1.5.1: pngjs "^5.0.0" yargs "^15.3.1" -qs@^6.10.3: - version "6.11.2" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" - integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== - dependencies: - side-channel "^1.0.4" - query-string@6.13.5: version "6.13.5" resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.13.5.tgz#99e95e2fb7021db90a6f373f990c0c814b3812d8" @@ -4150,16 +3218,6 @@ query-string@7.1.3: split-on-first "^1.0.0" strict-uri-encode "^2.0.0" -query-string@^6.13.5: - version "6.14.1" - resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.14.1.tgz#7ac2dca46da7f309449ba0f86b1fd28255b0c86a" - integrity sha512-XDxAeVmpfu1/6IjyT/gXHOl+S0vQ9owggJ30hhWKdHAsNPOcasn5o9BW0eejZqL2e4vMjhAxoW3jVHcD6mbcYw== - dependencies: - decode-uri-component "^0.2.0" - filter-obj "^1.1.0" - split-on-first "^1.0.0" - strict-uri-encode "^2.0.0" - querystringify@^2.1.1: version "2.2.0" resolved "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz" @@ -4195,17 +3253,6 @@ react-remove-scroll-bar@^2.3.3: react-style-singleton "^2.2.1" tslib "^2.0.0" -react-remove-scroll@2.5.4: - version "2.5.4" - resolved "https://registry.yarnpkg.com/react-remove-scroll/-/react-remove-scroll-2.5.4.tgz#afe6491acabde26f628f844b67647645488d2ea0" - integrity sha512-xGVKJJr0SJGQVirVFAUZ2k1QLyO6m+2fy0l8Qawbp5Jgrv3DeLalrfMNBFSlmz5kriGGzsVBtGVnf4pTKIhhWA== - dependencies: - react-remove-scroll-bar "^2.3.3" - react-style-singleton "^2.2.1" - tslib "^2.1.0" - use-callback-ref "^1.3.0" - use-sidecar "^1.1.2" - react-remove-scroll@2.5.5: version "2.5.5" resolved "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.5.5.tgz" @@ -4240,7 +3287,7 @@ react-twitter-embed@^4.0.4: dependencies: scriptjs "^2.5.9" -readable-stream@^3.1.1, readable-stream@^3.5.0, readable-stream@^3.6.0: +readable-stream@^3.1.1: version "3.6.2" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== @@ -4259,11 +3306,6 @@ regenerator-runtime@^0.13.11: resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== -regenerator-runtime@^0.14.0: - version "0.14.0" - resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz#5e19d68eb12d486f797e15a3c6a918f7cec5eb45" - integrity sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA== - require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" @@ -4284,19 +3326,6 @@ retry@^0.12.0: resolved "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz" integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== -rpc-websockets@^7.5.1: - version "7.6.0" - resolved "https://registry.yarnpkg.com/rpc-websockets/-/rpc-websockets-7.6.0.tgz#d3f4c0dac108ca35566b0e31552c32e58928cd04" - integrity sha512-Jgcs8q6t8Go98dEulww1x7RysgTkzpCMelVxZW4hvuyFtOGpeUz9prpr2KjUa/usqxgFCd9Tu3+yhHEP9GVmiQ== - dependencies: - "@babel/runtime" "^7.17.2" - eventemitter3 "^4.0.7" - uuid "^8.3.2" - ws "^8.5.0" - optionalDependencies: - bufferutil "^4.0.1" - utf-8-validate "^5.0.2" - rxjs@^6.6.3: version "6.6.7" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" @@ -4318,7 +3347,7 @@ sade@^1.8.1: dependencies: mri "^1.1.0" -safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@~5.2.0: +safe-buffer@^5.1.0, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== @@ -4343,35 +3372,11 @@ scrypt-js@3.0.1: resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-3.0.1.tgz#d314a57c2aef69d1ad98a138a21fe9eafa9ee312" integrity sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA== -semver@^7.3.8: - version "7.5.4" - resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" - integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== - dependencies: - lru-cache "^6.0.0" - set-blocking@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== -sha.js@^2.4.11: - version "2.4.11" - resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.11.tgz#37a5cf0b81ecbc6943de109ba2960d1b26584ae7" - integrity sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ== - dependencies: - inherits "^2.0.1" - safe-buffer "^5.0.1" - -side-channel@^1.0.4: - version "1.0.4" - resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" - integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== - dependencies: - call-bind "^1.0.0" - get-intrinsic "^1.0.2" - object-inspect "^1.9.0" - signal-exit@^3.0.2: version "3.0.7" resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" @@ -4412,14 +3417,6 @@ split2@^4.0.0: resolved "https://registry.yarnpkg.com/split2/-/split2-4.2.0.tgz#c9c5920904d148bab0b9f67145f245a86aadbfa4" integrity sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg== -stream-browserify@^3.0.0: - version "3.0.0" - resolved "https://registry.yarnpkg.com/stream-browserify/-/stream-browserify-3.0.0.tgz#22b0a2850cdf6503e73085da1fc7b7d0c2122f2f" - integrity sha512-H73RAHsVBapbim0tU2JwwOiXUj+fikfiaoYAKHF3VJfA0pe2BCzkhAHBlLG6REzE+2WNZcxOXjK7lkso+9euLA== - dependencies: - inherits "~2.0.4" - readable-stream "^3.5.0" - stream-shift@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" @@ -4490,23 +3487,6 @@ style-to-object@0.3.0: dependencies: inline-style-parser "0.1.1" -superstruct@^0.14.2: - version "0.14.2" - resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-0.14.2.tgz#0dbcdf3d83676588828f1cf5ed35cda02f59025b" - integrity sha512-nPewA6m9mR3d6k7WkZ8N8zpTWfenFH3q9pA2PkuiZxINr9DKB2+40wEQf0ixn8VaGuJ78AB6iWOtStI+/4FKZQ== - -superstruct@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-1.0.3.tgz#de626a5b49c6641ff4d37da3c7598e7a87697046" - integrity sha512-8iTn3oSS8nRGn+C2pgXSKPI3jmpm6FExNazNpjvqS6ZUJQCej3PUXEKM8NjHBOs54ExM+LPW/FBRhymrdcCiSg== - -supports-color@^7.1.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-7.2.0.tgz#1b7dcdcb32b8138801b3e478ba6a51caa89648da" - integrity sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw== - dependencies: - has-flag "^4.0.0" - svelte-i18n@^3.3.13: version "3.7.4" resolved "https://registry.yarnpkg.com/svelte-i18n/-/svelte-i18n-3.7.4.tgz#6cf2c86075fd748bd8ca2de5762e43a596c7d189" @@ -4525,11 +3505,6 @@ svelte@^3.49.0: resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.59.2.tgz#a137b28e025a181292b2ae2e3dca90bf8ec73aec" integrity sha512-vzSyuGr3eEoAtT/A6bmajosJZIUWySzY2CzB3w2pgPvnkUjGqlDnsNnA0PMO+mMAhuyMul6C2uuZzY6ELSkzyA== -text-encoding-utf-8@^1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/text-encoding-utf-8/-/text-encoding-utf-8-1.0.2.tgz#585b62197b0ae437e3c7b5d0af27ac1021e10d13" - integrity sha512-8bw4MY9WjdsD2aMtO0OzOCY3pXGYNx2d2FfHRVUKkiCPDWjKuOlhLVASS+pD7VkLTVjW268LYJHwsnPFlBpbAg== - thread-stream@^0.15.1: version "0.15.2" resolved "https://registry.yarnpkg.com/thread-stream/-/thread-stream-0.15.2.tgz#fb95ad87d2f1e28f07116eb23d85aba3bc0425f4" @@ -4537,11 +3512,6 @@ thread-stream@^0.15.1: dependencies: real-require "^0.1.0" -"through@>=2.2.7 <3": - version "2.3.8" - resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" - integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== - timers-ext@^0.1.7: version "0.1.7" resolved "https://registry.yarnpkg.com/timers-ext/-/timers-ext-0.1.7.tgz#6f57ad8578e07a3fb9f91d9387d65647555e25c6" @@ -4584,9 +3554,9 @@ tslib@^2.0.0, tslib@^2.1.0, tslib@^2.3.0: integrity sha512-336iVw3rtn2BUK7ORdIAHTyxHGRIHVReokCR3XjbckJMK7ms8FysBfhLR8IXnAgy7T0PTPNBWKiH514FOW/WSg== tslib@^2.3.1: - version "2.6.1" - resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.1.tgz#fd8c9a0ff42590b25703c0acb3de3d3f4ede0410" - integrity sha512-t0hLfiEKfMUoqhG+U1oid7Pva4bbDPHYfJNiB7BiIjRkj1pyC++4N3huJfqY6aRH6VTB0rvtzQwjM4K6qpfOig== + version "2.6.2" + resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.2.tgz#703ac29425e7b37cd6fd456e92404d46d1f3e4ae" + integrity sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q== tus-js-client@^3.1.0: version "3.1.1" @@ -4658,34 +3628,11 @@ use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: resolved "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz" integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== -utf-8-validate@^5.0.2: - version "5.0.10" - resolved "https://registry.yarnpkg.com/utf-8-validate/-/utf-8-validate-5.0.10.tgz#d7d10ea39318171ca982718b6b96a8d2442571a2" - integrity sha512-Z6czzLq4u8fPOyx7TU6X3dvUZVvoJmxSQ+IcrlmagKhilxlhZgxPK6C5Jqbkw1IDUmFTM+cz9QDnnLTwDz/2gQ== - dependencies: - node-gyp-build "^4.3.0" - util-deprecate@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== -util@^0.12.4: - version "0.12.5" - resolved "https://registry.yarnpkg.com/util/-/util-0.12.5.tgz#5f17a6059b73db61a875668781a1c2b136bd6fbc" - integrity sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA== - dependencies: - inherits "^2.0.3" - is-arguments "^1.0.4" - is-generator-function "^1.0.7" - is-typed-array "^1.1.3" - which-typed-array "^1.1.2" - -uuid@^8.3.2: - version "8.3.2" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" - integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== - valtio@1.11.0: version "1.11.0" resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.11.0.tgz#c029dcd17a0f99d2fbec933721fe64cfd32a31ed" @@ -4694,34 +3641,6 @@ valtio@1.11.0: proxy-compare "2.5.1" use-sync-external-store "1.2.0" -viem@^1.0.0: - version "1.6.0" - resolved "https://registry.yarnpkg.com/viem/-/viem-1.6.0.tgz#8befa678c3ac79b9558dfd1708130b2ecb1994f4" - integrity sha512-ae9Twkd0q2Qlj4yYpWjb4DzYAhKY0ibEpRH8FJaTywZXNpTjFidSdBaT0CVn1BaH7O7cnX4/O47zvDUMGJD1AA== - dependencies: - "@adraffy/ens-normalize" "1.9.0" - "@noble/curves" "1.1.0" - "@noble/hashes" "1.3.0" - "@scure/bip32" "1.3.0" - "@scure/bip39" "1.2.0" - "@types/ws" "^8.5.4" - "@wagmi/chains" "1.6.0" - abitype "0.9.3" - isomorphic-ws "5.0.0" - ws "8.12.0" - -wagmi@^1.3.10: - version "1.3.10" - resolved "https://registry.yarnpkg.com/wagmi/-/wagmi-1.3.10.tgz#100aeaecf7a030e9e91118d366a734ec30c56551" - integrity sha512-MMGJcnxOmeUZWDmzUxgRGcB1cqxbJoSFSa+pNY4vBCWMz0n4ptpE5F8FKISLCx+BGoDwsaz2ldcMALcdJZ+29w== - dependencies: - "@tanstack/query-sync-storage-persister" "^4.27.1" - "@tanstack/react-query" "^4.28.0" - "@tanstack/react-query-persist-client" "^4.28.0" - "@wagmi/core" "1.3.9" - abitype "0.8.7" - use-sync-external-store "^1.2.0" - webidl-conversions@^3.0.0: version "3.0.1" resolved "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz" @@ -4740,17 +3659,6 @@ which-module@^2.0.0: resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.1.tgz#776b1fe35d90aebe99e8ac15eb24093389a4a409" integrity sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ== -which-typed-array@^1.1.11, which-typed-array@^1.1.2: - version "1.1.11" - resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.11.tgz#99d691f23c72aab6768680805a271b69761ed61a" - integrity sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew== - dependencies: - available-typed-arrays "^1.0.5" - call-bind "^1.0.2" - for-each "^0.3.3" - gopd "^1.0.1" - has-tostringtag "^1.0.0" - wrap-ansi@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09" @@ -4784,21 +3692,11 @@ ws@7.5.3: resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.3.tgz#160835b63c7d97bfab418fc1b8a9fced2ac01a74" integrity sha512-kQ/dHIzuLrS6Je9+uv81ueZomEwH0qVYstcAQ4/Z93K8zeko9gtAbttJWzoC5ukqXY1PpoouV3+VSOqEAFt5wg== -ws@8.12.0: - version "8.12.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.12.0.tgz#485074cc392689da78e1828a9ff23585e06cddd8" - integrity sha512-kU62emKIdKVeEIOIKVegvqpXMSTAMLJozpHZaJNDYqBjzlSYXQGviYwN1osDLJ9av68qHd4a2oSjd7yD4pacig== - -ws@^7.4.5, ws@^7.5.1: +ws@^7.5.1: version "7.5.9" resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591" integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q== -ws@^8.5.0: - version "8.13.0" - resolved "https://registry.yarnpkg.com/ws/-/ws-8.13.0.tgz#9a9fb92f93cf41512a0735c8f4dd09b8a1211cd0" - integrity sha512-x9vcZYTrFPC7aSIbj7sRCYo7L/Xb8Iy+pW0ng0wt2vCJv7M9HOMy0UoN3rr+IFC7hb7vXoqS+P9ktyLLLhO+LA== - ws@~8.11.0: version "8.11.0" resolved "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz" @@ -4809,21 +3707,11 @@ xmlhttprequest-ssl@~2.0.0: resolved "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz" integrity sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A== -xtend@^4.0.1: - version "4.0.2" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" - integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== - y18n@^4.0.0: version "4.0.3" resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.3.tgz#b5f259c82cd6e336921efd7bfd8bf560de9eeedf" integrity sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ== -yallist@^4.0.0: - version "4.0.0" - resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" - integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== - yargs-parser@^13.1.2: version "13.1.2" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" @@ -4873,13 +3761,6 @@ yargs@^15.3.1: y18n "^4.0.0" yargs-parser "^18.1.2" -zustand@^4.3.1: - version "4.4.1" - resolved "https://registry.yarnpkg.com/zustand/-/zustand-4.4.1.tgz#0cd3a3e4756f21811bd956418fdc686877e8b3b0" - integrity sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw== - dependencies: - use-sync-external-store "1.2.0" - zustand@^4.3.9: version "4.4.0" resolved "https://registry.npmjs.org/zustand/-/zustand-4.4.0.tgz" From 02994fa55059c3373368ab07999c9fb0fe617a84 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 15 Sep 2023 11:24:48 +0530 Subject: [PATCH 240/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.11?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 4 ++++ packages/uiweb/package.json | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 0a785bc63..857bf807c 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,10 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.10...uiweb-0.0.1-alpha.11) (2023-09-15) + + + ## [0.0.1-alpha.10](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.9...uiweb-0.0.1-alpha.10) (2023-09-09) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 97cde6404..3303c6804 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.10", + "version": "0.0.1-alpha.11", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 8ae0f49fcd385dfdcad197de2f89c58a074f681e Mon Sep 17 00:00:00 2001 From: Satyam <100528412+KlausMikhaelson@users.noreply.github.com> Date: Wed, 20 Sep 2023 07:32:22 -0600 Subject: [PATCH 241/298] fix: added condition while showing tokengatedIcon (#715) --- .../chat/ChatProfile/ChatProfile.tsx | 130 +++++++++--------- 1 file changed, 68 insertions(+), 62 deletions(-) diff --git a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx index 1b0d45e8d..b9267b17b 100644 --- a/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatProfile/ChatProfile.tsx @@ -31,10 +31,10 @@ import 'react-toastify/dist/ReactToastify.min.css'; -const Options = ({ options, setOptions, isGroup, chatInfo, groupInfo, setGroupInfo,theme }: OptionProps) => { +const Options = ({ options, setOptions, isGroup, chatInfo, groupInfo, setGroupInfo, theme }: OptionProps) => { const DropdownRef = useRef(null); const [modal, setModal] = useState(false); - + useClickAway(DropdownRef, () => { setOptions(false); }); @@ -42,59 +42,65 @@ const Options = ({ options, setOptions, isGroup, chatInfo, groupInfo, setGroupIn const ShowModal = () => { setModal(true); } + console.log(groupInfo?.rules?.chat, "groupInfooo") - if (groupInfo && isGroup){ + if (groupInfo && isGroup) { return (
- + { + (groupInfo?.rules?.chat?.conditions || groupInfo?.rules?.entry?.conditions) && ( + + ) + } - {groupInfo?.isPublic && - ()} + {groupInfo?.isPublic && + ()} setOptions(true)}> - - - {options && - ( - - - - - Group Info - - - )} - - {modal && - ()} + + + {options && + ( + + + + + Group Info + + + )} + + {modal && + ()}
) - } else { - return null } - }; + } else { + return null + } +}; + - -export const ChatProfile: React.FC = ({ chatId, style }: {chatId: string, style: "Info" | "Preview"}) => { +export const ChatProfile: React.FC = ({ chatId, style }: { chatId: string, style: "Info" | "Preview" }) => { const theme = useContext(ThemeContext); const { account, env } = useChatData(); const { getGroupByID } = useGetGroupByID(); const { fetchUserChatProfile } = useChatProfile(); const [isGroup, setIsGroup] = useState(false); - const [options, setOptions] = useState(false); - const [chatInfo, setChatInfo ] = useState(); - const [groupInfo, setGroupInfo ] = useState(); - const [ensName, setEnsName ] = useState(''); + const [options, setOptions] = useState(false); + const [chatInfo, setChatInfo] = useState(); + const [groupInfo, setGroupInfo] = useState(); + const [ensName, setEnsName] = useState(''); const isMobile = useMediaQuery(device.tablet); const l1ChainId = allowedNetworks[env].includes(1) ? 1 : 5; const provider = new ethers.providers.InfuraProvider(l1ChainId, InfuraAPIKey); @@ -102,13 +108,13 @@ export const ChatProfile: React.FC = ({ chatId, style }: {chatId: const fetchProfileData = async () => { - if(isValidETHAddress(chatId)){ + if (isValidETHAddress(chatId)) { const ChatProfile = await fetchUserChatProfile({ profileId: chatId }); setChatInfo(ChatProfile); setGroupInfo(null); setIsGroup(false); } else { - const GroupProfile = await getGroupByID({ groupId : chatId}) + const GroupProfile = await getGroupByID({ groupId: chatId }) setGroupInfo(GroupProfile); setChatInfo(null); setIsGroup(true); @@ -116,44 +122,44 @@ export const ChatProfile: React.FC = ({ chatId, style }: {chatId: } const getName = async (chatId: string) => { - if(isValidETHAddress(chatId)){ - const result = await resolveNewEns(chatId, provider); - // if(result) - setEnsName(result); - } + if (isValidETHAddress(chatId)) { + const result = await resolveNewEns(chatId, provider); + // if(result) + setEnsName(result); + } } - useEffect(()=> { - if(!chatId) return; + useEffect(() => { + if (!chatId) return; fetchProfileData(); getName(chatId); - },[chatId, account, env]) + }, [chatId, account, env]) if (chatId && style === 'Info') { return ( {chatInfo || groupInfo ? ( + ?.toString()} height="48px" maxHeight="48px" width='48px' borderRadius="100%" /> ) : ()} - + - {isGroup ? groupInfo?.groupName : ensName ? `${ensName} (${isMobile ? shortenText(chatInfo?.did?.split(':')[1] ?? '', 4, true) : chatId})`: chatInfo ? shortenText(chatInfo.did?.split(':')[1] ?? '', 6, true) : shortenText(chatId,6, true)} - + {isGroup ? groupInfo?.groupName : ensName ? `${ensName} (${isMobile ? shortenText(chatInfo?.did?.split(':')[1] ?? '', 4, true) : chatId})` : chatInfo ? shortenText(chatInfo.did?.split(':')[1] ?? '', 6, true) : shortenText(chatId, 6, true)} + - + {/* {!isGroup && @@ -161,10 +167,10 @@ export const ChatProfile: React.FC = ({ chatId, style }: {chatId: } */} - + + - - + ) } else { return null; From 4e30c36532a55abd440f779c98b31f52bfb9e107 Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Wed, 20 Sep 2023 19:02:44 +0530 Subject: [PATCH 242/298] fix: added disconnect for wallet (#721) * fix: added disconnect for wallet * fix: added autoConnect --- .../src/app/ChatUITest/ChatViewComponent.tsx | 2 +- .../chat/ChatViewComponent/ChatViewComponent.tsx | 2 ++ .../lib/components/chat/ConnectButton/ConnectButton.tsx | 7 ++++++- .../uiweb/src/lib/components/chat/ConnectButton/index.tsx | 8 ++++++-- .../src/lib/components/chat/MessageInput/MessageInput.tsx | 5 +++-- packages/uiweb/src/lib/components/chat/exportedTypes.ts | 2 ++ 6 files changed, 20 insertions(+), 6 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 5b26347a3..2bfa43a81 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -14,7 +14,7 @@ const ChatViewComponentTest = () => {

Chat UI Test page

- console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} /> + console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} autoConnect={true}/>
); diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx index 73db94254..d7d4e196c 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -34,6 +34,7 @@ export const ChatViewComponent: React.FC = ( file = true, gif = true, isConnected = true, + autoConnect = false, onClick, } = options || {}; @@ -92,6 +93,7 @@ export const ChatViewComponent: React.FC = ( Emoji={emoji} GIF={gif} isConnected={isConnected} + autoConnect = {autoConnect} />
)} diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx index a67c40b4d..f739f6e0a 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/ConnectButton.tsx @@ -19,7 +19,10 @@ interface IThemeProps { theme?: IChatTheme; } -export const ConnectButtonSub = () => { +interface IConnectButtonProps { + autoConnect?: boolean; +} +export const ConnectButtonSub: React.FC = ({autoConnect = false}) => { const [{ wallet, connecting }, connect, disconnect] = useConnectWallet(); const { @@ -51,6 +54,8 @@ export const ConnectButtonSub = () => { } useEffect(() => { + if(wallet && !autoConnect) + disconnect(wallet); newFunc() }, [wallet]) diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx index 3465bf8ba..f562974e6 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx @@ -90,10 +90,14 @@ const web3OnBoard = init({ } }) -export const ConnectButtonComp = ({ pageProps }: any) => { +interface IConnectButtonCompProps { + autoConnect?: boolean; +} + +export const ConnectButtonComp:React.FC = ({ autoConnect }) => { return ( - + ); }; \ No newline at end of file diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 34c6842af..160e404b0 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -54,7 +54,8 @@ export const MessageInput: React.FC = ({ Emoji = true, GIF = true, File = true, - isConnected, + isConnected = true, + autoConnect = false, onClick, }) => { const [typedMessage, setTypedMessage] = useState(''); @@ -385,7 +386,7 @@ export const MessageInput: React.FC = ({ You need to connect your wallet to get started )} - +
)} diff --git a/packages/uiweb/src/lib/components/chat/exportedTypes.ts b/packages/uiweb/src/lib/components/chat/exportedTypes.ts index b42fc9590..5143d1a76 100644 --- a/packages/uiweb/src/lib/components/chat/exportedTypes.ts +++ b/packages/uiweb/src/lib/components/chat/exportedTypes.ts @@ -19,6 +19,7 @@ export interface IChatViewComponentProps { gif?: boolean; file?: boolean; isConnected?: boolean; + autoConnect?:boolean; onClick?: () => void; } @@ -66,6 +67,7 @@ export interface MessageInputProps { File?: boolean; Image?: boolean; isConnected?: boolean; + autoConnect?:boolean; onClick?: () => void; } From 3a864ce22a62548b566a82286236c048b130805f Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Wed, 20 Sep 2023 19:12:02 +0530 Subject: [PATCH 243/298] Wallet disconnect (#722) * fix: added disconnect for wallet * fix: added autoConnect * fix: changed onClick to onGetTokenClick --- .../src/lib/components/chat/MessageInput/MessageInput.tsx | 6 +++--- packages/uiweb/src/lib/components/chat/exportedTypes.ts | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index 160e404b0..d8feee194 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -56,7 +56,7 @@ export const MessageInput: React.FC = ({ File = true, isConnected = true, autoConnect = false, - onClick, + onGetTokenClick, }) => { const [typedMessage, setTypedMessage] = useState(''); const [showEmojis, setShowEmojis] = useState(false); @@ -527,8 +527,8 @@ export const MessageInput: React.FC = ({
{ - if (onClick) { - onClick(); + if (onGetTokenClick) { + onGetTokenClick(); } setVerificationSuccessfull(true); }} diff --git a/packages/uiweb/src/lib/components/chat/exportedTypes.ts b/packages/uiweb/src/lib/components/chat/exportedTypes.ts index 5143d1a76..45e82431c 100644 --- a/packages/uiweb/src/lib/components/chat/exportedTypes.ts +++ b/packages/uiweb/src/lib/components/chat/exportedTypes.ts @@ -68,7 +68,7 @@ export interface MessageInputProps { Image?: boolean; isConnected?: boolean; autoConnect?:boolean; - onClick?: () => void; + onGetTokenClick?: () => void; } export type UpdateGroupType = { From cf9e610d836518db73b54aded42d5cf4ab812057 Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Wed, 20 Sep 2023 19:14:57 +0530 Subject: [PATCH 244/298] Wallet disconnect (#723) * fix: added disconnect for wallet * fix: added autoConnect * fix: changed onClick to onGetTokenClick * fix: fixed errors --- .../src/app/ChatUITest/ChatViewComponent.tsx | 2 +- .../components/chat/ChatViewComponent/ChatViewComponent.tsx | 4 ++-- packages/uiweb/src/lib/components/chat/exportedTypes.ts | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 2bfa43a81..51efcde71 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -14,7 +14,7 @@ const ChatViewComponentTest = () => {

Chat UI Test page

- console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} autoConnect={true}/> + console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} autoConnect={true}/>
); diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx index d7d4e196c..6678fa5d7 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -35,7 +35,7 @@ export const ChatViewComponent: React.FC = ( gif = true, isConnected = true, autoConnect = false, - onClick, + onGetTokenClick, } = options || {}; const { env, signer, account, pgpPrivateKey } = useChatData(); @@ -87,7 +87,7 @@ export const ChatViewComponent: React.FC = ( {(messageInput && (!!signer || (!!account && !!pgpPrivateKey) || isConnected )) && (
void; + onGetTokenClick?: () => void; } export interface IChatProfile { From 71b6e97cd5661fb6c216e4eb38864f8897ae86d7 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 20 Sep 2023 19:25:30 +0530 Subject: [PATCH 245/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.12?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 13 +++++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 857bf807c..5eb68c0f7 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,19 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.11...uiweb-0.0.1-alpha.12) (2023-09-20) + + +### Bug Fixes + +* added condition while showing tokengatedIcon ([#715](https://github.com/ethereum-push-notification-service/push-sdk/issues/715)) ([8ae0f49](https://github.com/ethereum-push-notification-service/push-sdk/commit/8ae0f49fcd385dfdcad197de2f89c58a074f681e)) +* added disconnect for wallet ([#721](https://github.com/ethereum-push-notification-service/push-sdk/issues/721)) ([4e30c36](https://github.com/ethereum-push-notification-service/push-sdk/commit/4e30c36532a55abd440f779c98b31f52bfb9e107)) +* Merge branch 'alpha' into alpha-deployment ([a3b4ead](https://github.com/ethereum-push-notification-service/push-sdk/commit/a3b4ead84601329e36afd8555011a5088dba6983)) +* Merge branch 'alpha' into alpha-deployment ([a356f4b](https://github.com/ethereum-push-notification-service/push-sdk/commit/a356f4b8497252e75c8f70fd6f6bf533a6980c0a)) +* Merge branch 'alpha' into alpha-deployment ([1a4c5ac](https://github.com/ethereum-push-notification-service/push-sdk/commit/1a4c5ac8f704cc5bfeed1ba4eb688e4742acfd9e)) + + + ## [0.0.1-alpha.11](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.10...uiweb-0.0.1-alpha.11) (2023-09-15) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 3303c6804..3d82d904e 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.11", + "version": "0.0.1-alpha.12", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 165312644d23f6b90cfdbcaa12ab1ed5de40cbfb Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Thu, 21 Sep 2023 21:46:58 +0530 Subject: [PATCH 246/298] Changed messageInput params Case (#725) * fix: added disconnect for wallet * fix: added autoConnect * fix: changed onClick to onGetTokenClick * fix: fixed errors --- .../chat/ChatViewComponent/ChatViewComponent.tsx | 6 +++--- .../components/chat/MessageInput/MessageInput.tsx | 12 ++++++------ .../uiweb/src/lib/components/chat/exportedTypes.ts | 7 +++---- 3 files changed, 12 insertions(+), 13 deletions(-) diff --git a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx index 6678fa5d7..9cd16d4da 100644 --- a/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx +++ b/packages/uiweb/src/lib/components/chat/ChatViewComponent/ChatViewComponent.tsx @@ -89,9 +89,9 @@ export const ChatViewComponent: React.FC = ( diff --git a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx index d8feee194..2fb41b5e2 100644 --- a/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx +++ b/packages/uiweb/src/lib/components/chat/MessageInput/MessageInput.tsx @@ -51,9 +51,9 @@ interface IThemeProps { export const MessageInput: React.FC = ({ chatId, - Emoji = true, - GIF = true, - File = true, + emoji = true, + gif = true, + file = true, isConnected = true, autoConnect = false, onGetTokenClick, @@ -556,7 +556,7 @@ export const MessageInput: React.FC = ({ (chatFeed && !chatFeed?.groupInformation)) && ( <>
- {Emoji && ( + {emoji && (
= ({ />
- {GIF && ( + {gif && (
= ({
)}
- {!fileUploading && File && ( + {!fileUploading && file && ( <>
void; From 236f1665f14889326ca5f63b9b17eee5ff648be1 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 21 Sep 2023 21:50:37 +0530 Subject: [PATCH 247/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.13?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 5eb68c0f7..2ceb5c701 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.12...uiweb-0.0.1-alpha.13) (2023-09-21) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([fed5d89](https://github.com/ethereum-push-notification-service/push-sdk/commit/fed5d8940aaa20f6f68f6ec3dad6d4dd90afdda0)) + + + ## [0.0.1-alpha.12](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.11...uiweb-0.0.1-alpha.12) (2023-09-20) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 3d82d904e..f601052a7 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.12", + "version": "0.0.1-alpha.13", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From ccdabb89c2a6642ce21c9b276d2388717da3e7bb Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 22 Sep 2023 18:41:59 +0530 Subject: [PATCH 248/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 5a02abe6d..0fddb05ca 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.20](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.19...restapi-1.4.20) (2023-09-22) + + +### Bug Fixes + +* added chat.decrypt ([#726](https://github.com/ethereum-push-notification-service/push-sdk/issues/726)) ([995042b](https://github.com/ethereum-push-notification-service/push-sdk/commit/995042b789b19d487b5e2953463cae60e75199b8)) +* Merge branch 'main' into deployment ([2462c8b](https://github.com/ethereum-push-notification-service/push-sdk/commit/2462c8b060f4a2e6a0ea2cd03735569ead0b8e93)) + + + ## [1.4.19](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.18...restapi-1.4.19) (2023-09-06) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index a094d760f..cb236e058 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.19", + "version": "1.4.20", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 986f0b0a62596a1dc59e47c2ae3357b7e9428a4c Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Mon, 25 Sep 2023 12:43:30 +0530 Subject: [PATCH 249/298] Wallet disconnect (#728) * fix: added disconnect for wallet * fix: added autoConnect * fix: changed onClick to onGetTokenClick * fix: fixed errors * fix: added coinbase wallet * fix: img added * fix: fixed metamask not showing if not present in it --------- Co-authored-by: KlausMikhaelson --- .../src/app/ChatUITest/ChatViewComponent.tsx | 5 +- packages/uiweb/package.json | 1 + .../components/chat/ConnectButton/index.tsx | 14 +- packages/uiweb/yarn.lock | 632 +++++++++++++++++- 4 files changed, 639 insertions(+), 13 deletions(-) diff --git a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx index 51efcde71..ba0f92847 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatUITest/ChatViewComponent.tsx @@ -14,7 +14,10 @@ const ChatViewComponentTest = () => {

Chat UI Test page

- console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} autoConnect={true}/> + + console.log("BOIIII RETURNNNSSSSS")} chatId='b8e068e02fe12d7136bc2f24408835573f30c6fbf0b65ea26ab4c7055a2c85f1' limit={10} isConnected={true} autoConnect={false}/> + +
); diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 97cde6404..c01f58de0 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -8,6 +8,7 @@ "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", "@unstoppabledomains/resolution": "^8.5.0", + "@web3-onboard/coinbase": "^2.2.5", "@web3-onboard/core": "^2.21.1", "@web3-onboard/injected-wallets": "^2.10.5", "@web3-onboard/react": "^2.8.9", diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx index f562974e6..493c6dd05 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx @@ -1,9 +1,10 @@ import { IChatTheme } from '../theme'; +import coinbaseWalletModule from '@web3-onboard/coinbase' import { ConnectButtonSub } from './ConnectButton'; import { InfuraAPIKey } from '../../../config'; import { Web3OnboardProvider } from '@web3-onboard/react'; -import injectedModule from '@web3-onboard/injected-wallets'; +import injectedModule, { ProviderLabel } from '@web3-onboard/injected-wallets'; import walletConnectModule from '@web3-onboard/walletconnect' import init from '@web3-onboard/core'; import { ethers } from 'ethers'; @@ -23,6 +24,7 @@ const wcv2InitOptions = { } const walletConnect = walletConnectModule(wcv2InitOptions) +const coinbaseWalletSdk = coinbaseWalletModule({ darkMode: true }) const chains = [ { id: '0x1', @@ -61,11 +63,15 @@ const chains = [ rpcUrl: 'https://rpc.ankr.com/arbitrum' } ] -const wallets = [injectedModule(), walletConnect] + +const wallets = [injectedModule({ + displayUnavailable: [ProviderLabel.MetaMask] +}), walletConnect, coinbaseWalletSdk] + const appMetadata = { name: 'Push Protocol', - icon: 'https://files.slack.com/files-pri/T011WQBLH39-F05QWQA0MSR/pushlogoblocknative.png', + icon: 'https://push.org/static/media/PushLogoTextBlack.fa01629c2ebd2149bab979861756591d.svg', description: 'Example showcasing how to connect a wallet.', recommendedInjectedWallets: [ @@ -94,7 +100,7 @@ interface IConnectButtonCompProps { autoConnect?: boolean; } -export const ConnectButtonComp:React.FC = ({ autoConnect }) => { +export const ConnectButtonComp: React.FC = ({ autoConnect }) => { return ( diff --git a/packages/uiweb/yarn.lock b/packages/uiweb/yarn.lock index 9c6b1b231..bcc12c14b 100644 --- a/packages/uiweb/yarn.lock +++ b/packages/uiweb/yarn.lock @@ -9,6 +9,36 @@ dependencies: regenerator-runtime "^0.13.11" +"@babel/runtime@^7.17.2", "@babel/runtime@^7.22.6": + version "7.22.15" + resolved "https://registry.yarnpkg.com/@babel/runtime/-/runtime-7.22.15.tgz#38f46494ccf6cf020bd4eed7124b425e83e523b8" + integrity sha512-T0O+aa+4w0u06iNmapipJXMV4HoUir03hpx3/YqXXhu9xim3w+dVphjFWl1OH8NbZHw5Lbm9k45drDkgq2VNNA== + dependencies: + regenerator-runtime "^0.14.0" + +"@coinbase/wallet-sdk@^3.7.1": + version "3.7.2" + resolved "https://registry.yarnpkg.com/@coinbase/wallet-sdk/-/wallet-sdk-3.7.2.tgz#7a89bd9e3a06a1f26d4480d8642af33fb0c7e3aa" + integrity sha512-lIGvXMsgpsQWci/XOMQIJ2nIZ8JUy/L+bvC0wkRaYarr0YylwpXrJ2gRM3hCXPS477pkyO7N/kSiAoRgEXUdJQ== + dependencies: + "@metamask/safe-event-emitter" "2.0.0" + "@solana/web3.js" "^1.70.1" + bind-decorator "^1.0.11" + bn.js "^5.1.1" + buffer "^6.0.3" + clsx "^1.1.0" + eth-block-tracker "6.1.0" + eth-json-rpc-filters "5.1.0" + eth-rpc-errors "4.0.2" + json-rpc-engine "6.1.0" + keccak "^3.0.1" + preact "^10.5.9" + qs "^6.10.3" + rxjs "^6.6.3" + sha.js "^2.4.11" + stream-browserify "^3.0.0" + util "^0.12.4" + "@esbuild/android-arm64@0.19.2": version "0.19.2" resolved "https://registry.yarnpkg.com/@esbuild/android-arm64/-/android-arm64-0.19.2.tgz#bc35990f412a749e948b792825eef7df0ce0e073" @@ -979,6 +1009,21 @@ livepeer "2.8.0" zustand "^4.3.9" +"@metamask/safe-event-emitter@2.0.0", "@metamask/safe-event-emitter@^2.0.0": + version "2.0.0" + resolved "https://registry.yarnpkg.com/@metamask/safe-event-emitter/-/safe-event-emitter-2.0.0.tgz#af577b477c683fad17c619a78208cede06f9605c" + integrity sha512-/kSXhY692qiV1MXu6EeOZvg5nECLclxNXcKCxJ3cXQgYuRymRHpdx/t7JXfsK+JLjwA1e1c1/SBrlQYpusC29Q== + +"@metamask/utils@^3.0.1": + version "3.6.0" + resolved "https://registry.yarnpkg.com/@metamask/utils/-/utils-3.6.0.tgz#b218b969a05ca7a8093b5d1670f6625061de707d" + integrity sha512-9cIRrfkWvHblSiNDVXsjivqa9Ak0RYo/1H6tqTqTbAx+oBK2Sva0lWDHxGchOqA7bySGUJKAWSNJvH6gdHZ0gQ== + dependencies: + "@types/debug" "^4.1.7" + debug "^4.3.4" + semver "^7.3.8" + superstruct "^1.0.3" + "@motionone/animation@^10.15.1": version "10.15.1" resolved "https://registry.yarnpkg.com/@motionone/animation/-/animation-10.15.1.tgz#4a85596c31cbc5100ae8eb8b34c459fb0ccf6807" @@ -1048,6 +1093,18 @@ "@motionone/dom" "^10.16.2" tslib "^2.3.1" +"@noble/curves@^1.0.0": + version "1.2.0" + resolved "https://registry.yarnpkg.com/@noble/curves/-/curves-1.2.0.tgz#92d7e12e4e49b23105a2555c6984d41733d65c35" + integrity sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw== + dependencies: + "@noble/hashes" "1.3.2" + +"@noble/hashes@1.3.2", "@noble/hashes@^1.3.1": + version "1.3.2" + resolved "https://registry.yarnpkg.com/@noble/hashes/-/hashes-1.3.2.tgz#6f26dbc8fbc7205873ce3cee2f690eba0d421b39" + integrity sha512-MVC8EAQp7MvEcm30KWENFjgR+Mkmf+D189XJTkFIlwohU5hcBbn1ZkKq7KVTi2Hme3PMGF390DaL52beVrIihQ== + "@pushprotocol/socket@^0.5.0": version "0.5.0" resolved "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.0.tgz" @@ -1358,6 +1415,34 @@ resolved "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz" integrity sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg== +"@solana/buffer-layout@^4.0.0": + version "4.0.1" + resolved "https://registry.yarnpkg.com/@solana/buffer-layout/-/buffer-layout-4.0.1.tgz#b996235eaec15b1e0b5092a8ed6028df77fa6c15" + integrity sha512-E1ImOIAD1tBZFRdjeM4/pzTiTApC0AOBGwyAMS4fwIodCWArzJ3DWdoh8cKxeFM2fElkxBh2Aqts1BPC373rHA== + dependencies: + buffer "~6.0.3" + +"@solana/web3.js@^1.70.1": + version "1.78.5" + resolved "https://registry.yarnpkg.com/@solana/web3.js/-/web3.js-1.78.5.tgz#591cd47423cdb0b5e5cb7e8dc4dc70b2abe02f80" + integrity sha512-2ZHsDNqkKdglJQrIvJ3p2DmgS3cGnary3VJyqt9C1SPrpAtLYzcElr3xyXJOznyQTU/8AMw+GoF11lFoKbicKg== + dependencies: + "@babel/runtime" "^7.22.6" + "@noble/curves" "^1.0.0" + "@noble/hashes" "^1.3.1" + "@solana/buffer-layout" "^4.0.0" + agentkeepalive "^4.3.0" + bigint-buffer "^1.1.5" + bn.js "^5.2.1" + borsh "^0.7.0" + bs58 "^4.0.1" + buffer "6.0.3" + fast-stable-stringify "^1.0.0" + jayson "^4.1.0" + node-fetch "^2.6.12" + rpc-websockets "^7.5.1" + superstruct "^0.14.2" + "@stablelib/aead@^1.0.1": version "1.0.1" resolved "https://registry.yarnpkg.com/@stablelib/aead/-/aead-1.0.1.tgz#c4b1106df9c23d1b867eb9b276d8f42d5fc4c0c3" @@ -1536,11 +1621,47 @@ "@tanstack/query-core" "4.29.23" use-sync-external-store "^1.2.0" +"@types/connect@^3.4.33": + version "3.4.36" + resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.36.tgz#e511558c15a39cb29bd5357eebb57bd1459cd1ab" + integrity sha512-P63Zd/JUGq+PdrM1lv0Wv5SBYeA2+CORvbrXbngriYY0jzLUWfQMQQxOhjONEz/wlHOAxOdY7CY65rgQdTjq2w== + dependencies: + "@types/node" "*" + +"@types/debug@^4.1.7": + version "4.1.8" + resolved "https://registry.yarnpkg.com/@types/debug/-/debug-4.1.8.tgz#cef723a5d0a90990313faec2d1e22aee5eecb317" + integrity sha512-/vPO1EPOs306Cvhwv7KfVfYvOJqA/S/AXjaHQiJboCZzcNDb+TIJFN9/2C9DZ//ijSKWioNyUxD792QmDJ+HKQ== + dependencies: + "@types/ms" "*" + +"@types/ms@*": + version "0.7.31" + resolved "https://registry.yarnpkg.com/@types/ms/-/ms-0.7.31.tgz#31b7ca6407128a3d2bbc27fe2d21b345397f6197" + integrity sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA== + +"@types/node@*": + version "20.6.3" + resolved "https://registry.yarnpkg.com/@types/node/-/node-20.6.3.tgz#5b763b321cd3b80f6b8dde7a37e1a77ff9358dd9" + integrity sha512-HksnYH4Ljr4VQgEy2lTStbCKv/P590tmPe5HqOnv9Gprffgv5WXAY+Y5Gqniu0GGqeTCUdBnzC3QSrzPkBkAMA== + +"@types/node@^12.12.54": + version "12.20.55" + resolved "https://registry.yarnpkg.com/@types/node/-/node-12.20.55.tgz#c329cbd434c42164f846b909bd6f85b5537f6240" + integrity sha512-J8xLz7q2OFulZ2cyGTLE1TbbZcjpno7FaN6zdJNrgAdrJ+DZzh/uFR6YrTb4C+nXakvud8Q4+rbhoIWlYQbUFQ== + "@types/trusted-types@^2.0.2": version "2.0.3" resolved "https://registry.yarnpkg.com/@types/trusted-types/-/trusted-types-2.0.3.tgz#a136f83b0758698df454e328759dbd3d44555311" integrity sha512-NfQ4gyz38SL8sDNrSixxU2Os1a5xcdFxipAFxYEuLUlvU2uDwS4NUpsImcf1//SlWItCVMMLiylsxbmNMToV/g== +"@types/ws@^7.4.4": + version "7.4.7" + resolved "https://registry.yarnpkg.com/@types/ws/-/ws-7.4.7.tgz#f7c390a36f7a0679aa69de2d501319f4f8d9b702" + integrity sha512-JQbbmxZTZehdc2iszGKs5oC3NFnjeay7mtAWrdt7qNtAVK0g19muApzAy4bm9byz79xa2ZnO/BOBC2R8RC5Lww== + dependencies: + "@types/node" "*" + "@unstoppabledomains/resolution@^8.5.0": version "8.5.0" resolved "https://registry.npmjs.org/@unstoppabledomains/resolution/-/resolution-8.5.0.tgz" @@ -1943,6 +2064,14 @@ "@walletconnect/window-getters" "^1.0.1" tslib "1.14.1" +"@web3-onboard/coinbase@^2.2.5": + version "2.2.5" + resolved "https://registry.yarnpkg.com/@web3-onboard/coinbase/-/coinbase-2.2.5.tgz#fb7a57e5456323c0ee107ce48ea0cc80acbb6e07" + integrity sha512-mEiaK+K+nB2TwxUpkyAZmb4AHguymsJrHFbsZDdAolFTgZizCSjGHBhYlCEfxLL4fh3CpUryTa/AaNxxhdG6OQ== + dependencies: + "@coinbase/wallet-sdk" "^3.7.1" + "@web3-onboard/common" "^2.3.3" + "@web3-onboard/common@^2.3.3": version "2.3.3" resolved "https://registry.yarnpkg.com/@web3-onboard/common/-/common-2.3.3.tgz#02096e967dbed272c0637cda955902b96a0fce06" @@ -2024,6 +2153,14 @@ resolved "https://registry.yarnpkg.com/@web3-react/types/-/types-6.0.7.tgz#34a6204224467eedc6123abaf55fbb6baeb2809f" integrity sha512-ofGmfDhxmNT1/P/MgVa8IKSkCStFiyvXe+U5tyZurKdrtTDFU+wJ/LxClPDtFerWpczNFPUSrKcuhfPX1sI6+A== +JSONStream@^1.3.5: + version "1.3.5" + resolved "https://registry.yarnpkg.com/JSONStream/-/JSONStream-1.3.5.tgz#3208c1f08d3a4d99261ab64f92302bc15e111ca0" + integrity sha512-E+iruNOY8VV9s4JEbe1aNEm6MiszPRr/UfcHMz0TQh1BXSxHK+ASV1R6W4HpjBhSeS+54PIsAMCBmwD06LLsqQ== + dependencies: + jsonparse "^1.2.0" + through ">=2.2.7 <3" + aes-js@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.0.0.tgz#e21df10ad6c2053295bcbb8dab40b09dbea87e4d" @@ -2034,6 +2171,13 @@ aes-js@^3.1.2: resolved "https://registry.yarnpkg.com/aes-js/-/aes-js-3.1.2.tgz#db9aabde85d5caabbfc0d4f2a4446960f627146a" integrity sha512-e5pEa2kBnBOgR4Y/p20pskXI74UEz7de8ZGVo58asOtvSVG5YAbJeELPZxOmt+Bnz3rX753YKhfIn4X4l1PPRQ== +agentkeepalive@^4.3.0: + version "4.5.0" + resolved "https://registry.yarnpkg.com/agentkeepalive/-/agentkeepalive-4.5.0.tgz#2673ad1389b3c418c5a20c5d7364f93ca04be923" + integrity sha512-5GG/5IbQQpC9FpkRGsSvZI5QYeSCzlJHdpBQntCsuTOxhKD8lqKhrleg2Yi7yvMIf82Ycmmqln9U8V9qwEiJew== + dependencies: + humanize-ms "^1.2.1" + ansi-regex@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/ansi-regex/-/ansi-regex-4.1.1.tgz#164daac87ab2d6f6db3a29875e2d1766582dabed" @@ -2065,11 +2209,30 @@ aria-hidden@^1.1.1: dependencies: tslib "^2.0.0" +async-mutex@^0.2.6: + version "0.2.6" + resolved "https://registry.yarnpkg.com/async-mutex/-/async-mutex-0.2.6.tgz#0d7a3deb978bc2b984d5908a2038e1ae2e54ff40" + integrity sha512-Hs4R+4SPgamu6rSGW8C7cV9gaWUKEHykfzCCvIRuaVv636Ju10ZdeUbvb4TBEW0INuq2DHZqXbK4Nd3yG4RaRw== + dependencies: + tslib "^2.0.0" + atomic-sleep@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/atomic-sleep/-/atomic-sleep-1.0.0.tgz#eb85b77a601fc932cfe432c5acd364a9e2c9075b" integrity sha512-kNOjDqAh7px0XWNI+4QbzoiR/nTkHAWNud2uvnJquD1/x5a7EQZMJT0AczqK0Qn67oY/TTQ1LbUKajZpp3I9tQ== +available-typed-arrays@^1.0.5: + version "1.0.5" + resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz#92f95616501069d07d10edb2fc37d3e1c65123b7" + integrity sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw== + +base-x@^3.0.2: + version "3.0.9" + resolved "https://registry.yarnpkg.com/base-x/-/base-x-3.0.9.tgz#6349aaabb58526332de9f60995e548a53fe21320" + integrity sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ== + dependencies: + safe-buffer "^5.0.1" + base64-js@^1.3.1: version "1.5.1" resolved "https://registry.yarnpkg.com/base64-js/-/base64-js-1.5.1.tgz#1b1b440160a5bf7ad40b650f095963481903930a" @@ -2080,11 +2243,30 @@ bech32@1.1.4: resolved "https://registry.yarnpkg.com/bech32/-/bech32-1.1.4.tgz#e38c9f37bf179b8eb16ae3a772b40c356d4832e9" integrity sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ== +bigint-buffer@^1.1.5: + version "1.1.5" + resolved "https://registry.yarnpkg.com/bigint-buffer/-/bigint-buffer-1.1.5.tgz#d038f31c8e4534c1f8d0015209bf34b4fa6dd442" + integrity sha512-trfYco6AoZ+rKhKnxA0hgX0HAbVP/s808/EuDSe2JDzUnCp/xAsli35Orvk67UrTEcwuxZqYZDmfA2RXJgxVvA== + dependencies: + bindings "^1.3.0" + bignumber.js@^9.0.0, bignumber.js@^9.1.0: version "9.1.2" resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.1.2.tgz#b7c4242259c008903b13707983b5f4bbd31eda0c" integrity sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug== +bind-decorator@^1.0.11: + version "1.0.11" + resolved "https://registry.yarnpkg.com/bind-decorator/-/bind-decorator-1.0.11.tgz#e41bc06a1f65dd9cec476c91c5daf3978488252f" + integrity sha512-yzkH0uog6Vv/vQ9+rhSKxecnqGUZHYncg7qS7voz3Q76+TAi1SGiOKk2mlOvusQnFz9Dc4BC/NMkeXu11YgjJg== + +bindings@^1.3.0: + version "1.5.0" + resolved "https://registry.yarnpkg.com/bindings/-/bindings-1.5.0.tgz#10353c9e945334bc0511a6d90b38fbc7c9c504df" + integrity sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ== + dependencies: + file-uri-to-path "1.0.0" + bn.js@4.11.8: version "4.11.8" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f" @@ -2095,7 +2277,7 @@ bn.js@^4.11.9, bn.js@^4.4.0: resolved "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== -bn.js@^5.2.1: +bn.js@^5.1.1, bn.js@^5.2.0, bn.js@^5.2.1: version "5.2.1" resolved "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz" integrity sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ== @@ -2110,6 +2292,15 @@ bnc-sdk@^4.6.7: rxjs "^6.6.3" sturdy-websocket "^0.1.12" +borsh@^0.7.0: + version "0.7.0" + resolved "https://registry.yarnpkg.com/borsh/-/borsh-0.7.0.tgz#6e9560d719d86d90dc589bca60ffc8a6c51fec2a" + integrity sha512-CLCsZGIBCFnPtkNnieW/a8wmreDmfUtjU2m9yHrzPXIlNbqVs0AQrSatSG6vdNYUqdc83tkQi2eHfF98ubzQLA== + dependencies: + bn.js "^5.2.0" + bs58 "^4.0.0" + text-encoding-utf-8 "^1.0.2" + bowser@^2.11.0: version "2.11.0" resolved "https://registry.yarnpkg.com/bowser/-/bowser-2.11.0.tgz#5ca3c35757a7aa5771500c70a73a9f91ef420a8f" @@ -2120,6 +2311,13 @@ brorand@^1.1.0: resolved "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz" integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== +bs58@^4.0.0, bs58@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/bs58/-/bs58-4.0.1.tgz#be161e76c354f6f788ae4071f63f34e8c4f0a42a" + integrity sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw== + dependencies: + base-x "^3.0.2" + buffer-alloc-unsafe@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/buffer-alloc-unsafe/-/buffer-alloc-unsafe-1.1.0.tgz#bd7dc26ae2972d0eda253be061dba992349c19f0" @@ -2143,6 +2341,14 @@ buffer-from@^1.1.1, buffer-from@^1.1.2: resolved "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz" integrity sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ== +buffer@6.0.3, buffer@^6.0.3, buffer@~6.0.3: + version "6.0.3" + resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" + integrity sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA== + dependencies: + base64-js "^1.3.1" + ieee754 "^1.2.1" + buffer@^5.4.3: version "5.7.1" resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.7.1.tgz#ba62e7c13133053582197160851a8f648e99eed0" @@ -2151,6 +2357,21 @@ buffer@^5.4.3: base64-js "^1.3.1" ieee754 "^1.1.13" +bufferutil@^4.0.1: + version "4.0.7" + resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.7.tgz#60c0d19ba2c992dd8273d3f73772ffc894c153ad" + integrity sha512-kukuqc39WOHtdxtw4UScxF/WVnMFVSQVKhtx3AjZJzhd0RGZZldcrfSEbVsWWe6KNH253574cq5F+wpv0G9pJw== + dependencies: + node-gyp-build "^4.3.0" + +call-bind@^1.0.0, call-bind@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.2.tgz#b1d4e89e688119c3c9a903ad30abb2f6a919be3c" + integrity sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA== + dependencies: + function-bind "^1.1.1" + get-intrinsic "^1.0.2" + camelcase@^5.0.0: version "5.3.1" resolved "https://registry.yarnpkg.com/camelcase/-/camelcase-5.3.1.tgz#e3c9b31569e106811df242f715725a1f4c494320" @@ -2185,7 +2406,7 @@ cliui@^6.0.0: strip-ansi "^6.0.0" wrap-ansi "^6.2.0" -clsx@^1.1.1, clsx@^1.2.1: +clsx@^1.1.0, clsx@^1.1.1, clsx@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz" integrity sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg== @@ -2222,6 +2443,11 @@ combine-errors@^3.0.3: custom-error-instance "2.1.1" lodash.uniqby "4.5.0" +commander@^2.20.3: + version "2.20.3" + resolved "https://registry.yarnpkg.com/commander/-/commander-2.20.3.tgz#fd485e84c03eb4881c20722ba48035e8531aeb33" + integrity sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ== + copy-to-clipboard@^3.3.1: version "3.3.3" resolved "https://registry.yarnpkg.com/copy-to-clipboard/-/copy-to-clipboard-3.3.3.tgz#55ac43a1db8ae639a4bd99511c148cdd1b83a1b0" @@ -2278,7 +2504,7 @@ date-fns@^2.28.0: dependencies: "@babel/runtime" "^7.21.0" -debug@~4.3.1, debug@~4.3.2: +debug@^4.3.4, debug@~4.3.1, debug@~4.3.2: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== @@ -2300,6 +2526,11 @@ deepmerge@^4.2.2: resolved "https://registry.yarnpkg.com/deepmerge/-/deepmerge-4.3.1.tgz#44b5f2147cd3b00d4b56137685966f26fd25dd4a" integrity sha512-3sUqbMEc77XqpdNO7FRyRog+eW3ph+GYCbj+rK+uYyRMuwsVy0rMiVtPn+QJlKFvWP/1PYpapqYn0Me2knFn+A== +delay@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/delay/-/delay-5.0.0.tgz#137045ef1b96e5071060dd5be60bf9334436bd1d" + integrity sha512-ReEBKkIfe4ya47wlPYf/gu5ib6yUG0/Aez0JQZQz94kiWtRQvZIQbTiehsnwHvLSWJnQdhVeqYue7Id1dKr0qw== + detect-browser@5.2.0: version "5.2.0" resolved "https://registry.yarnpkg.com/detect-browser/-/detect-browser-5.2.0.tgz#c9cd5afa96a6a19fda0bbe9e9be48a6b6e1e9c97" @@ -2446,6 +2677,18 @@ es6-iterator@^2.0.3: es5-ext "^0.10.35" es6-symbol "^3.1.1" +es6-promise@^4.0.3: + version "4.2.8" + resolved "https://registry.yarnpkg.com/es6-promise/-/es6-promise-4.2.8.tgz#4eb21594c972bc40553d276e510539143db53e0a" + integrity sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w== + +es6-promisify@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/es6-promisify/-/es6-promisify-5.0.0.tgz#5109d62f3e56ea967c4b63505aef08291c8a5203" + integrity sha512-C+d6UdsYDk0lMebHNR4S2NybQMMngAOnOwYBQjTOiv0MkoJMP0Myw2mgpDLBcpfCmRLxyFqYhS/CfOENq4SJhQ== + dependencies: + es6-promise "^4.0.3" + es6-symbol@^3.1.1, es6-symbol@^3.1.3: version "3.1.3" resolved "https://registry.yarnpkg.com/es6-symbol/-/es6-symbol-3.1.3.tgz#bad5d3c1bcdac28269f4cb331e431c78ac705d18" @@ -2497,6 +2740,49 @@ estree-walker@^2: resolved "https://registry.yarnpkg.com/estree-walker/-/estree-walker-2.0.2.tgz#52f010178c2a4c117a7757cfe942adb7d2da4cac" integrity sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w== +eth-block-tracker@6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/eth-block-tracker/-/eth-block-tracker-6.1.0.tgz#0481f97bbb88a100b9d45806fe7e37af741cbefc" + integrity sha512-K9SY8+/xMBi4M5HHTDdxnpEqEEGjbNpzHFqvxyjMZej8InV/B+CkFRKM6W+uvrFJ7m8Zd1E0qUkseU3vdIDFYQ== + dependencies: + "@metamask/safe-event-emitter" "^2.0.0" + "@metamask/utils" "^3.0.1" + json-rpc-random-id "^1.0.1" + pify "^3.0.0" + +eth-json-rpc-filters@5.1.0: + version "5.1.0" + resolved "https://registry.yarnpkg.com/eth-json-rpc-filters/-/eth-json-rpc-filters-5.1.0.tgz#f0c2aeaec2a45e2dc6ca1b9843d8e85447821427" + integrity sha512-fos+9xmoa1A2Ytsc9eYof17r81BjdJOUcGcgZn4K/tKdCCTb+a8ytEtwlu1op5qsXFDlgGmstTELFrDEc89qEQ== + dependencies: + "@metamask/safe-event-emitter" "^2.0.0" + async-mutex "^0.2.6" + eth-query "^2.1.2" + json-rpc-engine "^6.1.0" + pify "^5.0.0" + +eth-query@^2.1.2: + version "2.1.2" + resolved "https://registry.yarnpkg.com/eth-query/-/eth-query-2.1.2.tgz#d6741d9000106b51510c72db92d6365456a6da5e" + integrity sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA== + dependencies: + json-rpc-random-id "^1.0.0" + xtend "^4.0.1" + +eth-rpc-errors@4.0.2: + version "4.0.2" + resolved "https://registry.yarnpkg.com/eth-rpc-errors/-/eth-rpc-errors-4.0.2.tgz#11bc164e25237a679061ac05b7da7537b673d3b7" + integrity sha512-n+Re6Gu8XGyfFy1it0AwbD1x0MUzspQs0D5UiPs1fFPCr6WAwZM+vbIhXheBFrpgosqN9bs5PqlB4Q61U/QytQ== + dependencies: + fast-safe-stringify "^2.0.6" + +eth-rpc-errors@^4.0.2: + version "4.0.3" + resolved "https://registry.yarnpkg.com/eth-rpc-errors/-/eth-rpc-errors-4.0.3.tgz#6ddb6190a4bf360afda82790bb7d9d5e724f423a" + integrity sha512-Z3ymjopaoft7JDoxZcEb3pwdGh7yiYMhOwm2doUt6ASXlMavpNlK6Cre0+IMl2VSGyEU9rkiperQhp5iRxn5Pg== + dependencies: + fast-safe-stringify "^2.0.6" + ethers@5.5.3: version "5.5.3" resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.5.3.tgz#1e361516711c0c3244b6210e7e3ecabf0c75fca0" @@ -2630,11 +2916,31 @@ ext@^1.1.2: dependencies: type "^2.7.2" +eyes@^0.1.8: + version "0.1.8" + resolved "https://registry.yarnpkg.com/eyes/-/eyes-0.1.8.tgz#62cf120234c683785d902348a800ef3e0cc20bc0" + integrity sha512-GipyPsXO1anza0AOZdy69Im7hGFCNB7Y/NGjDlZGJ3GJJLtwNSb2vrzYrTYJRrRloVx7pl+bhUaTB8yiccPvFQ== + fast-redact@^3.0.0: version "3.3.0" resolved "https://registry.yarnpkg.com/fast-redact/-/fast-redact-3.3.0.tgz#7c83ce3a7be4898241a46560d51de10f653f7634" integrity sha512-6T5V1QK1u4oF+ATxs1lWUmlEk6P2T9HqJG3e2DnHOdVgZy2rFJBoEnrIedcTXlkAHU/zKC+7KETJ+KGGKwxgMQ== +fast-safe-stringify@^2.0.6: + version "2.1.1" + resolved "https://registry.yarnpkg.com/fast-safe-stringify/-/fast-safe-stringify-2.1.1.tgz#c406a83b6e70d9e35ce3b30a81141df30aeba884" + integrity sha512-W+KJc2dmILlPplD/H4K9l9LcAHAfPtP6BY84uVLXQ6Evcz9Lcg33Y2z1IVblT6xdY54PXYVHEv+0Wpq8Io6zkA== + +fast-stable-stringify@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/fast-stable-stringify/-/fast-stable-stringify-1.0.0.tgz#5c5543462b22aeeefd36d05b34e51c78cb86d313" + integrity sha512-wpYMUmFu5f00Sm0cj2pfivpmawLZ0NKdviQ4w9zJeR8JVtOpOxHmLaJuj0vxvGqMJQWyP/COUkF75/57OKyRag== + +file-uri-to-path@1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz#553a7b8446ff6f684359c445f1e37a05dacc33dd" + integrity sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw== + filter-obj@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/filter-obj/-/filter-obj-1.1.0.tgz#9b311112bc6c6127a16e016c6c5d7f19e0805c5b" @@ -2660,11 +2966,33 @@ font-awesome@^4.7.0: resolved "https://registry.npmjs.org/font-awesome/-/font-awesome-4.7.0.tgz" integrity sha512-U6kGnykA/6bFmg1M/oT9EkFeIYv7JlX3bozwQJWiiLz6L0w3F5vBVPxHlwyX/vtNq1ckcpRKOB9f2Qal/VtFpg== +for-each@^0.3.3: + version "0.3.3" + resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" + integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== + dependencies: + is-callable "^1.1.3" + +function-bind@^1.1.1: + version "1.1.1" + resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== + get-caller-file@^2.0.1: version "2.0.5" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== +get-intrinsic@^1.0.2, get-intrinsic@^1.1.3: + version "1.2.1" + resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" + integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== + dependencies: + function-bind "^1.1.1" + has "^1.0.3" + has-proto "^1.0.1" + has-symbols "^1.0.3" + get-nonce@^1.0.0: version "1.0.1" resolved "https://registry.npmjs.org/get-nonce/-/get-nonce-1.0.1.tgz" @@ -2685,11 +3013,42 @@ globrex@^0.1.2: resolved "https://registry.yarnpkg.com/globrex/-/globrex-0.1.2.tgz#dd5d9ec826232730cd6793a5e33a9302985e6098" integrity sha512-uHJgbwAMwNFf5mLst7IWLNg14x1CkeqglJb/K3doi4dw6q2IvAAmM/Y81kevy83wP+Sst+nutFTYOGg3d1lsxg== +gopd@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" + integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== + dependencies: + get-intrinsic "^1.1.3" + graceful-fs@^4.2.4: version "4.2.11" resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== +has-proto@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" + integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== + +has-symbols@^1.0.2, has-symbols@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" + integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== + +has-tostringtag@^1.0.0: + version "1.0.0" + resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" + integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== + dependencies: + has-symbols "^1.0.2" + +has@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== + dependencies: + function-bind "^1.1.1" + hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3, hash.js@^1.1.7: version "1.1.7" resolved "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" @@ -2745,12 +3104,19 @@ htmlparser2@7.2.0: domutils "^2.8.0" entities "^3.0.1" -ieee754@^1.1.13: +humanize-ms@^1.2.1: + version "1.2.1" + resolved "https://registry.yarnpkg.com/humanize-ms/-/humanize-ms-1.2.1.tgz#c46e3159a293f6b896da29316d8b6fe8bb79bbed" + integrity sha512-Fl70vYtsAFb/C06PTS9dZBo7ihau+Tu/DNCk/OyHhea07S+aeMWpFFkUaXRa8fI+ScZbEI8dfSxwY7gxZ9SAVQ== + dependencies: + ms "^2.0.0" + +ieee754@^1.1.13, ieee754@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== -inherits@^2.0.3, inherits@^2.0.4: +inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.4: version "2.0.4" resolved "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== @@ -2777,6 +3143,19 @@ invariant@^2.2.4: dependencies: loose-envify "^1.0.0" +is-arguments@^1.0.4: + version "1.1.1" + resolved "https://registry.yarnpkg.com/is-arguments/-/is-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" + integrity sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA== + dependencies: + call-bind "^1.0.2" + has-tostringtag "^1.0.0" + +is-callable@^1.1.3: + version "1.2.7" + resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" + integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== + is-fullwidth-code-point@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-2.0.0.tgz#a3b30a5c4f199183167aaab93beefae3ddfb654f" @@ -2787,6 +3166,13 @@ is-fullwidth-code-point@^3.0.0: resolved "https://registry.yarnpkg.com/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz#f116f8064fe90b3f7844a38997c0b75051269f1d" integrity sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg== +is-generator-function@^1.0.7: + version "1.0.10" + resolved "https://registry.yarnpkg.com/is-generator-function/-/is-generator-function-1.0.10.tgz#f1558baf1ac17e0deea7c0415c438351ff2b3c72" + integrity sha512-jsEjy9l3yiXEQ+PsXdmBwEPcOxaXWLspKdplFUVI9vq1iZgIekeC0L167qeu86czQaxed3q/Uzuw0swL0irL8A== + dependencies: + has-tostringtag "^1.0.0" + is-promise@^2.2.2: version "2.2.2" resolved "https://registry.yarnpkg.com/is-promise/-/is-promise-2.2.2.tgz#39ab959ccbf9a774cf079f7b40c7a26f763135f1" @@ -2797,6 +3183,13 @@ is-stream@^2.0.0: resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== +is-typed-array@^1.1.3: + version "1.1.12" + resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.12.tgz#d0bab5686ef4a76f7a73097b95470ab199c57d4a" + integrity sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg== + dependencies: + which-typed-array "^1.1.11" + is-typedarray@1.0.0, is-typedarray@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" @@ -2807,6 +3200,29 @@ isarray@^2.0.1: resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723" integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== +isomorphic-ws@^4.0.1: + version "4.0.1" + resolved "https://registry.yarnpkg.com/isomorphic-ws/-/isomorphic-ws-4.0.1.tgz#55fd4cd6c5e6491e76dc125938dd863f5cd4f2dc" + integrity sha512-BhBvN2MBpWTaSHdWRb/bwdZJ1WaehQ2L1KngkCkfLUGF0mAWAT1sQUQacEmQ0jXkFw/czDXPNQSL5u2/Krsz1w== + +jayson@^4.1.0: + version "4.1.0" + resolved "https://registry.yarnpkg.com/jayson/-/jayson-4.1.0.tgz#60dc946a85197317f2b1439d672a8b0a99cea2f9" + integrity sha512-R6JlbyLN53Mjku329XoRT2zJAE6ZgOQ8f91ucYdMCD4nkGCF9kZSrcGXpHIU4jeKj58zUZke2p+cdQchU7Ly7A== + dependencies: + "@types/connect" "^3.4.33" + "@types/node" "^12.12.54" + "@types/ws" "^7.4.4" + JSONStream "^1.3.5" + commander "^2.20.3" + delay "^5.0.0" + es6-promisify "^5.0.0" + eyes "^0.1.8" + isomorphic-ws "^4.0.1" + json-stringify-safe "^5.0.1" + uuid "^8.3.2" + ws "^7.4.5" + joi@17.9.1: version "17.9.1" resolved "https://registry.yarnpkg.com/joi/-/joi-17.9.1.tgz#74899b9fa3646904afa984a11df648eca66c9018" @@ -2833,6 +3249,38 @@ js-sha3@0.8.0: resolved "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz" integrity sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ== +json-rpc-engine@6.1.0, json-rpc-engine@^6.1.0: + version "6.1.0" + resolved "https://registry.yarnpkg.com/json-rpc-engine/-/json-rpc-engine-6.1.0.tgz#bf5ff7d029e1c1bf20cb6c0e9f348dcd8be5a393" + integrity sha512-NEdLrtrq1jUZyfjkr9OCz9EzCNhnRyWtt1PAnvnhwy6e8XETS0Dtc+ZNCO2gvuAoKsIn2+vCSowXTYE4CkgnAQ== + dependencies: + "@metamask/safe-event-emitter" "^2.0.0" + eth-rpc-errors "^4.0.2" + +json-rpc-random-id@^1.0.0, json-rpc-random-id@^1.0.1: + version "1.0.1" + resolved "https://registry.yarnpkg.com/json-rpc-random-id/-/json-rpc-random-id-1.0.1.tgz#ba49d96aded1444dbb8da3d203748acbbcdec8c8" + integrity sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA== + +json-stringify-safe@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" + integrity sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA== + +jsonparse@^1.2.0: + version "1.3.1" + resolved "https://registry.yarnpkg.com/jsonparse/-/jsonparse-1.3.1.tgz#3f4dae4a91fac315f71062f8521cc239f1366280" + integrity sha512-POQXvpdL69+CluYsillJ7SUhKvytYjW9vG/GKpnf+xP8UWgYEM/RaMzHHofbALDiKbbP1W8UEYmgGl39WkPZsg== + +keccak@^3.0.1: + version "3.0.4" + resolved "https://registry.yarnpkg.com/keccak/-/keccak-3.0.4.tgz#edc09b89e633c0549da444432ecf062ffadee86d" + integrity sha512-3vKuW0jV8J3XNTzvfyicFR5qvxrSAGl7KIhvgOu5cmWwM7tZRj3fMbj/pfIf4be7aznbc+prBWGjywox/g2Y6Q== + dependencies: + node-addon-api "^2.0.0" + node-gyp-build "^4.2.0" + readable-stream "^3.6.0" + keyvaluestorage-interface@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/keyvaluestorage-interface/-/keyvaluestorage-interface-1.0.0.tgz#13ebdf71f5284ad54be94bd1ad9ed79adad515ff" @@ -2974,6 +3422,13 @@ loose-envify@^1.0.0: dependencies: js-tokens "^3.0.0 || ^4.0.0" +lru-cache@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-6.0.0.tgz#6d6fe6570ebd96aaf90fcad1dafa3b2566db3a94" + integrity sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA== + dependencies: + yallist "^4.0.0" + lru-queue@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/lru-queue/-/lru-queue-0.1.0.tgz#2738bd9f0d3cf4f84490c5736c48699ac632cda3" @@ -3032,6 +3487,11 @@ ms@2.1.2: resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== +ms@^2.0.0: + version "2.1.3" + resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" + integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== + ms@^3.0.0-canary.1: version "3.0.0-canary.1" resolved "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz" @@ -3057,6 +3517,11 @@ next-tick@1, next-tick@^1.1.0: resolved "https://registry.yarnpkg.com/next-tick/-/next-tick-1.1.0.tgz#1836ee30ad56d67ef281b22bd199f709449b35eb" integrity sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ== +node-addon-api@^2.0.0: + version "2.0.2" + resolved "https://registry.yarnpkg.com/node-addon-api/-/node-addon-api-2.0.2.tgz#432cfa82962ce494b132e9d72a15b29f71ff5d32" + integrity sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA== + node-fetch@^2.6.12: version "2.6.12" resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz" @@ -3064,6 +3529,16 @@ node-fetch@^2.6.12: dependencies: whatwg-url "^5.0.0" +node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: + version "4.6.1" + resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.6.1.tgz#24b6d075e5e391b8d5539d98c7fc5c210cac8a3e" + integrity sha512-24vnklJmyRS8ViBNI8KbtK/r/DmXQMRiOMXTNz2nrTnAYUwjmEEbnnpB/+kt+yWRv73bPsSPRFddrcIbAxSiMQ== + +object-inspect@^1.9.0: + version "1.12.3" + resolved "https://registry.yarnpkg.com/object-inspect/-/object-inspect-1.12.3.tgz#ba62dffd67ee256c8c086dfae69e016cd1f198b9" + integrity sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g== + on-exit-leak-free@^0.2.0: version "0.2.0" resolved "https://registry.yarnpkg.com/on-exit-leak-free/-/on-exit-leak-free-0.2.0.tgz#b39c9e3bf7690d890f4861558b0d7b90a442d209" @@ -3112,6 +3587,16 @@ path-exists@^4.0.0: resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-4.0.0.tgz#513bdbe2d3b95d7762e8c1137efa195c6c61b5b3" integrity sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w== +pify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-3.0.0.tgz#e5a4acd2c101fdf3d9a4d07f0dbc4db49dd28176" + integrity sha512-C3FsVNH1udSEX48gGX1xfvwTWfsYWj5U+8/uK15BGzIGrKoUpghX8hWZwa/OFnakBiiVNmBvemTJR5mcy7iPcg== + +pify@^5.0.0: + version "5.0.0" + resolved "https://registry.yarnpkg.com/pify/-/pify-5.0.0.tgz#1f5eca3f5e87ebec28cc6d54a0e4aaf00acc127f" + integrity sha512-eW/gHNMlxdSP6dmG6uJip6FXN0EQBwm2clYYd8Wul42Cwu/DK8HEftzsapcNdYe2MfLiIwZqsDk2RDEsTE79hA== + pino-abstract-transport@v0.5.0: version "0.5.0" resolved "https://registry.yarnpkg.com/pino-abstract-transport/-/pino-abstract-transport-0.5.0.tgz#4b54348d8f73713bfd14e3dc44228739aa13d9c0" @@ -3157,6 +3642,11 @@ preact@10.4.1: resolved "https://registry.yarnpkg.com/preact/-/preact-10.4.1.tgz#9b3ba020547673a231c6cf16f0fbaef0e8863431" integrity sha512-WKrRpCSwL2t3tpOOGhf2WfTpcmbpxaWtDbdJdKdjd0aEiTkvOmS4NBkG6kzlaAHI9AkQ3iVqbFWM3Ei7mZ4o1Q== +preact@^10.5.9: + version "10.17.1" + resolved "https://registry.yarnpkg.com/preact/-/preact-10.17.1.tgz#0a1b3c658c019e759326b9648c62912cf5c2dde1" + integrity sha512-X9BODrvQ4Ekwv9GURm9AKAGaomqXmip7NQTZgY7gcNmr7XE83adOMJvd3N42id1tMFU7ojiynRsYnY6/BRFxLA== + process-warning@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/process-warning/-/process-warning-1.0.0.tgz#980a0b25dc38cd6034181be4b7726d89066b4616" @@ -3199,6 +3689,13 @@ qrcode@1.5.3: pngjs "^5.0.0" yargs "^15.3.1" +qs@^6.10.3: + version "6.11.2" + resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" + integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== + dependencies: + side-channel "^1.0.4" + query-string@6.13.5: version "6.13.5" resolved "https://registry.yarnpkg.com/query-string/-/query-string-6.13.5.tgz#99e95e2fb7021db90a6f373f990c0c814b3812d8" @@ -3287,7 +3784,7 @@ react-twitter-embed@^4.0.4: dependencies: scriptjs "^2.5.9" -readable-stream@^3.1.1: +readable-stream@^3.1.1, readable-stream@^3.5.0, readable-stream@^3.6.0: version "3.6.2" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== @@ -3306,6 +3803,11 @@ regenerator-runtime@^0.13.11: resolved "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.11.tgz" integrity sha512-kY1AZVr2Ra+t+piVaJ4gxaFaReZVH40AKNo7UCX6W+dEwBo/2oZJzqfuN1qLq1oL45o56cPaTXELwrTh8Fpggg== +regenerator-runtime@^0.14.0: + version "0.14.0" + resolved "https://registry.yarnpkg.com/regenerator-runtime/-/regenerator-runtime-0.14.0.tgz#5e19d68eb12d486f797e15a3c6a918f7cec5eb45" + integrity sha512-srw17NI0TUWHuGa5CFGGmhfNIeja30WMBfbslPNhf6JrqQlLN5gcrvig1oqPxiVaXb0oW0XRKtH6Nngs5lKCIA== + require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" @@ -3326,6 +3828,19 @@ retry@^0.12.0: resolved "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz" integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== +rpc-websockets@^7.5.1: + version "7.6.0" + resolved "https://registry.yarnpkg.com/rpc-websockets/-/rpc-websockets-7.6.0.tgz#d3f4c0dac108ca35566b0e31552c32e58928cd04" + integrity sha512-Jgcs8q6t8Go98dEulww1x7RysgTkzpCMelVxZW4hvuyFtOGpeUz9prpr2KjUa/usqxgFCd9Tu3+yhHEP9GVmiQ== + dependencies: + "@babel/runtime" "^7.17.2" + eventemitter3 "^4.0.7" + uuid "^8.3.2" + ws "^8.5.0" + optionalDependencies: + bufferutil "^4.0.1" + utf-8-validate "^5.0.2" + rxjs@^6.6.3: version "6.6.7" resolved "https://registry.yarnpkg.com/rxjs/-/rxjs-6.6.7.tgz#90ac018acabf491bf65044235d5863c4dab804c9" @@ -3347,7 +3862,7 @@ sade@^1.8.1: dependencies: mri "^1.1.0" -safe-buffer@^5.1.0, safe-buffer@~5.2.0: +safe-buffer@^5.0.1, safe-buffer@^5.1.0, safe-buffer@~5.2.0: version "5.2.1" resolved "https://registry.yarnpkg.com/safe-buffer/-/safe-buffer-5.2.1.tgz#1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6" integrity sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ== @@ -3372,11 +3887,35 @@ scrypt-js@3.0.1: resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-3.0.1.tgz#d314a57c2aef69d1ad98a138a21fe9eafa9ee312" integrity sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA== +semver@^7.3.8: + version "7.5.4" + resolved "https://registry.yarnpkg.com/semver/-/semver-7.5.4.tgz#483986ec4ed38e1c6c48c34894a9182dbff68a6e" + integrity sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA== + dependencies: + lru-cache "^6.0.0" + set-blocking@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/set-blocking/-/set-blocking-2.0.0.tgz#045f9782d011ae9a6803ddd382b24392b3d890f7" integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== +sha.js@^2.4.11: + version "2.4.11" + resolved "https://registry.yarnpkg.com/sha.js/-/sha.js-2.4.11.tgz#37a5cf0b81ecbc6943de109ba2960d1b26584ae7" + integrity sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ== + dependencies: + inherits "^2.0.1" + safe-buffer "^5.0.1" + +side-channel@^1.0.4: + version "1.0.4" + resolved "https://registry.yarnpkg.com/side-channel/-/side-channel-1.0.4.tgz#efce5c8fdc104ee751b25c58d4290011fa5ea2cf" + integrity sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw== + dependencies: + call-bind "^1.0.0" + get-intrinsic "^1.0.2" + object-inspect "^1.9.0" + signal-exit@^3.0.2: version "3.0.7" resolved "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz" @@ -3417,6 +3956,14 @@ split2@^4.0.0: resolved "https://registry.yarnpkg.com/split2/-/split2-4.2.0.tgz#c9c5920904d148bab0b9f67145f245a86aadbfa4" integrity sha512-UcjcJOWknrNkF6PLX83qcHM6KHgVKNkV62Y8a5uYDVv9ydGQVwAHMKqHdJje1VTWpljG0WYpCDhrCdAOYH4TWg== +stream-browserify@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/stream-browserify/-/stream-browserify-3.0.0.tgz#22b0a2850cdf6503e73085da1fc7b7d0c2122f2f" + integrity sha512-H73RAHsVBapbim0tU2JwwOiXUj+fikfiaoYAKHF3VJfA0pe2BCzkhAHBlLG6REzE+2WNZcxOXjK7lkso+9euLA== + dependencies: + inherits "~2.0.4" + readable-stream "^3.5.0" + stream-shift@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/stream-shift/-/stream-shift-1.0.1.tgz#d7088281559ab2778424279b0877da3c392d5a3d" @@ -3487,6 +4034,16 @@ style-to-object@0.3.0: dependencies: inline-style-parser "0.1.1" +superstruct@^0.14.2: + version "0.14.2" + resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-0.14.2.tgz#0dbcdf3d83676588828f1cf5ed35cda02f59025b" + integrity sha512-nPewA6m9mR3d6k7WkZ8N8zpTWfenFH3q9pA2PkuiZxINr9DKB2+40wEQf0ixn8VaGuJ78AB6iWOtStI+/4FKZQ== + +superstruct@^1.0.3: + version "1.0.3" + resolved "https://registry.yarnpkg.com/superstruct/-/superstruct-1.0.3.tgz#de626a5b49c6641ff4d37da3c7598e7a87697046" + integrity sha512-8iTn3oSS8nRGn+C2pgXSKPI3jmpm6FExNazNpjvqS6ZUJQCej3PUXEKM8NjHBOs54ExM+LPW/FBRhymrdcCiSg== + svelte-i18n@^3.3.13: version "3.7.4" resolved "https://registry.yarnpkg.com/svelte-i18n/-/svelte-i18n-3.7.4.tgz#6cf2c86075fd748bd8ca2de5762e43a596c7d189" @@ -3505,6 +4062,11 @@ svelte@^3.49.0: resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.59.2.tgz#a137b28e025a181292b2ae2e3dca90bf8ec73aec" integrity sha512-vzSyuGr3eEoAtT/A6bmajosJZIUWySzY2CzB3w2pgPvnkUjGqlDnsNnA0PMO+mMAhuyMul6C2uuZzY6ELSkzyA== +text-encoding-utf-8@^1.0.2: + version "1.0.2" + resolved "https://registry.yarnpkg.com/text-encoding-utf-8/-/text-encoding-utf-8-1.0.2.tgz#585b62197b0ae437e3c7b5d0af27ac1021e10d13" + integrity sha512-8bw4MY9WjdsD2aMtO0OzOCY3pXGYNx2d2FfHRVUKkiCPDWjKuOlhLVASS+pD7VkLTVjW268LYJHwsnPFlBpbAg== + thread-stream@^0.15.1: version "0.15.2" resolved "https://registry.yarnpkg.com/thread-stream/-/thread-stream-0.15.2.tgz#fb95ad87d2f1e28f07116eb23d85aba3bc0425f4" @@ -3512,6 +4074,11 @@ thread-stream@^0.15.1: dependencies: real-require "^0.1.0" +"through@>=2.2.7 <3": + version "2.3.8" + resolved "https://registry.yarnpkg.com/through/-/through-2.3.8.tgz#0dd4c9ffaabc357960b1b724115d7e0e86a2e1f5" + integrity sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg== + timers-ext@^0.1.7: version "0.1.7" resolved "https://registry.yarnpkg.com/timers-ext/-/timers-ext-0.1.7.tgz#6f57ad8578e07a3fb9f91d9387d65647555e25c6" @@ -3628,11 +4195,34 @@ use-sync-external-store@1.2.0, use-sync-external-store@^1.2.0: resolved "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz" integrity sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA== +utf-8-validate@^5.0.2: + version "5.0.10" + resolved "https://registry.yarnpkg.com/utf-8-validate/-/utf-8-validate-5.0.10.tgz#d7d10ea39318171ca982718b6b96a8d2442571a2" + integrity sha512-Z6czzLq4u8fPOyx7TU6X3dvUZVvoJmxSQ+IcrlmagKhilxlhZgxPK6C5Jqbkw1IDUmFTM+cz9QDnnLTwDz/2gQ== + dependencies: + node-gyp-build "^4.3.0" + util-deprecate@^1.0.1: version "1.0.2" resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== +util@^0.12.4: + version "0.12.5" + resolved "https://registry.yarnpkg.com/util/-/util-0.12.5.tgz#5f17a6059b73db61a875668781a1c2b136bd6fbc" + integrity sha512-kZf/K6hEIrWHI6XqOFUiiMa+79wE/D8Q+NCNAWclkyg3b4d2k7s0QGepNjiABc+aR3N1PAyHL7p6UcLY6LmrnA== + dependencies: + inherits "^2.0.3" + is-arguments "^1.0.4" + is-generator-function "^1.0.7" + is-typed-array "^1.1.3" + which-typed-array "^1.1.2" + +uuid@^8.3.2: + version "8.3.2" + resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" + integrity sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg== + valtio@1.11.0: version "1.11.0" resolved "https://registry.yarnpkg.com/valtio/-/valtio-1.11.0.tgz#c029dcd17a0f99d2fbec933721fe64cfd32a31ed" @@ -3659,6 +4249,17 @@ which-module@^2.0.0: resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.1.tgz#776b1fe35d90aebe99e8ac15eb24093389a4a409" integrity sha512-iBdZ57RDvnOR9AGBhML2vFZf7h8vmBjhoaZqODJBFWHVtKkDmKuHai3cx5PgVMrX5YDNp27AofYbAwctSS+vhQ== +which-typed-array@^1.1.11, which-typed-array@^1.1.2: + version "1.1.11" + resolved "https://registry.yarnpkg.com/which-typed-array/-/which-typed-array-1.1.11.tgz#99d691f23c72aab6768680805a271b69761ed61a" + integrity sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew== + dependencies: + available-typed-arrays "^1.0.5" + call-bind "^1.0.2" + for-each "^0.3.3" + gopd "^1.0.1" + has-tostringtag "^1.0.0" + wrap-ansi@^5.1.0: version "5.1.0" resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09" @@ -3692,11 +4293,16 @@ ws@7.5.3: resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.3.tgz#160835b63c7d97bfab418fc1b8a9fced2ac01a74" integrity sha512-kQ/dHIzuLrS6Je9+uv81ueZomEwH0qVYstcAQ4/Z93K8zeko9gtAbttJWzoC5ukqXY1PpoouV3+VSOqEAFt5wg== -ws@^7.5.1: +ws@^7.4.5, ws@^7.5.1: version "7.5.9" resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591" integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q== +ws@^8.5.0: + version "8.14.2" + resolved "https://registry.yarnpkg.com/ws/-/ws-8.14.2.tgz#6c249a806eb2db7a20d26d51e7709eab7b2e6c7f" + integrity sha512-wEBG1ftX4jcglPxgFCMJmZ2PLtSbJ2Peg6TmpJFTbe9GZYOQCDPdMYu/Tm0/bGZkw8paZnJY45J4K2PZrLYq8g== + ws@~8.11.0: version "8.11.0" resolved "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz" @@ -3707,11 +4313,21 @@ xmlhttprequest-ssl@~2.0.0: resolved "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz" integrity sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A== +xtend@^4.0.1: + version "4.0.2" + resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" + integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== + y18n@^4.0.0: version "4.0.3" resolved "https://registry.yarnpkg.com/y18n/-/y18n-4.0.3.tgz#b5f259c82cd6e336921efd7bfd8bf560de9eeedf" integrity sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ== +yallist@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/yallist/-/yallist-4.0.0.tgz#9bb92790d9c0effec63be73519e11a35019a3a72" + integrity sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A== + yargs-parser@^13.1.2: version "13.1.2" resolved "https://registry.yarnpkg.com/yargs-parser/-/yargs-parser-13.1.2.tgz#130f09702ebaeef2650d54ce6e3e5706f7a4fb38" From 24448b02f2bbfdcafd421c9a6455502f2c0e16b6 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 25 Sep 2023 13:45:38 +0530 Subject: [PATCH 250/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.14?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 2ceb5c701..2e42f5d88 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.13...uiweb-0.0.1-alpha.14) (2023-09-25) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([7efc3ab](https://github.com/ethereum-push-notification-service/push-sdk/commit/7efc3ab1c3a409a29166c9644c94708b0ac37417)) + + + ## [0.0.1-alpha.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.12...uiweb-0.0.1-alpha.13) (2023-09-21) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 68e20aa0c..b44327ac9 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.13", + "version": "0.0.1-alpha.14", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 5617655f25f1f9a431f2e6a403afb4fe383324b1 Mon Sep 17 00:00:00 2001 From: Monalisha Mishra <42746736+mishramonalisha76@users.noreply.github.com> Date: Mon, 25 Sep 2023 18:46:16 +0530 Subject: [PATCH 251/298] Wallet disconnect (#732) * fix: added disconnect for wallet * fix: added autoConnect * fix: changed onClick to onGetTokenClick * fix: fixed errors * fix: added coinbase wallet * fix: img added * fix: fixed metamask not showing if not present in it * fix: fixed injected wallets --------- Co-authored-by: KlausMikhaelson --- .../uiweb/src/lib/components/chat/ConnectButton/index.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx index 493c6dd05..6994cbb3c 100644 --- a/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx +++ b/packages/uiweb/src/lib/components/chat/ConnectButton/index.tsx @@ -64,9 +64,9 @@ const chains = [ } ] -const wallets = [injectedModule({ - displayUnavailable: [ProviderLabel.MetaMask] -}), walletConnect, coinbaseWalletSdk] + +const wallets = [injectedModule(), walletConnect, coinbaseWalletSdk] + const appMetadata = { From 50bfe43545afde7ef9ea2e2e20f22c89b32a0bee Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Mon, 25 Sep 2023 18:48:35 +0530 Subject: [PATCH 252/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20beta?= =?UTF-8?q?=20release=20to=20uiweb-v0.0.1-alpha.15?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 9 +++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 2e42f5d88..fc461f033 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.15](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.14...uiweb-0.0.1-alpha.15) (2023-09-25) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([eef6b18](https://github.com/ethereum-push-notification-service/push-sdk/commit/eef6b18d87a27c59930029b9933540333fb36bc6)) + + + ## [0.0.1-alpha.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-0.0.1-alpha.13...uiweb-0.0.1-alpha.14) (2023-09-25) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index b44327ac9..10f3afd3d 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "0.0.1-alpha.14", + "version": "0.0.1-alpha.15", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 44f0b7be1fb568c90c4dfebb7dc61ab82efaddc2 Mon Sep 17 00:00:00 2001 From: Ashis Kumar Pradhan <38760485+akp111@users.noreply.github.com> Date: Tue, 26 Sep 2023 16:09:35 +0530 Subject: [PATCH 253/298] fix: added class based implementation for notification (#699) * fix: added class based implementation for notification * fix: class based implementation for notification * fix: small fixes * fix: minor fixes and testcases * fix: fixes for testcases * fix: updated core abi and minor fixes * fix: removed comment * fix: minor fixes and additional checks * fix: minor fixes * fix: viem support for contract and new folder structure --- packages/restapi/src/lib/abis/comm.ts | 520 +++++++ packages/restapi/src/lib/abis/core.ts | 957 ++++++++++++ packages/restapi/src/lib/abis/token.ts | 709 +++++++++ packages/restapi/src/lib/config.ts | 231 ++- packages/restapi/src/lib/index.ts | 2 +- packages/restapi/src/lib/progressHook.ts | 62 + .../lib/pushNotification/PushNotification.ts | 1336 +++++++++++++++++ .../pushNotification/PushNotificationTypes.ts | 104 ++ packages/restapi/src/lib/pushapi/PushAPI.ts | 4 +- .../restapi/src/lib/pushapi/pushAPITypes.ts | 2 +- packages/restapi/src/lib/types/index.ts | 5 +- .../src/lib/user/getFeedsPerChannel.ts | 57 + packages/restapi/src/lib/user/index.ts | 2 + .../lib/pushNotification/channel.test.ts | 257 ++++ .../lib/pushNotification/delegate.test.ts | 126 ++ .../lib/pushNotification/notification.test.ts | 246 +++ .../lib/pushNotification/onchain.test.ts | 99 ++ .../tests/lib/pushNotification/tokenABI.ts | 709 +++++++++ 18 files changed, 5420 insertions(+), 8 deletions(-) create mode 100644 packages/restapi/src/lib/abis/comm.ts create mode 100644 packages/restapi/src/lib/abis/core.ts create mode 100644 packages/restapi/src/lib/abis/token.ts create mode 100644 packages/restapi/src/lib/pushNotification/PushNotification.ts create mode 100644 packages/restapi/src/lib/pushNotification/PushNotificationTypes.ts create mode 100644 packages/restapi/src/lib/user/getFeedsPerChannel.ts create mode 100644 packages/restapi/tests/lib/pushNotification/channel.test.ts create mode 100644 packages/restapi/tests/lib/pushNotification/delegate.test.ts create mode 100644 packages/restapi/tests/lib/pushNotification/notification.test.ts create mode 100644 packages/restapi/tests/lib/pushNotification/onchain.test.ts create mode 100644 packages/restapi/tests/lib/pushNotification/tokenABI.ts diff --git a/packages/restapi/src/lib/abis/comm.ts b/packages/restapi/src/lib/abis/comm.ts new file mode 100644 index 000000000..31b7c27d7 --- /dev/null +++ b/packages/restapi/src/lib/abis/comm.ts @@ -0,0 +1,520 @@ +export const commABI = [ + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: false, + internalType: 'address', + name: 'delegate', + type: 'address', + }, + ], + name: 'AddDelegate', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'string', + name: '_chainName', + type: 'string', + }, + { + indexed: true, + internalType: 'uint256', + name: '_chainID', + type: 'uint256', + }, + { + indexed: true, + internalType: 'address', + name: '_channelOwnerAddress', + type: 'address', + }, + { + indexed: false, + internalType: 'string', + name: '_ethereumChannelAddress', + type: 'string', + }, + ], + name: 'ChannelAlias', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'owner', + type: 'address', + }, + { + indexed: false, + internalType: 'bytes', + name: 'publickey', + type: 'bytes', + }, + ], + name: 'PublicKeyRegistered', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: false, + internalType: 'address', + name: 'delegate', + type: 'address', + }, + ], + name: 'RemoveDelegate', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'recipient', + type: 'address', + }, + { + indexed: false, + internalType: 'bytes', + name: 'identity', + type: 'bytes', + }, + ], + name: 'SendNotification', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + ], + name: 'Subscribe', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + ], + name: 'Unsubscribe', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: '_channel', + type: 'address', + }, + { + indexed: false, + internalType: 'address', + name: '_user', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: '_notifID', + type: 'uint256', + }, + { + indexed: false, + internalType: 'string', + name: '_notifSettings', + type: 'string', + }, + ], + name: 'UserNotifcationSettingsAdded', + type: 'event', + }, + { + inputs: [], + name: 'DOMAIN_TYPEHASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'EPNSCoreAddress', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'NAME_HASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'SEND_NOTIFICATION_TYPEHASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'SUBSCRIBE_TYPEHASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'UNSUBSCRIBE_TYPEHASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_delegate', type: 'address' }], + name: 'addDelegate', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address[]', name: '_channelList', type: 'address[]' }, + ], + name: 'batchSubscribe', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address[]', name: '_channelList', type: 'address[]' }, + ], + name: 'batchUnsubscribe', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'bytes', name: '_publicKey', type: 'bytes' }], + name: 'broadcastUserPublicKey', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'chainID', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'chainName', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channel', type: 'address' }, + { internalType: 'uint256', name: '_notifID', type: 'uint256' }, + { internalType: 'string', name: '_notifSettings', type: 'string' }, + ], + name: 'changeUserChannelSettings', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'completeMigration', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '', type: 'address' }, + { internalType: 'address', name: '', type: 'address' }, + ], + name: 'delegatedNotificationSenders', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'bytes', name: '_publicKey', type: 'bytes' }], + name: 'getWalletFromPublicKey', + outputs: [{ internalType: 'address', name: 'wallet', type: 'address' }], + stateMutability: 'pure', + type: 'function', + }, + { + inputs: [], + name: 'governance', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_pushChannelAdmin', type: 'address' }, + { internalType: 'string', name: '_chainName', type: 'string' }, + ], + name: 'initialize', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'isMigrationComplete', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channel', type: 'address' }, + { internalType: 'address', name: '_user', type: 'address' }, + ], + name: 'isUserSubscribed', + outputs: [{ internalType: 'bool', name: 'isSubscriber', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + name: 'mapAddressUsers', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'uint256', name: '_startIndex', type: 'uint256' }, + { internalType: 'uint256', name: '_endIndex', type: 'uint256' }, + { internalType: 'address[]', name: '_channelList', type: 'address[]' }, + { internalType: 'address[]', name: '_usersList', type: 'address[]' }, + ], + name: 'migrateSubscribeData', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'name', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'nonces', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'pushChannelAdmin', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_delegate', type: 'address' }], + name: 'removeDelegate', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channel', type: 'address' }, + { internalType: 'address', name: '_recipient', type: 'address' }, + { internalType: 'bytes', name: '_identity', type: 'bytes' }, + { internalType: 'uint256', name: 'nonce', type: 'uint256' }, + { internalType: 'uint256', name: 'expiry', type: 'uint256' }, + { internalType: 'uint8', name: 'v', type: 'uint8' }, + { internalType: 'bytes32', name: 'r', type: 'bytes32' }, + { internalType: 'bytes32', name: 's', type: 'bytes32' }, + ], + name: 'sendNotifBySig', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channel', type: 'address' }, + { internalType: 'address', name: '_recipient', type: 'address' }, + { internalType: 'bytes', name: '_identity', type: 'bytes' }, + ], + name: 'sendNotification', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_coreAddress', type: 'address' }, + ], + name: 'setEPNSCoreAddress', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_governanceAddress', type: 'address' }, + ], + name: 'setGovernanceAddress', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_channel', type: 'address' }], + name: 'subscribe', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: 'channel', type: 'address' }, + { internalType: 'uint256', name: 'nonce', type: 'uint256' }, + { internalType: 'uint256', name: 'expiry', type: 'uint256' }, + { internalType: 'uint8', name: 'v', type: 'uint8' }, + { internalType: 'bytes32', name: 'r', type: 'bytes32' }, + { internalType: 'bytes32', name: 's', type: 'bytes32' }, + ], + name: 'subscribeBySig', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channel', type: 'address' }, + { internalType: 'address', name: '_user', type: 'address' }, + ], + name: 'subscribeViaCore', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_newAdmin', type: 'address' }], + name: 'transferPushChannelAdminControl', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_channel', type: 'address' }], + name: 'unsubscribe', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: 'channel', type: 'address' }, + { internalType: 'uint256', name: 'nonce', type: 'uint256' }, + { internalType: 'uint256', name: 'expiry', type: 'uint256' }, + { internalType: 'uint8', name: 'v', type: 'uint8' }, + { internalType: 'bytes32', name: 'r', type: 'bytes32' }, + { internalType: 'bytes32', name: 's', type: 'bytes32' }, + ], + name: 'unsubscribeBySig', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '', type: 'address' }, + { internalType: 'address', name: '', type: 'address' }, + ], + name: 'userToChannelNotifs', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'users', + outputs: [ + { internalType: 'bool', name: 'userActivated', type: 'bool' }, + { internalType: 'bool', name: 'publicKeyRegistered', type: 'bool' }, + { internalType: 'uint256', name: 'userStartBlock', type: 'uint256' }, + { internalType: 'uint256', name: 'subscribedCount', type: 'uint256' }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'usersCount', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'string', name: '_channelAddress', type: 'string' }, + ], + name: 'verifyChannelAlias', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, +] as const; diff --git a/packages/restapi/src/lib/abis/core.ts b/packages/restapi/src/lib/abis/core.ts new file mode 100644 index 000000000..6032a8b3d --- /dev/null +++ b/packages/restapi/src/lib/abis/core.ts @@ -0,0 +1,957 @@ +export const coreABI = [ + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'enum EPNSCoreStorageV1_5.ChannelType', + name: 'channelType', + type: 'uint8', + }, + { + indexed: false, + internalType: 'bytes', + name: 'identity', + type: 'bytes', + }, + ], + name: 'AddChannel', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: false, + internalType: 'bytes', + name: '_subGraphData', + type: 'bytes', + }, + ], + name: 'AddSubGraph', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + ], + name: 'ChannelBlocked', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: '_channel', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'totalNotifOptions', + type: 'uint256', + }, + { + indexed: false, + internalType: 'string', + name: '_notifSettings', + type: 'string', + }, + { + indexed: false, + internalType: 'string', + name: '_notifDescription', + type: 'string', + }, + ], + name: 'ChannelNotifcationSettingsAdded', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'newOwner', + type: 'address', + }, + ], + name: 'ChannelOwnershipTransfer', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'revoker', + type: 'address', + }, + ], + name: 'ChannelVerificationRevoked', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'verifier', + type: 'address', + }, + ], + name: 'ChannelVerified', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + { + indexed: true, + internalType: 'uint256', + name: 'amountClaimed', + type: 'uint256', + }, + ], + name: 'ChatIncentiveClaimed', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'uint256', + name: 'amountRefunded', + type: 'uint256', + }, + ], + name: 'DeactivateChannel', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: 'requestSender', + type: 'address', + }, + { + indexed: false, + internalType: 'address', + name: 'requestReceiver', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'amountForReqReceiver', + type: 'uint256', + }, + { + indexed: false, + internalType: 'uint256', + name: 'feePoolAmount', + type: 'uint256', + }, + { + indexed: false, + internalType: 'uint256', + name: 'timestamp', + type: 'uint256', + }, + ], + name: 'IncentivizeChatReqReceived', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: 'account', + type: 'address', + }, + ], + name: 'Paused', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'uint256', + name: 'amountDeposited', + type: 'uint256', + }, + ], + name: 'ReactivateChannel', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + { + indexed: false, + internalType: 'uint256', + name: 'rewardAmount', + type: 'uint256', + }, + ], + name: 'RewardsClaimed', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + { + indexed: true, + internalType: 'uint256', + name: 'rewardAmount', + type: 'uint256', + }, + { + indexed: false, + internalType: 'uint256', + name: 'fromEpoch', + type: 'uint256', + }, + { + indexed: false, + internalType: 'uint256', + name: 'tillEpoch', + type: 'uint256', + }, + ], + name: 'RewardsHarvested', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + { + indexed: true, + internalType: 'uint256', + name: 'amountStaked', + type: 'uint256', + }, + ], + name: 'Staked', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: true, + internalType: 'uint256', + name: 'amountRefunded', + type: 'uint256', + }, + ], + name: 'TimeBoundChannelDestroyed', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: false, + internalType: 'address', + name: 'account', + type: 'address', + }, + ], + name: 'Unpaused', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { indexed: true, internalType: 'address', name: 'user', type: 'address' }, + { + indexed: true, + internalType: 'uint256', + name: 'amountUnstaked', + type: 'uint256', + }, + ], + name: 'Unstaked', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'channel', + type: 'address', + }, + { + indexed: false, + internalType: 'bytes', + name: 'identity', + type: 'bytes', + }, + { + indexed: true, + internalType: 'uint256', + name: 'amountDeposited', + type: 'uint256', + }, + ], + name: 'UpdateChannel', + type: 'event', + }, + { + inputs: [], + name: 'ADD_CHANNEL_MIN_FEES', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'CHANNEL_POOL_FUNDS', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'CREATE_CHANNEL_TYPEHASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'DOMAIN_TYPEHASH', + outputs: [{ internalType: 'bytes32', name: '', type: 'bytes32' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'FEE_AMOUNT', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'MIN_POOL_CONTRIBUTION', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'PROTOCOL_POOL_FEES', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'PUSH_TOKEN_ADDRESS', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'REFERRAL_CODE', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'UNISWAP_V2_ROUTER', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'WETH_ADDRESS', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'aDaiAddress', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'uint256', name: '_rewardAmount', type: 'uint256' }, + ], + name: 'addPoolFees', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'bytes', name: '_subGraphData', type: 'bytes' }], + name: 'addSubGraph', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'uint256', name: '_startIndex', type: 'uint256' }, + { internalType: 'uint256', name: '_endIndex', type: 'uint256' }, + { internalType: 'address[]', name: '_channelList', type: 'address[]' }, + ], + name: 'batchVerification', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channelAddress', type: 'address' }, + ], + name: 'blockChannel', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_user', type: 'address' }, + { internalType: 'uint256', name: '_epochId', type: 'uint256' }, + ], + name: 'calculateEpochRewards', + outputs: [{ internalType: 'uint256', name: 'rewards', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'celebUserFunds', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + name: 'channelById', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'channelNotifSettings', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'channelUpdateCounter', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'channels', + outputs: [ + { + internalType: 'enum EPNSCoreStorageV1_5.ChannelType', + name: 'channelType', + type: 'uint8', + }, + { internalType: 'uint8', name: 'channelState', type: 'uint8' }, + { internalType: 'address', name: 'verifiedBy', type: 'address' }, + { internalType: 'uint256', name: 'poolContribution', type: 'uint256' }, + { internalType: 'uint256', name: 'channelHistoricalZ', type: 'uint256' }, + { + internalType: 'uint256', + name: 'channelFairShareCount', + type: 'uint256', + }, + { internalType: 'uint256', name: 'channelLastUpdate', type: 'uint256' }, + { internalType: 'uint256', name: 'channelStartBlock', type: 'uint256' }, + { internalType: 'uint256', name: 'channelUpdateBlock', type: 'uint256' }, + { internalType: 'uint256', name: 'channelWeight', type: 'uint256' }, + { internalType: 'uint256', name: 'expiryTime', type: 'uint256' }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'channelsCount', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_amount', type: 'uint256' }], + name: 'claimChatIncentives', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'uint256', name: '_notifOptions', type: 'uint256' }, + { internalType: 'string', name: '_notifSettings', type: 'string' }, + { internalType: 'string', name: '_notifDescription', type: 'string' }, + { internalType: 'uint256', name: '_amountDeposited', type: 'uint256' }, + ], + name: 'createChannelSettings', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'enum EPNSCoreStorageV1_5.ChannelType', + name: '_channelType', + type: 'uint8', + }, + { internalType: 'bytes', name: '_identity', type: 'bytes' }, + { internalType: 'uint256', name: '_amount', type: 'uint256' }, + { internalType: 'uint256', name: '_channelExpiryTime', type: 'uint256' }, + ], + name: 'createChannelWithPUSH', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'daiAddress', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_tillEpoch', type: 'uint256' }], + name: 'daoHarvestPaginated', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'deactivateChannel', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channelAddress', type: 'address' }, + ], + name: 'destroyTimeBoundChannel', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'epnsCommunicator', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'epochDuration', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + name: 'epochRewards', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + name: 'epochToTotalStakedWeight', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'genesisEpoch', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_channel', type: 'address' }], + name: 'getChannelVerfication', + outputs: [ + { internalType: 'uint8', name: 'verificationStatus', type: 'uint8' }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'governance', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'groupFairShareCount', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'groupHistoricalZ', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'groupLastUpdate', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'groupNormalizedWeight', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: 'requestSender', type: 'address' }, + { internalType: 'address', name: 'requestReceiver', type: 'address' }, + { internalType: 'uint256', name: 'amount', type: 'uint256' }, + ], + name: 'handleChatRequestData', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'harvestAll', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_tillEpoch', type: 'uint256' }], + name: 'harvestPaginated', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_pushChannelAdmin', type: 'address' }, + { internalType: 'address', name: '_pushTokenAddress', type: 'address' }, + { internalType: 'address', name: '_wethAddress', type: 'address' }, + { + internalType: 'address', + name: '_uniswapRouterAddress', + type: 'address', + }, + { + internalType: 'address', + name: '_lendingPoolProviderAddress', + type: 'address', + }, + { internalType: 'address', name: '_daiAddress', type: 'address' }, + { internalType: 'address', name: '_aDaiAddress', type: 'address' }, + { internalType: 'uint256', name: '_referralCode', type: 'uint256' }, + ], + name: 'initialize', + outputs: [{ internalType: 'bool', name: 'success', type: 'bool' }], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'initializeStake', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'isMigrationComplete', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { internalType: 'uint256', name: '_from', type: 'uint256' }, + { internalType: 'uint256', name: '_to', type: 'uint256' }, + ], + name: 'lastEpochRelative', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'lendingPoolProviderAddress', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'name', + outputs: [{ internalType: 'string', name: '', type: 'string' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'nonces', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'pauseContract', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'paused', + outputs: [{ internalType: 'bool', name: '', type: 'bool' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'previouslySetEpochRewards', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'pushChannelAdmin', + outputs: [{ internalType: 'address', name: '', type: 'address' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_amount', type: 'uint256' }], + name: 'reactivateChannel', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_commAddress', type: 'address' }, + ], + name: 'setEpnsCommunicatorAddress', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_newFees', type: 'uint256' }], + name: 'setFeeAmount', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_governanceAddress', type: 'address' }, + ], + name: 'setGovernanceAddress', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_newFees', type: 'uint256' }], + name: 'setMinChannelCreationFees', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_newAmount', type: 'uint256' }], + name: 'setMinPoolContribution', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'uint256', name: '_amount', type: 'uint256' }], + name: 'stake', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'totalStakedAmount', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_newAdmin', type: 'address' }], + name: 'transferPushChannelAdminControl', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'unPauseContract', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'unstake', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_channel', type: 'address' }], + name: 'unverifyChannel', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { internalType: 'address', name: '_channel', type: 'address' }, + { internalType: 'bytes', name: '_newIdentity', type: 'bytes' }, + { internalType: 'uint256', name: '_amount', type: 'uint256' }, + ], + name: 'updateChannelMeta', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'userFeesInfo', + outputs: [ + { internalType: 'uint256', name: 'stakedAmount', type: 'uint256' }, + { internalType: 'uint256', name: 'stakedWeight', type: 'uint256' }, + { internalType: 'uint256', name: 'lastStakedBlock', type: 'uint256' }, + { internalType: 'uint256', name: 'lastClaimedBlock', type: 'uint256' }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '', type: 'address' }], + name: 'usersRewardsClaimed', + outputs: [{ internalType: 'uint256', name: '', type: 'uint256' }], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [{ internalType: 'address', name: '_channel', type: 'address' }], + name: 'verifyChannel', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, +] as const; diff --git a/packages/restapi/src/lib/abis/token.ts b/packages/restapi/src/lib/abis/token.ts new file mode 100644 index 000000000..a68265ba9 --- /dev/null +++ b/packages/restapi/src/lib/abis/token.ts @@ -0,0 +1,709 @@ +export const tokenABI = [ + { + inputs: [ + { + internalType: 'address', + name: 'account', + type: 'address', + }, + ], + stateMutability: 'nonpayable', + type: 'constructor', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'owner', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'spender', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'amount', + type: 'uint256', + }, + ], + name: 'Approval', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'delegator', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'fromDelegate', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'toDelegate', + type: 'address', + }, + ], + name: 'DelegateChanged', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'delegate', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'previousBalance', + type: 'uint256', + }, + { + indexed: false, + internalType: 'uint256', + name: 'newBalance', + type: 'uint256', + }, + ], + name: 'DelegateVotesChanged', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'holder', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'amount', + type: 'uint256', + }, + { + indexed: false, + internalType: 'uint256', + name: 'weight', + type: 'uint256', + }, + ], + name: 'HolderWeightChanged', + type: 'event', + }, + { + anonymous: false, + inputs: [ + { + indexed: true, + internalType: 'address', + name: 'from', + type: 'address', + }, + { + indexed: true, + internalType: 'address', + name: 'to', + type: 'address', + }, + { + indexed: false, + internalType: 'uint256', + name: 'amount', + type: 'uint256', + }, + ], + name: 'Transfer', + type: 'event', + }, + { + inputs: [], + name: 'DELEGATION_TYPEHASH', + outputs: [ + { + internalType: 'bytes32', + name: '', + type: 'bytes32', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'DOMAIN_TYPEHASH', + outputs: [ + { + internalType: 'bytes32', + name: '', + type: 'bytes32', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'PERMIT_TYPEHASH', + outputs: [ + { + internalType: 'bytes32', + name: '', + type: 'bytes32', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'account', + type: 'address', + }, + { + internalType: 'address', + name: 'spender', + type: 'address', + }, + ], + name: 'allowance', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'spender', + type: 'address', + }, + { + internalType: 'uint256', + name: 'rawAmount', + type: 'uint256', + }, + ], + name: 'approve', + outputs: [ + { + internalType: 'bool', + name: '', + type: 'bool', + }, + ], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'account', + type: 'address', + }, + ], + name: 'balanceOf', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'born', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'uint256', + name: 'rawAmount', + type: 'uint256', + }, + ], + name: 'burn', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + { + internalType: 'uint32', + name: '', + type: 'uint32', + }, + ], + name: 'checkpoints', + outputs: [ + { + internalType: 'uint32', + name: 'fromBlock', + type: 'uint32', + }, + { + internalType: 'uint96', + name: 'votes', + type: 'uint96', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'decimals', + outputs: [ + { + internalType: 'uint8', + name: '', + type: 'uint8', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'delegatee', + type: 'address', + }, + ], + name: 'delegate', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'delegatee', + type: 'address', + }, + { + internalType: 'uint256', + name: 'nonce', + type: 'uint256', + }, + { + internalType: 'uint256', + name: 'expiry', + type: 'uint256', + }, + { + internalType: 'uint8', + name: 'v', + type: 'uint8', + }, + { + internalType: 'bytes32', + name: 'r', + type: 'bytes32', + }, + { + internalType: 'bytes32', + name: 's', + type: 'bytes32', + }, + ], + name: 'delegateBySig', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + ], + name: 'delegates', + outputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'account', + type: 'address', + }, + ], + name: 'getCurrentVotes', + outputs: [ + { + internalType: 'uint96', + name: '', + type: 'uint96', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'account', + type: 'address', + }, + { + internalType: 'uint256', + name: 'blockNumber', + type: 'uint256', + }, + ], + name: 'getPriorVotes', + outputs: [ + { + internalType: 'uint96', + name: '', + type: 'uint96', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + { + internalType: 'address', + name: '', + type: 'address', + }, + ], + name: 'holderDelegation', + outputs: [ + { + internalType: 'bool', + name: '', + type: 'bool', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + ], + name: 'holderWeight', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'name', + outputs: [ + { + internalType: 'string', + name: '', + type: 'string', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + ], + name: 'nonces', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: '', + type: 'address', + }, + ], + name: 'numCheckpoints', + outputs: [ + { + internalType: 'uint32', + name: '', + type: 'uint32', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'owner', + type: 'address', + }, + { + internalType: 'address', + name: 'spender', + type: 'address', + }, + { + internalType: 'uint256', + name: 'rawAmount', + type: 'uint256', + }, + { + internalType: 'uint256', + name: 'deadline', + type: 'uint256', + }, + { + internalType: 'uint8', + name: 'v', + type: 'uint8', + }, + { + internalType: 'bytes32', + name: 'r', + type: 'bytes32', + }, + { + internalType: 'bytes32', + name: 's', + type: 'bytes32', + }, + ], + name: 'permit', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'holder', + type: 'address', + }, + ], + name: 'resetHolderWeight', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'account', + type: 'address', + }, + { + internalType: 'address', + name: 'delegate', + type: 'address', + }, + ], + name: 'returnHolderDelegation', + outputs: [ + { + internalType: 'bool', + name: '', + type: 'bool', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'returnHolderRatio', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'delegate', + type: 'address', + }, + { + internalType: 'bool', + name: 'value', + type: 'bool', + }, + ], + name: 'setHolderDelegation', + outputs: [], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [], + name: 'symbol', + outputs: [ + { + internalType: 'string', + name: '', + type: 'string', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [], + name: 'totalSupply', + outputs: [ + { + internalType: 'uint256', + name: '', + type: 'uint256', + }, + ], + stateMutability: 'view', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'dst', + type: 'address', + }, + { + internalType: 'uint256', + name: 'rawAmount', + type: 'uint256', + }, + ], + name: 'transfer', + outputs: [ + { + internalType: 'bool', + name: '', + type: 'bool', + }, + ], + stateMutability: 'nonpayable', + type: 'function', + }, + { + inputs: [ + { + internalType: 'address', + name: 'src', + type: 'address', + }, + { + internalType: 'address', + name: 'dst', + type: 'address', + }, + { + internalType: 'uint256', + name: 'rawAmount', + type: 'uint256', + }, + ], + name: 'transferFrom', + outputs: [ + { + internalType: 'bool', + name: '', + type: 'bool', + }, + ], + stateMutability: 'nonpayable', + type: 'function', + }, +] as const; diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index c4ed49fb2..96a80c793 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -1,5 +1,19 @@ import Constants from './constants'; - +import { coreABI } from './abis/core'; +import { commABI } from './abis/comm'; +import { tokenABI } from './abis/token'; +import { + mainnet, + goerli, + polygon, + polygonMumbai, + bsc, + bscTestnet, + optimism, + optimismGoerli, + polygonZkEvm, + polygonZkEvmTestnet, +} from 'viem/chains'; const { ENV } = Constants; // for methods not needing the entire config @@ -29,6 +43,12 @@ const BLOCKCHAIN_NETWORK = { export type ALIAS_CHAIN = 'POLYGON' | 'BSC' | 'OPTIMISM' | 'POLYGONZKEVM'; +export const ETH_CHAIN_ID = { + [ENV.PROD]: 1, + [ENV.STAGING]: 5, + [ENV.DEV]: 5, + [ENV.LOCAL]: 5, +}; export const ALIAS_CHAIN_ID = { POLYGON: { [ENV.PROD]: 137, @@ -52,15 +72,80 @@ export const ALIAS_CHAIN_ID = { [ENV.PROD]: 1101, [ENV.STAGING]: 1442, [ENV.DEV]: 1442, - [ENV.LOCAL]: 420, + [ENV.LOCAL]: 1442, }, }; +export const CHAIN_ID = { + ETHEREUM: ETH_CHAIN_ID, + ...ALIAS_CHAIN_ID, +}; + +export const CHAIN_NAME: { [key: number]: string } = { + // eth + 1: 'ETHEREUM', + 5: 'ETHEREUM', + // polygon + 137: 'POLYGON', + 80001: 'POLYGON', + // bsc + 56: 'BSC', + 97: 'BSC', + // optimism + 10: 'OPTIMISM', + 420: 'OPTIMISM', + // plygonzkevm + 1101: 'POLYGONZKEVM', + 1442: 'POLYGONZKEVM', +}; export interface ConfigType { API_BASE_URL: string; EPNS_COMMUNICATOR_CONTRACT: string; } + +export const VIEM_CORE_CONFIG = { + [ENV.PROD]: { + NETWORK: mainnet, + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_CORE_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [ENV.STAGING]: { + NETWORK: goerli, + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_CORE_CONTRACT: '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C', + }, + [ENV.DEV]: { + NETWORK: goerli, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + }, + [ENV.LOCAL]: { + NETWORK: goerli, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + }, +}; + +export const CORE_CONFIG = { + [ENV.PROD]: { + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_CORE_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [ENV.STAGING]: { + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_CORE_CONTRACT: '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C', + }, + [ENV.DEV]: { + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + }, + [ENV.LOCAL]: { + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + }, +}; + const CONFIG = { [ENV.PROD]: { [BLOCKCHAIN_NETWORK.ETH_MAINNET]: { @@ -153,3 +238,145 @@ const CONFIG = { }; export default CONFIG; +export const TOKEN = { + [ENV.PROD]: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + [ENV.STAGING]: '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + [ENV.DEV]: '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + [ENV.LOCAL]: '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', +}; + +export const TOKEN_VIEM_NETWORK_MAP = { + [ENV.PROD]: mainnet, + [ENV.STAGING]: goerli, + [ENV.DEV]: goerli, + [ENV.LOCAL]: goerli, +} + +export const MIN_TOKEN_BALANCE = { + [ENV.PROD]: 50, + [ENV.STAGING]: 50, + [ENV.DEV]: 50, + [ENV.LOCAL]: 50, +}; +export const ABIS = { + CORE: coreABI, + COMM: commABI, + TOKEN: tokenABI, +}; + +export const CHANNEL_TYPE = { + TIMEBOUND: 4, + GENERAL: 2, +}; + + +export const VIEM_CONFIG = { + [ENV.PROD]: { + [BLOCKCHAIN_NETWORK.ETH_MAINNET]: { + NETWORK: mainnet, + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.POLYGON_MAINNET]: { + NETWORK: polygon, + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.BSC_MAINNET]: { + NETWORK: bsc, + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.OPTIMISM_MAINNET]: { + NETWORK: optimism, + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_MAINNET]: { + NETWORK: polygonZkEvm, + API_BASE_URL: API_BASE_URL[ENV.PROD], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + }, + [ENV.STAGING]: { + [BLOCKCHAIN_NETWORK.ETH_GOERLI]: { + NETWORK: goerli, + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.POLYGON_MUMBAI]: { + NETWORK: polygonMumbai, + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.BSC_TESTNET]: { + NETWORK: bscTestnet, + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.OPTIMISM_TESTNET]: { + NETWORK: optimismGoerli, + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_TESTNET]: { + NETWORK: polygonZkEvmTestnet, + API_BASE_URL: API_BASE_URL[ENV.STAGING], + EPNS_COMMUNICATOR_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + }, + }, + [ENV.DEV]: { + [BLOCKCHAIN_NETWORK.ETH_GOERLI]: { + NETWORK: goerli, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + }, + [BLOCKCHAIN_NETWORK.POLYGON_MUMBAI]: { + NETWORK: polygonMumbai, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0xAf55BE8e6b0d6107891bA76eADeEa032ef8A4504', + }, + [BLOCKCHAIN_NETWORK.BSC_TESTNET]: { + NETWORK: bscTestnet, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0x4132061E3349ff36cFfCadA460E10Bd4f31F7ea8', + }, + [BLOCKCHAIN_NETWORK.OPTIMISM_TESTNET]: { + NETWORK: optimismGoerli, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0x4305D572F2bf38Fc2AE8D0172055b1EFd18F57a6', + }, + [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_TESTNET]: { + NETWORK: polygonZkEvmTestnet, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0x630b152e4185c63D7177c656b56b26f878C61572', + }, + }, + [ENV.LOCAL]: { + [BLOCKCHAIN_NETWORK.ETH_GOERLI]: { + NETWORK: goerli, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + }, + [BLOCKCHAIN_NETWORK.POLYGON_MUMBAI]: { + NETWORK: polygonMumbai, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0xAf55BE8e6b0d6107891bA76eADeEa032ef8A4504', + }, + [BLOCKCHAIN_NETWORK.BSC_TESTNET]: { + NETWORK: bscTestnet, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0x4132061E3349ff36cFfCadA460E10Bd4f31F7ea8', + }, + [BLOCKCHAIN_NETWORK.OPTIMISM_TESTNET]: { + NETWORK: optimismGoerli, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0x4305D572F2bf38Fc2AE8D0172055b1EFd18F57a6', + }, + [BLOCKCHAIN_NETWORK.POLYGON_ZK_EVM_TESTNET]: { + NETWORK: polygonZkEvmTestnet, + API_BASE_URL: API_BASE_URL[ENV.DEV], + EPNS_COMMUNICATOR_CONTRACT: '0x630b152e4185c63D7177c656b56b26f878C61572', + }, + }, +}; diff --git a/packages/restapi/src/lib/index.ts b/packages/restapi/src/lib/index.ts index cd3f53dbd..eecc148e5 100644 --- a/packages/restapi/src/lib/index.ts +++ b/packages/restapi/src/lib/index.ts @@ -9,7 +9,7 @@ import * as video from "./video" export * from './types'; export { PushAPI } from './pushapi/PushAPI'; - +export { PushNotification } from './pushNotification/PushNotification' export { alias, channels, diff --git a/packages/restapi/src/lib/progressHook.ts b/packages/restapi/src/lib/progressHook.ts index 0309c5618..64b6556b6 100644 --- a/packages/restapi/src/lib/progressHook.ts +++ b/packages/restapi/src/lib/progressHook.ts @@ -176,6 +176,60 @@ const PROGRESSHOOK: Record< progressInfo: '', level: 'SUCCESS', }, + /** + * PUSH_CHANNEL_CREATE PROGRESSHOOKS + */ + 'PUSH-CHANNEL-CREATE-01': { + progressId: 'PUSH-CHANNEL-CREATE-01', + progressTitle: 'Uploading data to IPFS', + progressInfo: 'The channel’s data is getting uploaded to IPFS', + level: 'INFO', + }, + 'PUSH-CHANNEL-CREATE-02': { + progressId: 'PUSH-CHANNEL-CREATE-02', + progressTitle: 'Approving PUSH tokens', + progressInfo: 'Gives approval to Push Core contract to spend 50 DAI', + level: 'INFO', + }, + 'PUSH-CHANNEL-CREATE-03': { + progressId: 'PUSH-CHANNEL-CREATE-03', + progressTitle: 'Channel is getting created', + progressInfo: 'Calls Push Core contract to create your channel', + level: 'INFO', + }, + 'PUSH-CHANNEL-CREATE-04': { + progressId: 'PUSH-CHANNEL-CREATE-04', + progressTitle: 'Channel creation is done, Welcome to Push Ecosystem', + progressInfo: 'Channel creation is completed', + level: 'SUCCESS', + }, + /** + * PUSH_CHANNEL_UPDATE PROGRESSHOOKS + */ + 'PUSH-CHANNEL-UPDATE-01': { + progressId: 'PUSH-CHANNEL-UPDATE-01', + progressTitle: 'Uploading new data to IPFS', + progressInfo: 'The channel’s new data is getting uploaded to IPFS', + level: 'INFO', + }, + 'PUSH-CHANNEL-UPDATE-02': { + progressId: 'PUSH-CHANNEL-UPDATE-02', + progressTitle: 'Approving PUSH tokens', + progressInfo: 'Gives approval to Push Core contract to spend 50 DAI', + level: 'INFO', + }, + 'PUSH-CHANNEL-UPDATE-03': { + progressId: 'PUSH-CHANNEL-UPDATE-03', + progressTitle: 'Channel is getting updated', + progressInfo: 'Calls Push Core contract to update your channel details', + level: 'INFO', + }, + 'PUSH-CHANNEL-UPDATE-04': { + progressId: 'PUSH-CHANNEL-UPDATE-04', + progressTitle: 'Channel is updated with new data', + progressInfo: 'Channel is successfully updated', + level: 'SUCCESS', + }, /** * PUSH-ERROR PROGRESSHOOKS */ @@ -195,5 +249,13 @@ const PROGRESSHOOK: Record< level: 'WARN', }; }, + 'PUSH-ERROR-02': (name: string, err: string) => { + return { + progressId: 'PUSH-ERROR-02', + progressTitle: 'Transaction failed', + progressInfo: `[Push SDK] - Contract - Error - ${name} -: ${err}`, + level: 'ERROR', + }; + }, }; export default PROGRESSHOOK; diff --git a/packages/restapi/src/lib/pushNotification/PushNotification.ts b/packages/restapi/src/lib/pushNotification/PushNotification.ts new file mode 100644 index 000000000..be7c58987 --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/PushNotification.ts @@ -0,0 +1,1336 @@ +import Constants, { ENV } from '../constants'; +import { + SignerType, + ISendNotificationInputOptions, + ProgressHookType, + ProgressHookTypeFunction, + ethersV5SignerType, +} from '../types'; +import { + ChannelInfoOptions, + SubscribeUnsubscribeOptions, + SubscriptionOptions, + AliasOptions, + FeedType, + FeedsOptions, + ChannelSearchOptions, + NotificationOptions, + CreateChannelOptions, + NotificationSettings, +} from './PushNotificationTypes'; +import CONFIG, * as config from '../config'; +import * as PUSH_USER from '../user'; +import * as PUSH_PAYLOAD from '../payloads'; +import * as PUSH_CHANNEL from '../channels'; +import * as PUSH_ALIAS from '../alias'; +import { getAccountAddress } from '../chat/helpers'; +import { + getCAIPDetails, + getCAIPWithChainId, + validateCAIP, + getFallbackETHCAIPAddress, +} from '../helpers'; +import PROGRESSHOOK from '../progressHook'; +import { IDENTITY_TYPE, NOTIFICATION_TYPE } from '../payloads/constants'; +import { ethers, Contract, ContractInterface, Signer, BigNumber } from 'ethers'; +import axios from 'axios'; +import { mainnet, goerli } from 'viem/chains'; +import { + createPublicClient, + http, + getContract, + GetContractReturnType, + WalletClient, + Chain, +} from 'viem'; + +// ERROR CONSTANTS +const ERROR_ACCOUNT_NEEDED = 'Account is required'; +const ERROR_SIGNER_NEEDED = 'Signer object is required'; +const ERROR_CHANNEL_NEEDED = 'Channel is needed'; +const ERROR_INVALID_CAIP = 'Invalid CAIP format'; + +const BROADCAST_TYPE = '*'; +const LENGTH_UPPER_LIMIT = 125; +const LENGTH_LOWER_LIMTI = 1; +const SETTING_DELIMITER = '-'; +const SETTING_SEPARATOR = '+'; + +export const FEED_MAP = { + INBOX: false, + SPAM: true, +}; +export class PushNotification { + private signer: SignerType | undefined; + private account: string | undefined; + private env: ENV | undefined; + private guestMode: boolean; + private coreContract: Contract | undefined; + + constructor( + signer?: SignerType, + env?: ENV, + account?: string, + coreContract?: any + ) { + this.signer = signer; + this.env = env; + this.guestMode = !!(account && signer); + this.account = account; + this.coreContract = coreContract; + } + static async initialize( + signer?: SignerType, + options?: { env?: ENV } + ): Promise { + const { env = ENV.STAGING } = options || {}; + // Derives account from signer if not provided + let derivedAccount; + let coreContract; + if (signer) { + if (!('_signTypedData' in signer!) && !('signTypedData' in signer!)) { + throw new Error('Unsupported signer type'); + } else if ('_signTypedData' in signer) { + derivedAccount = await getAccountAddress({ + account: null, + signer: signer, + }); + if (signer?.provider) { + coreContract = new ethers.Contract( + config.CORE_CONFIG[env].EPNS_CORE_CONTRACT, + config.ABIS.CORE, + signer as unknown as Signer + ); + } + } else if ('signTypedData' in signer) { + derivedAccount = await getAccountAddress({ + account: null, + signer: signer, + }); + const client = createPublicClient({ + chain: config.TOKEN_VIEM_NETWORK_MAP[env], + transport: http(), + }); + coreContract = getContract({ + abi: config.ABIS.CORE, + address: config.CORE_CONFIG[env].EPNS_CORE_CONTRACT as `0x${string}`, + publicClient: client, + walletClient: signer as unknown as WalletClient, + }); + } + } + + // Initialize PushNotifications instance + return new PushNotification( + signer, + env as ENV, + derivedAccount, + coreContract + ); + } + + // check if addresses is supplied either by user or derived from signer object or if its guest mode + private checkUserAddressExists(user?: string) { + if (!user && !this.account && !this.guestMode) + throw new Error(ERROR_ACCOUNT_NEEDED); + return true; + } + + // checks if the signer object is supplied + private checkSignerObjectExists() { + if (!this.signer) throw new Error(ERROR_SIGNER_NEEDED); + return true; + } + + // get type of notification from recipient + private getNotificationType( + recipient: string[], + channel: string + ): { recipient: string[] | string; type: number } { + if (recipient.length == 1) { + if (recipient[0] == BROADCAST_TYPE) { + return { recipient: channel, type: NOTIFICATION_TYPE['BROADCAST'] }; + } else { + return { + recipient: recipient[0], + type: NOTIFICATION_TYPE['TARGETTED'], + }; + } + } + return { recipient, type: NOTIFICATION_TYPE['SUBSET'] }; + } + + // get identity type for lowlevel call + private generateNotificationLowLevelPayload({ + signer, + env, + recipients, + options, + channel, + }: { + signer: SignerType; + env: ENV; + recipients: string[]; + options: NotificationOptions; + channel?: string; + }): ISendNotificationInputOptions { + if (!channel) { + channel = `${this.account}`; + } + const notificationType = this.getNotificationType(recipients, channel); + const identityType = IDENTITY_TYPE.DIRECT_PAYLOAD; + const notificationPayload: ISendNotificationInputOptions = { + signer: signer, + channel: channel, + type: notificationType.type, + identityType: identityType, + notification: options.notification, + payload: { + title: options.payload?.title ?? options.notification.title, + body: options.payload?.body ?? options.notification.body, + cta: options.payload?.cta ?? '', + img: options.payload?.embed ?? '', + hidden: options.config?.hidden, + etime: options.config?.expiry, + silent: options.config?.silent, + additionalMeta: options.payload?.meta, + }, + recipients: notificationType.recipient, + graph: options.advanced?.graph, + ipfsHash: options.advanced?.ipfs, + env: env, + chatId: options.advanced?.chatid, + pgpPrivateKey: options.advanced?.pgpPrivateKey, + }; + + return notificationPayload; + } + + // check if the fields are empty + private isEmpty(field: string) { + if (field.trim().length == 0) { + return true; + } + + return false; + } + + // check if the length is valid + private isValidLength( + data: string, + upperLen: number = LENGTH_UPPER_LIMIT, + lowerLen: number = LENGTH_LOWER_LIMTI + ): boolean { + return data.length >= lowerLen && data.length <= upperLen!; + } + + // check if url is valid + private isValidUrl(urlString: string): boolean { + const urlPattern = new RegExp( + '^((?:https|http):\\/\\/)' + // validate protocol + '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|' + // validate domain name + '((\\d{1,3}\\.){3}\\d{1,3}))' + // validate OR ip (v4) address + '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + // validate port and path + '(\\?[;&a-z\\d%_.~+=-]*)?' + // validate query string + '(\\#[-a-z\\d_]*)?$', + 'i' + ); // validate fragment locator + return !!urlPattern.test(urlString); + } + + // check all the fields of channel + private verifyEmptyChannelParameters(options: CreateChannelOptions): boolean { + if (this.isEmpty(options.name)) { + throw new Error('Channel name cannot be empty'); + } else if (this.isEmpty(options.description)) { + throw new Error('Channel description cannot be empty'); + } else if (this.isEmpty(options.icon)) { + throw new Error('Channel icon cannot be empty'); + } else if (this.isEmpty(options.url)) { + throw new Error('Channel url cannot ne empty'); + } else { + return true; + } + } + + // check for valid length and url + private validateParameterLength(options: CreateChannelOptions): boolean { + if (!this.isValidLength(options.name)) { + throw new Error( + `Channel name should not exceed ${LENGTH_UPPER_LIMIT} characters` + ); + } else if (!this.isValidLength(options.description)) { + throw new Error( + `Channel description should not exceed ${LENGTH_UPPER_LIMIT} characters` + ); + } else if ( + !this.isValidLength(options.url) || + !this.isValidUrl(options.url) + ) { + throw new Error( + `Channel url either excees ${LENGTH_UPPER_LIMIT} characters or is not a valid url` + ); + } else { + return true; + } + } + + private validateChannelParameters(options: CreateChannelOptions): boolean { + return ( + this.verifyEmptyChannelParameters(options) && + this.validateParameterLength(options) + ); + } + + // create contract instance + public createContractInstance( + contractAddress: string | `0x${string}`, + contractABI: any, + network: Chain + ) { + let contract: any; + if ( + !('_signTypedData' in this.signer!) && + !('signTypedData' in this.signer!) + ) { + throw new Error('Unsupported signer type'); + } else if ('_signTypedData' in this.signer) { + if (!this.signer?.provider) { + throw new Error('Provider is required'); + } + contract = new ethers.Contract( + contractAddress, + contractABI, + this.signer as unknown as Signer + ); + } else if ('signTypedData' in this.signer) { + const client = createPublicClient({ + chain: network, + transport: http(), + }); + contract = getContract({ + abi: contractABI, + address: contractAddress as `0x${string}`, + publicClient: client, + walletClient: this.signer as unknown as WalletClient, + }); + } else { + throw new Error('Unsupported signer type'); + } + return contract; + } + + private async fetchBalance(contract: any, userAddress: string) { + let balance: BigNumber; + try { + if ('_signTypedData' in this.signer!) { + balance = await contract!['balanceOf'](userAddress); + } else if ('signTypedData' in this.signer!) { + const balanceInBigInt = await contract.read.balanceOf({ + args: [userAddress], + }); + balance = ethers.BigNumber.from(balanceInBigInt); + } else { + throw new Error('Unsupported signer'); + } + return balance; + } catch (error) { + console.log(error); + throw new Error(JSON.stringify(error)); + } + } + + private async fetchAllownace( + contract: any, + userAddress: string, + spenderAddress: string + ) { + let allowance: BigNumber; + try { + if ('_signTypedData' in this.signer!) { + allowance = await contract!['allowance'](userAddress, spenderAddress); + } else if ('signTypedData' in this.signer!) { + const allowanceInBigInt = await contract.read.allowance({ + args: [userAddress, spenderAddress], + }); + allowance = ethers.BigNumber.from(allowanceInBigInt); + } else { + throw new Error('Unsupported signer'); + } + return allowance; + } catch (error) { + throw new Error(JSON.stringify(error)); + } + } + + private async approveToken( + contract: any, + spenderAddress: string, + amount: string | BigNumber + ) { + try { + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const approvalTrxPromise = contract!['approve'](spenderAddress, amount); + const approvalTrx = await approvalTrxPromise; + await this.signer?.provider?.waitForTransaction(approvalTrx.hash); + // console.log(approvalTrx.hash) + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const approvalTrxPromise = contract.write.approve({ + args: [spenderAddress, amount], + }); + const approvalTrxRes = await approvalTrxPromise; + // console.log(approvalTrxRes); + } else { + throw new Error('Unsupported signer'); + } + return true; + } catch (error) { + console.log(error); + return false; + } + } + + private async createChannel( + contract: any, + channelType: number, + identityBytes: Uint8Array, + fees: BigNumber + ) { + let createChannelRes; + try { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + if ('_signTypedData' in this.signer!) { + const createChannelPromise = contract!['createChannelWithPUSH']( + channelType, + identityBytes, + fees, + this.getTimeBound(), + { + gasLimit: 1000000, + } + ); + const createChannelTrx = await createChannelPromise; + const createChannelTrxStatus = + await this.signer?.provider?.waitForTransaction( + createChannelTrx.hash + ); + if (createChannelTrxStatus?.status == 0) { + throw new Error('Something Went wrong while creating your channel'); + } + createChannelRes = createChannelTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const createChannelPromise = contract.write.createChannelWithPUSH({ + args: [channelType, identityBytes, fees, this.getTimeBound()], + }); + createChannelRes = await createChannelPromise; + } + + return createChannelRes; + } catch (error: any) { + throw new Error(error?.message); + } + } + + private async updateChannel( + contract: any, + account: string, + identityBytes: Uint8Array, + fees: BigNumber + ) { + let updateChannelRes; + try { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + if ('_signTypedData' in this.signer!) { + const updateChannelPromise = contract!['updateChannelMeta']( + account, + identityBytes, + fees, + { + gasLimit: 1000000, + } + ); + const updateChannelTrx = await updateChannelPromise; + const updateChannelTrxStatus = + await this.signer?.provider?.waitForTransaction( + updateChannelTrx.hash + ); + if (updateChannelTrxStatus?.status == 0) { + throw new Error('Something Went wrong while creating your channel'); + } + updateChannelRes = updateChannelTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const updateChannelPromise = contract.write.createChannelWithPUSH({ + args: [account, identityBytes, fees], + }); + updateChannelRes = await updateChannelPromise; + } + + return updateChannelRes; + } catch (error: any) { + throw new Error(error?.message); + } + } + + private async verifyChannel(contract: any, channelToBeVerified: string) { + try { + let verifyTrxRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const verifyTrxPromise = contract!['verify'](channelToBeVerified); + const verifyTrx = await verifyTrxPromise; + await this.signer?.provider?.waitForTransaction(verifyTrx.hash); + verifyTrxRes = verifyTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const verifyTrxPromise = contract.write.verify({ + args: [channelToBeVerified], + }); + verifyTrxRes = await verifyTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return verifyTrxRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + private async createChanelSettings( + contract: any, + numberOfSettings: number, + settings: string, + description: string, + fees: BigNumber + ) { + try { + let createSettingsRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const createSettingsPromise = contract!['createChannelSettings']( + numberOfSettings, + settings, + description, + fees + ); + const createSettings = await createSettingsPromise; + await this.signer?.provider?.waitForTransaction(createSettings.hash); + createSettingsRes = createSettings.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const createSettingsTrxPromise = contract.write.createChannelSettings({ + args: [numberOfSettings, settings, description, fees], + }); + createSettingsRes = await createSettingsTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return createSettingsRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + private async addDelegator(contract: any, delegatee: string) { + try { + let addDelegateRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const addDelegateTrxPromise = contract!['addDelegate'](delegatee); + const addDelegateTrx = await addDelegateTrxPromise; + await this.signer?.provider?.waitForTransaction(addDelegateTrx.hash); + addDelegateRes = addDelegateTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const addDelegateTrxPromise = contract.write.addDelegate({ + args: [delegatee], + }); + addDelegateRes = await addDelegateTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return addDelegateRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + private async removeDelegator(contract: any, delegatee: string) { + try { + let removeDelegateRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const removeDelegateTrxPromise = contract!['removeDelegate'](delegatee); + const removeDelegateTrx = await removeDelegateTrxPromise; + await this.signer?.provider?.waitForTransaction(removeDelegateTrx.hash); + removeDelegateRes = removeDelegateTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const removeDelegateTrxPromise = contract.write.removeDelegate({ + args: [delegatee], + }); + removeDelegateRes = await removeDelegateTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return removeDelegateRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + private async getChianId(signer: SignerType) { + let chainId; + if ('_signTypedData' in signer!) { + const chainDetails = await signer?.provider?.getNetwork(); + chainId = chainDetails?.chainId; + } else if ('signTypedData' in signer!) { + chainId = await signer.getChainId(); + } + return chainId; + } + + private async uploadToIPFSViaPushNode(data: string): Promise { + try { + const response = await axios.post( + `${config.CORE_CONFIG[this.env!].API_BASE_URL}/v1/ipfs/upload`, + { data } + ); + return response.data.cid as string; + } catch (error) { + throw new Error('Something went wrong while uploading data to IPFS'); + } + } + + private getTimeBound(timeStamp?: number) { + // for now returns 0 for non-time bound. Later it can be modified to handle time bound channels + return 0; + } + + private getMinimalSetting(configuration: NotificationSettings): { + setting: string; + description: string; + } { + let notificationSetting = ''; + let notificationSettingDescription = ''; + for (let i = 0; i < configuration.length; i++) { + const ele = configuration[i]; + if (ele.type == 0) { + notificationSetting = + notificationSetting + + SETTING_SEPARATOR + + ele.type + + SETTING_DELIMITER + + ele.default; + notificationSettingDescription = + notificationSettingDescription + ele.description; + } + if (ele.type == 1) { + if (ele.data) { + notificationSetting = + notificationSetting + + SETTING_SEPARATOR + + ele.type + + SETTING_DELIMITER + + ele.default + + SETTING_DELIMITER + + ele.data.lower + + SETTING_DELIMITER + + ele.data.upper; + + notificationSettingDescription = + notificationSettingDescription + ele.description; + } + } + } + return { + setting: notificationSetting.replace(/^\+/, ''), + description: notificationSettingDescription, + }; + } + notification = { + /** + * @description - Fetches feeds and spam feeds for a specific user + * @param {enums} spam - indicates if its a spam or not. `INBOX` for non-spam and `SPAM` for spam. default `INBOX` + * @param {string} [options.user] - user address, defaults to address from signer + * @param {number} [options.page] - page number. default is set to Constants.PAGINATION.INITIAL_PAGE + * @param {number} [options.limit] - number of feeds per page. default is set to Constants.PAGINATION.LIMIT + * @param {boolean} [options.raw] - indicates if the response should be raw or formatted. defaults is set to false + * @returns feeds for a specific address + */ + list: async ( + spam: `${FeedType}` = FeedType.INBOX, + options?: FeedsOptions + ) => { + const { + account = this.account + ? getFallbackETHCAIPAddress(this.env!, this.account!) + : null, + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + channels = [], + raw = false, + } = options || {}; + try { + // guest mode and valid address check + this.checkUserAddressExists(account!); + if (!validateCAIP(account!)) { + throw new Error('Invalid CAIP'); + } + const nonCaipAccount = + account?.split(':')[account?.split(':').length - 1]; + if (channels.length == 0) { + // else return the response + return await PUSH_USER.getFeeds({ + user: nonCaipAccount!, + page: page, + limit: limit, + spam: FEED_MAP[spam], + raw: raw, + env: this.env, + }); + } else { + return await PUSH_USER.getFeedsPerChannel({ + user: nonCaipAccount!, + page: page, + limit: limit, + spam: FEED_MAP[spam], + raw: raw, + env: this.env, + channels: channels, + }); + } + } catch (error) { + throw new Error(`Push SDK Error: API : notifcaiton::list : ${error}`); + } + }, + + subscriptions: async (options?: SubscriptionOptions) => { + try { + const { + account = this.account, + // TODO: to be used once pagination is implemeted at API level + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + } = options || {}; + this.checkUserAddressExists(account!); + return await PUSH_USER.getSubscriptions({ + user: account!, + env: this.env, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : notifcaiton::subscriptions : ${error}` + ); + } + }, + /** + * Subscribes a user to a channel + * @param {string} channel - channel address in caip format + * @param {function} [options.onSuccess] - callback function when a user successfully subscribes to a channel + * @param {function} [options.onError] - callback function incase a user was not able to subscribe to a channel + * @returns Subscribe status object + */ + subscribe: async ( + channel: string, + options?: SubscribeUnsubscribeOptions + ) => { + try { + const { onSuccess, onError } = options || {}; + // Vaidatiions + // validates if signer object is present + this.checkSignerObjectExists(); + // validates if the user address exists + this.checkUserAddressExists(); + // validates if channel exists + if (!channel && channel != '') { + throw new Error(ERROR_CHANNEL_NEEDED); + } + // validates if caip is correct + if (!validateCAIP(channel)) { + throw new Error(ERROR_INVALID_CAIP); + } + // get channel caip + const caipDetail = getCAIPDetails(channel); + // based on the caip, construct the user caip + const userAddressInCaip = getCAIPWithChainId( + this.account!, + parseInt(caipDetail?.networkId as string) + ); + return await PUSH_CHANNEL.subscribe({ + signer: this.signer!, + channelAddress: channel, + userAddress: userAddressInCaip, + env: this.env, + onSuccess: onSuccess, + onError: onError, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : notifcaiton::subscribe : ${error}` + ); + } + }, + + /** + * Unsubscribes a user to a channel + * @param {string} channel - channel address in caip format + * @param {function} [options.onSuccess] - callback function when a user successfully unsubscribes to a channel + * @param {function} [options.onError] - callback function incase a user was not able to unsubscribe to a channel + * @returns Unsubscribe status object + */ + unsubscribe: async ( + channel: string, + options?: SubscribeUnsubscribeOptions + ) => { + try { + const { onSuccess, onError } = options || {}; + // Vaidatiions + // validates if the user address exists + this.checkUserAddressExists(); + // validates if signer object is present + this.checkSignerObjectExists(); + // validates if channel exists + if (!channel && channel != '') { + return new Error(ERROR_CHANNEL_NEEDED); + } + // validates if caip is correct + if (!validateCAIP(channel)) { + return new Error(ERROR_INVALID_CAIP); + } + const caipDetail = getCAIPDetails(channel); + const userAddressInCaip = getCAIPWithChainId( + this.account!, + parseInt(caipDetail?.networkId as string) + ); + return await PUSH_CHANNEL.unsubscribe({ + signer: this.signer!, + channelAddress: channel, + userAddress: userAddressInCaip, + env: this.env, + onSuccess: onSuccess, + onError: onError, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : notifcaiton::unsubscribe : ${error}` + ); + } + }, + }; + + channel = { + /** + * @description - returns information about a channel + * @param {string} [options.channel] - channel address in caip, defaults to eth caip address + * @returns information about the channel if it exists + */ + info: async (channel?: string) => { + try { + this.checkUserAddressExists(channel); + channel = + channel ?? getFallbackETHCAIPAddress(this.env!, this.account!); + return await PUSH_CHANNEL.getChannel({ + channel: channel as string, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::info : ${error}`); + } + }, + + /** + * @description - returns relevant information as per the query that was passed + * @param {string} query - search query + * @param {number} [options.page] - page number. default is set to Constants.PAGINATION.INITIAL_PAGE + * @param {number} [options.limit] - number of feeds per page. default is set to Constants.PAGINATION.LIMIT + * @returns Array of results relevant to the serach query + */ + search: async (query: string, options?: ChannelSearchOptions) => { + try { + const { + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + } = options || {}; + return await PUSH_CHANNEL.search({ + query: query, + page: page, + limit: limit, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::search : ${error}`); + } + }, + /** + * @description - Get subscribers of a channell + * @param {string} [options.channel] - channel in caip. defaults to account from signer with eth caip + * @returns array of subscribers + */ + subscribers: async (options?: ChannelInfoOptions) => { + try { + const { + channel = this.account + ? getFallbackETHCAIPAddress(this.env!, this.account!) + : null, + } = options || {}; + + this.checkUserAddressExists(channel!); + if (!validateCAIP(channel!)) { + throw new Error('Invalid CAIP'); + } + return await PUSH_CHANNEL._getSubscribers({ + channel: channel!, + env: this.env, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : channel::subscribers : ${error}` + ); + } + }, + /** + * + * @param {string[]} recipients - Array of recipients. `['0x1'] -> TARGET`, `['0x1, 0x2'] -> SUBSET`, `['*'] -> BROADCAST` + * @param {object} options - Notification options + * @returns + */ + send: async (recipients: string[], options: NotificationOptions) => { + try { + this.checkSignerObjectExists(); + const lowLevelPayload = this.generateNotificationLowLevelPayload({ + signer: this.signer!, + env: this.env!, + recipients: recipients, + options: options, + channel: options.channel ?? this.account, + }); + return await PUSH_PAYLOAD.sendNotification(lowLevelPayload); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::send : ${error}`); + } + }, + + create: async (options: CreateChannelOptions) => { + const { + name, + description, + url, + icon, + alias = null, + progressHook, + } = options || {}; + try { + // create push token instance + let aliasInfo; + this.checkSignerObjectExists(); + if (!this.signer || !this.signer?.provider) { + throw new Error('Provider is required'); + } + // validate all the parameters and length + this.validateChannelParameters(options); + // check for PUSH balance + const pushTokenContract = await this.createContractInstance( + config.TOKEN[this.env!], + config.ABIS.TOKEN, + config.TOKEN_VIEM_NETWORK_MAP[this.env!] + ); + const balance = await this.fetchBalance( + pushTokenContract, + this.account! + ); + const fees = ethers.utils.parseUnits( + config.MIN_TOKEN_BALANCE[this.env!].toString(), + 18 + ); + if (fees.gte(balance)) { + throw new Error('Insufficient PUSH balance'); + } + // if alias is passed, check for the caip + if (alias) { + if (!validateCAIP(alias)) { + throw new Error('Invalid alias CAIP'); + } + const aliasDetails = getCAIPDetails(alias); + aliasInfo = { + [`${aliasDetails?.blockchain}:${aliasDetails?.networkId}`]: + aliasDetails?.address, + }; + } + // construct channel identity + progressHook?.(PROGRESSHOOK['PUSH-CREATE-01'] as ProgressHookType); + const input = { + name: name, + info: description, + url: url, + icon: icon, + aliasDetails: aliasInfo ?? {}, + }; + const cid = await this.uploadToIPFSViaPushNode(JSON.stringify(input)); + const allowanceAmount = await this.fetchAllownace( + pushTokenContract, + this.account!, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT + ); + if (!allowanceAmount.gte(fees)) { + progressHook?.(PROGRESSHOOK['PUSH-CREATE-02'] as ProgressHookType); + const approvalRes = await this.approveToken( + pushTokenContract, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, + fees + ); + if (!approvalRes) { + throw new Error('Something went wrong while approving the token'); + } + } + // generate the contract parameters + const channelType = config.CHANNEL_TYPE['GENERAL']; + const identity = '1+' + cid; + const identityBytes = ethers.utils.toUtf8Bytes(identity); + // call contract + progressHook?.(PROGRESSHOOK['PUSH-CREATE-03'] as ProgressHookType); + const createChannelRes = await this.createChannel( + this.coreContract, + channelType, + identityBytes, + fees + ); + progressHook?.(PROGRESSHOOK['PUSH-CREATE-04'] as ProgressHookType); + return { transactionHash: createChannelRes }; + } catch (error) { + const errorProgressHook = PROGRESSHOOK[ + 'PUSH-ERROR-02' + ] as ProgressHookTypeFunction; + progressHook?.(errorProgressHook('Create Channel', error)); + throw new Error( + `Push SDK Error: Contract : createChannelWithPUSH : ${error}` + ); + } + }, + + update: async (options: CreateChannelOptions) => { + const { + name, + description, + url, + icon, + alias = null, + progressHook, + } = options || {}; + try { + // create push token instance + let aliasInfo; + this.checkSignerObjectExists(); + if (!this.signer || !this.signer.provider) { + throw new Error('Provider is required'); + } + // validate all the parameters and length + this.validateChannelParameters(options); + // check for PUSH balance + const pushTokenContract = await this.createContractInstance( + config.TOKEN[this.env!], + config.ABIS.TOKEN, + config.TOKEN_VIEM_NETWORK_MAP[this.env!] + ); + const balance = await this.fetchBalance( + pushTokenContract, + this.account! + ); + const fees = ethers.utils.parseUnits( + config.MIN_TOKEN_BALANCE[this.env!].toString(), + 18 + ); + if (fees.gt(balance)) { + throw new Error('Insufficient PUSH balance'); + } + // if alias is passed, check for the caip + if (alias) { + if (!validateCAIP(alias)) { + throw new Error('Invalid alias CAIP'); + } + const aliasDetails = getCAIPDetails(alias); + aliasInfo = { + [`${aliasDetails?.blockchain}:${aliasDetails?.networkId}`]: + aliasDetails?.address, + }; + } + // construct channel identity + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-01'] as ProgressHookType); + const input = { + name: name, + info: description, + url: url, + icon: icon, + aliasDetails: aliasInfo ?? {}, + }; + const cid = await this.uploadToIPFSViaPushNode(JSON.stringify(input)); + // approve the tokens to core contract + const allowanceAmount = await this.fetchAllownace( + pushTokenContract, + this.account!, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT + ); + // if allowance is not greater than the fees, dont call approval again + if (!allowanceAmount.gte(fees)) { + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-02'] as ProgressHookType); + const approvalRes = await this.approveToken( + pushTokenContract, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, + fees + ); + if (!approvalRes) { + throw new Error('Something went wrong while approving the token'); + } + } + // generate the contract parameters + const identity = '1+' + cid; + const identityBytes = ethers.utils.toUtf8Bytes(identity); + // call contract + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-03'] as ProgressHookType); + const updateChannelRes = await this.updateChannel( + this.coreContract, + this.account!, + identityBytes, + fees + ); + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-04'] as ProgressHookType); + return { transactionHash: updateChannelRes }; + } catch (error) { + const errorProgressHook = PROGRESSHOOK[ + 'PUSH-ERROR-02' + ] as ProgressHookTypeFunction; + progressHook?.(errorProgressHook('Update Channel', error)); + throw new Error(`Push SDK Error: Contract channel::update : ${error}`); + } + }, + /** + * @description verifies a channel + * @param {string} channelToBeVerified - address of the channel to be verified + * @returns the transaction hash if the transaction is successful + */ + verify: async (channelToBeVerified: string) => { + try { + this.checkSignerObjectExists(); + if (validateCAIP(channelToBeVerified)) { + channelToBeVerified = channelToBeVerified.split(':')[2]; + } + // checks if it is a valid address + if (!ethers.utils.isAddress(channelToBeVerified)) { + throw new Error('Invalid channel address'); + } + // if valid, continue with it + const res = await this.verifyChannel( + this.coreContract, + channelToBeVerified + ); + if (!res) { + throw new Error('Something went wrong while verifying the channel'); + } + return { transactionHash: res }; + } catch (error) { + throw new Error(`Push SDK Error: Contract channel::verify : ${error}`); + } + }, + + setting: async (configuration: NotificationSettings) => { + try { + this.checkSignerObjectExists(); + // check for PUSH balance + const pushTokenContract = await this.createContractInstance( + config.TOKEN[this.env!], + config.ABIS.TOKEN, + config.TOKEN_VIEM_NETWORK_MAP[this.env!] + ); + const balance = await this.fetchBalance( + pushTokenContract, + this.account! + ); + const fees = ethers.utils.parseUnits( + config.MIN_TOKEN_BALANCE[this.env!].toString(), + 18 + ); + if (fees.gte(balance)) { + throw new Error('Insufficient PUSH balance'); + } + const allowanceAmount = await this.fetchAllownace( + pushTokenContract, + this.account!, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT + ); + // if allowance is not greater than the fees, dont call approval again + if (!allowanceAmount.gte(fees)) { + const approveRes = this.approveToken( + pushTokenContract, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, + fees + ); + if (!approveRes) { + throw new Error('Something went wrong while approving your token'); + } + } + const { setting, description } = this.getMinimalSetting(configuration); + const createSettingsRes = await this.createChanelSettings( + this.coreContract, + configuration.length, + setting, + description, + fees + ); + return { transactionHash: createSettingsRes }; + } catch (error) { + throw new Error( + `Push SDK Error: Contract : channel::setting : ${error}` + ); + } + }, + }; + + delegate = { + /** + * @description - Get delegates of a channell + * @param {string} [options.channel] - channel in caip. defaults to account from signer with eth caip + * @returns array of delegates + */ + get: async (options?: ChannelInfoOptions) => { + try { + const { + channel = this.account + ? getFallbackETHCAIPAddress(this.env!, this.account!) + : null, + } = options || {}; + this.checkUserAddressExists(channel!); + if (!validateCAIP(channel!)) { + throw new Error('Invalid CAIP'); + } + return await PUSH_CHANNEL.getDelegates({ + channel: channel!, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : delegate::get : ${error}`); + } + }, + + /** + * @description adds a delegate + * @param {string} delegate - delegate address in caip to be added + * @returns the transaction hash if the transaction is successfull + */ + add: async (delegate: string) => { + try { + if (!validateCAIP(delegate)) { + throw new Error('Invalid CAIP'); + } + + const networkDetails = await this.getChianId(this.signer!); + if (networkDetails !== parseInt(delegate.split(':')[1])) { + return new Error('Signer and CAIP chain id doesnt match'); + } + const caip = `eip155:${networkDetails}`; + if (!CONFIG[this.env!][caip] || !config.VIEM_CONFIG[this.env!][caip]) { + throw new Error('Unsupported Chainid'); + } + const commAddress = CONFIG[this.env!][caip].EPNS_COMMUNICATOR_CONTRACT; + const commContract = this.createContractInstance( + commAddress, + config.ABIS.COMM, + config.VIEM_CONFIG[this.env!][caip].NETWORK + ); + const addDelegateRes = await this.addDelegator( + commContract, + delegate.split(':')[2] + ); + return { transactionHash: addDelegateRes }; + } catch (error) { + throw new Error(`Push SDK Error: Contract : delegate::add : ${error}`); + } + }, + + /** + * @description removes a delegate + * @param {string} delegate - caip address of the delegate to be removed + * @returns the transaction hash if the transaction is successfull + */ + remove: async (delegate: string) => { + try { + this.checkSignerObjectExists(); + if (this.signer && !this.signer.provider) { + throw new Error('Provider is required'); + } + if (!validateCAIP(delegate)) { + throw new Error('Invalid CAIP'); + } + + const networkDetails = await this.getChianId(this.signer!); + if (networkDetails !== parseInt(delegate.split(':')[1])) { + return new Error('Signer and CAIP chain id doesnt match'); + } + const caip = `eip155:${networkDetails}`; + if (!CONFIG[this.env!][caip] || !config.VIEM_CONFIG[this.env!][caip]) { + throw new Error('Unsupported Chainid'); + } + const commAddress = CONFIG[this.env!][caip].EPNS_COMMUNICATOR_CONTRACT; + const commContract = this.createContractInstance( + commAddress, + config.ABIS.COMM, + config.VIEM_CONFIG[this.env!][caip].NETWORK + ); + const removeDelegateRes = await this.removeDelegator( + commContract, + delegate.split(':')[2] + ); + return { transactionHash: removeDelegateRes }; + } catch (error) { + throw new Error( + `Push SDK Error: Contract : delegate::remove : ${error}` + ); + } + }, + }; + + alias = { + /** + * @description - fetches alias information + * @param {AliasOptions} options - options related to alias + * @returns Alias details + */ + info: async (options: AliasOptions) => { + try { + return await PUSH_ALIAS.getAliasInfo({ ...options, env: this.env }); + } catch (error) { + throw new Error(`Push SDK Error: API : alias::info : ${error}`); + } + }, + }; +} diff --git a/packages/restapi/src/lib/pushNotification/PushNotificationTypes.ts b/packages/restapi/src/lib/pushNotification/PushNotificationTypes.ts new file mode 100644 index 000000000..bc83e881c --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/PushNotificationTypes.ts @@ -0,0 +1,104 @@ +import { ProgressHookType } from '../types'; +import { GetAliasInfoOptionsType } from '../alias'; +import { + ADDITIONAL_META_TYPE, +} from '../../lib/payloads/constants'; + +export type SubscriptionOptions = { + account?: string; + page?: number; + limit?: number; +}; +export type ChannelInfoOptions = { + channel?: string; +}; + +export type SubscribeUnsubscribeOptions = { + onSuccess?: () => void; + onError?: (err: Error) => void; +}; + +export type AliasOptions = Omit; + +export enum FeedType { + INBOX = 'INBOX', + SPAM = 'SPAM', +} + +export type FeedsOptions = { + account?: string; + //TODO: change it to string[] once we start supporting multiple channel + channels?: [string]; + page?: number; + limit?: number; + raw?: boolean; +}; + +export type ChannelSearchOptions = { + page?: number; + limit?: number; +}; + +// Types related to notification +export type INotification = { + title: string; + body: string; +}; + +export type IPayload = { + title?: string; + body?: string; + cta?: string; + embed?: string; + meta?: { + domain?: string; + type: `${ADDITIONAL_META_TYPE}+${number}`; + data: string; + }; +}; + +export type IConfig = { + expiry?: number; + silent?: boolean; + hidden?: boolean; +}; + +export type IAdvance = { + graph?: { + id: string; + counter: number; + }; + ipfs?: string; + minimal?: string; + chatid?: string; + pgpPrivateKey?: string; +}; + +export type NotificationOptions = { + notification: INotification; + payload?: IPayload; + config?: IConfig; + advanced?: IAdvance; + channel?: string; +}; + +export type CreateChannelOptions = { + name: string; + description: string; + icon: string; + url: string; + alias?: string; + progressHook?: (progress: ProgressHookType) => void; +}; + +export type NotificationSetting = { + type: number, + default: number, + description: string, + data?: { + upper: number; + lower: number; + } +} + +export type NotificationSettings = NotificationSetting[] \ No newline at end of file diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index 13e5f3a98..f47ee89cc 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -31,7 +31,6 @@ export class PushAPI { private account: string; private decryptedPgpPvtKey: string; private pgpPublicKey: string; - private env: ENV; private progressHook?: (progress: ProgressHookType) => void; @@ -49,6 +48,7 @@ export class PushAPI { this.decryptedPgpPvtKey = decryptedPgpPvtKey; this.pgpPublicKey = pgpPublicKey; this.progressHook = progressHook; + } static async initialize( @@ -585,4 +585,4 @@ export class PushAPI { }); }, }; -} +} \ No newline at end of file diff --git a/packages/restapi/src/lib/pushapi/pushAPITypes.ts b/packages/restapi/src/lib/pushapi/pushAPITypes.ts index 391598ffe..dc6717a79 100644 --- a/packages/restapi/src/lib/pushapi/pushAPITypes.ts +++ b/packages/restapi/src/lib/pushapi/pushAPITypes.ts @@ -45,4 +45,4 @@ export interface GroupUpdateOptions { status?: ChatStatus | null; meta?: string | null; rules?: Rules | null; -} +} \ No newline at end of file diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index b197b515b..2ca869d70 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -537,7 +537,7 @@ export interface UserInfo { isAdmin: boolean; } -type ethersV5SignerType = { +export type ethersV5SignerType = { _signTypedData: ( domain: TypedDataDomain, types: Record>, @@ -549,7 +549,7 @@ type ethersV5SignerType = { privateKey?: string; provider?: providers.Provider; }; -type viemSignerType = { +export type viemSignerType = { signTypedData: (args: { account: any; domain: any; @@ -566,6 +566,7 @@ type viemSignerType = { account: { [key: string]: any }; privateKey?: string; provider?: providers.Provider; + }; export type SignerType = ethersV5SignerType | viemSignerType; diff --git a/packages/restapi/src/lib/user/getFeedsPerChannel.ts b/packages/restapi/src/lib/user/getFeedsPerChannel.ts new file mode 100644 index 000000000..fb6d902d4 --- /dev/null +++ b/packages/restapi/src/lib/user/getFeedsPerChannel.ts @@ -0,0 +1,57 @@ +import axios from 'axios'; +import { + getCAIPAddress, + getAPIBaseUrls, + getQueryParams, + getLimit, +} from '../helpers'; +import Constants, { ENV } from '../constants'; +import { parseApiResponse } from '../utils'; + +export type FeedsPerChannelOptionsType = { + user: string; + env?: ENV; + channels?: [string]; + page?: number; + limit?: number; + spam?: boolean; + raw?: boolean; +}; + +export const getFeedsPerChannel = async (options: FeedsPerChannelOptionsType) => { + const { + user, + env = Constants.ENV.PROD, + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + spam = false, + raw = false, + channels = [], + } = options || {}; + + const _user = await getCAIPAddress(env, user, 'User'); + const API_BASE_URL = getAPIBaseUrls(env); + if (channels.length == 0) { + throw new Error('channels cannot be empty'); + } + const _channel = await getCAIPAddress(env, channels[0], 'Channel'); + const apiEndpoint = `${API_BASE_URL}/v1/users/${_channel}/channels/${_user}/feeds`; + const queryObj = { + page, + limit: getLimit(limit), + spam, + }; + + const requestUrl = `${apiEndpoint}?${getQueryParams(queryObj)}`; + return axios + .get(requestUrl) + .then((response) => { + if (raw) { + return response?.data?.feeds || []; + } + return parseApiResponse(response?.data?.feeds) || []; + }) + .catch((err) => { + console.error(`[Push SDK] - API ${requestUrl}: `, err); + }); +}; diff --git a/packages/restapi/src/lib/user/index.ts b/packages/restapi/src/lib/user/index.ts index 3c3affd54..d5c2b9084 100644 --- a/packages/restapi/src/lib/user/index.ts +++ b/packages/restapi/src/lib/user/index.ts @@ -9,6 +9,8 @@ export * from './getUsersBatch'; export * from './upgradeUser'; export * from './decryptAuth'; export * from './createUserWithProfile'; +export * from './getFeedsPerChannel'; + export const auth = { update: authUpdate, }; diff --git a/packages/restapi/tests/lib/pushNotification/channel.test.ts b/packages/restapi/tests/lib/pushNotification/channel.test.ts new file mode 100644 index 000000000..f8438e62c --- /dev/null +++ b/packages/restapi/tests/lib/pushNotification/channel.test.ts @@ -0,0 +1,257 @@ +import * as path from 'path'; +import * as dotenv from 'dotenv'; +dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); + +import { PushNotification } from '../../../src/lib/pushNotification/PushNotification'; // Ensure correct import path +import { expect } from 'chai'; +import { ethers } from 'ethers'; + +describe('PushAPI.channel functionality', () => { + let userAlice: PushNotification; + let userBob: PushNotification; + let userKate: PushNotification; + let signer1: any; + let account1: string; + let signer2: any; + let account2: string; + + beforeEach(async () => { + signer1 = new ethers.Wallet(`0x${process.env['WALLET_PRIVATE_KEY']}`); + account1 = await signer1.getAddress(); + + const provider = new ethers.providers.JsonRpcProvider( + // PUBLIC RPC + 'https://goerli.blockpi.network/v1/rpc/public' + ); + + signer2 = new ethers.Wallet( + `0x${process.env['WALLET_PRIVATE_KEY']}`, + provider + ); + account2 = await signer2.getAddress(); + + // initialisation with signer and provider + userKate = await PushNotification.initialize(signer2); + // initialisation with signer + userAlice = await PushNotification.initialize(signer1); + // initialisation without signer + userBob = await PushNotification.initialize(); + }); + + describe('channel :: info', () => { + it('Without signer and account: Should throw error', async () => { + await expect(() => userBob.channel.info()).to.Throw; + }); + + it('Without signer but with non-caip account: Should return response', async () => { + const res = await userBob.channel.info( + '0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + expect(res).not.null; + }); + + it('Without signer and with valid caip account: Should return response', async () => { + const res = await userBob.channel.info( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + // console.log(res); + expect(res).not.null; + }); + }); + + describe('channel :: search', () => { + it('Without signer and account : Should return response', async () => { + const res = await userBob.channel.search(' '); + // console.log(res); + expect(res).not.null; + }); + + it('With signer: Should return response', async () => { + const res = await userBob.channel.search(' '); + // console.log(res); + expect(res).not.null; + }); + + it('Should throw error for empty query', async () => { + await expect(() => userBob.channel.search('')).to.Throw; + }); + }); + + describe('channel :: subscribers', () => { + it('Without signer and account : Should throw error', async () => { + await expect(() => userBob.channel.subscribers()).to.Throw; + }); + + it('Without signer and account : Should return response as address is passed', async () => { + const res = await userBob.channel.subscribers({ + channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + }); + expect(res).not.null; + }); + + it('Without signer and account : Should return response for alias address', async () => { + const res = await userBob.channel.subscribers({ + channel: 'eip155:80001:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + }); + expect(res).not.null; + }); + + it('Without signer and account : Should return response without passing the options', async () => { + const res = await userKate.channel.subscribers(); + expect(res).not.null; + }); + + it('Without signer and account : Should throw error for invalid caip', async () => { + await expect(() => + userBob.channel.subscribers({ + channel: '0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + }) + ).to.Throw; + }); + }); + + describe('channel :: send', () => { + it('Without signer and account : Should throw error', async () => { + await expect(() => { + userBob.channel.send(['*'], { + notification: { + title: 'test', + body: 'test', + }, + }); + }).to.Throw; + }); + + it('With signer : broadcast : Should send notification with title and body', async () => { + const res = await userAlice.channel.send(['*'], { + notification: { + title: 'test', + body: 'test', + }, + }); + expect(res.status).to.equal(204); + }); + + it('With signer : targeted : Should send notification with title and body', async () => { + const res = await userAlice.channel.send( + ['eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681'], + { + notification: { + title: 'hi', + body: 'test-targeted', + }, + } + ); + expect(res.status).to.equal(204); + }); + + it('With signer : targeted : Should send notification with title and body', async () => { + const res = await userAlice.channel.send( + ['eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681'], + { + notification: { + title: 'hi', + body: 'test-targeted', + }, + } + ); + expect(res.status).to.equal(204); + }); + + it('With signer : subset : Should send notification with title and body', async () => { + const res = await userAlice.channel.send( + [ + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + 'eip155:5:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + ], + { + notification: { + title: 'hi', + body: 'test-targeted', + }, + } + ); + expect(res.status).to.equal(204); + }); + + it('With signer : subset : Should send notification with title and body along with additional options', async () => { + const res = await userAlice.channel.send( + [ + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + 'eip155:5:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + ], + { + notification: { + title: 'hi', + body: 'test-targeted', + }, + payload: { + title: 'testing first notification', + body: 'testing with random body', + cta: 'https://google.com/', + embed: 'https://avatars.githubusercontent.com/u/64157541?s=200&v=4', + }, + } + ); + expect(res.status).to.equal(204); + }); + + it('With signer : subset : Should send notification with title and body along with additional options', async () => { + const res = await userAlice.channel.send( + [ + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + 'eip155:5:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + ], + { + notification: { + title: 'hi', + body: 'test-subset', + }, + payload: { + title: 'testing first subset notification', + body: 'testing with random body', + cta: 'https://google.com/', + embed: 'https://avatars.githubusercontent.com/u/64157541?s=200&v=4', + }, + } + ); + expect(res.status).to.equal(204); + }); + + it('With signer : subset : Should send notification with title and body along with additional options for alias', async () => { + const res = await userAlice.channel.send( + [ + 'eip155:97:0xD8634C39BBFd4033c0d3289C4515275102423681', + 'eip155:97:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + ], + { + notification: { + title: 'hi', + body: 'test-subset', + }, + payload: { + title: 'testing first subset notification', + body: 'testing with random body', + cta: 'https://google.com/', + embed: 'https://avatars.githubusercontent.com/u/64157541?s=200&v=4', + }, + channel: 'eip155:97:0xD8634C39BBFd4033c0d3289C4515275102423681', + } + ); + expect(res.status).to.equal(204); + }); + }); + + describe.skip('channel :: update', () => { + it('Should update channel meta', async () => { + const res = await userKate.channel.update({ + name: 'Updated Name', + description: 'Testing new description', + url: 'https://google.com', + icon: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAz0lEQVR4AcXBsU0EQQyG0e+saWJ7oACiKYDMEZVs6GgSpC2BIhzRwAS0sgk9HKn3gpFOAv3v3V4/3+4U4Z1q5KTy42Ql940qvFONnFSGmCFmiN2+fj7uCBlihpgh1ngwcvKfwjuVIWaIGWKNB+GdauSk8uNkJfeNKryzYogZYoZY40m5b/wlQ8wQM8TayMlKeKcaOVkJ71QjJyuGmCFmiDUe+HFy4VyEd57hx0mV+0ZliBlihlgL71w4FyMnVXhnZeSkiu93qheuDDFDzBD7BcCyMAOfy204AAAAAElFTkSuQmCC', + }); + // console.log(res) + expect(res).not.null + }, 10000000000); + }); +}); diff --git a/packages/restapi/tests/lib/pushNotification/delegate.test.ts b/packages/restapi/tests/lib/pushNotification/delegate.test.ts new file mode 100644 index 000000000..5a9f12811 --- /dev/null +++ b/packages/restapi/tests/lib/pushNotification/delegate.test.ts @@ -0,0 +1,126 @@ +import * as path from 'path'; +import * as dotenv from 'dotenv'; +dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); + +import { PushNotification } from '../../../src/lib/pushNotification/PushNotification'; // Ensure correct import path +import { expect } from 'chai'; +import { ethers } from 'ethers'; +// import tokenABI from './tokenABI'; +describe('PushAPI.notification functionality', () => { + let userAlice: PushNotification; + let userBob: PushNotification; + let userKate: PushNotification; + let signer1: any; + let account1: string; + let signer2: any; + let account2: string; + + beforeEach(async () => { + signer1 = new ethers.Wallet(`0x${process.env['WALLET_PRIVATE_KEY']}`); + account1 = await signer1.getAddress(); + + const provider = new ethers.providers.JsonRpcProvider( + 'https://goerli.blockpi.network/v1/rpc/public' + ); + + signer2 = new ethers.Wallet( + `0x${process.env['WALLET_PRIVATE_KEY']}`, + provider + ); + account2 = await signer2.getAddress(); + + // initialisation with signer and provider + userKate = await PushNotification.initialize(signer2); + // initialisation with signer + userAlice = await PushNotification.initialize(signer1); + // initialisation without signer + userBob = await PushNotification.initialize(); + }); + + describe('delegate :: add', () => { + it('Without signer and account :: should throw error', async () => { + await expect(() => + userBob.delegate.add( + 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ) + ).to.Throw; + }); + + it('With signer and without provider :: should throw error', async () => { + await expect(() => + userAlice.delegate.add( + 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ) + ).to.Throw; + }); + + it('With signer and provider :: should add delegate', async () => { + const res = await userKate.delegate.add( + 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ); + // console.log(res); + expect(res).not.null; + }, 100000000); + + it('With signer and provider :: should throw error as delegate caip and provider doesnt match', async () => { + await expect(() => + userKate.delegate.add( + 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ) + ).to.Throw; + }); + + it('With signer and provider :: should throw error as delegate caip and provider doesnt match', async () => { + // create polygon mumbai provider + const provider = new ethers.providers.JsonRpcProvider( + 'https://rpc-mumbai.maticvigil.com' + ); + + signer2 = new ethers.Wallet( + `0x${process.env['WALLET_PRIVATE_KEY']}`, + provider + ); + userKate = await PushNotification.initialize(signer2); + const res = await userKate.delegate.add( + 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ); + // console.log(res); + expect(res).not.null; + }, 10000000); + }); + + describe('delegate :: get', () => { + it('Without signer and account : Should throw error', async () => { + await expect(() => userBob.delegate.get()).to.Throw; + }); + it('Without signer : Should throw error for non-caip format', async () => { + await expect(() => + userBob.delegate.get({ + channel: '0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924', + }) + ).to.Throw; + }); + + it('Without signer : Should fetch delegates', async () => { + const res = await userBob.delegate.get({ + channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + }); + // console.log(res) + expect(res).not.null; + }); + + it('Without signer : Should fetch delegates for alias', async () => { + const res = await userBob.delegate.get({ + channel: 'eip155:80001:0xD8634C39BBFd4033c0d3289C4515275102423681', + }); + // console.log(res) + expect(res).not.null; + }); + + it('With signer : Should fetch delegates for channel', async () => { + const res = await userKate.delegate.get(); + // console.log(res); + expect(res).not.null; + }); + }); +}); diff --git a/packages/restapi/tests/lib/pushNotification/notification.test.ts b/packages/restapi/tests/lib/pushNotification/notification.test.ts new file mode 100644 index 000000000..283f1e726 --- /dev/null +++ b/packages/restapi/tests/lib/pushNotification/notification.test.ts @@ -0,0 +1,246 @@ +import * as path from 'path'; +import * as dotenv from 'dotenv'; +dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); + +import { PushNotification } from '../../../src/lib/pushNotification/PushNotification'; // Ensure correct import path +import { expect } from 'chai'; +import { ethers } from 'ethers'; +import { createWalletClient, http } from 'viem'; +import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; +import { goerli } from 'viem/chains'; +// import tokenABI from './tokenABI'; +describe('PushAPI.notification functionality', () => { + let userAlice: PushNotification; + let userBob: PushNotification; + let userKate: PushNotification; + let signer1: any; + let account1: string; + let signer2: any; + let account2: string; + let viemSigner: any; + let userViem: PushNotification; + beforeEach(async () => { + signer1 = new ethers.Wallet( + `0x${process.env['NFT_HOLDER_WALLET_PRIVATE_KEY_1']}` + ); + account1 = await signer1.getAddress(); + + const provider = new ethers.providers.JsonRpcProvider( + 'https://goerli.blockpi.network/v1/rpc/public' + ); + + signer2 = new ethers.Wallet( + `0x${process.env['NFT_HOLDER_WALLET_PRIVATE_KEY_1']}`, + provider + ); + account2 = await signer2.getAddress(); + viemSigner = createWalletClient({ + account: privateKeyToAccount( + `0x${process.env['NFT_HOLDER_WALLET_PRIVATE_KEY_1']}` + ), + chain: goerli, + transport: http(), + }); + // initialisation with signer and provider + userKate = await PushNotification.initialize(signer2); + // initialisation with signer + userAlice = await PushNotification.initialize(signer1); + // initialisation without signer + userBob = await PushNotification.initialize(); + // initialisation with viem + userViem = await PushNotification.initialize(viemSigner); + }); + + describe('notification :: list', () => { + it('Should return feeds with signer object', async () => { + const response = await userAlice.notification.list('SPAM'); + expect(response).not.null; + }); + + it('Should return feeds with signer object when an account is passed', async () => { + const response = await userAlice.notification.list('SPAM', { + account: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + }); + expect(response).not.null; + expect(response.length).not.equal(0); + }); + + it('Should return feeds without signer object when an account is passed', async () => { + const response = await userBob.notification.list('SPAM', { + account: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + }); + expect(response).not.null; + expect(response.length).not.equal(0); + }); + + it('Should throw error without signer object when an account is not passed', async () => { + await expect(() => userBob.notification.list('SPAM')).to.Throw; + }); + + it('Should return feeds when signer with provider is used', async () => { + const response = await userKate.notification.list('SPAM'); + expect(response).not.null; + }); + + it('Should return feeds when viem is used', async () => { + const response = await userViem.notification.list('SPAM'); + expect(response).not.null; + }); + + it('Should return feeds when signer with provider is used', async () => { + const response = await userKate.notification.list('INBOX', { + account: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + channels: ['0xD8634C39BBFd4033c0d3289C4515275102423681'], + raw: true, + }); + // console.log(response) + expect(response).not.null; + }); + }); + + describe('notification :: subscribe', () => { + beforeEach(async () => { + await userAlice.notification.unsubscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + + await userKate.notification.unsubscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + }); + + afterEach(async () => { + await userAlice.notification.unsubscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + + await userKate.notification.unsubscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + }); + it('Without signer object: should throw error', async () => { + await expect(() => + userBob.notification.subscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ) + ).to.Throw; + }); + + it('With signer object: should throw error for invalid channel caip', async () => { + await expect(() => { + userAlice.notification.subscribe( + '0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + }).to.Throw; + }); + + it('With signer object: Should subscribe', async () => { + const res = await userAlice.notification.subscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + expect(res).not.null; + }); + + it('With signer and provider: Should subscribe', async () => { + const res = await userKate.notification.subscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + // console.log(res) + expect(res).not.null; + }); + + it('With viem signer and provider: Should subscribe', async () => { + const res = await userViem.notification.subscribe( + 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + ); + // console.log(res) + expect(res).not.null; + }); + }); + + describe('notification :: subscriptions', () => { + it('No signer or account: Should throw error', async () => { + await expect(() => userBob.notification.subscriptions()).to.Throw; + }); + + it('Signer with no account: Should return response', async () => { + const response = await userAlice.notification.subscriptions(); + // console.log(response); + expect(response).not.null; + }); + + it('Signer with account: Should return response', async () => { + const response = await userAlice.notification.subscriptions({ + account: 'eip155:80001:0xD8634C39BBFd4033c0d3289C4515275102423681', + }); + // console.log(response); + expect(response).not.null; + expect(response.lenth).not.equal(0); + }); + }); + + // TO RUN THIS, MAKE THE PRIVATE FUNTIONS PUBLIC + // describe('debug :: test private functions', () => { + // it('Fetching data from contract', async () => { + // const contract = userKate.createContractInstance( + // '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', + // tokenABI + // ); + // const balance = await contract['balanceOf']( + // '0xD8634C39BBFd4033c0d3289C4515275102423681' + // ); + // console.log(balance.toString()); + // const fees = ethers.utils.parseUnits('50', 18); + // console.log(fees) + // console.log(fees.lte(balance)) + // }); + + // it("Uploading data to ipfs via push node", async () => { + // await userAlice.uploadToIPFSViaPushNode("test") + // }) + + // it('Should get proper minnimal payload', () => { + // const inputData = [ + // { + // type: 0, + // default: 1, + // description: 'test1', + // }, + // { + // type: 1, + // default: 10, + // description: 'test2', + // data: { + // upper: 100, + // lower: 1, + // }, + // }, + // ]; + + // const minimalSettings = userAlice.getMinimalSetting(inputData); + // console.log(minimalSettings); + // }); + + // it('Should get proper minnimal payload', () => { + // const inputData = [ + // { + // type: 1, + // default: 10, + // description: 'test2', + // data: { + // upper: 100, + // lower: 1, + // }, + // }, + // { + // type: 0, + // default: 1, + // description: 'test1', + // }, + // ]; + + // const minimalSettings = userAlice.getMinimalSetting(inputData); + // console.log(minimalSettings); + // }); + // }); +}); diff --git a/packages/restapi/tests/lib/pushNotification/onchain.test.ts b/packages/restapi/tests/lib/pushNotification/onchain.test.ts new file mode 100644 index 000000000..e5412da59 --- /dev/null +++ b/packages/restapi/tests/lib/pushNotification/onchain.test.ts @@ -0,0 +1,99 @@ +// import * as path from 'path'; +// import * as dotenv from 'dotenv'; +// dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); +// import { expect } from 'chai'; +// import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; + +// import { PushNotification } from '../../../../src/lib/pushNotification/PushNotification'; +// import { +// createWalletClient, +// http, +// getContract, +// createPublicClient, +// } from 'viem'; +// import { abi } from './tokenABI'; +// import { goerli, polygonMumbai } from 'viem/chains'; +// import { BigNumber, ethers } from 'ethers'; + +// describe.only('test', () => { +// const signer = createWalletClient({ +// account: privateKeyToAccount(`0x${process.env['WALLET_PRIVATE_KEY']}`), +// chain: goerli, +// transport: http( +// 'https://goerli.blockpi.network/v1/rpc/public' +// ), +// }); + +// const signer3 = createWalletClient({ +// account: privateKeyToAccount(`0x${process.env['WALLET_PRIVATE_KEY']}`), +// chain: polygonMumbai, +// transport: http(), +// }); + +// const provider = new ethers.providers.JsonRpcProvider( +// 'https://goerli.blockpi.network/v1/rpc/public' +// ); +// const signer2 = new ethers.Wallet( +// `0x${process.env['WALLET_PRIVATE_KEY']}`, +// provider +// ); + +// it.only('testing with viem', async () => { +// const userViem = await PushNotification.initialize(signer); +// const viemContract = await userViem.createContractInstance( +// '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', +// abi, +// goerli +// ); +// // const balance = await userViem.fetchBalance( +// // viemContract, +// // '0xD8634C39BBFd4033c0d3289C4515275102423681' +// // ); +// // console.log(balance); +// // const allowance = await userViem.fetchAllownace( +// // viemContract, +// // '0xD8634C39BBFd4033c0d3289C4515275102423681', +// // '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C' +// // ); +// // console.log(allowance); +// // const approveAmount = ethers.BigNumber.from(10000); +// // const approveRes = await userViem.approveToken( +// // viemContract, +// // '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C', +// // approveAmount +// // ); +// // console.log(approveRes); + +// const addDelegate = await userViem.delegate.add( +// 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' +// ); +// console.log(addDelegate); +// }); + +// it('test with ethers', async () => { +// const userEthers = await PushNotification.initialize(signer2); +// const ethersContract = await userEthers.createContractInstance( +// '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', +// abi, +// goerli +// ); +// const balance2 = await userEthers.fetchBalance( +// ethersContract, +// '0xD8634C39BBFd4033c0d3289C4515275102423681' +// ); +// console.log(balance2); +// const allowance2 = await userEthers.fetchAllownace( +// ethersContract, +// '0xD8634C39BBFd4033c0d3289C4515275102423681', +// '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C' +// ); +// console.log(allowance2); +// const approveAmount2 = ethers.BigNumber.from(10000); +// const approveRes2 = await userEthers.approveToken( +// ethersContract, +// '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C', +// approveAmount2 +// ); +// console.log(approveRes2); +// }); +// }); diff --git a/packages/restapi/tests/lib/pushNotification/tokenABI.ts b/packages/restapi/tests/lib/pushNotification/tokenABI.ts new file mode 100644 index 000000000..0f602271d --- /dev/null +++ b/packages/restapi/tests/lib/pushNotification/tokenABI.ts @@ -0,0 +1,709 @@ +export const abi = [ + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Approval", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "delegator", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "fromDelegate", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "toDelegate", + "type": "address" + } + ], + "name": "DelegateChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "previousBalance", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newBalance", + "type": "uint256" + } + ], + "name": "DelegateVotesChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "holder", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "weight", + "type": "uint256" + } + ], + "name": "HolderWeightChanged", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "indexed": true, + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "Transfer", + "type": "event" + }, + { + "inputs": [], + "name": "DELEGATION_TYPEHASH", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "DOMAIN_TYPEHASH", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "PERMIT_TYPEHASH", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + } + ], + "name": "allowance", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "rawAmount", + "type": "uint256" + } + ], + "name": "approve", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "balanceOf", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "born", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "rawAmount", + "type": "uint256" + } + ], + "name": "burn", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "uint32", + "name": "", + "type": "uint32" + } + ], + "name": "checkpoints", + "outputs": [ + { + "internalType": "uint32", + "name": "fromBlock", + "type": "uint32" + }, + { + "internalType": "uint96", + "name": "votes", + "type": "uint96" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "decimals", + "outputs": [ + { + "internalType": "uint8", + "name": "", + "type": "uint8" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "delegatee", + "type": "address" + } + ], + "name": "delegate", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "delegatee", + "type": "address" + }, + { + "internalType": "uint256", + "name": "nonce", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "expiry", + "type": "uint256" + }, + { + "internalType": "uint8", + "name": "v", + "type": "uint8" + }, + { + "internalType": "bytes32", + "name": "r", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "s", + "type": "bytes32" + } + ], + "name": "delegateBySig", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "delegates", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + } + ], + "name": "getCurrentVotes", + "outputs": [ + { + "internalType": "uint96", + "name": "", + "type": "uint96" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "uint256", + "name": "blockNumber", + "type": "uint256" + } + ], + "name": "getPriorVotes", + "outputs": [ + { + "internalType": "uint96", + "name": "", + "type": "uint96" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + }, + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "holderDelegation", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "holderWeight", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "name", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "nonces", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "numCheckpoints", + "outputs": [ + { + "internalType": "uint32", + "name": "", + "type": "uint32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "owner", + "type": "address" + }, + { + "internalType": "address", + "name": "spender", + "type": "address" + }, + { + "internalType": "uint256", + "name": "rawAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "deadline", + "type": "uint256" + }, + { + "internalType": "uint8", + "name": "v", + "type": "uint8" + }, + { + "internalType": "bytes32", + "name": "r", + "type": "bytes32" + }, + { + "internalType": "bytes32", + "name": "s", + "type": "bytes32" + } + ], + "name": "permit", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "holder", + "type": "address" + } + ], + "name": "resetHolderWeight", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "account", + "type": "address" + }, + { + "internalType": "address", + "name": "delegate", + "type": "address" + } + ], + "name": "returnHolderDelegation", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "returnHolderRatio", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "delegate", + "type": "address" + }, + { + "internalType": "bool", + "name": "value", + "type": "bool" + } + ], + "name": "setHolderDelegation", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [], + "name": "symbol", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "totalSupply", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "rawAmount", + "type": "uint256" + } + ], + "name": "transfer", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "src", + "type": "address" + }, + { + "internalType": "address", + "name": "dst", + "type": "address" + }, + { + "internalType": "uint256", + "name": "rawAmount", + "type": "uint256" + } + ], + "name": "transferFrom", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "nonpayable", + "type": "function" + } + ] as const \ No newline at end of file From 8ca7e4203bcc06886dfe293f8aec5597aec60e5b Mon Sep 17 00:00:00 2001 From: akp111 Date: Wed, 27 Sep 2023 13:27:33 +0530 Subject: [PATCH 254/298] fix: changed typescript 5.0.2 and configured eslint --- .eslintrc.json | 6 +++++- package.json | 2 +- .../src/lib/pushNotification/PushNotification.ts | 5 +---- yarn.lock | 10 +++++----- 4 files changed, 12 insertions(+), 11 deletions(-) diff --git a/.eslintrc.json b/.eslintrc.json index 06cc47d9a..2f936c714 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -24,7 +24,11 @@ { "files": ["*.ts", "*.tsx"], "extends": ["plugin:@nrwl/nx/typescript"], - "rules": {} + "rules": { + "@typescript-eslint/no-unused-vars": "off", + "@typescript-eslint/no-non-null-assertion": "off", + "@typescript-eslint/no-explicit-any": "off" + } }, { "files": ["*.js", "*.jsx"], diff --git a/package.json b/package.json index 49514fb87..c6d4e222a 100644 --- a/package.json +++ b/package.json @@ -120,6 +120,6 @@ "react-test-renderer": "17.0.2", "ts-jest": "27.1.4", "ts-node": "9.1.1", - "typescript": "~4.6.2" + "typescript": "5.0.2" } } diff --git a/packages/restapi/src/lib/pushNotification/PushNotification.ts b/packages/restapi/src/lib/pushNotification/PushNotification.ts index be7c58987..6352f8497 100644 --- a/packages/restapi/src/lib/pushNotification/PushNotification.ts +++ b/packages/restapi/src/lib/pushNotification/PushNotification.ts @@ -4,7 +4,6 @@ import { ISendNotificationInputOptions, ProgressHookType, ProgressHookTypeFunction, - ethersV5SignerType, } from '../types'; import { ChannelInfoOptions, @@ -32,14 +31,12 @@ import { } from '../helpers'; import PROGRESSHOOK from '../progressHook'; import { IDENTITY_TYPE, NOTIFICATION_TYPE } from '../payloads/constants'; -import { ethers, Contract, ContractInterface, Signer, BigNumber } from 'ethers'; +import { ethers, Contract, Signer, BigNumber } from 'ethers'; import axios from 'axios'; -import { mainnet, goerli } from 'viem/chains'; import { createPublicClient, http, getContract, - GetContractReturnType, WalletClient, Chain, } from 'viem'; diff --git a/yarn.lock b/yarn.lock index bc45eb097..14420088a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -14967,16 +14967,16 @@ typedarray@^0.0.6: resolved "https://registry.npmjs.org/typedarray/-/typedarray-0.0.6.tgz" integrity sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA== +typescript@5.0.2: + version "5.0.2" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-5.0.2.tgz#891e1a90c5189d8506af64b9ef929fca99ba1ee5" + integrity sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw== + typescript@^4.6.4: version "4.8.4" resolved "https://registry.npmjs.org/typescript/-/typescript-4.8.4.tgz" integrity sha512-QCh+85mCy+h0IGff8r5XWzOVSbBO+KfeYrMQh7NJ58QujwcE22u+NUSmUxqF+un70P9GXKxa2HCNiTTMJknyjQ== -typescript@~4.6.2: - version "4.6.4" - resolved "https://registry.npmjs.org/typescript/-/typescript-4.6.4.tgz" - integrity sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg== - ua-parser-js@^0.7.30: version "0.7.31" resolved "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-0.7.31.tgz" From 312631c57c21c53f49dca1a25b0fc5f71859ce18 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Wed, 27 Sep 2023 13:32:22 +0530 Subject: [PATCH 255/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.34?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d80469550..5bd6d3477 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.34](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.33...restapi-0.0.1-alpha.34) (2023-09-27) + + +### Bug Fixes + +* added class based implementation for notification ([#699](https://github.com/ethereum-push-notification-service/push-sdk/issues/699)) ([44f0b7b](https://github.com/ethereum-push-notification-service/push-sdk/commit/44f0b7be1fb568c90c4dfebb7dc61ab82efaddc2)) +* changed typescript 5.0.2 and configured eslint ([8ca7e42](https://github.com/ethereum-push-notification-service/push-sdk/commit/8ca7e4203bcc06886dfe293f8aec5597aec60e5b)) + + + ## [0.0.1-alpha.33](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.19...restapi-0.0.1-alpha.33) (2023-09-07) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 9e96e0e89..98ae4a710 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.33", + "version": "0.0.1-alpha.34", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 7ccc775ddb4c0e34f84693dcfdea07fc67edf790 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 28 Sep 2023 21:23:14 +0530 Subject: [PATCH 256/298] 720 pushstream class implementation (#729) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * chore: added an example of automated chat using the new class based initialization * fix: fixed usecases * chore: added an example of automated chat using the new class based i… (#712) * chore: added an example of automated chat using the new class based initialization * fix: fixed usecases --------- Co-authored-by: aman035 * chore(automated chat example): tweaked automated chat example * fix: stream changes * fix: stream changes * fix: added chat.decrypt (#726) * fix: added chat.decrypt * fix: fix examples * fix: stream changes * fix: PUSH Stream Changes * fix: chat classes split * fix: Notification socket initialisations and rules backward compatibility * fix: added message decrypt * fix: review comments * fix: socket events * fix: test case fix and UserInfo to user * fix: rip PushNotification class * fix: additional check --------- Co-authored-by: harshrajat Co-authored-by: aman035 Co-authored-by: Harsh | Push Co-authored-by: akp111 --- packages/examples/automated-chat/README.md | 13 + packages/examples/automated-chat/index.js | 39 + .../examples/automated-chat/package-lock.json | 6446 +++++++++++++++++ packages/examples/automated-chat/package.json | 24 + .../sdk-backend-node/package-lock.json | 5600 ++++++++++++++ .../examples/sdk-backend-node/package.json | 2 +- .../sdk-backend-node/pushAPI/index.ts | 22 + .../src/app/ChatTest/ChatTest.tsx | 3 + .../app/ChatTest/GetGroupMemberStatusTest.tsx | 86 + .../sdk-frontend-react/src/app/app.tsx | 3 + packages/examples/use-cases/.DONNOTREMOVE | 0 .../automated-chat/package-lock.json | 6446 +++++++++++++++++ .../use-cases/automated-chat/package.json | 24 + .../use-cases/automated-chat/src/index.js | 42 + packages/restapi/PushChatLowLevelAPI.md | 30 +- packages/restapi/README.md | 6 +- packages/restapi/package-lock.json | 3673 +++++++++- packages/restapi/package.json | 1 + .../src/lib/chat/getGroupMemberStatus.ts | 54 + .../restapi/src/lib/chat/helpers/inbox.ts | 38 +- .../src/lib/chat/helpers/payloadHelper.ts | 4 +- packages/restapi/src/lib/chat/index.ts | 1 + .../restapi/src/lib/chat/rejectRequest.ts | 2 +- packages/restapi/src/lib/index.ts | 1 - .../lib/pushNotification/PushNotification.ts | 1333 ---- .../restapi/src/lib/pushNotification/alias.ts | 27 + .../src/lib/pushNotification/channel.ts | 418 ++ .../src/lib/pushNotification/delegate.ts | 112 + .../src/lib/pushNotification/notification.ts | 216 + .../pushNotification/pushNotificationBase.ts | 662 ++ packages/restapi/src/lib/pushapi/PushAPI.ts | 689 +- packages/restapi/src/lib/pushapi/chat.ts | 449 ++ .../restapi/src/lib/pushapi/encryption.ts | 67 + packages/restapi/src/lib/pushapi/profile.ts | 36 + .../restapi/src/lib/pushapi/pushAPITypes.ts | 11 +- packages/restapi/src/lib/pushapi/user.ts | 13 + .../src/lib/pushstream/DataModifier.ts | 291 + .../restapi/src/lib/pushstream/PushStream.ts | 215 + .../src/lib/pushstream/pushStreamTypes.ts | 168 + packages/restapi/src/lib/types/index.ts | 21 +- .../tests/lib/chat/updateGroup.test.ts | 1 - .../tests/lib/pushNotification/alias.test.ts | 53 + .../lib/pushNotification/channel.test.ts | 44 +- .../lib/pushNotification/delegate.test.ts | 82 +- .../lib/pushNotification/notification.test.ts | 35 +- .../restapi/tests/lib/pushapi/chat.test.ts | 11 + .../tests/lib/pushstream/initialize.test.ts | 363 + packages/restapi/yarn.lock | 356 +- 48 files changed, 25911 insertions(+), 2322 deletions(-) create mode 100644 packages/examples/automated-chat/README.md create mode 100644 packages/examples/automated-chat/index.js create mode 100644 packages/examples/automated-chat/package-lock.json create mode 100644 packages/examples/automated-chat/package.json create mode 100644 packages/examples/sdk-backend-node/package-lock.json create mode 100644 packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupMemberStatusTest.tsx create mode 100644 packages/examples/use-cases/.DONNOTREMOVE create mode 100644 packages/examples/use-cases/automated-chat/package-lock.json create mode 100644 packages/examples/use-cases/automated-chat/package.json create mode 100644 packages/examples/use-cases/automated-chat/src/index.js create mode 100644 packages/restapi/src/lib/chat/getGroupMemberStatus.ts delete mode 100644 packages/restapi/src/lib/pushNotification/PushNotification.ts create mode 100644 packages/restapi/src/lib/pushNotification/alias.ts create mode 100644 packages/restapi/src/lib/pushNotification/channel.ts create mode 100644 packages/restapi/src/lib/pushNotification/delegate.ts create mode 100644 packages/restapi/src/lib/pushNotification/notification.ts create mode 100644 packages/restapi/src/lib/pushNotification/pushNotificationBase.ts create mode 100644 packages/restapi/src/lib/pushapi/chat.ts create mode 100644 packages/restapi/src/lib/pushapi/encryption.ts create mode 100644 packages/restapi/src/lib/pushapi/profile.ts create mode 100644 packages/restapi/src/lib/pushapi/user.ts create mode 100644 packages/restapi/src/lib/pushstream/DataModifier.ts create mode 100644 packages/restapi/src/lib/pushstream/PushStream.ts create mode 100644 packages/restapi/src/lib/pushstream/pushStreamTypes.ts create mode 100644 packages/restapi/tests/lib/pushNotification/alias.test.ts create mode 100644 packages/restapi/tests/lib/pushstream/initialize.test.ts diff --git a/packages/examples/automated-chat/README.md b/packages/examples/automated-chat/README.md new file mode 100644 index 000000000..4bc950dbd --- /dev/null +++ b/packages/examples/automated-chat/README.md @@ -0,0 +1,13 @@ +# About Automated Chat +Automated chat example shows how you can receive chats when you talk to someone using Push Chat. In this example, we establish a socket connection and then send a message to pushai.eth, which is an automated chat bot that replies back. + +## What's the use case +You can use this example to see the functionality of sockets and how you can respond to messages from backend (server) when a wallet messages you (or a wallet you own). Some use cases are: + +- Creating an automated support bot +- Creating an AI chat bot + +## Install instructions +1. Navigate to this directory from the terminal +2. do `npm install` or `yarn install` +3. do `yarn start` \ No newline at end of file diff --git a/packages/examples/automated-chat/index.js b/packages/examples/automated-chat/index.js new file mode 100644 index 000000000..7d6e63356 --- /dev/null +++ b/packages/examples/automated-chat/index.js @@ -0,0 +1,39 @@ +import { PushAPI } from '@pushprotocol/restapi'; +import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; +import { ethers } from 'ethers'; + +// Creating a random signer from a wallet, ideally this is the wallet you will connect +const signer = ethers.Wallet.createRandom(); + +// Initialize wallet user, pass 'prod' instead of 'staging' for mainnet apps +const userAlice = await PushAPI.initialize(signer, { env: 'prod' }); + +// This will be the wallet address of the recipient +const pushAIWalletAddress = '0x99A08ac6254dcf7ccc37CeC662aeba8eFA666666'; + +// Create Socket to Listen to incoming messages +const pushSDKSocket = await createSocketConnection({ + user: signer.address, + socketType: 'chat', + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + env: 'prod', +}); + +pushSDKSocket.on(EVENTS.CONNECT, (message) => { + console.log('Socket Connected'); + + // Send a message to Bob after socket connection so that messages as an example + console.log('Sending message to PushAI Bot'); + const aliceMessagesPushAI = userAlice.chat.send(pushAIWalletAddress, { + content: "Gm gm! It's a me... Mario", + }); + +}); + +// React to message payload getting recieved +pushSDKSocket.on(EVENTS.CHAT_RECEIVED_MESSAGE, (message) => { + console.log('Encrypted Message Received'); + console.log(message); + + pushSDKSocket.disconnect(); +}); diff --git a/packages/examples/automated-chat/package-lock.json b/packages/examples/automated-chat/package-lock.json new file mode 100644 index 000000000..7287555fa --- /dev/null +++ b/packages/examples/automated-chat/package-lock.json @@ -0,0 +1,6446 @@ +{ + "name": "automated-chat", + "version": "1.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "automated-chat", + "version": "1.0.0", + "license": "ISC", + "dependencies": { + "@pushprotocol/restapi": "1.4.19", + "@pushprotocol/socket": "0.5.2", + "ethers": "5.7.2", + "node-dev": "8.0.0" + }, + "devDependencies": { + "nodemon": "3.0.1" + } + }, + "node_modules/@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "dependencies": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, + "node_modules/@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==", + "bin": { + "rlp": "bin/rlp" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "dependencies": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "node_modules/@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "node_modules/@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + } + }, + "node_modules/@ethersproject/bignumber/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "node_modules/@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "node_modules/@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "node_modules/@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "node_modules/@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ] + }, + "node_modules/@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "node_modules/@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "node_modules/@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "node_modules/@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "node_modules/@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@livepeer/core": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.5.tgz", + "integrity": "sha512-02rD++yZhEmOi5N1kkTz88LbkhardAAXumo11muNBX1V9SRrS1oRRJMQyNt8QwOduH0RyNVTPEGxQSxyFHChFg==", + "dependencies": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "dependencies": { + "@ljharb/through": "^2.3.9" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "dependencies": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "dependencies": { + "@noble/hashes": "1.3.1" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==", + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@pushprotocol/restapi": { + "version": "1.4.19", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.19.tgz", + "integrity": "sha512-MGeYMX0NB2/sPSOnyvERZL2jKqeBPE6nUgySecEvW/JaUW8DsAX7KSN5IU4xvF9KpQblbUDcdXq4iW55/oZqOA==", + "dependencies": { + "@ambire/signature-validator": "^1.3.1", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "dependencies": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@scure/base": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", + "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==", + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "dependencies": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "dependencies": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "node_modules/@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "node_modules/@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "node_modules/@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "node_modules/abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", + "dev": true + }, + "node_modules/aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + }, + "node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "dependencies": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "dependencies": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "node_modules/available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "dependencies": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "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==" + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + }, + "node_modules/binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "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==", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "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, + "dependencies": { + "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "node_modules/buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/chokidar": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", + "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://paulmillr.com/funding/" + } + ], + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "dependencies": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "node_modules/core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==", + "hasInstallScript": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "node_modules/cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "dependencies": { + "node-fetch": "^2.6.12" + } + }, + "node_modules/crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "node_modules/custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "node_modules/dateformat": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", + "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==", + "engines": { + "node": "*" + } + }, + "node_modules/debounce": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/debounce/-/debounce-1.2.1.tgz", + "integrity": "sha512-XRRe6Glud4rd/ZGQfiV1ruXSfbvfJedlV9Y6zOlP+2K04vBYiJEte6stfFkCP03aMnY5tsipamumUjL14fofug==" + }, + "node_modules/debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/debug/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==" + }, + "node_modules/deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "dependencies": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "dependencies": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "dependencies": { + "minimatch": "^3.0.4" + }, + "bin": { + "ignored": "bin/ignored" + } + }, + "node_modules/duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "node_modules/dynamic-dedupe": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/dynamic-dedupe/-/dynamic-dedupe-0.3.0.tgz", + "integrity": "sha512-ssuANeD+z97meYOqd50e04Ze5qp4bPqo8cCkI4TRjZkzAUgIDTrXV1R8QCdINpiI+hw14+rYazvTRdQrz0/rFQ==", + "dependencies": { + "xtend": "^4.0.0" + } + }, + "node_modules/elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + } + }, + "node_modules/engine.io-client/node_modules/ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==", + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, + "node_modules/es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "dependencies": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dependencies": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "dependencies": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "node_modules/ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "node_modules/ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "dependencies": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "dependencies": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/filewatcher": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/filewatcher/-/filewatcher-3.0.1.tgz", + "integrity": "sha512-Fro8py2B8EJupSP37Kyd4kjKZLr+5ksFq7Vbw8A392Z15Unq8016SPUDvO/AsDj5V6bbPk98PTAinpc5YhPbJw==", + "dependencies": { + "debounce": "^1.0.0" + } + }, + "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, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "dependencies": { + "is-callable": "^1.1.3" + } + }, + "node_modules/form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "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==" + }, + "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, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "node_modules/function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, + "node_modules/get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "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": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "dependencies": { + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "node_modules/growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha512-+xGQY0YyAWCnqy7Cd++hc2JqMYzlm0dG30Jd0beaA64sROr8C4nt8Yc9V5Ro3avlSUDTN0ulqP/VBKi1/lLygw==" + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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, + "engines": { + "node": ">=4" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "dependencies": { + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "dependencies": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "node_modules/hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, + "node_modules/hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "dependencies": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/ignore-by-default": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/ignore-by-default/-/ignore-by-default-1.0.1.tgz", + "integrity": "sha512-Ius2VYcGNk7T90CppJqcIkS5ooHUZyIQK+ClZfMfMNFEF9VSE73Fq+906u/CWu92x4gzZMWOwfFYckPObzdEbA==", + "dev": true + }, + "node_modules/immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "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==", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "dependencies": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "dependencies": { + "has-bigints": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", + "bin": { + "is-docker": "cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "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, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==", + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "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, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==", + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "dependencies": { + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", + "dependencies": { + "is-docker": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + }, + "node_modules/joi": { + "version": "17.10.1", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.1.tgz", + "integrity": "sha512-vIiDxQKmRidUVp8KngT8MZSOcmRVm2zV7jbMjNYWuHcJWI0bUck3nRTGQjhpPlQenIQIBC5Vp9AhcnHbWQqafw==", + "dependencies": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "node_modules/js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "node_modules/js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "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==", + "peer": true + }, + "node_modules/livepeer": { + "version": "2.8.5", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.5.tgz", + "integrity": "sha512-m9v0yIIKC4M5NujAklkYNqMk5fHeRrIfqyah0F4XxpI4zgTPFy+vUm3bUg+meyrdYzwZBljpvGUpYO1A1w/EKA==", + "dependencies": { + "@livepeer/core": "^1.8.5", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "node_modules/lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "dependencies": { + "lodash._stringtopath": "~4.8.0" + } + }, + "node_modules/lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "node_modules/lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "dependencies": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "node_modules/lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "node_modules/lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "node_modules/lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "dependencies": { + "lodash._basetostring": "~4.12.0" + } + }, + "node_modules/lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "node_modules/lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "dependencies": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.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==", + "peer": true, + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "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==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==" + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "node_modules/minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, + "node_modules/multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node_modules/node-dev": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/node-dev/-/node-dev-8.0.0.tgz", + "integrity": "sha512-GXc0KxmBXfQxMPdymOui40yvC5W/RXFwmuUDT65wvTAO/o9wAsddYC8q4EHKxq3Qqt+uLS/g7XKdgVcsjyk9lw==", + "dependencies": { + "dateformat": "^3.0.3", + "dynamic-dedupe": "^0.3.0", + "filewatcher": "~3.0.0", + "get-package-type": "^0.1.0", + "minimist": "^1.2.6", + "node-notifier": "^8.0.1", + "resolve": "^1.22.0", + "semver": "^7.3.7" + }, + "bin": { + "node-dev": "bin/node-dev" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/node-dev/node_modules/resolve": { + "version": "1.22.5", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.5.tgz", + "integrity": "sha512-qWhv7PF1V95QPvRoUGHxOtnAlEvlXBylMZcjUR9pAumMmveFtcHJRXGIr+TkjfNJVQypqv2qcDiiars2y1PsSg==", + "dependencies": { + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/node-notifier": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-8.0.2.tgz", + "integrity": "sha512-oJP/9NAdd9+x2Q+rfphB2RJCHjod70RcRLjosiPMMu5gjIfwVnOUGq2nbTjTUbmy0DJ/tFIVT30+Qe3nzl4TJg==", + "dependencies": { + "growly": "^1.3.0", + "is-wsl": "^2.2.0", + "semver": "^7.3.2", + "shellwords": "^0.1.1", + "uuid": "^8.3.0", + "which": "^2.0.2" + } + }, + "node_modules/node-notifier/node_modules/uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/nodemon": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.0.1.tgz", + "integrity": "sha512-g9AZ7HmkhQkqXkRc20w+ZfQ73cHLbE8hnPbtaFbFtCumZsjyMhKk9LajQ07U5Ux28lvFjZ5X7HvWR1xzU8jHVw==", + "dev": true, + "dependencies": { + "chokidar": "^3.5.2", + "debug": "^3.2.7", + "ignore-by-default": "^1.0.1", + "minimatch": "^3.1.2", + "pstree.remy": "^1.1.8", + "semver": "^7.5.3", + "simple-update-notifier": "^2.0.0", + "supports-color": "^5.5.0", + "touch": "^3.1.0", + "undefsafe": "^2.0.5" + }, + "bin": { + "nodemon": "bin/nodemon.js" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/nodemon" + } + }, + "node_modules/nodemon/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/nodemon/node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true + }, + "node_modules/nodemon/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, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/nopt": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz", + "integrity": "sha512-NWmpvLSqUrgrAC9HCuxEvb+PSloHpqVu+FqcO4eeF2h5qYRhA7ev6KvelyQAKtegUbC6RypJnlEOhd8vloNKYg==", + "dev": true, + "dependencies": { + "abbrev": "1" + }, + "bin": { + "nopt": "bin/nopt.js" + }, + "engines": { + "node": "*" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/openpgp": { + "version": "5.10.1", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.10.1.tgz", + "integrity": "sha512-SR5Ft+ej51d0+p53ld5Ney0Yiz0y8Mh1YYLJrvpRMbTaNhvS1QcDX0Oq1rW9sjBnQXtgrpWw2Zve3rm7K5C/pw==", + "dependencies": { + "asn1.js": "^5.0.0" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==", + "engines": { + "node": ">=0.10.0" + } + }, + "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==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "dependencies": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "node_modules/pstree.remy": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/pstree.remy/-/pstree.remy-1.1.8.tgz", + "integrity": "sha512-77DZwxQmxKnu3aR542U+X8FypNzbfJ+C5XQDk3uWjWxn6151aIMGthWYRXTqT1E5oJvg+ljaa2OJi+VfvCOQ8w==", + "dev": true + }, + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "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==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "node_modules/react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, + "node_modules/regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "node_modules/resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "dependencies": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", + "engines": { + "node": ">= 4" + } + }, + "node_modules/safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "node_modules/scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + }, + "node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "dependencies": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==" + }, + "node_modules/side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "dependencies": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "node_modules/simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "node_modules/simple-update-notifier": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/simple-update-notifier/-/simple-update-notifier-2.0.0.tgz", + "integrity": "sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==", + "dev": true, + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "dependencies": { + "internal-slot": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "dependencies": { + "is-hex-prefixed": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "dependencies": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "bin": { + "tap-out": "bin/cmd.js" + } + }, + "node_modules/tap-out/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/tap-out/node_modules/readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "dependencies": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/tap-out/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/tap-out/node_modules/string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "dependencies": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + }, + "bin": { + "tap-spec": "bin/cmd.js", + "tspec": "bin/cmd.js" + } + }, + "node_modules/tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "dependencies": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + }, + "bin": { + "tape": "bin/tape" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "node_modules/through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "dependencies": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + } + }, + "node_modules/through2/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/through2/node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "node_modules/through2/node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "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/through2/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/through2/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "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, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/touch": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/touch/-/touch-3.1.0.tgz", + "integrity": "sha512-WBx8Uy5TLtOSRtIq+M03/sKDrXCLHxwDcquSP2c43Le03/9serjQBIztjRz6FkJez9D/hleyAXTBGLwwZUw9lA==", + "dev": true, + "dependencies": { + "nopt": "~1.0.10" + }, + "bin": { + "nodetouch": "bin/nodetouch.js" + } + }, + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "node_modules/trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==", + "deprecated": "Use String.prototype.trim() instead" + }, + "node_modules/tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "node_modules/tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "dependencies": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "node_modules/tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "node_modules/tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + }, + "node_modules/typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "dependencies": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/undefsafe": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/undefsafe/-/undefsafe-2.0.5.tgz", + "integrity": "sha512-WxONCrssBM8TSPRqN5EmsjVrsv4A8X12J4ArBiiayv3DyyG3ZlIg6yysuuSYdZsVz3TKcTg2fd//Ujd4CHV1iA==", + "dev": true + }, + "node_modules/unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==", + "engines": { + "node": ">=8" + } + }, + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "node_modules/uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", + "funding": [ + "https://github.com/sponsors/broofa", + "https://github.com/sponsors/ctavan" + ], + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "node_modules/webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "node_modules/whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "dependencies": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "dependencies": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==" + }, + "node_modules/ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "engines": { + "node": ">=8.3.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "engines": { + "node": ">=0.4" + } + }, + "node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, + "node_modules/zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "dependencies": { + "use-sync-external-store": "1.2.0" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@types/react": ">=16.8", + "immer": ">=9.0", + "react": ">=16.8" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + } + } + } + }, + "dependencies": { + "@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "requires": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, + "@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==" + }, + "@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "requires": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + } + }, + "@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "requires": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "requires": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + }, + "dependencies": { + "bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + } + } + }, + "@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "requires": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" + }, + "@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + }, + "dependencies": { + "bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + } + } + }, + "@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "requires": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "requires": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@livepeer/core": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.5.tgz", + "integrity": "sha512-02rD++yZhEmOi5N1kkTz88LbkhardAAXumo11muNBX1V9SRrS1oRRJMQyNt8QwOduH0RyNVTPEGxQSxyFHChFg==", + "requires": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + } + }, + "@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "requires": { + "@ljharb/through": "^2.3.9" + } + }, + "@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==" + }, + "@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "requires": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + } + }, + "@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "requires": { + "@noble/hashes": "1.3.1" + } + }, + "@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==" + }, + "@pushprotocol/restapi": { + "version": "1.4.19", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.19.tgz", + "integrity": "sha512-MGeYMX0NB2/sPSOnyvERZL2jKqeBPE6nUgySecEvW/JaUW8DsAX7KSN5IU4xvF9KpQblbUDcdXq4iW55/oZqOA==", + "requires": { + "@ambire/signature-validator": "^1.3.1", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + } + }, + "@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "requires": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + } + }, + "@scure/base": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", + "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==" + }, + "@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "requires": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + } + }, + "@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "requires": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + } + }, + "@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", + "dev": true + }, + "aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + }, + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==" + }, + "anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "requires": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + } + }, + "array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + } + }, + "arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + } + }, + "asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "requires": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==" + }, + "axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "requires": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + }, + "base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==" + }, + "bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + }, + "binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "dev": true + }, + "bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "requires": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + } + }, + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "chokidar": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", + "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", + "dev": true, + "requires": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "fsevents": "~2.3.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + } + }, + "combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "requires": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "requires": { + "delayed-stream": "~1.0.0" + } + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==" + }, + "core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "requires": { + "node-fetch": "^2.6.12" + } + }, + "crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "dateformat": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", + "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==" + }, + "debounce": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/debounce/-/debounce-1.2.1.tgz", + "integrity": "sha512-XRRe6Glud4rd/ZGQfiV1ruXSfbvfJedlV9Y6zOlP+2K04vBYiJEte6stfFkCP03aMnY5tsipamumUjL14fofug==" + }, + "debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "requires": { + "ms": "2.1.2" + }, + "dependencies": { + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + } + } + }, + "deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + } + }, + "define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "requires": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + } + }, + "define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "requires": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + } + }, + "defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==" + }, + "delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==" + }, + "dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "requires": { + "minimatch": "^3.0.4" + } + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "dynamic-dedupe": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/dynamic-dedupe/-/dynamic-dedupe-0.3.0.tgz", + "integrity": "sha512-ssuANeD+z97meYOqd50e04Ze5qp4bPqo8cCkI4TRjZkzAUgIDTrXV1R8QCdINpiI+hw14+rYazvTRdQrz0/rFQ==", + "requires": { + "xtend": "^4.0.0" + } + }, + "elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "requires": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + }, + "dependencies": { + "ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "requires": {} + } + } + }, + "engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==" + }, + "err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, + "es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + } + }, + "es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + } + }, + "es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "requires": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "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==" + }, + "ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "requires": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "requires": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "requires": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + } + }, + "figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "requires": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + } + }, + "filewatcher": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/filewatcher/-/filewatcher-3.0.1.tgz", + "integrity": "sha512-Fro8py2B8EJupSP37Kyd4kjKZLr+5ksFq7Vbw8A392Z15Unq8016SPUDvO/AsDj5V6bbPk98PTAinpc5YhPbJw==", + "requires": { + "debounce": "^1.0.0" + } + }, + "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, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==" + }, + "for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "requires": { + "is-callable": "^1.1.3" + } + }, + "form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "requires": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + }, + "fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + } + }, + "functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==" + }, + "get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, + "get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + } + }, + "get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==" + }, + "get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "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, + "requires": { + "is-glob": "^4.0.1" + } + }, + "globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "requires": { + "define-properties": "^1.1.3" + } + }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + } + }, + "graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha512-+xGQY0YyAWCnqy7Cd++hc2JqMYzlm0dG30Jd0beaA64sROr8C4nt8Yc9V5Ro3avlSUDTN0ulqP/VBKi1/lLygw==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==" + }, + "has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "dev": true + }, + "has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "requires": { + "get-intrinsic": "^1.1.1" + } + }, + "has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==" + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "requires": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, + "hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "requires": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" + }, + "ignore-by-default": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/ignore-by-default/-/ignore-by-default-1.0.1.tgz", + "integrity": "sha512-Ius2VYcGNk7T90CppJqcIkS5ooHUZyIQK+ClZfMfMNFEF9VSE73Fq+906u/CWu92x4gzZMWOwfFYckPObzdEbA==", + "dev": true + }, + "immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "requires": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + } + }, + "is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + } + }, + "is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "requires": { + "has-bigints": "^1.0.1" + } + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==" + }, + "is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "requires": { + "has": "^1.0.3" + } + }, + "is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==" + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true + }, + "is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==" + }, + "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, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==" + }, + "is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==" + }, + "is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==" + }, + "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 + }, + "is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==" + }, + "is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==" + }, + "is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "requires": { + "which-typed-array": "^1.1.11" + } + }, + "is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==" + }, + "is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", + "requires": { + "is-docker": "^2.0.0" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + }, + "joi": { + "version": "17.10.1", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.1.tgz", + "integrity": "sha512-vIiDxQKmRidUVp8KngT8MZSOcmRVm2zV7jbMjNYWuHcJWI0bUck3nRTGQjhpPlQenIQIBC5Vp9AhcnHbWQqafw==", + "requires": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "peer": true + }, + "livepeer": { + "version": "2.8.5", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.5.tgz", + "integrity": "sha512-m9v0yIIKC4M5NujAklkYNqMk5fHeRrIfqyah0F4XxpI4zgTPFy+vUm3bUg+meyrdYzwZBljpvGUpYO1A1w/EKA==", + "requires": { + "@livepeer/core": "^1.8.5", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + } + }, + "lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "requires": { + "lodash._stringtopath": "~4.8.0" + } + }, + "lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "requires": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "requires": { + "lodash._basetostring": "~4.12.0" + } + }, + "lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "requires": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.0" + } + }, + "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==", + "peer": true, + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, + "lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "requires": { + "yallist": "^4.0.0" + } + }, + "micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==" + }, + "mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==" + }, + "mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "requires": { + "mime-db": "1.52.0" + } + }, + "minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==" + }, + "ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==" + }, + "multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node-dev": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/node-dev/-/node-dev-8.0.0.tgz", + "integrity": "sha512-GXc0KxmBXfQxMPdymOui40yvC5W/RXFwmuUDT65wvTAO/o9wAsddYC8q4EHKxq3Qqt+uLS/g7XKdgVcsjyk9lw==", + "requires": { + "dateformat": "^3.0.3", + "dynamic-dedupe": "^0.3.0", + "filewatcher": "~3.0.0", + "get-package-type": "^0.1.0", + "minimist": "^1.2.6", + "node-notifier": "^8.0.1", + "resolve": "^1.22.0", + "semver": "^7.3.7" + }, + "dependencies": { + "resolve": { + "version": "1.22.5", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.5.tgz", + "integrity": "sha512-qWhv7PF1V95QPvRoUGHxOtnAlEvlXBylMZcjUR9pAumMmveFtcHJRXGIr+TkjfNJVQypqv2qcDiiars2y1PsSg==", + "requires": { + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + } + } + }, + "node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "requires": { + "whatwg-url": "^5.0.0" + } + }, + "node-notifier": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-8.0.2.tgz", + "integrity": "sha512-oJP/9NAdd9+x2Q+rfphB2RJCHjod70RcRLjosiPMMu5gjIfwVnOUGq2nbTjTUbmy0DJ/tFIVT30+Qe3nzl4TJg==", + "requires": { + "growly": "^1.3.0", + "is-wsl": "^2.2.0", + "semver": "^7.3.2", + "shellwords": "^0.1.1", + "uuid": "^8.3.0", + "which": "^2.0.2" + }, + "dependencies": { + "uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==" + } + } + }, + "nodemon": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.0.1.tgz", + "integrity": "sha512-g9AZ7HmkhQkqXkRc20w+ZfQ73cHLbE8hnPbtaFbFtCumZsjyMhKk9LajQ07U5Ux28lvFjZ5X7HvWR1xzU8jHVw==", + "dev": true, + "requires": { + "chokidar": "^3.5.2", + "debug": "^3.2.7", + "ignore-by-default": "^1.0.1", + "minimatch": "^3.1.2", + "pstree.remy": "^1.1.8", + "semver": "^7.5.3", + "simple-update-notifier": "^2.0.0", + "supports-color": "^5.5.0", + "touch": "^3.1.0", + "undefsafe": "^2.0.5" + }, + "dependencies": { + "debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true + }, + "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, + "requires": { + "has-flag": "^3.0.0" + } + } + } + }, + "nopt": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz", + "integrity": "sha512-NWmpvLSqUrgrAC9HCuxEvb+PSloHpqVu+FqcO4eeF2h5qYRhA7ev6KvelyQAKtegUbC6RypJnlEOhd8vloNKYg==", + "dev": true, + "requires": { + "abbrev": "1" + } + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==" + }, + "object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==" + }, + "object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + } + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" + }, + "object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "requires": { + "wrappy": "1" + } + }, + "openpgp": { + "version": "5.10.1", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.10.1.tgz", + "integrity": "sha512-SR5Ft+ej51d0+p53ld5Ney0Yiz0y8Mh1YYLJrvpRMbTaNhvS1QcDX0Oq1rW9sjBnQXtgrpWw2Zve3rm7K5C/pw==", + "requires": { + "asn1.js": "^5.0.0" + } + }, + "parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==" + }, + "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==" + }, + "path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true + }, + "plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==" + }, + "pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "requires": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + } + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "requires": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "pstree.remy": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/pstree.remy/-/pstree.remy-1.1.8.tgz", + "integrity": "sha512-77DZwxQmxKnu3aR542U+X8FypNzbfJ+C5XQDk3uWjWxn6151aIMGthWYRXTqT1E5oJvg+ljaa2OJi+VfvCOQ8w==", + "dev": true + }, + "querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==" + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "requires": { + "loose-envify": "^1.1.0" + } + }, + "readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, + "readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "requires": { + "picomatch": "^2.2.1" + } + }, + "regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + } + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==" + }, + "requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "requires": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + }, + "retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==" + }, + "safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + } + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + } + }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + }, + "semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "requires": { + "lru-cache": "^6.0.0" + } + }, + "set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "requires": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + } + }, + "shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==" + }, + "side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "requires": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + } + }, + "signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "requires": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "simple-update-notifier": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/simple-update-notifier/-/simple-update-notifier-2.0.0.tgz", + "integrity": "sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==", + "dev": true, + "requires": { + "semver": "^7.5.3" + } + }, + "socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + } + }, + "socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + } + }, + "split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "requires": { + "through": "2" + } + }, + "stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "requires": { + "internal-slot": "^1.0.4" + } + }, + "string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "requires": { + "safe-buffer": "~5.2.0" + } + }, + "string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "requires": { + "is-hex-prefixed": "1.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==" + }, + "supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==" + }, + "tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "requires": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "requires": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "requires": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + } + }, + "tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "requires": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "requires": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "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, + "requires": { + "is-number": "^7.0.0" + } + }, + "touch": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/touch/-/touch-3.1.0.tgz", + "integrity": "sha512-WBx8Uy5TLtOSRtIq+M03/sKDrXCLHxwDcquSP2c43Le03/9serjQBIztjRz6FkJez9D/hleyAXTBGLwwZUw9lA==", + "dev": true, + "requires": { + "nopt": "~1.0.10" + } + }, + "tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==" + }, + "tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "requires": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + }, + "typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + } + }, + "unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "requires": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + } + }, + "undefsafe": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/undefsafe/-/undefsafe-2.0.5.tgz", + "integrity": "sha512-WxONCrssBM8TSPRqN5EmsjVrsv4A8X12J4ArBiiayv3DyyG3ZlIg6yysuuSYdZsVz3TKcTg2fd//Ujd4CHV1iA==", + "dev": true + }, + "unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==" + }, + "url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "requires": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "requires": {} + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==" + }, + "video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "requires": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "requires": { + "isexe": "^2.0.0" + } + }, + "which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "requires": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + } + }, + "which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "requires": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + } + }, + "which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + }, + "ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "requires": {} + }, + "xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==" + }, + "xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==" + }, + "yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, + "zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "requires": { + "use-sync-external-store": "1.2.0" + } + } + } +} diff --git a/packages/examples/automated-chat/package.json b/packages/examples/automated-chat/package.json new file mode 100644 index 000000000..2fc205e6d --- /dev/null +++ b/packages/examples/automated-chat/package.json @@ -0,0 +1,24 @@ +{ + "name": "automated-chat", + "version": "1.0.0", + "description": "Example of Push Chat from backend, auto-responding to messages sent", + "main": "index.js", + "type": "module", + "scripts": { + "build": "rimraf ./build && tsc", + "start": "nodemon", + "inspect": "nodemon --inspect index.js", + "dev": "node-dev --respawn --transpile-only index.js", + "test": "echo \"Error: no test specified\" && exit 1" + }, + "author": "", + "license": "ISC", + "dependencies": { + "@pushprotocol/restapi": "1.4.19", + "@pushprotocol/socket": "0.5.2", + "ethers": "5.7.2" + }, + "devDependencies": { + "nodemon": "3.0.1" + } +} diff --git a/packages/examples/sdk-backend-node/package-lock.json b/packages/examples/sdk-backend-node/package-lock.json new file mode 100644 index 000000000..d1b261a12 --- /dev/null +++ b/packages/examples/sdk-backend-node/package-lock.json @@ -0,0 +1,5600 @@ +{ + "name": "sdk-backend-node", + "version": "1.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "sdk-backend-node", + "version": "1.0.0", + "license": "ISC", + "dependencies": { + "@pushprotocol/restapi": "^1.4.17", + "@pushprotocol/socket": "^0.5.2" + } + }, + "node_modules/@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "dependencies": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, + "node_modules/@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==", + "bin": { + "rlp": "bin/rlp" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "dependencies": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "node_modules/@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "node_modules/@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + } + }, + "node_modules/@ethersproject/bignumber/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "node_modules/@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "node_modules/@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "node_modules/@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "node_modules/@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ] + }, + "node_modules/@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "node_modules/@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "node_modules/@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "node_modules/@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "node_modules/@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@livepeer/core": { + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.6.tgz", + "integrity": "sha512-VWMHaHMzNCr8YuC9hD87Ju+fwnpldEoe3y9CqOXrQPyyIgiAWfraZBA6Ard67f09X9UBGaaRcAMgMcCUs9HtKA==", + "dependencies": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "dependencies": { + "@ljharb/through": "^2.3.9" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "dependencies": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "dependencies": { + "@noble/hashes": "1.3.1" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==", + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@pushprotocol/restapi": { + "version": "1.4.19", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.19.tgz", + "integrity": "sha512-MGeYMX0NB2/sPSOnyvERZL2jKqeBPE6nUgySecEvW/JaUW8DsAX7KSN5IU4xvF9KpQblbUDcdXq4iW55/oZqOA==", + "dependencies": { + "@ambire/signature-validator": "^1.3.1", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "dependencies": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@scure/base": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", + "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==", + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "dependencies": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "dependencies": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "node_modules/@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "node_modules/@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "node_modules/@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "node_modules/aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + }, + "node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "dependencies": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "dependencies": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "node_modules/available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "dependencies": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "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==" + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + }, + "node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "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==", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "node_modules/brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "node_modules/buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "dependencies": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "node_modules/core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==", + "hasInstallScript": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "node_modules/cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "dependencies": { + "node-fetch": "^2.6.12" + } + }, + "node_modules/crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "node_modules/custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "node_modules/debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/debug/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==" + }, + "node_modules/deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "dependencies": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "dependencies": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "dependencies": { + "minimatch": "^3.0.4" + }, + "bin": { + "ignored": "bin/ignored" + } + }, + "node_modules/duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "node_modules/elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + } + }, + "node_modules/engine.io-client/node_modules/ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==", + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, + "node_modules/es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "dependencies": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dependencies": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "dependencies": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "node_modules/ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "node_modules/ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "dependencies": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "dependencies": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "dependencies": { + "is-callable": "^1.1.3" + } + }, + "node_modules/form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "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==" + }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "node_modules/function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, + "node_modules/get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "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/globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "dependencies": { + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "dependencies": { + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "dependencies": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "node_modules/hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, + "node_modules/hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "dependencies": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "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==", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "dependencies": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "dependencies": { + "has-bigints": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==", + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==", + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "dependencies": { + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "node_modules/joi": { + "version": "17.10.2", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.2.tgz", + "integrity": "sha512-hcVhjBxRNW/is3nNLdGLIjkgXetkeGc2wyhydhz8KumG23Aerk4HPjU5zaPAMRqXQFc0xNqXTC7+zQjxr0GlKA==", + "dependencies": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "node_modules/js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "node_modules/js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "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==", + "peer": true + }, + "node_modules/livepeer": { + "version": "2.8.6", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.6.tgz", + "integrity": "sha512-8K2lRtpgZKbv6l6cGYYMJW9qpdRKkGUuy7R7xTLkS6NaRQzaeW08vubftmbMHil8v8GX/nDmodcW2vA4oIkP0w==", + "dependencies": { + "@livepeer/core": "^1.8.6", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "node_modules/lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "dependencies": { + "lodash._stringtopath": "~4.8.0" + } + }, + "node_modules/lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "node_modules/lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "dependencies": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "node_modules/lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "node_modules/lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "node_modules/lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "dependencies": { + "lodash._basetostring": "~4.12.0" + } + }, + "node_modules/lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "node_modules/lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "dependencies": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.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==", + "peer": true, + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "node_modules/micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==" + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "node_modules/minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, + "node_modules/multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node_modules/node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/openpgp": { + "version": "5.10.2", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.10.2.tgz", + "integrity": "sha512-nRqMp4o31rBagWB02tgfKCsocXWq4uYobZf9GDVlD5rQXBq/wRIZHiDhGX1dlDAI2inkZcPd2dSZOqmtGnsK1A==", + "dependencies": { + "asn1.js": "^5.0.0" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==", + "engines": { + "node": ">=0.10.0" + } + }, + "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==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "node_modules/plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "dependencies": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "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==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "node_modules/react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "node_modules/resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "dependencies": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", + "engines": { + "node": ">= 4" + } + }, + "node_modules/safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "node_modules/scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + }, + "node_modules/set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "dependencies": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "dependencies": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "node_modules/simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "node_modules/socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "dependencies": { + "internal-slot": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "dependencies": { + "is-hex-prefixed": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "dependencies": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "bin": { + "tap-out": "bin/cmd.js" + } + }, + "node_modules/tap-out/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/tap-out/node_modules/readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "dependencies": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/tap-out/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/tap-out/node_modules/string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "dependencies": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + }, + "bin": { + "tap-spec": "bin/cmd.js", + "tspec": "bin/cmd.js" + } + }, + "node_modules/tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "dependencies": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + }, + "bin": { + "tape": "bin/tape" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "node_modules/through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "dependencies": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + } + }, + "node_modules/through2/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/through2/node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "node_modules/through2/node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "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/through2/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/through2/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "node_modules/trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==", + "deprecated": "Use String.prototype.trim() instead" + }, + "node_modules/tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "node_modules/tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "dependencies": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "node_modules/tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "node_modules/tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + }, + "node_modules/typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "dependencies": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==", + "engines": { + "node": ">=8" + } + }, + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "node_modules/uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", + "funding": [ + "https://github.com/sponsors/broofa", + "https://github.com/sponsors/ctavan" + ], + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "node_modules/webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "node_modules/whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "node_modules/which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "dependencies": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "dependencies": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==" + }, + "node_modules/ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "engines": { + "node": ">=8.3.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "engines": { + "node": ">=0.4" + } + }, + "node_modules/zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "dependencies": { + "use-sync-external-store": "1.2.0" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@types/react": ">=16.8", + "immer": ">=9.0", + "react": ">=16.8" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + } + } + } + }, + "dependencies": { + "@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "requires": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, + "@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==" + }, + "@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "requires": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + } + }, + "@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "requires": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "requires": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + }, + "dependencies": { + "bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + } + } + }, + "@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "requires": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" + }, + "@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + }, + "dependencies": { + "bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + } + } + }, + "@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "requires": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "requires": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@livepeer/core": { + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.6.tgz", + "integrity": "sha512-VWMHaHMzNCr8YuC9hD87Ju+fwnpldEoe3y9CqOXrQPyyIgiAWfraZBA6Ard67f09X9UBGaaRcAMgMcCUs9HtKA==", + "requires": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + } + }, + "@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "requires": { + "@ljharb/through": "^2.3.9" + } + }, + "@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==" + }, + "@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "requires": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + } + }, + "@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "requires": { + "@noble/hashes": "1.3.1" + } + }, + "@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==" + }, + "@pushprotocol/restapi": { + "version": "1.4.19", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.19.tgz", + "integrity": "sha512-MGeYMX0NB2/sPSOnyvERZL2jKqeBPE6nUgySecEvW/JaUW8DsAX7KSN5IU4xvF9KpQblbUDcdXq4iW55/oZqOA==", + "requires": { + "@ambire/signature-validator": "^1.3.1", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + } + }, + "@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "requires": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + } + }, + "@scure/base": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", + "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==" + }, + "@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "requires": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + } + }, + "@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "requires": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + } + }, + "@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + }, + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==" + }, + "array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "requires": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + } + }, + "array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + } + }, + "arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + } + }, + "asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "requires": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==" + }, + "axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "requires": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + }, + "base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==" + }, + "bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + }, + "bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "requires": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + } + }, + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "requires": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "requires": { + "delayed-stream": "~1.0.0" + } + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==" + }, + "core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "requires": { + "node-fetch": "^2.6.12" + } + }, + "crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "requires": { + "ms": "2.1.2" + }, + "dependencies": { + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + } + } + }, + "deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + } + }, + "define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "requires": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + } + }, + "define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "requires": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + } + }, + "defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==" + }, + "delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==" + }, + "dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "requires": { + "minimatch": "^3.0.4" + } + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "requires": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + }, + "dependencies": { + "ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "requires": {} + } + } + }, + "engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==" + }, + "err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, + "es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + } + }, + "es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + } + }, + "es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "requires": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "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==" + }, + "ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "requires": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "requires": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "requires": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + } + }, + "figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "requires": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + } + }, + "follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==" + }, + "for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "requires": { + "is-callable": "^1.1.3" + } + }, + "form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "requires": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + } + }, + "functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==" + }, + "get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, + "get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + } + }, + "get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==" + }, + "get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "requires": { + "define-properties": "^1.1.3" + } + }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + } + }, + "graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==" + }, + "has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "requires": { + "get-intrinsic": "^1.1.1" + } + }, + "has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==" + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "requires": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, + "hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "requires": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" + }, + "immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "requires": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + } + }, + "is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + } + }, + "is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "requires": { + "has-bigints": "^1.0.1" + } + }, + "is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==" + }, + "is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "requires": { + "has": "^1.0.3" + } + }, + "is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==" + }, + "is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==" + }, + "is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==" + }, + "is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==" + }, + "is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==" + }, + "is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==" + }, + "is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "requires": { + "which-typed-array": "^1.1.11" + } + }, + "is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==" + }, + "is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "joi": { + "version": "17.10.2", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.2.tgz", + "integrity": "sha512-hcVhjBxRNW/is3nNLdGLIjkgXetkeGc2wyhydhz8KumG23Aerk4HPjU5zaPAMRqXQFc0xNqXTC7+zQjxr0GlKA==", + "requires": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "peer": true + }, + "livepeer": { + "version": "2.8.6", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.6.tgz", + "integrity": "sha512-8K2lRtpgZKbv6l6cGYYMJW9qpdRKkGUuy7R7xTLkS6NaRQzaeW08vubftmbMHil8v8GX/nDmodcW2vA4oIkP0w==", + "requires": { + "@livepeer/core": "^1.8.6", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + } + }, + "lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "requires": { + "lodash._stringtopath": "~4.8.0" + } + }, + "lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "requires": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "requires": { + "lodash._basetostring": "~4.12.0" + } + }, + "lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "requires": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.0" + } + }, + "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==", + "peer": true, + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, + "micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==" + }, + "mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==" + }, + "mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "requires": { + "mime-db": "1.52.0" + } + }, + "minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==" + }, + "ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==" + }, + "multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "requires": { + "whatwg-url": "^5.0.0" + } + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==" + }, + "object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==" + }, + "object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + } + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" + }, + "object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "requires": { + "wrappy": "1" + } + }, + "openpgp": { + "version": "5.10.2", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.10.2.tgz", + "integrity": "sha512-nRqMp4o31rBagWB02tgfKCsocXWq4uYobZf9GDVlD5rQXBq/wRIZHiDhGX1dlDAI2inkZcPd2dSZOqmtGnsK1A==", + "requires": { + "asn1.js": "^5.0.0" + } + }, + "parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==" + }, + "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==" + }, + "path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==" + }, + "pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "requires": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + } + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "requires": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==" + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "requires": { + "loose-envify": "^1.1.0" + } + }, + "readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, + "regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + } + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==" + }, + "requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "requires": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + }, + "retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==" + }, + "safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + } + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + } + }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + }, + "set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "requires": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + } + }, + "side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "requires": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + } + }, + "signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "requires": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + } + }, + "socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + } + }, + "split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "requires": { + "through": "2" + } + }, + "stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "requires": { + "internal-slot": "^1.0.4" + } + }, + "string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "requires": { + "safe-buffer": "~5.2.0" + } + }, + "string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "requires": { + "is-hex-prefixed": "1.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==" + }, + "supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==" + }, + "tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "requires": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "requires": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "requires": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + } + }, + "tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "requires": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "requires": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==" + }, + "tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "requires": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + }, + "typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + } + }, + "unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "requires": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + } + }, + "unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==" + }, + "url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "requires": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "requires": {} + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==" + }, + "video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "requires": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "requires": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + } + }, + "which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "requires": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + } + }, + "which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + }, + "ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "requires": {} + }, + "xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==" + }, + "xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==" + }, + "zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "requires": { + "use-sync-external-store": "1.2.0" + } + } + } +} diff --git a/packages/examples/sdk-backend-node/package.json b/packages/examples/sdk-backend-node/package.json index 97b7d47cb..47b5d3196 100644 --- a/packages/examples/sdk-backend-node/package.json +++ b/packages/examples/sdk-backend-node/package.json @@ -11,7 +11,7 @@ "author": "", "license": "ISC", "dependencies": { - "@pushprotocol/restapi": "^1.4.17", + "@pushprotocol/restapi": "@latest", "@pushprotocol/socket": "^0.5.2" } } diff --git a/packages/examples/sdk-backend-node/pushAPI/index.ts b/packages/examples/sdk-backend-node/pushAPI/index.ts index e14d56659..60fdd8285 100644 --- a/packages/examples/sdk-backend-node/pushAPI/index.ts +++ b/packages/examples/sdk-backend-node/pushAPI/index.ts @@ -9,6 +9,7 @@ import { config } from '../config'; import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; import { createWalletClient, http } from 'viem'; import { goerli } from 'viem/chains'; +import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; // CONFIGS const { env, showAPIResponse } = config; @@ -135,6 +136,27 @@ export const runPushAPICases = async (): Promise => { console.log('PushAPI.chat.send | Response - 200 OK\n\n'); // ------------------------------------------------------------------- // ------------------------------------------------------------------- + console.log('PushAPI.chat.decrypt'); + const pushSDKSocket = createSocketConnection({ + user: signerAddress, + socketType: 'chat', + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + env: env, + }); + if (pushSDKSocket) { + await userAlice.chat.send(secondSignerAddress, { + content: 'Hello Bob!', + type: 'Text', + }); + pushSDKSocket.on(EVENTS.CHAT_RECEIVED_MESSAGE, async (message) => { + // uncomment after latest sdk deployment + // await userAlice.chat.decrypt([message]); + // pushSDKSocket.disconnect(); + }); + } + console.log('PushAPI.chat.decrypt | Response - 200 OK\n\n'); + // ------------------------------------------------------------------- + // ------------------------------------------------------------------- console.log('PushAPI.chat.accept'); const bobAcceptsRequest = await userBob.chat.accept(signerAddress); if (showAPIResponse) { diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx index d898b3736..789c84588 100644 --- a/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/ChatTest.tsx @@ -71,6 +71,9 @@ const ChatTest = () => { CHAT.GETGROUPACCESS + + CHAT.GETGROUPMEMBERSTATUS + CHAT.SEARCHGROUPS diff --git a/packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupMemberStatusTest.tsx b/packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupMemberStatusTest.tsx new file mode 100644 index 000000000..085c86ac9 --- /dev/null +++ b/packages/examples/sdk-frontend-react/src/app/ChatTest/GetGroupMemberStatusTest.tsx @@ -0,0 +1,86 @@ +import { useState, useContext } from 'react'; +import { + Section, + SectionItem, + CodeFormatter, + SectionButton, +} from '../components/StyledComponents'; +import Loader from '../components/Loader'; +import { EnvContext } from '../context'; +import * as PushAPI from '@pushprotocol/restapi'; + +const GetGroupMemberStatusTest = () => { + const { env } = useContext(EnvContext); + const [isLoading, setLoading] = useState(false); + const [chatId, setChatId] = useState(''); + const [did, setDid] = useState(''); + const [sendResponse, setSendResponse] = useState(''); + + const updateChatId = (e: React.SyntheticEvent) => { + setChatId((e.target as HTMLInputElement).value); + }; + + const updateDid = (e: React.SyntheticEvent) => { + setDid((e.target as HTMLInputElement).value); + }; + + const testGetGroupMemberStatus = async () => { + try { + setLoading(true); + + const response = await PushAPI.chat.getGroupMemberStatus({ + chatId: chatId, + did: did, + env, + }); + setSendResponse(response); + } catch (e) { + console.error(e); + } finally { + setLoading(false); + } + }; + + return ( +
+

Get Group Member Status Test Page

+ + + +
+ + get group member status + + + + + + + + + + +
+ {sendResponse ? ( + + {JSON.stringify(sendResponse, null, 4)} + + ) : null} +
+
+
+
+ ); +}; + +export default GetGroupMemberStatusTest; diff --git a/packages/examples/sdk-frontend-react/src/app/app.tsx b/packages/examples/sdk-frontend-react/src/app/app.tsx index 28c2825b2..7f1db9f4c 100644 --- a/packages/examples/sdk-frontend-react/src/app/app.tsx +++ b/packages/examples/sdk-frontend-react/src/app/app.tsx @@ -87,6 +87,7 @@ import { lightChatTheme } from '@pushprotocol/uiweb'; import SearchSpaceTest from './SpaceTest/SearchSpaceTest'; import SearchGroupTest from './ChatTest/SearchGroupTest'; import RejectRequestTest from './ChatTest/RejectRequestTest'; +import GetGroupMemberStatusTest from './ChatTest/GetGroupMemberStatusTest'; window.Buffer = window.Buffer || Buffer; @@ -456,6 +457,8 @@ export function App() { } /> } /> } /> + } /> + } diff --git a/packages/examples/use-cases/.DONNOTREMOVE b/packages/examples/use-cases/.DONNOTREMOVE new file mode 100644 index 000000000..e69de29bb diff --git a/packages/examples/use-cases/automated-chat/package-lock.json b/packages/examples/use-cases/automated-chat/package-lock.json new file mode 100644 index 000000000..7287555fa --- /dev/null +++ b/packages/examples/use-cases/automated-chat/package-lock.json @@ -0,0 +1,6446 @@ +{ + "name": "automated-chat", + "version": "1.0.0", + "lockfileVersion": 2, + "requires": true, + "packages": { + "": { + "name": "automated-chat", + "version": "1.0.0", + "license": "ISC", + "dependencies": { + "@pushprotocol/restapi": "1.4.19", + "@pushprotocol/socket": "0.5.2", + "ethers": "5.7.2", + "node-dev": "8.0.0" + }, + "devDependencies": { + "nodemon": "3.0.1" + } + }, + "node_modules/@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "dependencies": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, + "node_modules/@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==", + "bin": { + "rlp": "bin/rlp" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "dependencies": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "node_modules/@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "node_modules/@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "node_modules/@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "node_modules/@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + } + }, + "node_modules/@ethersproject/bignumber/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "node_modules/@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "node_modules/@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "node_modules/@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "node_modules/@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ] + }, + "node_modules/@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "node_modules/@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "node_modules/@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + } + }, + "node_modules/@ethersproject/signing-key/node_modules/bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + }, + "node_modules/@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "node_modules/@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "node_modules/@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "node_modules/@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "node_modules/@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "node_modules/@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@livepeer/core": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.5.tgz", + "integrity": "sha512-02rD++yZhEmOi5N1kkTz88LbkhardAAXumo11muNBX1V9SRrS1oRRJMQyNt8QwOduH0RyNVTPEGxQSxyFHChFg==", + "dependencies": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "dependencies": { + "@ljharb/through": "^2.3.9" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "dependencies": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + }, + "engines": { + "node": ">=14.0.0" + } + }, + "node_modules/@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "dependencies": { + "@noble/hashes": "1.3.1" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==", + "engines": { + "node": ">= 16" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@pushprotocol/restapi": { + "version": "1.4.19", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.19.tgz", + "integrity": "sha512-MGeYMX0NB2/sPSOnyvERZL2jKqeBPE6nUgySecEvW/JaUW8DsAX7KSN5IU4xvF9KpQblbUDcdXq4iW55/oZqOA==", + "dependencies": { + "@ambire/signature-validator": "^1.3.1", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "dependencies": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, + "node_modules/@scure/base": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", + "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==", + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "dependencies": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "dependencies": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + }, + "funding": { + "url": "https://paulmillr.com/funding/" + } + }, + "node_modules/@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "node_modules/@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "node_modules/@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "node_modules/@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "node_modules/abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", + "dev": true + }, + "node_modules/aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + }, + "node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "dependencies": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "dependencies": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "dependencies": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "node_modules/available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "dependencies": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "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==" + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + }, + "node_modules/binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "dev": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "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==", + "dependencies": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "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, + "dependencies": { + "fill-range": "^7.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "node_modules/buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "node_modules/buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/chokidar": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", + "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", + "dev": true, + "funding": [ + { + "type": "individual", + "url": "https://paulmillr.com/funding/" + } + ], + "dependencies": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + }, + "engines": { + "node": ">= 8.10.0" + }, + "optionalDependencies": { + "fsevents": "~2.3.2" + } + }, + "node_modules/combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "dependencies": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "node_modules/core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==", + "hasInstallScript": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "node_modules/cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "dependencies": { + "node-fetch": "^2.6.12" + } + }, + "node_modules/crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "node_modules/custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "node_modules/dateformat": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", + "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==", + "engines": { + "node": "*" + } + }, + "node_modules/debounce": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/debounce/-/debounce-1.2.1.tgz", + "integrity": "sha512-XRRe6Glud4rd/ZGQfiV1ruXSfbvfJedlV9Y6zOlP+2K04vBYiJEte6stfFkCP03aMnY5tsipamumUjL14fofug==" + }, + "node_modules/debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "dependencies": { + "ms": "2.1.2" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/debug/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==" + }, + "node_modules/deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "dependencies": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "dependencies": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "dependencies": { + "minimatch": "^3.0.4" + }, + "bin": { + "ignored": "bin/ignored" + } + }, + "node_modules/duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "node_modules/dynamic-dedupe": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/dynamic-dedupe/-/dynamic-dedupe-0.3.0.tgz", + "integrity": "sha512-ssuANeD+z97meYOqd50e04Ze5qp4bPqo8cCkI4TRjZkzAUgIDTrXV1R8QCdINpiI+hw14+rYazvTRdQrz0/rFQ==", + "dependencies": { + "xtend": "^4.0.0" + } + }, + "node_modules/elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "dependencies": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + } + }, + "node_modules/engine.io-client/node_modules/ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==", + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, + "node_modules/es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "dependencies": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dependencies": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "dependencies": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "node_modules/ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "funding": [ + { + "type": "individual", + "url": "https://gitcoin.co/grants/13/ethersjs-complete-simple-and-tiny-2" + }, + { + "type": "individual", + "url": "https://www.buymeacoffee.com/ricmoo" + } + ], + "dependencies": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "node_modules/ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "dependencies": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "dependencies": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/filewatcher": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/filewatcher/-/filewatcher-3.0.1.tgz", + "integrity": "sha512-Fro8py2B8EJupSP37Kyd4kjKZLr+5ksFq7Vbw8A392Z15Unq8016SPUDvO/AsDj5V6bbPk98PTAinpc5YhPbJw==", + "dependencies": { + "debounce": "^1.0.0" + } + }, + "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, + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==", + "funding": [ + { + "type": "individual", + "url": "https://github.com/sponsors/RubenVerborgh" + } + ], + "engines": { + "node": ">=4.0" + }, + "peerDependenciesMeta": { + "debug": { + "optional": true + } + } + }, + "node_modules/for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "dependencies": { + "is-callable": "^1.1.3" + } + }, + "node_modules/form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + }, + "engines": { + "node": ">= 6" + } + }, + "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==" + }, + "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, + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": "^8.16.0 || ^10.6.0 || >=11.0.0" + } + }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "node_modules/function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, + "node_modules/get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "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": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "dependencies": { + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "node_modules/growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha512-+xGQY0YyAWCnqy7Cd++hc2JqMYzlm0dG30Jd0beaA64sROr8C4nt8Yc9V5Ro3avlSUDTN0ulqP/VBKi1/lLygw==" + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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, + "engines": { + "node": ">=4" + } + }, + "node_modules/has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "dependencies": { + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "dependencies": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "node_modules/hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, + "node_modules/hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "dependencies": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/ignore-by-default": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/ignore-by-default/-/ignore-by-default-1.0.1.tgz", + "integrity": "sha512-Ius2VYcGNk7T90CppJqcIkS5ooHUZyIQK+ClZfMfMNFEF9VSE73Fq+906u/CWu92x4gzZMWOwfFYckPObzdEbA==", + "dev": true + }, + "node_modules/immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, + "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==", + "dependencies": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "node_modules/internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "dependencies": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "dependencies": { + "has-bigints": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "dependencies": { + "binary-extensions": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==", + "bin": { + "is-docker": "cli.js" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "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, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==", + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "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, + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==", + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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, + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "dependencies": { + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", + "dependencies": { + "is-docker": "^2.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "node_modules/isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + }, + "node_modules/joi": { + "version": "17.10.1", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.1.tgz", + "integrity": "sha512-vIiDxQKmRidUVp8KngT8MZSOcmRVm2zV7jbMjNYWuHcJWI0bUck3nRTGQjhpPlQenIQIBC5Vp9AhcnHbWQqafw==", + "dependencies": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "node_modules/js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "node_modules/js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "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==", + "peer": true + }, + "node_modules/livepeer": { + "version": "2.8.5", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.5.tgz", + "integrity": "sha512-m9v0yIIKC4M5NujAklkYNqMk5fHeRrIfqyah0F4XxpI4zgTPFy+vUm3bUg+meyrdYzwZBljpvGUpYO1A1w/EKA==", + "dependencies": { + "@livepeer/core": "^1.8.5", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "node_modules/lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "dependencies": { + "lodash._stringtopath": "~4.8.0" + } + }, + "node_modules/lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "node_modules/lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "dependencies": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "node_modules/lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "node_modules/lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "node_modules/lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "dependencies": { + "lodash._basetostring": "~4.12.0" + } + }, + "node_modules/lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "node_modules/lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "dependencies": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.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==", + "peer": true, + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, + "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==", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==" + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "node_modules/minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, + "node_modules/multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node_modules/node-dev": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/node-dev/-/node-dev-8.0.0.tgz", + "integrity": "sha512-GXc0KxmBXfQxMPdymOui40yvC5W/RXFwmuUDT65wvTAO/o9wAsddYC8q4EHKxq3Qqt+uLS/g7XKdgVcsjyk9lw==", + "dependencies": { + "dateformat": "^3.0.3", + "dynamic-dedupe": "^0.3.0", + "filewatcher": "~3.0.0", + "get-package-type": "^0.1.0", + "minimist": "^1.2.6", + "node-notifier": "^8.0.1", + "resolve": "^1.22.0", + "semver": "^7.3.7" + }, + "bin": { + "node-dev": "bin/node-dev" + }, + "engines": { + "node": ">=14" + } + }, + "node_modules/node-dev/node_modules/resolve": { + "version": "1.22.5", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.5.tgz", + "integrity": "sha512-qWhv7PF1V95QPvRoUGHxOtnAlEvlXBylMZcjUR9pAumMmveFtcHJRXGIr+TkjfNJVQypqv2qcDiiars2y1PsSg==", + "dependencies": { + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "dependencies": { + "whatwg-url": "^5.0.0" + }, + "engines": { + "node": "4.x || >=6.0.0" + }, + "peerDependencies": { + "encoding": "^0.1.0" + }, + "peerDependenciesMeta": { + "encoding": { + "optional": true + } + } + }, + "node_modules/node-notifier": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-8.0.2.tgz", + "integrity": "sha512-oJP/9NAdd9+x2Q+rfphB2RJCHjod70RcRLjosiPMMu5gjIfwVnOUGq2nbTjTUbmy0DJ/tFIVT30+Qe3nzl4TJg==", + "dependencies": { + "growly": "^1.3.0", + "is-wsl": "^2.2.0", + "semver": "^7.3.2", + "shellwords": "^0.1.1", + "uuid": "^8.3.0", + "which": "^2.0.2" + } + }, + "node_modules/node-notifier/node_modules/uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==", + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/nodemon": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.0.1.tgz", + "integrity": "sha512-g9AZ7HmkhQkqXkRc20w+ZfQ73cHLbE8hnPbtaFbFtCumZsjyMhKk9LajQ07U5Ux28lvFjZ5X7HvWR1xzU8jHVw==", + "dev": true, + "dependencies": { + "chokidar": "^3.5.2", + "debug": "^3.2.7", + "ignore-by-default": "^1.0.1", + "minimatch": "^3.1.2", + "pstree.remy": "^1.1.8", + "semver": "^7.5.3", + "simple-update-notifier": "^2.0.0", + "supports-color": "^5.5.0", + "touch": "^3.1.0", + "undefsafe": "^2.0.5" + }, + "bin": { + "nodemon": "bin/nodemon.js" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/nodemon" + } + }, + "node_modules/nodemon/node_modules/debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "dependencies": { + "ms": "^2.1.1" + } + }, + "node_modules/nodemon/node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true + }, + "node_modules/nodemon/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, + "dependencies": { + "has-flag": "^3.0.0" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/nopt": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz", + "integrity": "sha512-NWmpvLSqUrgrAC9HCuxEvb+PSloHpqVu+FqcO4eeF2h5qYRhA7ev6KvelyQAKtegUbC6RypJnlEOhd8vloNKYg==", + "dev": true, + "dependencies": { + "abbrev": "1" + }, + "bin": { + "nopt": "bin/nopt.js" + }, + "engines": { + "node": "*" + } + }, + "node_modules/normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==", + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/openpgp": { + "version": "5.10.1", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.10.1.tgz", + "integrity": "sha512-SR5Ft+ej51d0+p53ld5Ney0Yiz0y8Mh1YYLJrvpRMbTaNhvS1QcDX0Oq1rW9sjBnQXtgrpWw2Zve3rm7K5C/pw==", + "dependencies": { + "asn1.js": "^5.0.0" + }, + "engines": { + "node": ">= 8.0.0" + } + }, + "node_modules/parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==", + "engines": { + "node": ">=0.10.0" + } + }, + "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==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "node_modules/picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true, + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "dependencies": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "node_modules/pstree.remy": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/pstree.remy/-/pstree.remy-1.1.8.tgz", + "integrity": "sha512-77DZwxQmxKnu3aR542U+X8FypNzbfJ+C5XQDk3uWjWxn6151aIMGthWYRXTqT1E5oJvg+ljaa2OJi+VfvCOQ8w==", + "dev": true + }, + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "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==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "dependencies": { + "safe-buffer": "^5.1.0" + } + }, + "node_modules/re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "node_modules/react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "dependencies": { + "picomatch": "^2.2.1" + }, + "engines": { + "node": ">=8.10.0" + } + }, + "node_modules/regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==", + "engines": { + "node": ">=0.10" + } + }, + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "node_modules/resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "dependencies": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", + "engines": { + "node": ">= 4" + } + }, + "node_modules/safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ] + }, + "node_modules/safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "node_modules/scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + }, + "node_modules/semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "dependencies": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==" + }, + "node_modules/side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "dependencies": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "node_modules/simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "dependencies": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "node_modules/simple-update-notifier": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/simple-update-notifier/-/simple-update-notifier-2.0.0.tgz", + "integrity": "sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==", + "dev": true, + "dependencies": { + "semver": "^7.5.3" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "dependencies": { + "internal-slot": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "dependencies": { + "safe-buffer": "~5.2.0" + } + }, + "node_modules/string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "dependencies": { + "is-hex-prefixed": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "node_modules/supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "dependencies": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "bin": { + "tap-out": "bin/cmd.js" + } + }, + "node_modules/tap-out/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/tap-out/node_modules/readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "dependencies": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/tap-out/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/tap-out/node_modules/string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "dependencies": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + }, + "bin": { + "tap-spec": "bin/cmd.js", + "tspec": "bin/cmd.js" + } + }, + "node_modules/tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "dependencies": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + }, + "bin": { + "tape": "bin/tape" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "node_modules/through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "dependencies": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + } + }, + "node_modules/through2/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/through2/node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "node_modules/through2/node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "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/through2/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/through2/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "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, + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/touch": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/touch/-/touch-3.1.0.tgz", + "integrity": "sha512-WBx8Uy5TLtOSRtIq+M03/sKDrXCLHxwDcquSP2c43Le03/9serjQBIztjRz6FkJez9D/hleyAXTBGLwwZUw9lA==", + "dev": true, + "dependencies": { + "nopt": "~1.0.10" + }, + "bin": { + "nodetouch": "bin/nodetouch.js" + } + }, + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "node_modules/trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==", + "deprecated": "Use String.prototype.trim() instead" + }, + "node_modules/tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "node_modules/tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "dependencies": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "node_modules/tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "node_modules/tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + }, + "node_modules/typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "dependencies": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/undefsafe": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/undefsafe/-/undefsafe-2.0.5.tgz", + "integrity": "sha512-WxONCrssBM8TSPRqN5EmsjVrsv4A8X12J4ArBiiayv3DyyG3ZlIg6yysuuSYdZsVz3TKcTg2fd//Ujd4CHV1iA==", + "dev": true + }, + "node_modules/unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==", + "engines": { + "node": ">=8" + } + }, + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "node_modules/uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==", + "funding": [ + "https://github.com/sponsors/broofa", + "https://github.com/sponsors/ctavan" + ], + "bin": { + "uuid": "dist/bin/uuid" + } + }, + "node_modules/video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "node_modules/webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "node_modules/whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "node_modules/which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "dependencies": { + "isexe": "^2.0.0" + }, + "bin": { + "node-which": "bin/node-which" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "dependencies": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "dependencies": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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==" + }, + "node_modules/ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "engines": { + "node": ">=8.3.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "engines": { + "node": ">=0.4" + } + }, + "node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, + "node_modules/zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "dependencies": { + "use-sync-external-store": "1.2.0" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@types/react": ">=16.8", + "immer": ">=9.0", + "react": ">=16.8" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + } + } + } + }, + "dependencies": { + "@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "requires": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, + "@ethereumjs/rlp": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ethereumjs/rlp/-/rlp-4.0.1.tgz", + "integrity": "sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw==" + }, + "@ethereumjs/util": { + "version": "8.1.0", + "resolved": "https://registry.npmjs.org/@ethereumjs/util/-/util-8.1.0.tgz", + "integrity": "sha512-zQ0IqbdX8FZ9aw11vP+dZkKDkS+kgIvQPHnSAXzP9pLu+Rfu3D3XEeLbicvoXJTYnhZiPmsZUxgdzXwNKxRPbA==", + "requires": { + "@ethereumjs/rlp": "^4.0.1", + "ethereum-cryptography": "^2.0.0", + "micro-ftch": "^0.3.1" + } + }, + "@ethersproject/abi": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", + "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", + "requires": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/abstract-provider": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", + "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0" + } + }, + "@ethersproject/abstract-signer": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", + "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "@ethersproject/address": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", + "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/rlp": "^5.7.0" + } + }, + "@ethersproject/base64": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", + "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", + "requires": { + "@ethersproject/bytes": "^5.7.0" + } + }, + "@ethersproject/basex": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", + "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/properties": "^5.7.0" + } + }, + "@ethersproject/bignumber": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", + "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "bn.js": "^5.2.1" + }, + "dependencies": { + "bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + } + } + }, + "@ethersproject/bytes": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", + "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/constants": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", + "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0" + } + }, + "@ethersproject/contracts": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", + "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", + "requires": { + "@ethersproject/abi": "^5.7.0", + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/transactions": "^5.7.0" + } + }, + "@ethersproject/hash": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", + "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/hdnode": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", + "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "@ethersproject/json-wallets": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", + "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", + "requires": { + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/pbkdf2": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "aes-js": "3.0.0", + "scrypt-js": "3.0.1" + } + }, + "@ethersproject/keccak256": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", + "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "js-sha3": "0.8.0" + } + }, + "@ethersproject/logger": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" + }, + "@ethersproject/networks": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", + "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/pbkdf2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", + "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/sha2": "^5.7.0" + } + }, + "@ethersproject/properties": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", + "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", + "requires": { + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/providers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", + "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/base64": "^5.7.0", + "@ethersproject/basex": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/networks": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/web": "^5.7.0", + "bech32": "1.1.4", + "ws": "7.4.6" + } + }, + "@ethersproject/random": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", + "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/rlp": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", + "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/sha2": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", + "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "hash.js": "1.1.7" + } + }, + "@ethersproject/signing-key": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", + "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "bn.js": "^5.2.1", + "elliptic": "6.5.4", + "hash.js": "1.1.7" + }, + "dependencies": { + "bn.js": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" + } + } + }, + "@ethersproject/solidity": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", + "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/sha2": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/strings": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", + "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/transactions": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", + "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", + "requires": { + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/rlp": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0" + } + }, + "@ethersproject/units": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", + "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", + "requires": { + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/constants": "^5.7.0", + "@ethersproject/logger": "^5.7.0" + } + }, + "@ethersproject/wallet": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", + "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", + "requires": { + "@ethersproject/abstract-provider": "^5.7.0", + "@ethersproject/abstract-signer": "^5.7.0", + "@ethersproject/address": "^5.7.0", + "@ethersproject/bignumber": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/hdnode": "^5.7.0", + "@ethersproject/json-wallets": "^5.7.0", + "@ethersproject/keccak256": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/random": "^5.7.0", + "@ethersproject/signing-key": "^5.7.0", + "@ethersproject/transactions": "^5.7.0", + "@ethersproject/wordlists": "^5.7.0" + } + }, + "@ethersproject/web": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", + "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", + "requires": { + "@ethersproject/base64": "^5.7.0", + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@ethersproject/wordlists": { + "version": "5.7.0", + "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", + "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", + "requires": { + "@ethersproject/bytes": "^5.7.0", + "@ethersproject/hash": "^5.7.0", + "@ethersproject/logger": "^5.7.0", + "@ethersproject/properties": "^5.7.0", + "@ethersproject/strings": "^5.7.0" + } + }, + "@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@livepeer/core": { + "version": "1.8.5", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.5.tgz", + "integrity": "sha512-02rD++yZhEmOi5N1kkTz88LbkhardAAXumo11muNBX1V9SRrS1oRRJMQyNt8QwOduH0RyNVTPEGxQSxyFHChFg==", + "requires": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + } + }, + "@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "requires": { + "@ljharb/through": "^2.3.9" + } + }, + "@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==" + }, + "@metamask/eth-sig-util": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.1.0.tgz", + "integrity": "sha512-mlgziIHYlA9pi/XZerChqg4NocdOgBPB9NmxgXWQO2U2hH8RGOJQrz6j/AIKkYxgCMIE2PY000+joOwXfzeTDQ==", + "requires": { + "@ethereumjs/util": "^8.0.6", + "bn.js": "^4.12.0", + "ethereum-cryptography": "^2.0.0", + "ethjs-util": "^0.1.6", + "tweetnacl": "^1.0.3", + "tweetnacl-util": "^0.15.1" + } + }, + "@noble/curves": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/@noble/curves/-/curves-1.1.0.tgz", + "integrity": "sha512-091oBExgENk/kGj3AZmtBDMpxQPDtxQABR2B9lb1JbVTs6ytdzZNwvhxQ4MWasRNEzlbEH8jCWFCwhF/Obj5AA==", + "requires": { + "@noble/hashes": "1.3.1" + } + }, + "@noble/hashes": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@noble/hashes/-/hashes-1.3.1.tgz", + "integrity": "sha512-EbqwksQwz9xDRGfDST86whPBgM65E0OH/pCgqW0GBVzO22bNE+NuIbeTb714+IfSjU3aRk47EUvXIb5bTsenKA==" + }, + "@pushprotocol/restapi": { + "version": "1.4.19", + "resolved": "https://registry.npmjs.org/@pushprotocol/restapi/-/restapi-1.4.19.tgz", + "integrity": "sha512-MGeYMX0NB2/sPSOnyvERZL2jKqeBPE6nUgySecEvW/JaUW8DsAX7KSN5IU4xvF9KpQblbUDcdXq4iW55/oZqOA==", + "requires": { + "@ambire/signature-validator": "^1.3.1", + "@metamask/eth-sig-util": "^5.0.2", + "axios": "^0.27.2", + "buffer": "^6.0.3", + "crypto-js": "^4.1.1", + "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", + "openpgp": "^5.5.0", + "simple-peer": "^9.11.1", + "tslib": "^2.3.0", + "unique-names-generator": "^4.7.1", + "uuid": "^9.0.0", + "video-stream-merger": "^4.0.1" + } + }, + "@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "requires": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + } + }, + "@scure/base": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.3.tgz", + "integrity": "sha512-/+SgoRjLq7Xlf0CWuLHq2LUZeL/w65kfzAPG5NH9pcmBhs+nunQTn4gvdwgMTIXnt9b2C/1SeL2XiysZEyIC9Q==" + }, + "@scure/bip32": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@scure/bip32/-/bip32-1.3.1.tgz", + "integrity": "sha512-osvveYtyzdEVbt3OfwwXFr4P2iVBL5u1Q3q4ONBfDY/UpOuXmOlbgwc1xECEboY8wIays8Yt6onaWMUdUbfl0A==", + "requires": { + "@noble/curves": "~1.1.0", + "@noble/hashes": "~1.3.1", + "@scure/base": "~1.1.0" + } + }, + "@scure/bip39": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/@scure/bip39/-/bip39-1.2.1.tgz", + "integrity": "sha512-Z3/Fsz1yr904dduJD0NpiyRHhRYHdcnyh73FZWiV+/qhWi83wNJ3NWolYqCEN+ZWsUz2TWwajJggcRE9r1zUYg==", + "requires": { + "@noble/hashes": "~1.3.0", + "@scure/base": "~1.1.0" + } + }, + "@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, + "abbrev": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz", + "integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==", + "dev": true + }, + "aes-js": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" + }, + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + }, + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==" + }, + "anymatch": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/anymatch/-/anymatch-3.1.3.tgz", + "integrity": "sha512-KMReFUr0B4t+D+OBkjR3KYqvocp2XaSzO55UcB6mgQMd3KbcE+mWTyvVV7D/zsdEbNnV6acZUutkiHQXvTr1Rw==", + "dev": true, + "requires": { + "normalize-path": "^3.0.0", + "picomatch": "^2.0.4" + } + }, + "array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "requires": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + } + }, + "array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + } + }, + "arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + } + }, + "asn1.js": { + "version": "5.4.1", + "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", + "integrity": "sha512-+I//4cYPccV8LdmBLiX8CYvf9Sp3vQsrqu2QNXRcrbiWvcx/UdlFiqUJJzxRQxgsZmvhXhn4cSKeSmoFjVdupA==", + "requires": { + "bn.js": "^4.0.0", + "inherits": "^2.0.1", + "minimalistic-assert": "^1.0.0", + "safer-buffer": "^2.1.0" + } + }, + "asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==" + }, + "available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==" + }, + "axios": { + "version": "0.27.2", + "resolved": "https://registry.npmjs.org/axios/-/axios-0.27.2.tgz", + "integrity": "sha512-t+yRIyySRTp/wua5xEr+z1q60QmLq8ABsS5O9Me1AsE5dfKqgnCFzwiCZZ/cGNd1lq4/7akDWMxdhVlucjmnOQ==", + "requires": { + "follow-redirects": "^1.14.9", + "form-data": "^4.0.0" + } + }, + "balanced-match": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-1.0.2.tgz", + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" + }, + "base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==" + }, + "bech32": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" + }, + "binary-extensions": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/binary-extensions/-/binary-extensions-2.2.0.tgz", + "integrity": "sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==", + "dev": true + }, + "bn.js": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.12.0.tgz", + "integrity": "sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==" + }, + "brace-expansion": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", + "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", + "requires": { + "balanced-match": "^1.0.0", + "concat-map": "0.0.1" + } + }, + "braces": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.2.tgz", + "integrity": "sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==", + "dev": true, + "requires": { + "fill-range": "^7.0.1" + } + }, + "brorand": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" + }, + "buffer": { + "version": "6.0.3", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-6.0.3.tgz", + "integrity": "sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==", + "requires": { + "base64-js": "^1.3.1", + "ieee754": "^1.2.1" + } + }, + "buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "requires": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + } + }, + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "chokidar": { + "version": "3.5.3", + "resolved": "https://registry.npmjs.org/chokidar/-/chokidar-3.5.3.tgz", + "integrity": "sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==", + "dev": true, + "requires": { + "anymatch": "~3.1.2", + "braces": "~3.0.2", + "fsevents": "~2.3.2", + "glob-parent": "~5.1.2", + "is-binary-path": "~2.1.0", + "is-glob": "~4.0.1", + "normalize-path": "~3.0.0", + "readdirp": "~3.6.0" + } + }, + "combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "requires": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, + "combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "requires": { + "delayed-stream": "~1.0.0" + } + }, + "concat-map": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==" + }, + "core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" + }, + "cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "requires": { + "node-fetch": "^2.6.12" + } + }, + "crypto-js": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", + "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" + }, + "custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, + "dateformat": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/dateformat/-/dateformat-3.0.3.tgz", + "integrity": "sha512-jyCETtSl3VMZMWeRo7iY1FL19ges1t55hMo5yaam4Jrsm5EPL89UQkoQRyiI+Yf4k8r2ZpdngkV8hr1lIdjb3Q==" + }, + "debounce": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/debounce/-/debounce-1.2.1.tgz", + "integrity": "sha512-XRRe6Glud4rd/ZGQfiV1ruXSfbvfJedlV9Y6zOlP+2K04vBYiJEte6stfFkCP03aMnY5tsipamumUjL14fofug==" + }, + "debug": { + "version": "4.3.4", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", + "integrity": "sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==", + "requires": { + "ms": "2.1.2" + }, + "dependencies": { + "ms": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz", + "integrity": "sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==" + } + } + }, + "deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + } + }, + "define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "requires": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + } + }, + "define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "requires": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + } + }, + "defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==" + }, + "delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==" + }, + "dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "requires": { + "minimatch": "^3.0.4" + } + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, + "dynamic-dedupe": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/dynamic-dedupe/-/dynamic-dedupe-0.3.0.tgz", + "integrity": "sha512-ssuANeD+z97meYOqd50e04Ze5qp4bPqo8cCkI4TRjZkzAUgIDTrXV1R8QCdINpiI+hw14+rYazvTRdQrz0/rFQ==", + "requires": { + "xtend": "^4.0.0" + } + }, + "elliptic": { + "version": "6.5.4", + "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", + "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", + "requires": { + "bn.js": "^4.11.9", + "brorand": "^1.1.0", + "hash.js": "^1.0.0", + "hmac-drbg": "^1.0.1", + "inherits": "^2.0.4", + "minimalistic-assert": "^1.0.1", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + }, + "dependencies": { + "ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "requires": {} + } + } + }, + "engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==" + }, + "err-code": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", + "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" + }, + "es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + } + }, + "es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + } + }, + "es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "requires": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, + "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==" + }, + "ethereum-cryptography": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/ethereum-cryptography/-/ethereum-cryptography-2.1.2.tgz", + "integrity": "sha512-Z5Ba0T0ImZ8fqXrJbpHcbpAvIswRte2wGNR/KePnu8GbbvgJ47lMxT/ZZPG6i9Jaht4azPDop4HaM00J0J59ug==", + "requires": { + "@noble/curves": "1.1.0", + "@noble/hashes": "1.3.1", + "@scure/bip32": "1.3.1", + "@scure/bip39": "1.2.1" + } + }, + "ethers": { + "version": "5.7.2", + "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", + "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", + "requires": { + "@ethersproject/abi": "5.7.0", + "@ethersproject/abstract-provider": "5.7.0", + "@ethersproject/abstract-signer": "5.7.0", + "@ethersproject/address": "5.7.0", + "@ethersproject/base64": "5.7.0", + "@ethersproject/basex": "5.7.0", + "@ethersproject/bignumber": "5.7.0", + "@ethersproject/bytes": "5.7.0", + "@ethersproject/constants": "5.7.0", + "@ethersproject/contracts": "5.7.0", + "@ethersproject/hash": "5.7.0", + "@ethersproject/hdnode": "5.7.0", + "@ethersproject/json-wallets": "5.7.0", + "@ethersproject/keccak256": "5.7.0", + "@ethersproject/logger": "5.7.0", + "@ethersproject/networks": "5.7.1", + "@ethersproject/pbkdf2": "5.7.0", + "@ethersproject/properties": "5.7.0", + "@ethersproject/providers": "5.7.2", + "@ethersproject/random": "5.7.0", + "@ethersproject/rlp": "5.7.0", + "@ethersproject/sha2": "5.7.0", + "@ethersproject/signing-key": "5.7.0", + "@ethersproject/solidity": "5.7.0", + "@ethersproject/strings": "5.7.0", + "@ethersproject/transactions": "5.7.0", + "@ethersproject/units": "5.7.0", + "@ethersproject/wallet": "5.7.0", + "@ethersproject/web": "5.7.1", + "@ethersproject/wordlists": "5.7.0" + } + }, + "ethjs-util": { + "version": "0.1.6", + "resolved": "https://registry.npmjs.org/ethjs-util/-/ethjs-util-0.1.6.tgz", + "integrity": "sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==", + "requires": { + "is-hex-prefixed": "1.0.0", + "strip-hex-prefix": "1.0.0" + } + }, + "figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "requires": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + } + }, + "filewatcher": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/filewatcher/-/filewatcher-3.0.1.tgz", + "integrity": "sha512-Fro8py2B8EJupSP37Kyd4kjKZLr+5ksFq7Vbw8A392Z15Unq8016SPUDvO/AsDj5V6bbPk98PTAinpc5YhPbJw==", + "requires": { + "debounce": "^1.0.0" + } + }, + "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, + "requires": { + "to-regex-range": "^5.0.1" + } + }, + "follow-redirects": { + "version": "1.15.2", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.2.tgz", + "integrity": "sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==" + }, + "for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "requires": { + "is-callable": "^1.1.3" + } + }, + "form-data": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.0.tgz", + "integrity": "sha512-ETEklSGi5t0QMZuiXoA/Q6vcnxcLQP5vdugSpuAyi6SVGi2clPPp+xgEhuMaHC+zGgn31Kd235W35f7Hykkaww==", + "requires": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "mime-types": "^2.1.12" + } + }, + "fs.realpath": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz", + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" + }, + "fsevents": { + "version": "2.3.3", + "resolved": "https://registry.npmjs.org/fsevents/-/fsevents-2.3.3.tgz", + "integrity": "sha512-5xoDfX+fL7faATnagmWPpbFtwh/R77WmMMqqHGS65C3vvB0YHrgF+B1YmZ3441tMj5n63k0212XNoJwzlhffQw==", + "dev": true, + "optional": true + }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + } + }, + "functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==" + }, + "get-browser-rtc": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", + "integrity": "sha512-MghbMJ61EJrRsDe7w1Bvqt3ZsBuqhce5nrn/XAwgwOXhcsz53/ltdxOse1h/8eKXj5slzxdsz56g5rzOFSGwfQ==" + }, + "get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + } + }, + "get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==" + }, + "get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "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, + "requires": { + "is-glob": "^4.0.1" + } + }, + "globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "requires": { + "define-properties": "^1.1.3" + } + }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + } + }, + "graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "growly": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/growly/-/growly-1.3.0.tgz", + "integrity": "sha512-+xGQY0YyAWCnqy7Cd++hc2JqMYzlm0dG30Jd0beaA64sROr8C4nt8Yc9V5Ro3avlSUDTN0ulqP/VBKi1/lLygw==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==" + }, + "has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "has-flag": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-3.0.0.tgz", + "integrity": "sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==", + "dev": true + }, + "has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "requires": { + "get-intrinsic": "^1.1.1" + } + }, + "has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==" + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "hash.js": { + "version": "1.1.7", + "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", + "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", + "requires": { + "inherits": "^2.0.3", + "minimalistic-assert": "^1.0.1" + } + }, + "hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, + "hmac-drbg": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", + "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", + "requires": { + "hash.js": "^1.0.3", + "minimalistic-assert": "^1.0.0", + "minimalistic-crypto-utils": "^1.0.1" + } + }, + "ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==" + }, + "ignore-by-default": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/ignore-by-default/-/ignore-by-default-1.0.1.tgz", + "integrity": "sha512-Ius2VYcGNk7T90CppJqcIkS5ooHUZyIQK+ClZfMfMNFEF9VSE73Fq+906u/CWu92x4gzZMWOwfFYckPObzdEbA==", + "dev": true + }, + "immer": { + "version": "10.0.2", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.2.tgz", + "integrity": "sha512-Rx3CqeqQ19sxUtYV9CU911Vhy8/721wRFnJv3REVGWUmoAcIwzifTsdmJte/MV+0/XpM35LZdQMBGkRIoLPwQA==" + }, + "inflight": { + "version": "1.0.6", + "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", + "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", + "requires": { + "once": "^1.3.0", + "wrappy": "1" + } + }, + "inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" + }, + "internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "requires": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + } + }, + "is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + } + }, + "is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "requires": { + "has-bigints": "^1.0.1" + } + }, + "is-binary-path": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", + "integrity": "sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==", + "dev": true, + "requires": { + "binary-extensions": "^2.0.0" + } + }, + "is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==" + }, + "is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "requires": { + "has": "^1.0.3" + } + }, + "is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-docker": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-2.2.1.tgz", + "integrity": "sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==" + }, + "is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true + }, + "is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==" + }, + "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, + "requires": { + "is-extglob": "^2.1.1" + } + }, + "is-hex-prefixed": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", + "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==" + }, + "is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==" + }, + "is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==" + }, + "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 + }, + "is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==" + }, + "is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==" + }, + "is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "requires": { + "which-typed-array": "^1.1.11" + } + }, + "is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==" + }, + "is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "is-wsl": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-2.2.0.tgz", + "integrity": "sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==", + "requires": { + "is-docker": "^2.0.0" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, + "isexe": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", + "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==" + }, + "joi": { + "version": "17.10.1", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.1.tgz", + "integrity": "sha512-vIiDxQKmRidUVp8KngT8MZSOcmRVm2zV7jbMjNYWuHcJWI0bUck3nRTGQjhpPlQenIQIBC5Vp9AhcnHbWQqafw==", + "requires": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, + "js-sha3": { + "version": "0.8.0", + "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "peer": true + }, + "livepeer": { + "version": "2.8.5", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.5.tgz", + "integrity": "sha512-m9v0yIIKC4M5NujAklkYNqMk5fHeRrIfqyah0F4XxpI4zgTPFy+vUm3bUg+meyrdYzwZBljpvGUpYO1A1w/EKA==", + "requires": { + "@livepeer/core": "^1.8.5", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + } + }, + "lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "requires": { + "lodash._stringtopath": "~4.8.0" + } + }, + "lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "requires": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "requires": { + "lodash._basetostring": "~4.12.0" + } + }, + "lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "requires": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.0" + } + }, + "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==", + "peer": true, + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, + "lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "requires": { + "yallist": "^4.0.0" + } + }, + "micro-ftch": { + "version": "0.3.1", + "resolved": "https://registry.npmjs.org/micro-ftch/-/micro-ftch-0.3.1.tgz", + "integrity": "sha512-/0LLxhzP0tfiR5hcQebtudP56gUurs2CLkGarnCiB/OqEyUFQ6U3paQi/tgLv0hBJYt2rnr9MNpxz4fiiugstg==" + }, + "mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==" + }, + "mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "requires": { + "mime-db": "1.52.0" + } + }, + "minimalistic-assert": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz", + "integrity": "sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==" + }, + "minimalistic-crypto-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" + }, + "minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "requires": { + "brace-expansion": "^1.1.7" + } + }, + "minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==" + }, + "ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==" + }, + "multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, + "node-dev": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/node-dev/-/node-dev-8.0.0.tgz", + "integrity": "sha512-GXc0KxmBXfQxMPdymOui40yvC5W/RXFwmuUDT65wvTAO/o9wAsddYC8q4EHKxq3Qqt+uLS/g7XKdgVcsjyk9lw==", + "requires": { + "dateformat": "^3.0.3", + "dynamic-dedupe": "^0.3.0", + "filewatcher": "~3.0.0", + "get-package-type": "^0.1.0", + "minimist": "^1.2.6", + "node-notifier": "^8.0.1", + "resolve": "^1.22.0", + "semver": "^7.3.7" + }, + "dependencies": { + "resolve": { + "version": "1.22.5", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.5.tgz", + "integrity": "sha512-qWhv7PF1V95QPvRoUGHxOtnAlEvlXBylMZcjUR9pAumMmveFtcHJRXGIr+TkjfNJVQypqv2qcDiiars2y1PsSg==", + "requires": { + "is-core-module": "^2.13.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + } + } + }, + "node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "requires": { + "whatwg-url": "^5.0.0" + } + }, + "node-notifier": { + "version": "8.0.2", + "resolved": "https://registry.npmjs.org/node-notifier/-/node-notifier-8.0.2.tgz", + "integrity": "sha512-oJP/9NAdd9+x2Q+rfphB2RJCHjod70RcRLjosiPMMu5gjIfwVnOUGq2nbTjTUbmy0DJ/tFIVT30+Qe3nzl4TJg==", + "requires": { + "growly": "^1.3.0", + "is-wsl": "^2.2.0", + "semver": "^7.3.2", + "shellwords": "^0.1.1", + "uuid": "^8.3.0", + "which": "^2.0.2" + }, + "dependencies": { + "uuid": { + "version": "8.3.2", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-8.3.2.tgz", + "integrity": "sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==" + } + } + }, + "nodemon": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/nodemon/-/nodemon-3.0.1.tgz", + "integrity": "sha512-g9AZ7HmkhQkqXkRc20w+ZfQ73cHLbE8hnPbtaFbFtCumZsjyMhKk9LajQ07U5Ux28lvFjZ5X7HvWR1xzU8jHVw==", + "dev": true, + "requires": { + "chokidar": "^3.5.2", + "debug": "^3.2.7", + "ignore-by-default": "^1.0.1", + "minimatch": "^3.1.2", + "pstree.remy": "^1.1.8", + "semver": "^7.5.3", + "simple-update-notifier": "^2.0.0", + "supports-color": "^5.5.0", + "touch": "^3.1.0", + "undefsafe": "^2.0.5" + }, + "dependencies": { + "debug": { + "version": "3.2.7", + "resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz", + "integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==", + "dev": true, + "requires": { + "ms": "^2.1.1" + } + }, + "ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true + }, + "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, + "requires": { + "has-flag": "^3.0.0" + } + } + } + }, + "nopt": { + "version": "1.0.10", + "resolved": "https://registry.npmjs.org/nopt/-/nopt-1.0.10.tgz", + "integrity": "sha512-NWmpvLSqUrgrAC9HCuxEvb+PSloHpqVu+FqcO4eeF2h5qYRhA7ev6KvelyQAKtegUbC6RypJnlEOhd8vloNKYg==", + "dev": true, + "requires": { + "abbrev": "1" + } + }, + "normalize-path": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", + "integrity": "sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==", + "dev": true + }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==" + }, + "object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==" + }, + "object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + } + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" + }, + "object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + } + }, + "once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "requires": { + "wrappy": "1" + } + }, + "openpgp": { + "version": "5.10.1", + "resolved": "https://registry.npmjs.org/openpgp/-/openpgp-5.10.1.tgz", + "integrity": "sha512-SR5Ft+ej51d0+p53ld5Ney0Yiz0y8Mh1YYLJrvpRMbTaNhvS1QcDX0Oq1rW9sjBnQXtgrpWw2Zve3rm7K5C/pw==", + "requires": { + "asn1.js": "^5.0.0" + } + }, + "parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==" + }, + "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==" + }, + "path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, + "picomatch": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.1.tgz", + "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", + "dev": true + }, + "plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==" + }, + "pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "requires": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + } + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "requires": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, + "pstree.remy": { + "version": "1.1.8", + "resolved": "https://registry.npmjs.org/pstree.remy/-/pstree.remy-1.1.8.tgz", + "integrity": "sha512-77DZwxQmxKnu3aR542U+X8FypNzbfJ+C5XQDk3uWjWxn6151aIMGthWYRXTqT1E5oJvg+ljaa2OJi+VfvCOQ8w==", + "dev": true + }, + "querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, + "queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==" + }, + "randombytes": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/randombytes/-/randombytes-2.1.0.tgz", + "integrity": "sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==", + "requires": { + "safe-buffer": "^5.1.0" + } + }, + "re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "requires": { + "loose-envify": "^1.1.0" + } + }, + "readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "requires": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + } + }, + "readdirp": { + "version": "3.6.0", + "resolved": "https://registry.npmjs.org/readdirp/-/readdirp-3.6.0.tgz", + "integrity": "sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==", + "dev": true, + "requires": { + "picomatch": "^2.2.1" + } + }, + "regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + } + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==" + }, + "requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "requires": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + }, + "retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==" + }, + "safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + } + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + } + }, + "safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==" + }, + "scrypt-js": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" + }, + "semver": { + "version": "7.5.4", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.5.4.tgz", + "integrity": "sha512-1bCSESV6Pv+i21Hvpxp3Dx+pSD8lIPt8uVjRrxAUt/nbswYc+tK6Y2btiULjd4+fnq15PX+nqQDC7Oft7WkwcA==", + "requires": { + "lru-cache": "^6.0.0" + } + }, + "set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "requires": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + } + }, + "shellwords": { + "version": "0.1.1", + "resolved": "https://registry.npmjs.org/shellwords/-/shellwords-0.1.1.tgz", + "integrity": "sha512-vFwSUfQvqybiICwZY5+DAWIPLKsWO31Q91JSKl3UYv+K5c2QRPzn0qzec6QPu1Qc9eHYItiP3NdJqNVqetYAww==" + }, + "side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "requires": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + } + }, + "signal-exit": { + "version": "3.0.7", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" + }, + "simple-peer": { + "version": "9.11.1", + "resolved": "https://registry.npmjs.org/simple-peer/-/simple-peer-9.11.1.tgz", + "integrity": "sha512-D1SaWpOW8afq1CZGWB8xTfrT3FekjQmPValrqncJMX7QFl8YwhrPTZvMCANLtgBwwdS+7zURyqxDDEmY558tTw==", + "requires": { + "buffer": "^6.0.3", + "debug": "^4.3.2", + "err-code": "^3.0.1", + "get-browser-rtc": "^1.1.0", + "queue-microtask": "^1.2.3", + "randombytes": "^2.1.0", + "readable-stream": "^3.6.0" + } + }, + "simple-update-notifier": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/simple-update-notifier/-/simple-update-notifier-2.0.0.tgz", + "integrity": "sha512-a2B9Y0KlNXl9u/vsW6sTIu9vGEpfKu2wRV6l1H3XEas/0gUIzGzBoP/IouTcUQbm9JWZLH3COxyn03TYlFax6w==", + "dev": true, + "requires": { + "semver": "^7.5.3" + } + }, + "socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + } + }, + "socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + } + }, + "split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "requires": { + "through": "2" + } + }, + "stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "requires": { + "internal-slot": "^1.0.4" + } + }, + "string_decoder": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", + "integrity": "sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==", + "requires": { + "safe-buffer": "~5.2.0" + } + }, + "string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "requires": { + "is-hex-prefixed": "1.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==" + }, + "supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==" + }, + "tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "requires": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "requires": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "requires": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + } + }, + "tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "requires": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "requires": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "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, + "requires": { + "is-number": "^7.0.0" + } + }, + "touch": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/touch/-/touch-3.1.0.tgz", + "integrity": "sha512-WBx8Uy5TLtOSRtIq+M03/sKDrXCLHxwDcquSP2c43Le03/9serjQBIztjRz6FkJez9D/hleyAXTBGLwwZUw9lA==", + "dev": true, + "requires": { + "nopt": "~1.0.10" + } + }, + "tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==" + }, + "tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "requires": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "tweetnacl": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", + "integrity": "sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==" + }, + "tweetnacl-util": { + "version": "0.15.1", + "resolved": "https://registry.npmjs.org/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz", + "integrity": "sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==" + }, + "typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + } + }, + "unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "requires": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + } + }, + "undefsafe": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/undefsafe/-/undefsafe-2.0.5.tgz", + "integrity": "sha512-WxONCrssBM8TSPRqN5EmsjVrsv4A8X12J4ArBiiayv3DyyG3ZlIg6yysuuSYdZsVz3TKcTg2fd//Ujd4CHV1iA==", + "dev": true + }, + "unique-names-generator": { + "version": "4.7.1", + "resolved": "https://registry.npmjs.org/unique-names-generator/-/unique-names-generator-4.7.1.tgz", + "integrity": "sha512-lMx9dX+KRmG8sq6gulYYpKWZc9RlGsgBR6aoO8Qsm3qvkSJ+3rAymr+TnV8EDMrIrwuFJ4kruzMWM/OpYzPoow==" + }, + "url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "requires": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "requires": {} + }, + "util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==" + }, + "uuid": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/uuid/-/uuid-9.0.1.tgz", + "integrity": "sha512-b+1eJOlsR9K8HJpow9Ok3fiWOWSIcIzXodvv0rQjVoOVNpWMpxf1wZNpt4y9h10odCNrqnYp1OBzRktckBe3sA==" + }, + "video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "requires": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, + "which": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/which/-/which-2.0.2.tgz", + "integrity": "sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==", + "requires": { + "isexe": "^2.0.0" + } + }, + "which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "requires": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + } + }, + "which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "requires": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + } + }, + "which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + } + }, + "wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" + }, + "ws": { + "version": "7.4.6", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", + "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", + "requires": {} + }, + "xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==" + }, + "xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==" + }, + "yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + }, + "zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "requires": { + "use-sync-external-store": "1.2.0" + } + } + } +} diff --git a/packages/examples/use-cases/automated-chat/package.json b/packages/examples/use-cases/automated-chat/package.json new file mode 100644 index 000000000..dbd298c44 --- /dev/null +++ b/packages/examples/use-cases/automated-chat/package.json @@ -0,0 +1,24 @@ +{ + "name": "automated-chat", + "version": "1.0.0", + "description": "Example of Push Chat from backend, auto-responding to messages sent", + "main": "src/index.js", + "type": "module", + "scripts": { + "build": "rimraf ./build && tsc", + "start": "nodemon", + "inspect": "nodemon --inspect src/index.js", + "dev": "node-dev --respawn --transpile-only src/index.js", + "test": "echo \"Error: no test specified\" && exit 1" + }, + "author": "", + "license": "ISC", + "dependencies": { + "@pushprotocol/restapi": "1.4.19", + "@pushprotocol/socket": "0.5.2", + "ethers": "5.7.2" + }, + "devDependencies": { + "nodemon": "3.0.1" + } +} diff --git a/packages/examples/use-cases/automated-chat/src/index.js b/packages/examples/use-cases/automated-chat/src/index.js new file mode 100644 index 000000000..5725040e8 --- /dev/null +++ b/packages/examples/use-cases/automated-chat/src/index.js @@ -0,0 +1,42 @@ +console.log('Hello World'); + +import { PushAPI } from '@pushprotocol/restapi'; +import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; +import { ethers } from 'ethers'; + +// Creating a random signer from a wallet, ideally this is the wallet you will connect +const signer = ethers.Wallet.createRandom(); + +// Initialize wallet user, pass 'prod' instead of 'staging' for mainnet apps +const userAlice = await PushAPI.initialize(signer, { env: 'prod' }); + +// This will be the wallet address of the recipient +const pushAIWalletAddress = '0x99A08ac6254dcf7ccc37CeC662aeba8eFA666666'; + +// Send a message to Bob +console.log('sending message to PushAI Bot'); +const aliceMessagesPushAI = await userAlice.chat.send(pushAIWalletAddress, { + content: "Gm gm! It's a me... Mario", +}); + +// Create Socket to Listen to incoming messages +const pushSDKSocket = await createSocketConnection({ + user: signer.address, + socketType: 'chat', + socketOptions: { autoConnect: true, reconnectionAttempts: 3 }, + env: 'prod', +}); + +pushSDKSocket.on(EVENTS.CONNECT, (message) => { + console.log('Socket Connected'); +}); + +// React to message payload getting recieved +pushSDKSocket.on(EVENTS.CHAT_RECEIVED_MESSAGE, (message) => { + console.log(message); + pushSDKSocket.disconnect(); +}); + +pushSDKSocket.on(EVENTS.DISCONNECT, (message) => { + console.log('Socket Disconnected'); +}); diff --git a/packages/restapi/PushChatLowLevelAPI.md b/packages/restapi/PushChatLowLevelAPI.md index 1cd735442..5ead9ebde 100644 --- a/packages/restapi/PushChatLowLevelAPI.md +++ b/packages/restapi/PushChatLowLevelAPI.md @@ -1681,7 +1681,7 @@ const response = await PushAPI.chat.createGroup({ groupImage: <group image link> , admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], rules: { - 'groupAccess': { + 'entry': { 'conditions': [ { 'any': [ @@ -1717,7 +1717,7 @@ const response = await PushAPI.chat.createGroup({ } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -1803,10 +1803,10 @@ export type Condition = ConditionBase & { }; export interface Rules { - groupAccess?: { + entry?: { conditions: Array; }; - chatAccess?: { + chat?: { conditions: Array; }; } @@ -1814,7 +1814,7 @@ export interface Rules { #### Rules Object Description -The rules object consists of two main sections: `groupAccess` and `chatAccess`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. +The rules object consists of two main sections: `entry` and `chat`, both of which contain conditions to manage access and permissions within a chat application. These conditions may involve different criteria related to token holdings or guild membership. #### Conditions @@ -1995,7 +1995,7 @@ This structure governs user permissions within a guild. The subcategory dictates groupCreator: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', chatId: '0364908cbaef95a5a3124c394ada868177c158a4d677cedd6fd1e42db1852386', rules: { - 'groupAccess': { + 'entry': { 'conditions': [ { 'any': [ @@ -2030,7 +2030,7 @@ This structure governs user permissions within a guild. The subcategory dictates } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -2100,10 +2100,10 @@ Allowed Options (params with \_ are mandatory) ```typescript // PushAPI_chat_getGroupAccess | Response - 200 OK { - 'groupAccess': true, - 'chatAccess': false, + 'entry': true, + 'chat': false, 'rules': { - 'groupAccess': { + 'entry': { 'conditions': [ { 'any': [ @@ -2142,7 +2142,7 @@ Allowed Options (params with \_ are mandatory) } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -2227,7 +2227,7 @@ const response = await PushAPI.chat.updateGroup({ groupImage: <group image link> , admins: ['0x3829E53A15856d1846e1b52d3Bdf5839705c29e5'], rules: { - 'groupAccess': { + 'entry': { 'conditions': [ { 'any': [ @@ -2254,7 +2254,7 @@ const response = await PushAPI.chat.updateGroup({ } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ @@ -2431,7 +2431,7 @@ Allowed Options (params with _ are mandatory) groupCreator: 'eip155:0xb340E384FC4549591bc7994b0f90074753dEC72a', chatId: '870cbb20f0b116d5e461a154dc723dc1485976e97f61a673259698aa7f48371c', rules: { - 'groupAccess': { + 'entry': { 'conditions': [ { 'any': [ @@ -2458,7 +2458,7 @@ Allowed Options (params with _ are mandatory) } ] }, - 'chatAccess': { + 'chat': { 'conditions': [ { 'all': [ diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 617542f66..281487e32 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -2121,10 +2121,10 @@ export type Condition = ConditionBase & { }; export interface Rules { - groupAccess?: { + entry?: { conditions: Array; }; - chatAccess?: { + chat?: { conditions: Array; }; } @@ -2374,7 +2374,7 @@ const response = await PushAPI.space.update({ scheduleEnd: '2023-07-15T15:48:00.000Z', status: PushAPI.ChatStatus.PENDING, rules: { - 'groupAccess': { + 'entry': { 'conditions': [ { 'any': [ diff --git a/packages/restapi/package-lock.json b/packages/restapi/package-lock.json index a2cdeca0a..49c454e84 100644 --- a/packages/restapi/package-lock.json +++ b/packages/restapi/package-lock.json @@ -1,19 +1,24 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.13", + "version": "1.4.11", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.13", + "version": "1.4.11", "dependencies": { + "@ambire/signature-validator": "^1.3.1", "@metamask/eth-sig-util": "^5.0.2", + "@pushprotocol/socket": "^0.5.2", "buffer": "^6.0.3", "crypto-js": "^4.1.1", "immer": "^10.0.2", + "joi": "^17.9.2", + "livepeer": "^2.5.8", "openpgp": "^5.5.0", - "simple-peer": "^9.11.1" + "simple-peer": "^9.11.1", + "video-stream-merger": "^4.0.1" }, "devDependencies": { "@types/chai": "^4.3.4", @@ -31,6 +36,16 @@ "ethers": "^5.6.8" } }, + "node_modules/@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "dependencies": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, "node_modules/@chainsafe/as-sha256": { "version": "0.3.1", "resolved": "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz", @@ -104,7 +119,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/address": "^5.7.0", "@ethersproject/bignumber": "^5.7.0", @@ -131,7 +145,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -156,7 +169,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/bignumber": "^5.7.0", @@ -179,7 +191,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -202,7 +213,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0" } @@ -221,7 +231,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/properties": "^5.7.0" @@ -241,7 +250,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0", @@ -251,8 +259,7 @@ "node_modules/@ethersproject/bignumber/node_modules/bn.js": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "peer": true + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" }, "node_modules/@ethersproject/bytes": { "version": "5.7.0", @@ -268,7 +275,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/logger": "^5.7.0" } @@ -287,7 +293,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bignumber": "^5.7.0" } @@ -306,7 +311,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abi": "^5.7.0", "@ethersproject/abstract-provider": "^5.7.0", @@ -334,7 +338,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abstract-signer": "^5.7.0", "@ethersproject/address": "^5.7.0", @@ -361,7 +364,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abstract-signer": "^5.7.0", "@ethersproject/basex": "^5.7.0", @@ -391,7 +393,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abstract-signer": "^5.7.0", "@ethersproject/address": "^5.7.0", @@ -422,7 +423,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "js-sha3": "0.8.0" @@ -441,8 +441,7 @@ "type": "individual", "url": "https://www.buymeacoffee.com/ricmoo" } - ], - "peer": true + ] }, "node_modules/@ethersproject/networks": { "version": "5.7.1", @@ -458,7 +457,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/logger": "^5.7.0" } @@ -477,7 +475,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/sha2": "^5.7.0" @@ -497,7 +494,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/logger": "^5.7.0" } @@ -516,7 +512,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/abstract-signer": "^5.7.0", @@ -554,7 +549,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0" @@ -574,7 +568,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0" @@ -594,7 +587,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0", @@ -615,7 +607,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0", @@ -628,8 +619,7 @@ "node_modules/@ethersproject/signing-key/node_modules/bn.js": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "peer": true + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" }, "node_modules/@ethersproject/solidity": { "version": "5.7.0", @@ -645,7 +635,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -669,7 +658,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/constants": "^5.7.0", @@ -690,7 +678,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/address": "^5.7.0", "@ethersproject/bignumber": "^5.7.0", @@ -717,7 +704,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/constants": "^5.7.0", @@ -738,7 +724,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/abstract-signer": "^5.7.0", @@ -771,7 +756,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/base64": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -794,7 +778,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/hash": "^5.7.0", @@ -803,6 +786,19 @@ "@ethersproject/strings": "^5.7.0" } }, + "node_modules/@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "node_modules/@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, "node_modules/@jridgewell/resolve-uri": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", @@ -828,6 +824,53 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "node_modules/@livepeer/core": { + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.6.tgz", + "integrity": "sha512-VWMHaHMzNCr8YuC9hD87Ju+fwnpldEoe3y9CqOXrQPyyIgiAWfraZBA6Ard67f09X9UBGaaRcAMgMcCUs9HtKA==", + "dependencies": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/@livepeer/core/node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, + "node_modules/@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "dependencies": { + "@ljharb/through": "^2.3.9" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==", + "engines": { + "node": ">= 0.4" + } + }, "node_modules/@metamask/eth-sig-util": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz", @@ -866,6 +909,18 @@ } ] }, + "node_modules/@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "dependencies": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + }, + "peerDependencies": { + "ethers": "^5.6.8" + } + }, "node_modules/@scure/base": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz", @@ -908,6 +963,34 @@ "@scure/base": "~1.1.0" } }, + "node_modules/@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "dependencies": { + "@hapi/hoek": "^9.0.0" + } + }, + "node_modules/@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "node_modules/@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "node_modules/@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "node_modules/@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, "node_modules/@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", @@ -990,8 +1073,7 @@ "node_modules/aes-js": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", - "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==", - "peer": true + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" }, "node_modules/ansi-colors": { "version": "4.1.1", @@ -1051,6 +1133,55 @@ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", "dev": true }, + "node_modules/array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "dependencies": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/asn1.js": { "version": "5.4.1", "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", @@ -1071,11 +1202,21 @@ "node": "*" } }, + "node_modules/available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "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 + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, "node_modules/base64-js": { "version": "1.5.1", @@ -1099,8 +1240,7 @@ "node_modules/bech32": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", - "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==", - "peer": true + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" }, "node_modules/binary-extensions": { "version": "2.2.0", @@ -1120,7 +1260,6 @@ "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -1141,8 +1280,7 @@ "node_modules/brorand": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", - "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==", - "peer": true + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" }, "node_modules/browser-stdout": { "version": "1.3.1", @@ -1173,6 +1311,28 @@ "ieee754": "^1.2.1" } }, + "node_modules/buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "node_modules/buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "node_modules/call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "dependencies": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/camelcase": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", @@ -1325,11 +1485,34 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, + "node_modules/combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "dependencies": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, "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 + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "node_modules/core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==", + "hasInstallScript": true, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/core-js" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" }, "node_modules/create-require": { "version": "1.1.1", @@ -1337,6 +1520,14 @@ "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", "dev": true }, + "node_modules/cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "dependencies": { + "node-fetch": "^2.6.12" + } + }, "node_modules/cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", @@ -1358,6 +1549,11 @@ "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" }, + "node_modules/custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, "node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -1403,6 +1599,71 @@ "node": ">=6" } }, + "node_modules/deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "dependencies": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "dependencies": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/diff": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", @@ -1412,11 +1673,37 @@ "node": ">=0.3.1" } }, + "node_modules/dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "dependencies": { + "minimatch": "^3.0.4" + }, + "bin": { + "ignored": "bin/ignored" + } + }, + "node_modules/dotignore/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "dependencies": { + "brace-expansion": "^1.1.7" + }, + "engines": { + "node": "*" + } + }, + "node_modules/duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, "node_modules/elliptic": { "version": "6.5.4", "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", - "peer": true, "dependencies": { "bn.js": "^4.11.9", "brorand": "^1.1.0", @@ -1442,11 +1729,151 @@ "once": "^1.4.0" } }, + "node_modules/engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + } + }, + "node_modules/engine.io-client/node_modules/ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "engines": { + "node": ">=10.0.0" + }, + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + } + }, + "node_modules/engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==", + "engines": { + "node": ">=10.0.0" + } + }, "node_modules/err-code": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" }, + "node_modules/es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "dependencies": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "dependencies": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "dependencies": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -1493,7 +1920,6 @@ "url": "https://www.buymeacoffee.com/ricmoo" } ], - "peer": true, "dependencies": { "@ethersproject/abi": "5.7.0", "@ethersproject/abstract-provider": "5.7.0", @@ -1558,6 +1984,26 @@ "node": ">=6" } }, + "node_modules/figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "dependencies": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/figures/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==", + "engines": { + "node": ">=0.8.0" + } + }, "node_modules/fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", @@ -1595,11 +2041,18 @@ "flat": "cli.js" } }, + "node_modules/for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "dependencies": { + "is-callable": "^1.1.3" + } + }, "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 + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" }, "node_modules/fsevents": { "version": "2.3.2", @@ -1615,6 +2068,36 @@ "node": "^8.16.0 || ^10.6.0 || >=11.0.0" } }, + "node_modules/function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "node_modules/function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/get-browser-rtc": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", @@ -1638,9 +2121,31 @@ "node": "*" } }, - "node_modules/get-stream": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", + "node_modules/get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "dependencies": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==", + "engines": { + "node": ">=8.0.0" + } + }, + "node_modules/get-stream": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", "integrity": "sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==", "dev": true, "dependencies": { @@ -1650,6 +2155,21 @@ "node": ">=6" } }, + "node_modules/get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/glob": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", @@ -1694,6 +2214,86 @@ "node": "*" } }, + "node_modules/globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "dependencies": { + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "dependencies": { + "get-intrinsic": "^1.1.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "node_modules/has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "dependencies": { + "function-bind": "^1.1.1" + }, + "engines": { + "node": ">= 0.4.0" + } + }, + "node_modules/has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-ansi/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -1703,11 +2303,57 @@ "node": ">=8" } }, + "node_modules/has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "dependencies": { + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/hash.js": { "version": "1.1.7", "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", - "peer": true, "dependencies": { "inherits": "^2.0.3", "minimalistic-assert": "^1.0.1" @@ -1722,11 +2368,15 @@ "he": "bin/he" } }, + "node_modules/hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, "node_modules/hmac-drbg": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", - "peer": true, "dependencies": { "hash.js": "^1.0.3", "minimalistic-assert": "^1.0.0", @@ -1765,7 +2415,6 @@ "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", - "dev": true, "dependencies": { "once": "^1.3.0", "wrappy": "1" @@ -1776,6 +2425,19 @@ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, + "node_modules/internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "dependencies": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/invert-kv": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", @@ -1785,6 +2447,45 @@ "node": ">=4" } }, + "node_modules/is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "dependencies": { + "has-bigints": "^1.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", @@ -1797,6 +2498,57 @@ "node": ">=8" } }, + "node_modules/is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "dependencies": { + "has": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", @@ -1806,6 +2558,17 @@ "node": ">=0.10.0" } }, + "node_modules/is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==", + "engines": { + "node": ">=0.10.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/is-fullwidth-code-point": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", @@ -1836,6 +2599,25 @@ "npm": ">=3" } }, + "node_modules/is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/is-number": { "version": "7.0.0", "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", @@ -1845,6 +2627,20 @@ "node": ">=0.12.0" } }, + "node_modules/is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/is-plain-obj": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", @@ -1854,6 +2650,40 @@ "node": ">=8" } }, + "node_modules/is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "dependencies": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/is-stream": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", @@ -1863,6 +2693,48 @@ "node": ">=0.10.0" } }, + "node_modules/is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "dependencies": { + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "dependencies": { + "has-symbols": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "dependencies": { + "which-typed-array": "^1.1.11" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/is-unicode-supported": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", @@ -1875,16 +2747,74 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "node_modules/is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "dependencies": { + "call-bind": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, "node_modules/isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", "dev": true }, + "node_modules/joi": { + "version": "17.10.2", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.2.tgz", + "integrity": "sha512-hcVhjBxRNW/is3nNLdGLIjkgXetkeGc2wyhydhz8KumG23Aerk4HPjU5zaPAMRqXQFc0xNqXTC7+zQjxr0GlKA==", + "dependencies": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "node_modules/js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, "node_modules/js-sha3": { "version": "0.8.0", "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", - "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "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==", "peer": true }, "node_modules/js-yaml": { @@ -1911,6 +2841,37 @@ "node": ">=6" } }, + "node_modules/livepeer": { + "version": "2.8.6", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.6.tgz", + "integrity": "sha512-8K2lRtpgZKbv6l6cGYYMJW9qpdRKkGUuy7R7xTLkS6NaRQzaeW08vubftmbMHil8v8GX/nDmodcW2vA4oIkP0w==", + "dependencies": { + "@livepeer/core": "^1.8.6", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "peerDependencies": { + "react": ">=17.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + } + } + }, + "node_modules/livepeer/node_modules/ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==", + "engines": { + "node": ">=12.13" + } + }, "node_modules/locate-path": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", @@ -1926,15 +2887,74 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/log-symbols": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", - "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", - "dev": true, + "node_modules/lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "node_modules/lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", "dependencies": { - "chalk": "^4.1.0", - "is-unicode-supported": "^0.1.0" - }, + "lodash._stringtopath": "~4.8.0" + } + }, + "node_modules/lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "node_modules/lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "dependencies": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "node_modules/lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "node_modules/lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "node_modules/lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "dependencies": { + "lodash._basetostring": "~4.12.0" + } + }, + "node_modules/lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "node_modules/lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", + "dependencies": { + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.0" + } + }, + "node_modules/log-symbols": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-4.1.0.tgz", + "integrity": "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==", + "dev": true, + "dependencies": { + "chalk": "^4.1.0", + "is-unicode-supported": "^0.1.0" + }, "engines": { "node": ">=10" }, @@ -1942,6 +2962,18 @@ "url": "https://github.com/sponsors/sindresorhus" } }, + "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==", + "peer": true, + "dependencies": { + "js-tokens": "^3.0.0 || ^4.0.0" + }, + "bin": { + "loose-envify": "cli.js" + } + }, "node_modules/loupe": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz", @@ -2000,8 +3032,7 @@ "node_modules/minimalistic-crypto-utils": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", - "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==", - "peer": true + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" }, "node_modules/minimatch": { "version": "5.0.1", @@ -2024,6 +3055,14 @@ "balanced-match": "^1.0.0" } }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/mocha": { "version": "10.2.0", "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz", @@ -2403,6 +3442,11 @@ "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", "dev": true }, + "node_modules/multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, "node_modules/nanoid": { "version": "3.3.3", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", @@ -2421,6 +3465,25 @@ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", "dev": true }, + "node_modules/node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "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", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", @@ -2451,11 +3514,66 @@ "node": ">=0.10.0" } }, + "node_modules/object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "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, "dependencies": { "wrappy": "1" } @@ -2551,6 +3669,14 @@ "node": ">=4" } }, + "node_modules/parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==", + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -2564,7 +3690,6 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/path-is-absolute/-/path-is-absolute-1.0.1.tgz", "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==", - "dev": true, "engines": { "node": ">=0.10.0" } @@ -2578,6 +3703,11 @@ "node": ">=4" } }, + "node_modules/path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, "node_modules/pathval": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", @@ -2599,6 +3729,42 @@ "url": "https://github.com/sponsors/jonschlinkert" } }, + "node_modules/plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "dependencies": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "node_modules/proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "dependencies": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, "node_modules/pump": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", @@ -2609,6 +3775,11 @@ "once": "^1.3.1" } }, + "node_modules/querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -2636,6 +3807,23 @@ "safe-buffer": "^5.1.0" } }, + "node_modules/re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "node_modules/react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "dependencies": { + "loose-envify": "^1.1.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/readable-stream": { "version": "3.6.2", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", @@ -2661,6 +3849,30 @@ "node": ">=8.10.0" } }, + "node_modules/regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==", + "engines": { + "node": ">=0.10" + } + }, "node_modules/require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", @@ -2676,6 +3888,52 @@ "integrity": "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==", "dev": true }, + "node_modules/requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "node_modules/resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "dependencies": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + }, + "bin": { + "resolve": "bin/resolve" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==", + "engines": { + "node": ">= 4" + } + }, + "node_modules/safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + }, + "engines": { + "node": ">=0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", @@ -2695,6 +3953,19 @@ } ] }, + "node_modules/safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/safer-buffer": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", @@ -2703,8 +3974,7 @@ "node_modules/scrypt-js": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", - "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==", - "peer": true + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" }, "node_modules/semver": { "version": "5.7.1", @@ -2730,6 +4000,19 @@ "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", "dev": true }, + "node_modules/set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "dependencies": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", @@ -2751,11 +4034,23 @@ "node": ">=0.10.0" } }, + "node_modules/side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "dependencies": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/signal-exit": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", - "dev": true + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" }, "node_modules/simple-peer": { "version": "9.11.1", @@ -2785,6 +4080,54 @@ "readable-stream": "^3.6.0" } }, + "node_modules/socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "dependencies": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "dependencies": { + "through": "2" + }, + "engines": { + "node": "*" + } + }, + "node_modules/stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "dependencies": { + "internal-slot": "^1.0.4" + }, + "engines": { + "node": ">= 0.4" + } + }, "node_modules/string_decoder": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", @@ -2793,78 +4136,369 @@ "safe-buffer": "~5.2.0" } }, - "node_modules/string-width": { - "version": "4.2.3", - "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", - "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", - "dev": true, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "dependencies": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "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, + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-eof": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", + "integrity": "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/strip-hex-prefix": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", + "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "dependencies": { + "is-hex-prefixed": "1.0.0" + }, + "engines": { + "node": ">=6.5.0", + "npm": ">=3" + } + }, + "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, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/supports-color": { + "version": "8.1.1", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", + "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", + "dev": true, + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/supports-color?sponsor=1" + } + }, + "node_modules/supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "dependencies": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "bin": { + "tap-out": "bin/cmd.js" + } + }, + "node_modules/tap-out/node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/tap-out/node_modules/readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "dependencies": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/tap-out/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "node_modules/tap-out/node_modules/string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "dependencies": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + }, + "bin": { + "tap-spec": "bin/cmd.js", + "tspec": "bin/cmd.js" + } + }, + "node_modules/tap-spec/node_modules/ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tap-spec/node_modules/ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tap-spec/node_modules/chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "dependencies": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tap-spec/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==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/tap-spec/node_modules/strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "dependencies": { + "ansi-regex": "^2.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/tap-spec/node_modules/supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "dependencies": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + }, + "bin": { + "tape": "bin/tape" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/tape/node_modules/glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", "dependencies": { - "emoji-regex": "^8.0.0", - "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.1" + "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": ">=8" + "node": "*" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" } }, - "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, + "node_modules/tape/node_modules/minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", "dependencies": { - "ansi-regex": "^5.0.1" + "brace-expansion": "^1.1.7" }, "engines": { - "node": ">=8" + "node": "*" } }, - "node_modules/strip-eof": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz", - "integrity": "sha512-7FCwGGmx8mD5xQd3RPUvnSpUXHM3BWuzjtpD4TXsfcZ9EL4azvVVUscFYwD9nx8Kh+uCBC00XBtAykoMHwTh8Q==", - "dev": true, - "engines": { - "node": ">=0.10.0" + "node_modules/through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "node_modules/through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "dependencies": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" } }, - "node_modules/strip-hex-prefix": { + "node_modules/through2/node_modules/isarray": { "version": "1.0.0", - "resolved": "https://registry.npmjs.org/strip-hex-prefix/-/strip-hex-prefix-1.0.0.tgz", - "integrity": "sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "node_modules/through2/node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "node_modules/through2/node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", "dependencies": { - "is-hex-prefixed": "1.0.0" - }, - "engines": { - "node": ">=6.5.0", - "npm": ">=3" + "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/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, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } + "node_modules/through2/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" }, - "node_modules/supports-color": { - "version": "8.1.1", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-8.1.1.tgz", - "integrity": "sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==", - "dev": true, + "node_modules/through2/node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/supports-color?sponsor=1" + "safe-buffer": "~5.1.0" } }, "node_modules/to-regex-range": { @@ -2879,6 +4513,17 @@ "node": ">=8.0" } }, + "node_modules/tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "node_modules/trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==", + "deprecated": "Use String.prototype.trim() instead" + }, "node_modules/ts-node": { "version": "10.9.1", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", @@ -2922,6 +4567,36 @@ } } }, + "node_modules/tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "node_modules/tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "dependencies": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + } + }, + "node_modules/tus-js-client/node_modules/is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==", + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, "node_modules/tweetnacl": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", @@ -2941,6 +4616,67 @@ "node": ">=4" } }, + "node_modules/typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "dependencies": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "dependencies": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/typescript": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz", @@ -2954,6 +4690,37 @@ "node": ">=12.20" } }, + "node_modules/unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "dependencies": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "dependencies": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, "node_modules/util-deprecate": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", @@ -2965,6 +4732,25 @@ "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", "dev": true }, + "node_modules/video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "node_modules/webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "node_modules/whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "dependencies": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, "node_modules/which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", @@ -2977,12 +4763,59 @@ "which": "bin/which" } }, + "node_modules/which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "dependencies": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "dependencies": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==", "dev": true }, + "node_modules/which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "dependencies": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, "node_modules/workerpool": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz", @@ -3009,14 +4842,12 @@ "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 + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" }, "node_modules/ws": { "version": "7.4.6", "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", - "peer": true, "engines": { "node": ">=8.3.0" }, @@ -3033,6 +4864,22 @@ } } }, + "node_modules/xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==", + "engines": { + "node": ">=0.4" + } + }, "node_modules/y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -3104,9 +4951,46 @@ "funding": { "url": "https://github.com/sponsors/sindresorhus" } + }, + "node_modules/zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "dependencies": { + "use-sync-external-store": "1.2.0" + }, + "engines": { + "node": ">=12.7.0" + }, + "peerDependencies": { + "@types/react": ">=16.8", + "immer": ">=9.0", + "react": ">=16.8" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "immer": { + "optional": true + }, + "react": { + "optional": true + } + } } }, "dependencies": { + "@ambire/signature-validator": { + "version": "1.3.1", + "resolved": "https://registry.npmjs.org/@ambire/signature-validator/-/signature-validator-1.3.1.tgz", + "integrity": "sha512-kR6Se3nhAGf1VMeun7V2Lml9KRXB5oz64vO2zGSg+dNaGq4BPDEjsNdr0PIKXZ8651sDlRCN7V9SzL5E2ddBYQ==", + "requires": { + "ethers": "^5.6.5", + "tap-spec": "^5.0.0", + "tape": "^5.5.3" + } + }, "@chainsafe/as-sha256": { "version": "0.3.1", "resolved": "https://registry.npmjs.org/@chainsafe/as-sha256/-/as-sha256-0.3.1.tgz", @@ -3158,7 +5042,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/abi/-/abi-5.7.0.tgz", "integrity": "sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==", - "peer": true, "requires": { "@ethersproject/address": "^5.7.0", "@ethersproject/bignumber": "^5.7.0", @@ -3175,7 +5058,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/abstract-provider/-/abstract-provider-5.7.0.tgz", "integrity": "sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==", - "peer": true, "requires": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -3190,7 +5072,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/abstract-signer/-/abstract-signer-5.7.0.tgz", "integrity": "sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==", - "peer": true, "requires": { "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/bignumber": "^5.7.0", @@ -3203,7 +5084,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/address/-/address-5.7.0.tgz", "integrity": "sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==", - "peer": true, "requires": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -3216,7 +5096,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/base64/-/base64-5.7.0.tgz", "integrity": "sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0" } @@ -3225,7 +5104,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/basex/-/basex-5.7.0.tgz", "integrity": "sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/properties": "^5.7.0" @@ -3235,7 +5113,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/bignumber/-/bignumber-5.7.0.tgz", "integrity": "sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0", @@ -3245,8 +5122,7 @@ "bn.js": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "peer": true + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" } } }, @@ -3254,7 +5130,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/bytes/-/bytes-5.7.0.tgz", "integrity": "sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==", - "peer": true, "requires": { "@ethersproject/logger": "^5.7.0" } @@ -3263,7 +5138,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/constants/-/constants-5.7.0.tgz", "integrity": "sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==", - "peer": true, "requires": { "@ethersproject/bignumber": "^5.7.0" } @@ -3272,7 +5146,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/contracts/-/contracts-5.7.0.tgz", "integrity": "sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==", - "peer": true, "requires": { "@ethersproject/abi": "^5.7.0", "@ethersproject/abstract-provider": "^5.7.0", @@ -3290,7 +5163,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/hash/-/hash-5.7.0.tgz", "integrity": "sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==", - "peer": true, "requires": { "@ethersproject/abstract-signer": "^5.7.0", "@ethersproject/address": "^5.7.0", @@ -3307,7 +5179,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/hdnode/-/hdnode-5.7.0.tgz", "integrity": "sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==", - "peer": true, "requires": { "@ethersproject/abstract-signer": "^5.7.0", "@ethersproject/basex": "^5.7.0", @@ -3327,7 +5198,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/json-wallets/-/json-wallets-5.7.0.tgz", "integrity": "sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==", - "peer": true, "requires": { "@ethersproject/abstract-signer": "^5.7.0", "@ethersproject/address": "^5.7.0", @@ -3348,7 +5218,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/keccak256/-/keccak256-5.7.0.tgz", "integrity": "sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "js-sha3": "0.8.0" @@ -3357,14 +5226,12 @@ "@ethersproject/logger": { "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/logger/-/logger-5.7.0.tgz", - "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==", - "peer": true + "integrity": "sha512-0odtFdXu/XHtjQXJYA3u9G0G8btm0ND5Cu8M7i5vhEcE8/HmF4Lbdqanwyv4uQTr2tx6b7fQRmgLrsnpQlmnig==" }, "@ethersproject/networks": { "version": "5.7.1", "resolved": "https://registry.npmjs.org/@ethersproject/networks/-/networks-5.7.1.tgz", "integrity": "sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==", - "peer": true, "requires": { "@ethersproject/logger": "^5.7.0" } @@ -3373,7 +5240,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/pbkdf2/-/pbkdf2-5.7.0.tgz", "integrity": "sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/sha2": "^5.7.0" @@ -3383,7 +5249,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/properties/-/properties-5.7.0.tgz", "integrity": "sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==", - "peer": true, "requires": { "@ethersproject/logger": "^5.7.0" } @@ -3392,7 +5257,6 @@ "version": "5.7.2", "resolved": "https://registry.npmjs.org/@ethersproject/providers/-/providers-5.7.2.tgz", "integrity": "sha512-g34EWZ1WWAVgr4aptGlVBF8mhl3VWjv+8hoAnzStu8Ah22VHBsuGzP17eb6xDVRzw895G4W7vvx60lFFur/1Rg==", - "peer": true, "requires": { "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/abstract-signer": "^5.7.0", @@ -3420,7 +5284,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/random/-/random-5.7.0.tgz", "integrity": "sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0" @@ -3430,7 +5293,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/rlp/-/rlp-5.7.0.tgz", "integrity": "sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0" @@ -3440,7 +5302,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/sha2/-/sha2-5.7.0.tgz", "integrity": "sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0", @@ -3451,7 +5312,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/signing-key/-/signing-key-5.7.0.tgz", "integrity": "sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/logger": "^5.7.0", @@ -3464,8 +5324,7 @@ "bn.js": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/bn.js/-/bn.js-5.2.1.tgz", - "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==", - "peer": true + "integrity": "sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==" } } }, @@ -3473,7 +5332,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/solidity/-/solidity-5.7.0.tgz", "integrity": "sha512-HmabMd2Dt/raavyaGukF4XxizWKhKQ24DoLtdNbBmNKUOPqwjsKQSdV9GQtj9CBEea9DlzETlVER1gYeXXBGaA==", - "peer": true, "requires": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -3487,7 +5345,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/strings/-/strings-5.7.0.tgz", "integrity": "sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/constants": "^5.7.0", @@ -3498,7 +5355,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/transactions/-/transactions-5.7.0.tgz", "integrity": "sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==", - "peer": true, "requires": { "@ethersproject/address": "^5.7.0", "@ethersproject/bignumber": "^5.7.0", @@ -3515,7 +5371,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/units/-/units-5.7.0.tgz", "integrity": "sha512-pD3xLMy3SJu9kG5xDGI7+xhTEmGXlEqXU4OfNapmfnxLVY4EMSSRp7j1k7eezutBPH7RBN/7QPnwR7hzNlEFeg==", - "peer": true, "requires": { "@ethersproject/bignumber": "^5.7.0", "@ethersproject/constants": "^5.7.0", @@ -3526,7 +5381,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/wallet/-/wallet-5.7.0.tgz", "integrity": "sha512-MhmXlJXEJFBFVKrDLB4ZdDzxcBxQ3rLyCkhNqVu3CDYvR97E+8r01UgrI+TI99Le+aYm/in/0vp86guJuM7FCA==", - "peer": true, "requires": { "@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/abstract-signer": "^5.7.0", @@ -3549,7 +5403,6 @@ "version": "5.7.1", "resolved": "https://registry.npmjs.org/@ethersproject/web/-/web-5.7.1.tgz", "integrity": "sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==", - "peer": true, "requires": { "@ethersproject/base64": "^5.7.0", "@ethersproject/bytes": "^5.7.0", @@ -3562,7 +5415,6 @@ "version": "5.7.0", "resolved": "https://registry.npmjs.org/@ethersproject/wordlists/-/wordlists-5.7.0.tgz", "integrity": "sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==", - "peer": true, "requires": { "@ethersproject/bytes": "^5.7.0", "@ethersproject/hash": "^5.7.0", @@ -3571,6 +5423,19 @@ "@ethersproject/strings": "^5.7.0" } }, + "@hapi/hoek": { + "version": "9.3.0", + "resolved": "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz", + "integrity": "sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ==" + }, + "@hapi/topo": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz", + "integrity": "sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, "@jridgewell/resolve-uri": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/@jridgewell/resolve-uri/-/resolve-uri-3.1.0.tgz", @@ -3593,6 +5458,38 @@ "@jridgewell/sourcemap-codec": "^1.4.10" } }, + "@livepeer/core": { + "version": "1.8.6", + "resolved": "https://registry.npmjs.org/@livepeer/core/-/core-1.8.6.tgz", + "integrity": "sha512-VWMHaHMzNCr8YuC9hD87Ju+fwnpldEoe3y9CqOXrQPyyIgiAWfraZBA6Ard67f09X9UBGaaRcAMgMcCUs9HtKA==", + "requires": { + "cross-fetch": "^4.0.0", + "ms": "^3.0.0-canary.1", + "multiformats": "9.9.0", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "dependencies": { + "ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==" + } + } + }, + "@ljharb/resumer": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/@ljharb/resumer/-/resumer-0.0.1.tgz", + "integrity": "sha512-skQiAOrCfO7vRTq53cxznMpks7wS1va95UCidALlOVWqvBAzwPVErwizDwoMqNVMEn1mDq0utxZd02eIrvF1lw==", + "requires": { + "@ljharb/through": "^2.3.9" + } + }, + "@ljharb/through": { + "version": "2.3.9", + "resolved": "https://registry.npmjs.org/@ljharb/through/-/through-2.3.9.tgz", + "integrity": "sha512-yN599ZBuMPPK4tdoToLlvgJB4CLK8fGl7ntfy0Wn7U6ttNvHYurd81bfUiK/6sMkiIwm65R6ck4L6+Y3DfVbNQ==" + }, "@metamask/eth-sig-util": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/@metamask/eth-sig-util/-/eth-sig-util-5.0.2.tgz", @@ -3616,6 +5513,15 @@ "resolved": "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz", "integrity": "sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw==" }, + "@pushprotocol/socket": { + "version": "0.5.2", + "resolved": "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz", + "integrity": "sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw==", + "requires": { + "socket.io-client": "^4.5.2", + "tslib": "^2.3.0" + } + }, "@scure/base": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz", @@ -3640,6 +5546,34 @@ "@scure/base": "~1.1.0" } }, + "@sideway/address": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz", + "integrity": "sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw==", + "requires": { + "@hapi/hoek": "^9.0.0" + } + }, + "@sideway/formula": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz", + "integrity": "sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg==" + }, + "@sideway/pinpoint": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz", + "integrity": "sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ==" + }, + "@socket.io/component-emitter": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz", + "integrity": "sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg==" + }, + "@stitches/core": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz", + "integrity": "sha512-Gfkvwk9o9kE9r9XNBmJRfV8zONvXThnm1tcuojL04Uy5uRyqg93DC83lDebl0rocZCfKSjUv+fWYtMQmEDJldg==" + }, "@tsconfig/node10": { "version": "1.0.9", "resolved": "https://registry.npmjs.org/@tsconfig/node10/-/node10-1.0.9.tgz", @@ -3713,8 +5647,7 @@ "aes-js": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/aes-js/-/aes-js-3.0.0.tgz", - "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==", - "peer": true + "integrity": "sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==" }, "ansi-colors": { "version": "4.1.1", @@ -3759,6 +5692,40 @@ "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", "dev": true }, + "array-buffer-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/array-buffer-byte-length/-/array-buffer-byte-length-1.0.0.tgz", + "integrity": "sha512-LPuwb2P+NrQw3XhxGc36+XSvuBPopovXYTR9Ew++Du9Yb/bx5AzBfrIsBoj0EZUifjQU+sHL21sseZ3jerWO/A==", + "requires": { + "call-bind": "^1.0.2", + "is-array-buffer": "^3.0.1" + } + }, + "array.prototype.every": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz", + "integrity": "sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "is-string": "^1.0.7" + } + }, + "arraybuffer.prototype.slice": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz", + "integrity": "sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "get-intrinsic": "^1.2.1", + "is-array-buffer": "^3.0.2", + "is-shared-array-buffer": "^1.0.2" + } + }, "asn1.js": { "version": "5.4.1", "resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-5.4.1.tgz", @@ -3776,11 +5743,15 @@ "integrity": "sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==", "dev": true }, + "available-typed-arrays": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/available-typed-arrays/-/available-typed-arrays-1.0.5.tgz", + "integrity": "sha512-DMD0KiN46eipeziST1LPP/STfDU0sufISXmjSgvVsoU2tqxctQeASejWcfNtxYKqETM1UxQ8sp2OrSBWpHY6sw==" + }, "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 + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, "base64-js": { "version": "1.5.1", @@ -3790,8 +5761,7 @@ "bech32": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/bech32/-/bech32-1.1.4.tgz", - "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==", - "peer": true + "integrity": "sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==" }, "binary-extensions": { "version": "2.2.0", @@ -3808,7 +5778,6 @@ "version": "1.1.11", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -3826,8 +5795,7 @@ "brorand": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/brorand/-/brorand-1.1.0.tgz", - "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==", - "peer": true + "integrity": "sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==" }, "browser-stdout": { "version": "1.3.1", @@ -3844,6 +5812,25 @@ "ieee754": "^1.2.1" } }, + "buffer-from": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.2.tgz", + "integrity": "sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==" + }, + "buffer-shims": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/buffer-shims/-/buffer-shims-1.0.0.tgz", + "integrity": "sha512-Zy8ZXMyxIT6RMTeY7OP/bDndfj6bwCan7SS98CEndS6deHwWPpseeHlwarNcBim+etXnF9HBc1non5JgDaJU1g==" + }, + "call-bind": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind/-/call-bind-1.0.2.tgz", + "integrity": "sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==", + "requires": { + "function-bind": "^1.1.1", + "get-intrinsic": "^1.0.2" + } + }, "camelcase": { "version": "6.3.0", "resolved": "https://registry.npmjs.org/camelcase/-/camelcase-6.3.0.tgz", @@ -3954,11 +5941,29 @@ "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", "dev": true }, + "combine-errors": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/combine-errors/-/combine-errors-3.0.3.tgz", + "integrity": "sha512-C8ikRNRMygCwaTx+Ek3Yr+OuZzgZjduCOfSQBjbM8V3MfgcjSTeto/GXP6PAwKvJz/v15b7GHZvx5rOlczFw/Q==", + "requires": { + "custom-error-instance": "2.1.1", + "lodash.uniqby": "4.5.0" + } + }, "concat-map": { "version": "0.0.1", "resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz", - "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==", - "dev": true + "integrity": "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==" + }, + "core-js": { + "version": "3.32.2", + "resolved": "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz", + "integrity": "sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ==" + }, + "core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==" }, "create-require": { "version": "1.1.1", @@ -3966,6 +5971,14 @@ "integrity": "sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==", "dev": true }, + "cross-fetch": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/cross-fetch/-/cross-fetch-4.0.0.tgz", + "integrity": "sha512-e4a5N8lVvuLgAWgnCrLr2PP0YyDOTHa9H/Rj54dirp61qXnNq46m82bRhNqIA5VccJtWBvPTFRV3TtvHUKPB1g==", + "requires": { + "node-fetch": "^2.6.12" + } + }, "cross-spawn": { "version": "6.0.5", "resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz", @@ -3984,6 +5997,11 @@ "resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-4.1.1.tgz", "integrity": "sha512-o2JlM7ydqd3Qk9CA0L4NL6mTzU2sdx96a+oOfPu8Mkl/PK51vSyoi8/rQ8NknZtk44vq15lmhAj9CIAGwgeWKw==" }, + "custom-error-instance": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz", + "integrity": "sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg==" + }, "debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -4014,17 +6032,89 @@ "type-detect": "^4.0.0" } }, + "deep-equal": { + "version": "2.2.2", + "resolved": "https://registry.npmjs.org/deep-equal/-/deep-equal-2.2.2.tgz", + "integrity": "sha512-xjVyBf0w5vH0I42jdAZzOKVldmPgSulmiyPRywoyq7HXC9qdgo17kxJE+rdnif5Tz6+pIrpJI8dCpMNLIGkUiA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "call-bind": "^1.0.2", + "es-get-iterator": "^1.1.3", + "get-intrinsic": "^1.2.1", + "is-arguments": "^1.1.1", + "is-array-buffer": "^3.0.2", + "is-date-object": "^1.0.5", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "isarray": "^2.0.5", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.0", + "side-channel": "^1.0.4", + "which-boxed-primitive": "^1.0.2", + "which-collection": "^1.0.1", + "which-typed-array": "^1.1.9" + } + }, + "define-data-property": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz", + "integrity": "sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g==", + "requires": { + "get-intrinsic": "^1.2.1", + "gopd": "^1.0.1", + "has-property-descriptors": "^1.0.0" + } + }, + "define-properties": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz", + "integrity": "sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg==", + "requires": { + "define-data-property": "^1.0.1", + "has-property-descriptors": "^1.0.0", + "object-keys": "^1.1.1" + } + }, + "defined": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/defined/-/defined-1.0.1.tgz", + "integrity": "sha512-hsBd2qSVCRE+5PmNdHt1uzyrFu5d3RwmFDKzyNZMFq/EwDNJF7Ee5+D5oEKF0hU6LhtoUF1macFvOe4AskQC1Q==" + }, "diff": { "version": "4.0.2", "resolved": "https://registry.npmjs.org/diff/-/diff-4.0.2.tgz", "integrity": "sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==", "dev": true }, + "dotignore": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/dotignore/-/dotignore-0.1.2.tgz", + "integrity": "sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==", + "requires": { + "minimatch": "^3.0.4" + }, + "dependencies": { + "minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "requires": { + "brace-expansion": "^1.1.7" + } + } + } + }, + "duplexer": { + "version": "0.1.2", + "resolved": "https://registry.npmjs.org/duplexer/-/duplexer-0.1.2.tgz", + "integrity": "sha512-jtD6YG370ZCIi/9GTaJKQxWTZD045+4R4hTk/x1UyoqadyJ9x9CgSi1RlVDQF8U2sxLLSnFkCaMihqljHIWgMg==" + }, "elliptic": { "version": "6.5.4", "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.4.tgz", "integrity": "sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==", - "peer": true, "requires": { "bn.js": "^4.11.9", "brorand": "^1.1.0", @@ -4050,11 +6140,118 @@ "once": "^1.4.0" } }, + "engine.io-client": { + "version": "6.5.2", + "resolved": "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz", + "integrity": "sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1", + "engine.io-parser": "~5.2.1", + "ws": "~8.11.0", + "xmlhttprequest-ssl": "~2.0.0" + }, + "dependencies": { + "ws": { + "version": "8.11.0", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz", + "integrity": "sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg==", + "requires": {} + } + } + }, + "engine.io-parser": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz", + "integrity": "sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ==" + }, "err-code": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz", "integrity": "sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA==" }, + "es-abstract": { + "version": "1.22.2", + "resolved": "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz", + "integrity": "sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA==", + "requires": { + "array-buffer-byte-length": "^1.0.0", + "arraybuffer.prototype.slice": "^1.0.2", + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "es-set-tostringtag": "^2.0.1", + "es-to-primitive": "^1.2.1", + "function.prototype.name": "^1.1.6", + "get-intrinsic": "^1.2.1", + "get-symbol-description": "^1.0.0", + "globalthis": "^1.0.3", + "gopd": "^1.0.1", + "has": "^1.0.3", + "has-property-descriptors": "^1.0.0", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3", + "internal-slot": "^1.0.5", + "is-array-buffer": "^3.0.2", + "is-callable": "^1.2.7", + "is-negative-zero": "^2.0.2", + "is-regex": "^1.1.4", + "is-shared-array-buffer": "^1.0.2", + "is-string": "^1.0.7", + "is-typed-array": "^1.1.12", + "is-weakref": "^1.0.2", + "object-inspect": "^1.12.3", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "regexp.prototype.flags": "^1.5.1", + "safe-array-concat": "^1.0.1", + "safe-regex-test": "^1.0.0", + "string.prototype.trim": "^1.2.8", + "string.prototype.trimend": "^1.0.7", + "string.prototype.trimstart": "^1.0.7", + "typed-array-buffer": "^1.0.0", + "typed-array-byte-length": "^1.0.0", + "typed-array-byte-offset": "^1.0.0", + "typed-array-length": "^1.0.4", + "unbox-primitive": "^1.0.2", + "which-typed-array": "^1.1.11" + } + }, + "es-get-iterator": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/es-get-iterator/-/es-get-iterator-1.1.3.tgz", + "integrity": "sha512-sPZmqHBe6JIiTfN5q2pEi//TwxmAFHwj/XEuYjTuse78i8KxaqMTTzxPoFKuzRpDpTJ+0NAbpfenkmH2rePtuw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "has-symbols": "^1.0.3", + "is-arguments": "^1.1.1", + "is-map": "^2.0.2", + "is-set": "^2.0.2", + "is-string": "^1.0.7", + "isarray": "^2.0.5", + "stop-iteration-iterator": "^1.0.0" + } + }, + "es-set-tostringtag": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.0.1.tgz", + "integrity": "sha512-g3OMbtlwY3QewlqAiMLI47KywjWZoEytKr8pf6iTC8uJq5bIAH52Z9pnQ8pVL6whrCto53JZDuUIsifGeLorTg==", + "requires": { + "get-intrinsic": "^1.1.3", + "has": "^1.0.3", + "has-tostringtag": "^1.0.0" + } + }, + "es-to-primitive": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/es-to-primitive/-/es-to-primitive-1.2.1.tgz", + "integrity": "sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==", + "requires": { + "is-callable": "^1.1.4", + "is-date-object": "^1.0.1", + "is-symbol": "^1.0.2" + } + }, "escalade": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/escalade/-/escalade-3.1.1.tgz", @@ -4082,7 +6279,6 @@ "version": "5.7.2", "resolved": "https://registry.npmjs.org/ethers/-/ethers-5.7.2.tgz", "integrity": "sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg==", - "peer": true, "requires": { "@ethersproject/abi": "5.7.0", "@ethersproject/abstract-provider": "5.7.0", @@ -4140,6 +6336,22 @@ "strip-eof": "^1.0.0" } }, + "figures": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz", + "integrity": "sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ==", + "requires": { + "escape-string-regexp": "^1.0.5", + "object-assign": "^4.1.0" + }, + "dependencies": { + "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==" + } + } + }, "fill-range": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.0.1.tgz", @@ -4165,11 +6377,18 @@ "integrity": "sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==", "dev": true }, + "for-each": { + "version": "0.3.3", + "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz", + "integrity": "sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==", + "requires": { + "is-callable": "^1.1.3" + } + }, "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 + "integrity": "sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==" }, "fsevents": { "version": "2.3.2", @@ -4178,6 +6397,27 @@ "dev": true, "optional": true }, + "function-bind": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz", + "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" + }, + "function.prototype.name": { + "version": "1.1.6", + "resolved": "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz", + "integrity": "sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1", + "functions-have-names": "^1.2.3" + } + }, + "functions-have-names": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz", + "integrity": "sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==" + }, "get-browser-rtc": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/get-browser-rtc/-/get-browser-rtc-1.1.0.tgz", @@ -4195,6 +6435,22 @@ "integrity": "sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==", "dev": true }, + "get-intrinsic": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz", + "integrity": "sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw==", + "requires": { + "function-bind": "^1.1.1", + "has": "^1.0.3", + "has-proto": "^1.0.1", + "has-symbols": "^1.0.3" + } + }, + "get-package-type": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz", + "integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q==" + }, "get-stream": { "version": "4.1.0", "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz", @@ -4204,6 +6460,15 @@ "pump": "^3.0.0" } }, + "get-symbol-description": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz", + "integrity": "sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, "glob": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.0.tgz", @@ -4238,17 +6503,100 @@ "is-glob": "^4.0.1" } }, + "globalthis": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz", + "integrity": "sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA==", + "requires": { + "define-properties": "^1.1.3" + } + }, + "gopd": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz", + "integrity": "sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA==", + "requires": { + "get-intrinsic": "^1.1.3" + } + }, + "graceful-fs": { + "version": "4.2.11", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz", + "integrity": "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ==" + }, + "has": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz", + "integrity": "sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==", + "requires": { + "function-bind": "^1.1.1" + } + }, + "has-ansi": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz", + "integrity": "sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==", + "requires": { + "ansi-regex": "^2.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + } + } + }, + "has-bigints": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz", + "integrity": "sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==" + }, + "has-dynamic-import": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz", + "integrity": "sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true }, + "has-property-descriptors": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz", + "integrity": "sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==", + "requires": { + "get-intrinsic": "^1.1.1" + } + }, + "has-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz", + "integrity": "sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg==" + }, + "has-symbols": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz", + "integrity": "sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==" + }, + "has-tostringtag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz", + "integrity": "sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==", + "requires": { + "has-symbols": "^1.0.2" + } + }, "hash.js": { "version": "1.1.7", "resolved": "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz", "integrity": "sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==", - "peer": true, "requires": { "inherits": "^2.0.3", "minimalistic-assert": "^1.0.1" @@ -4260,11 +6608,15 @@ "integrity": "sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==", "dev": true }, + "hls.js": { + "version": "1.4.12", + "resolved": "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz", + "integrity": "sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA==" + }, "hmac-drbg": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz", "integrity": "sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==", - "peer": true, "requires": { "hash.js": "^1.0.3", "minimalistic-assert": "^1.0.0", @@ -4285,7 +6637,6 @@ "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", "integrity": "sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==", - "dev": true, "requires": { "once": "^1.3.0", "wrappy": "1" @@ -4296,12 +6647,49 @@ "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, + "internal-slot": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz", + "integrity": "sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ==", + "requires": { + "get-intrinsic": "^1.2.0", + "has": "^1.0.3", + "side-channel": "^1.0.4" + } + }, "invert-kv": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/invert-kv/-/invert-kv-2.0.0.tgz", "integrity": "sha512-wPVv/y/QQ/Uiirj/vh3oP+1Ww+AWehmi1g5fFWGPF6IpCBCDVrhgHRMvrLfdYcwDh3QJbGXDW4JAuzxElLSqKA==", "dev": true }, + "is-arguments": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz", + "integrity": "sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-array-buffer": { + "version": "3.0.2", + "resolved": "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz", + "integrity": "sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.0", + "is-typed-array": "^1.1.10" + } + }, + "is-bigint": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz", + "integrity": "sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==", + "requires": { + "has-bigints": "^1.0.1" + } + }, "is-binary-path": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-binary-path/-/is-binary-path-2.1.0.tgz", @@ -4311,12 +6699,47 @@ "binary-extensions": "^2.0.0" } }, + "is-boolean-object": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz", + "integrity": "sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-callable": { + "version": "1.2.7", + "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz", + "integrity": "sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==" + }, + "is-core-module": { + "version": "2.13.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz", + "integrity": "sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ==", + "requires": { + "has": "^1.0.3" + } + }, + "is-date-object": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz", + "integrity": "sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, "is-extglob": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", "dev": true }, + "is-finite": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz", + "integrity": "sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==" + }, "is-fullwidth-code-point": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", @@ -4337,40 +6760,153 @@ "resolved": "https://registry.npmjs.org/is-hex-prefixed/-/is-hex-prefixed-1.0.0.tgz", "integrity": "sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==" }, + "is-map": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", + "integrity": "sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg==" + }, + "is-negative-zero": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz", + "integrity": "sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==" + }, "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 }, + "is-number-object": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz", + "integrity": "sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, "is-plain-obj": { "version": "2.1.0", "resolved": "https://registry.npmjs.org/is-plain-obj/-/is-plain-obj-2.1.0.tgz", "integrity": "sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==", "dev": true }, + "is-regex": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz", + "integrity": "sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==", + "requires": { + "call-bind": "^1.0.2", + "has-tostringtag": "^1.0.0" + } + }, + "is-set": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz", + "integrity": "sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g==" + }, + "is-shared-array-buffer": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz", + "integrity": "sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==", + "requires": { + "call-bind": "^1.0.2" + } + }, "is-stream": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz", "integrity": "sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==", "dev": true }, + "is-string": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz", + "integrity": "sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==", + "requires": { + "has-tostringtag": "^1.0.0" + } + }, + "is-symbol": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz", + "integrity": "sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg==", + "requires": { + "has-symbols": "^1.0.2" + } + }, + "is-typed-array": { + "version": "1.1.12", + "resolved": "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz", + "integrity": "sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg==", + "requires": { + "which-typed-array": "^1.1.11" + } + }, "is-unicode-supported": { "version": "0.1.0", "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz", "integrity": "sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==", "dev": true }, + "is-weakmap": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz", + "integrity": "sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA==" + }, + "is-weakref": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz", + "integrity": "sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==", + "requires": { + "call-bind": "^1.0.2" + } + }, + "is-weakset": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz", + "integrity": "sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.1" + } + }, + "isarray": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz", + "integrity": "sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw==" + }, "isexe": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/isexe/-/isexe-2.0.0.tgz", "integrity": "sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==", "dev": true }, + "joi": { + "version": "17.10.2", + "resolved": "https://registry.npmjs.org/joi/-/joi-17.10.2.tgz", + "integrity": "sha512-hcVhjBxRNW/is3nNLdGLIjkgXetkeGc2wyhydhz8KumG23Aerk4HPjU5zaPAMRqXQFc0xNqXTC7+zQjxr0GlKA==", + "requires": { + "@hapi/hoek": "^9.0.0", + "@hapi/topo": "^5.0.0", + "@sideway/address": "^4.1.3", + "@sideway/formula": "^3.0.1", + "@sideway/pinpoint": "^2.0.0" + } + }, + "js-base64": { + "version": "3.7.5", + "resolved": "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz", + "integrity": "sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA==" + }, "js-sha3": { "version": "0.8.0", "resolved": "https://registry.npmjs.org/js-sha3/-/js-sha3-0.8.0.tgz", - "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==", + "integrity": "sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==" + }, + "js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", "peer": true }, "js-yaml": { @@ -4388,16 +6924,97 @@ "integrity": "sha512-avPEb8P8EGnwXKClwsNUgryVjllcRqtMYa49NTsbQagYuT1DcXnl1915oxWjoyGrXR6zH/Y0Zc96xWsPcoDKeA==", "dev": true, "requires": { - "invert-kv": "^2.0.0" + "invert-kv": "^2.0.0" + } + }, + "livepeer": { + "version": "2.8.6", + "resolved": "https://registry.npmjs.org/livepeer/-/livepeer-2.8.6.tgz", + "integrity": "sha512-8K2lRtpgZKbv6l6cGYYMJW9qpdRKkGUuy7R7xTLkS6NaRQzaeW08vubftmbMHil8v8GX/nDmodcW2vA4oIkP0w==", + "requires": { + "@livepeer/core": "^1.8.6", + "@stitches/core": "^1.2.8", + "core-js": "^3.31.1", + "cross-fetch": "^4.0.0", + "hls.js": "^1.4.9", + "ms": "^3.0.0-canary.1", + "tus-js-client": "^3.1.0", + "zustand": "^4.3.9" + }, + "dependencies": { + "ms": { + "version": "3.0.0-canary.1", + "resolved": "https://registry.npmjs.org/ms/-/ms-3.0.0-canary.1.tgz", + "integrity": "sha512-kh8ARjh8rMN7Du2igDRO9QJnqCb2xYTJxyQYK7vJJS4TvLLmsbyhiKpSW+t+y26gyOyMd0riphX0GeWKU3ky5g==" + } + } + }, + "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, + "requires": { + "p-locate": "^5.0.0" + } + }, + "lodash": { + "version": "4.17.21", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", + "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==" + }, + "lodash._baseiteratee": { + "version": "4.7.0", + "resolved": "https://registry.npmjs.org/lodash._baseiteratee/-/lodash._baseiteratee-4.7.0.tgz", + "integrity": "sha512-nqB9M+wITz0BX/Q2xg6fQ8mLkyfF7MU7eE+MNBNjTHFKeKaZAPEzEg+E8LWxKWf1DQVflNEn9N49yAuqKh2mWQ==", + "requires": { + "lodash._stringtopath": "~4.8.0" + } + }, + "lodash._basetostring": { + "version": "4.12.0", + "resolved": "https://registry.npmjs.org/lodash._basetostring/-/lodash._basetostring-4.12.0.tgz", + "integrity": "sha512-SwcRIbyxnN6CFEEK4K1y+zuApvWdpQdBHM/swxP962s8HIxPO3alBH5t3m/dl+f4CMUug6sJb7Pww8d13/9WSw==" + }, + "lodash._baseuniq": { + "version": "4.6.0", + "resolved": "https://registry.npmjs.org/lodash._baseuniq/-/lodash._baseuniq-4.6.0.tgz", + "integrity": "sha512-Ja1YevpHZctlI5beLA7oc5KNDhGcPixFhcqSiORHNsp/1QTv7amAXzw+gu4YOvErqVlMVyIJGgtzeepCnnur0A==", + "requires": { + "lodash._createset": "~4.0.0", + "lodash._root": "~3.0.0" + } + }, + "lodash._createset": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/lodash._createset/-/lodash._createset-4.0.3.tgz", + "integrity": "sha512-GTkC6YMprrJZCYU3zcqZj+jkXkrXzq3IPBcF/fIPpNEAB4hZEtXU8zp/RwKOvZl43NUmwDbyRk3+ZTbeRdEBXA==" + }, + "lodash._root": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/lodash._root/-/lodash._root-3.0.1.tgz", + "integrity": "sha512-O0pWuFSK6x4EXhM1dhZ8gchNtG7JMqBtrHdoUFUWXD7dJnNSUze1GuyQr5sOs0aCvgGeI3o/OJW8f4ca7FDxmQ==" + }, + "lodash._stringtopath": { + "version": "4.8.0", + "resolved": "https://registry.npmjs.org/lodash._stringtopath/-/lodash._stringtopath-4.8.0.tgz", + "integrity": "sha512-SXL66C731p0xPDC5LZg4wI5H+dJo/EO4KTqOMwLYCH3+FmmfAKJEZCm6ohGpI+T1xwsDsJCfL4OnhorllvlTPQ==", + "requires": { + "lodash._basetostring": "~4.12.0" } }, - "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, + "lodash.throttle": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.throttle/-/lodash.throttle-4.1.1.tgz", + "integrity": "sha512-wIkUCfVKpVsWo3JSZlc+8MB5it+2AN5W8J7YVMST30UrvcQNZ1Okbj+rbVniijTWE6FGYy4XJq/rHkas8qJMLQ==" + }, + "lodash.uniqby": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/lodash.uniqby/-/lodash.uniqby-4.5.0.tgz", + "integrity": "sha512-IRt7cfTtHy6f1aRVA5n7kT8rgN3N1nH6MOWLcHfpWG2SH19E3JksLK38MktLxZDhlAjCP9jpIXkOnRXlu6oByQ==", "requires": { - "p-locate": "^5.0.0" + "lodash._baseiteratee": "~4.7.0", + "lodash._baseuniq": "~4.6.0" } }, "log-symbols": { @@ -4410,6 +7027,15 @@ "is-unicode-supported": "^0.1.0" } }, + "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==", + "peer": true, + "requires": { + "js-tokens": "^3.0.0 || ^4.0.0" + } + }, "loupe": { "version": "2.3.6", "resolved": "https://registry.npmjs.org/loupe/-/loupe-2.3.6.tgz", @@ -4459,8 +7085,7 @@ "minimalistic-crypto-utils": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/minimalistic-crypto-utils/-/minimalistic-crypto-utils-1.0.1.tgz", - "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==", - "peer": true + "integrity": "sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==" }, "minimatch": { "version": "5.0.1", @@ -4482,6 +7107,11 @@ } } }, + "minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==" + }, "mocha": { "version": "10.2.0", "resolved": "https://registry.npmjs.org/mocha/-/mocha-10.2.0.tgz", @@ -4786,6 +7416,11 @@ "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", "dev": true }, + "multiformats": { + "version": "9.9.0", + "resolved": "https://registry.npmjs.org/multiformats/-/multiformats-9.9.0.tgz", + "integrity": "sha512-HoMUjhH9T8DDBNT+6xzkrd9ga/XiBI4xLr58LJACwK6G3HTOPeMz4nB4KJs33L2BelrIJa7P0VuNaVF3hMYfjg==" + }, "nanoid": { "version": "3.3.3", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.3.3.tgz", @@ -4798,6 +7433,14 @@ "integrity": "sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==", "dev": true }, + "node-fetch": { + "version": "2.7.0", + "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz", + "integrity": "sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A==", + "requires": { + "whatwg-url": "^5.0.0" + } + }, "normalize-path": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/normalize-path/-/normalize-path-3.0.0.tgz", @@ -4819,11 +7462,45 @@ "integrity": "sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==", "dev": true }, + "object-assign": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz", + "integrity": "sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==" + }, + "object-inspect": { + "version": "1.12.3", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.12.3.tgz", + "integrity": "sha512-geUvdk7c+eizMNUDkRpW1wJwgfOiOeHbxBR/hLXK1aT6zmVSO0jsQcs7fj6MGw89jC/cjGfLcNOrtMYtGqm81g==" + }, + "object-is": { + "version": "1.1.5", + "resolved": "https://registry.npmjs.org/object-is/-/object-is-1.1.5.tgz", + "integrity": "sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.3" + } + }, + "object-keys": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/object-keys/-/object-keys-1.1.1.tgz", + "integrity": "sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==" + }, + "object.assign": { + "version": "4.1.4", + "resolved": "https://registry.npmjs.org/object.assign/-/object.assign-4.1.4.tgz", + "integrity": "sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.1.4", + "has-symbols": "^1.0.3", + "object-keys": "^1.1.1" + } + }, "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, "requires": { "wrappy": "1" } @@ -4889,6 +7566,11 @@ "integrity": "sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==", "dev": true }, + "parse-ms": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/parse-ms/-/parse-ms-1.0.1.tgz", + "integrity": "sha512-LpH1Cf5EYuVjkBvCDBYvkUPh+iv2bk3FHflxHkpCYT0/FZ1d3N3uJaLiHr4yGuMcFUhv6eAivitTvWZI4B/chg==" + }, "path-exists": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", @@ -4898,8 +7580,7 @@ "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 + "integrity": "sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==" }, "path-key": { "version": "2.0.1", @@ -4907,6 +7588,11 @@ "integrity": "sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==", "dev": true }, + "path-parse": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/path-parse/-/path-parse-1.0.7.tgz", + "integrity": "sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==" + }, "pathval": { "version": "1.1.1", "resolved": "https://registry.npmjs.org/pathval/-/pathval-1.1.1.tgz", @@ -4919,6 +7605,36 @@ "integrity": "sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==", "dev": true }, + "plur": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/plur/-/plur-1.0.0.tgz", + "integrity": "sha512-qSnKBSZeDY8ApxwhfVIwKwF36KVJqb1/9nzYYq3j3vdwocULCXT8f8fQGkiw1Nk9BGfxiDagEe/pwakA+bOBqw==" + }, + "pretty-ms": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/pretty-ms/-/pretty-ms-2.1.0.tgz", + "integrity": "sha512-H2enpsxzDhuzRl3zeSQpQMirn8dB0Z/gxW96j06tMfTviUWvX14gjKb7qd1gtkUyYhDPuoNe00K5PqNvy2oQNg==", + "requires": { + "is-finite": "^1.0.1", + "parse-ms": "^1.0.0", + "plur": "^1.0.0" + } + }, + "process-nextick-args": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-1.0.7.tgz", + "integrity": "sha512-yN0WQmuCX63LP/TMvAg31nvT6m4vDqJEiiv2CAZqWOGNWutc9DfDk1NPYYmKUFmaVM2UwDowH4u5AHWYP/jxKw==" + }, + "proper-lockfile": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/proper-lockfile/-/proper-lockfile-4.1.2.tgz", + "integrity": "sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==", + "requires": { + "graceful-fs": "^4.2.4", + "retry": "^0.12.0", + "signal-exit": "^3.0.2" + } + }, "pump": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.0.tgz", @@ -4929,6 +7645,11 @@ "once": "^1.3.1" } }, + "querystringify": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/querystringify/-/querystringify-2.2.0.tgz", + "integrity": "sha512-FIqgj2EUvTa7R50u0rGsyTftzjYmv/a3hO345bZNrqabNqjtgiDMgmo4mkUjd+nzU5oF3dClKqFIPUKybUyqoQ==" + }, "queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -4942,6 +7663,20 @@ "safe-buffer": "^5.1.0" } }, + "re-emitter": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/re-emitter/-/re-emitter-1.1.3.tgz", + "integrity": "sha512-bHJul9CWcocrS+w5e5QrKYXV9NkbSA9hxSEyhYuctwm6keY9NXR2Xt/4A0vbMP0QvuwyfEyb4bkowYXv1ziEbg==" + }, + "react": { + "version": "18.2.0", + "resolved": "https://registry.npmjs.org/react/-/react-18.2.0.tgz", + "integrity": "sha512-/3IjMdb2L9QbBdWiW5e3P2/npwMBaU9mHCSCUzNln0ZCYbcfTsGbTJrU/kGemdH2IWmB2ioZ+zkxtmq6g09fGQ==", + "peer": true, + "requires": { + "loose-envify": "^1.1.0" + } + }, "readable-stream": { "version": "3.6.2", "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", @@ -4961,6 +7696,21 @@ "picomatch": "^2.2.1" } }, + "regexp.prototype.flags": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz", + "integrity": "sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "set-function-name": "^2.0.0" + } + }, + "repeat-string": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz", + "integrity": "sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==" + }, "require-directory": { "version": "2.1.1", "resolved": "https://registry.npmjs.org/require-directory/-/require-directory-2.1.1.tgz", @@ -4973,11 +7723,52 @@ "integrity": "sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==", "dev": true }, + "requires-port": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/requires-port/-/requires-port-1.0.0.tgz", + "integrity": "sha512-KigOCHcocU3XODJxsu8i/j8T9tzT4adHiecwORRQ0ZZFcp7ahwXuRU1m+yuO90C5ZUyGeGfocHDI14M3L3yDAQ==" + }, + "resolve": { + "version": "2.0.0-next.4", + "resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.4.tgz", + "integrity": "sha512-iMDbmAWtfU+MHpxt/I5iWI7cY6YVEZUQ3MBgPQ++XD1PELuJHIl82xBmObyP2KyQmkNB2dsqF7seoQQiAn5yDQ==", + "requires": { + "is-core-module": "^2.9.0", + "path-parse": "^1.0.7", + "supports-preserve-symlinks-flag": "^1.0.0" + } + }, + "retry": { + "version": "0.12.0", + "resolved": "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz", + "integrity": "sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==" + }, + "safe-array-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz", + "integrity": "sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "has-symbols": "^1.0.3", + "isarray": "^2.0.5" + } + }, "safe-buffer": { "version": "5.2.1", "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" }, + "safe-regex-test": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/safe-regex-test/-/safe-regex-test-1.0.0.tgz", + "integrity": "sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.1.3", + "is-regex": "^1.1.4" + } + }, "safer-buffer": { "version": "2.1.2", "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", @@ -4986,8 +7777,7 @@ "scrypt-js": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/scrypt-js/-/scrypt-js-3.0.1.tgz", - "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==", - "peer": true + "integrity": "sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==" }, "semver": { "version": "5.7.1", @@ -5010,6 +7800,16 @@ "integrity": "sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==", "dev": true }, + "set-function-name": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz", + "integrity": "sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA==", + "requires": { + "define-data-property": "^1.0.1", + "functions-have-names": "^1.2.3", + "has-property-descriptors": "^1.0.0" + } + }, "shebang-command": { "version": "1.2.0", "resolved": "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz", @@ -5025,11 +7825,20 @@ "integrity": "sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==", "dev": true }, + "side-channel": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.0.4.tgz", + "integrity": "sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==", + "requires": { + "call-bind": "^1.0.0", + "get-intrinsic": "^1.0.2", + "object-inspect": "^1.9.0" + } + }, "signal-exit": { "version": "3.0.7", "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-3.0.7.tgz", - "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==", - "dev": true + "integrity": "sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==" }, "simple-peer": { "version": "9.11.1", @@ -5045,6 +7854,42 @@ "readable-stream": "^3.6.0" } }, + "socket.io-client": { + "version": "4.7.2", + "resolved": "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz", + "integrity": "sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.2", + "engine.io-client": "~6.5.2", + "socket.io-parser": "~4.2.4" + } + }, + "socket.io-parser": { + "version": "4.2.4", + "resolved": "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz", + "integrity": "sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew==", + "requires": { + "@socket.io/component-emitter": "~3.1.0", + "debug": "~4.3.1" + } + }, + "split": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/split/-/split-1.0.0.tgz", + "integrity": "sha512-3SVfJe2A0WZg3D+ZEtXqYkvpSGAVaZ1MgufNCeHioBESCqQFsuT1VcQufiopBfJZqh92ZwQ6ddL378iUSbqVNQ==", + "requires": { + "through": "2" + } + }, + "stop-iteration-iterator": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/stop-iteration-iterator/-/stop-iteration-iterator-1.0.0.tgz", + "integrity": "sha512-iCGQj+0l0HOdZ2AEeBADlsRC+vsnDsZsbdSiH1yNSjcfKM7fdpCMfqAL/dwF5BLiw/XhRft/Wax6zQbhq2BcjQ==", + "requires": { + "internal-slot": "^1.0.4" + } + }, "string_decoder": { "version": "1.3.0", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", @@ -5064,6 +7909,36 @@ "strip-ansi": "^6.0.1" } }, + "string.prototype.trim": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz", + "integrity": "sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimend": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz", + "integrity": "sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, + "string.prototype.trimstart": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz", + "integrity": "sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg==", + "requires": { + "call-bind": "^1.0.2", + "define-properties": "^1.2.0", + "es-abstract": "^1.22.1" + } + }, "strip-ansi": { "version": "6.0.1", "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", @@ -5102,6 +7977,217 @@ "has-flag": "^4.0.0" } }, + "supports-preserve-symlinks-flag": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz", + "integrity": "sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==" + }, + "tap-out": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/tap-out/-/tap-out-2.1.0.tgz", + "integrity": "sha512-LJE+TBoVbOWhwdz4+FQk40nmbIuxJLqaGvj3WauQw3NYYU5TdjoV3C0x/yq37YAvVyi+oeBXmWnxWSjJ7IEyUw==", + "requires": { + "re-emitter": "1.1.3", + "readable-stream": "2.2.9", + "split": "1.0.0", + "trim": "0.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "readable-stream": { + "version": "2.2.9", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.2.9.tgz", + "integrity": "sha512-iuxqX7b7FYt08AriYECxUsK9KTXE3A/FenxIa3IPmvANHxaTP/wGIwwf+IidvvIDk/MsCp/oEV6A8CXo4SDcCg==", + "requires": { + "buffer-shims": "~1.0.0", + "core-util-is": "~1.0.0", + "inherits": "~2.0.1", + "isarray": "~1.0.0", + "process-nextick-args": "~1.0.6", + "string_decoder": "~1.0.0", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.0.3.tgz", + "integrity": "sha512-4AH6Z5fzNNBcH+6XDMfA/BTt87skxqJlO0lAh3Dker5zThcAxG6mKz+iGu308UKoPPQ8Dcqx/4JhujzltRa+hQ==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, + "tap-spec": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/tap-spec/-/tap-spec-5.0.0.tgz", + "integrity": "sha512-zMDVJiE5I6Y4XGjlueGXJIX2YIkbDN44broZlnypT38Hj/czfOXrszHNNJBF/DXR8n+x6gbfSx68x04kIEHdrw==", + "requires": { + "chalk": "^1.0.0", + "duplexer": "^0.1.1", + "figures": "^1.4.0", + "lodash": "^4.17.10", + "pretty-ms": "^2.1.0", + "repeat-string": "^1.5.2", + "tap-out": "^2.1.0", + "through2": "^2.0.0" + }, + "dependencies": { + "ansi-regex": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-2.1.1.tgz", + "integrity": "sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==" + }, + "ansi-styles": { + "version": "2.2.1", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-2.2.1.tgz", + "integrity": "sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==" + }, + "chalk": { + "version": "1.1.3", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-1.1.3.tgz", + "integrity": "sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==", + "requires": { + "ansi-styles": "^2.2.1", + "escape-string-regexp": "^1.0.2", + "has-ansi": "^2.0.0", + "strip-ansi": "^3.0.0", + "supports-color": "^2.0.0" + } + }, + "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==" + }, + "strip-ansi": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-3.0.1.tgz", + "integrity": "sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==", + "requires": { + "ansi-regex": "^2.0.0" + } + }, + "supports-color": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-2.0.0.tgz", + "integrity": "sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==" + } + } + }, + "tape": { + "version": "5.6.6", + "resolved": "https://registry.npmjs.org/tape/-/tape-5.6.6.tgz", + "integrity": "sha512-rGp2cZ3rfZ6QfTBm6yvohf8aXmDqPyzMKZwTMV12w4i+b/N2Adwlg8PlW8jLqWzlJUZhglyYaLOSrMt/ZlZkAA==", + "requires": { + "@ljharb/resumer": "^0.0.1", + "@ljharb/through": "^2.3.9", + "array.prototype.every": "^1.1.4", + "call-bind": "^1.0.2", + "deep-equal": "^2.2.2", + "defined": "^1.0.1", + "dotignore": "^0.1.2", + "for-each": "^0.3.3", + "get-package-type": "^0.1.0", + "glob": "^7.2.3", + "has": "^1.0.3", + "has-dynamic-import": "^2.0.1", + "inherits": "^2.0.4", + "is-regex": "^1.1.4", + "minimist": "^1.2.8", + "object-inspect": "^1.12.3", + "object-is": "^1.1.5", + "object-keys": "^1.1.1", + "object.assign": "^4.1.4", + "resolve": "^2.0.0-next.4", + "string.prototype.trim": "^1.2.7" + }, + "dependencies": { + "glob": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz", + "integrity": "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==", + "requires": { + "fs.realpath": "^1.0.0", + "inflight": "^1.0.4", + "inherits": "2", + "minimatch": "^3.1.1", + "once": "^1.3.0", + "path-is-absolute": "^1.0.0" + } + }, + "minimatch": { + "version": "3.1.2", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz", + "integrity": "sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==", + "requires": { + "brace-expansion": "^1.1.7" + } + } + } + }, + "through": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz", + "integrity": "sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==" + }, + "through2": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/through2/-/through2-2.0.5.tgz", + "integrity": "sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==", + "requires": { + "readable-stream": "~2.3.6", + "xtend": "~4.0.1" + }, + "dependencies": { + "isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==" + }, + "process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==" + }, + "readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "requires": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==" + }, + "string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "requires": { + "safe-buffer": "~5.1.0" + } + } + } + }, "to-regex-range": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", @@ -5111,6 +8197,16 @@ "is-number": "^7.0.0" } }, + "tr46": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/tr46/-/tr46-0.0.3.tgz", + "integrity": "sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==" + }, + "trim": { + "version": "0.0.1", + "resolved": "https://registry.npmjs.org/trim/-/trim-0.0.1.tgz", + "integrity": "sha512-YzQV+TZg4AxpKxaTHK3c3D+kRDCGVEE7LemdlQZoQXn0iennk10RsIoY6ikzAqJTc9Xjl9C1/waHom/J86ziAQ==" + }, "ts-node": { "version": "10.9.1", "resolved": "https://registry.npmjs.org/ts-node/-/ts-node-10.9.1.tgz", @@ -5132,6 +8228,32 @@ "yn": "3.1.1" } }, + "tslib": { + "version": "2.6.2", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz", + "integrity": "sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q==" + }, + "tus-js-client": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz", + "integrity": "sha512-SZzWP62jEFLmROSRZx+uoGLKqsYWMGK/m+PiNehPVWbCm7/S9zRIMaDxiaOcKdMnFno4luaqP5E+Y1iXXPjP0A==", + "requires": { + "buffer-from": "^1.1.2", + "combine-errors": "^3.0.3", + "is-stream": "^2.0.0", + "js-base64": "^3.7.2", + "lodash.throttle": "^4.1.1", + "proper-lockfile": "^4.1.2", + "url-parse": "^1.5.7" + }, + "dependencies": { + "is-stream": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz", + "integrity": "sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg==" + } + } + }, "tweetnacl": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/tweetnacl/-/tweetnacl-1.0.3.tgz", @@ -5148,12 +8270,81 @@ "integrity": "sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==", "dev": true }, + "typed-array-buffer": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-buffer/-/typed-array-buffer-1.0.0.tgz", + "integrity": "sha512-Y8KTSIglk9OZEr8zywiIHG/kmQ7KWyjseXs1CbSo8vC42w7hg2HgYTxSWwP0+is7bWDc1H+Fo026CpHFwm8tkw==", + "requires": { + "call-bind": "^1.0.2", + "get-intrinsic": "^1.2.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-length": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-length/-/typed-array-byte-length-1.0.0.tgz", + "integrity": "sha512-Or/+kvLxNpeQ9DtSydonMxCx+9ZXOswtwJn17SNLvhptaXYDJvkFFP5zbfU/uLmvnBJlI4yrnXRxpdWH/M5tNA==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-byte-offset": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/typed-array-byte-offset/-/typed-array-byte-offset-1.0.0.tgz", + "integrity": "sha512-RD97prjEt9EL8YgAgpOkf3O4IF9lhJFr9g0htQkm0rchFp/Vx7LW5Q8fSXXub7BXAODyUQohRMyOc3faCPd0hg==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "has-proto": "^1.0.1", + "is-typed-array": "^1.1.10" + } + }, + "typed-array-length": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/typed-array-length/-/typed-array-length-1.0.4.tgz", + "integrity": "sha512-KjZypGq+I/H7HI5HlOoGHkWUUGq+Q0TPhQurLbyrVrvnKTBgzLhIJ7j6J/XTQOi0d1RjyZ0wdas8bKs2p0x3Ng==", + "requires": { + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "is-typed-array": "^1.1.9" + } + }, "typescript": { "version": "5.0.2", "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.0.2.tgz", "integrity": "sha512-wVORMBGO/FAs/++blGNeAVdbNKtIh1rbBL2EyQ1+J9lClJ93KiiKe8PmFIVdXhHcyv44SL9oglmfeSsndo0jRw==", "dev": true }, + "unbox-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.2.tgz", + "integrity": "sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==", + "requires": { + "call-bind": "^1.0.2", + "has-bigints": "^1.0.2", + "has-symbols": "^1.0.3", + "which-boxed-primitive": "^1.0.2" + } + }, + "url-parse": { + "version": "1.5.10", + "resolved": "https://registry.npmjs.org/url-parse/-/url-parse-1.5.10.tgz", + "integrity": "sha512-WypcfiRhfeUP9vvF0j6rw0J3hrWrw6iZv3+22h6iRMJ/8z1Tj6XfLP4DsUix5MhMPnXpiHDoKyoZ/bdCkwBCiQ==", + "requires": { + "querystringify": "^2.1.1", + "requires-port": "^1.0.0" + } + }, + "use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "requires": {} + }, "util-deprecate": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", @@ -5165,6 +8356,25 @@ "integrity": "sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg==", "dev": true }, + "video-stream-merger": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/video-stream-merger/-/video-stream-merger-4.0.1.tgz", + "integrity": "sha512-VazYSr8tk6S/zkOq5jpR/ryy1HnGxm5XCw+d2Ejpqy1m6d71oZpyFG82dUkgAo7dg/lk3k4TqvJPtuRUtR8URA==" + }, + "webidl-conversions": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-3.0.1.tgz", + "integrity": "sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==" + }, + "whatwg-url": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/whatwg-url/-/whatwg-url-5.0.0.tgz", + "integrity": "sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==", + "requires": { + "tr46": "~0.0.3", + "webidl-conversions": "^3.0.0" + } + }, "which": { "version": "1.3.1", "resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz", @@ -5174,12 +8384,47 @@ "isexe": "^2.0.0" } }, + "which-boxed-primitive": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/which-boxed-primitive/-/which-boxed-primitive-1.0.2.tgz", + "integrity": "sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==", + "requires": { + "is-bigint": "^1.0.1", + "is-boolean-object": "^1.1.0", + "is-number-object": "^1.0.4", + "is-string": "^1.0.5", + "is-symbol": "^1.0.3" + } + }, + "which-collection": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/which-collection/-/which-collection-1.0.1.tgz", + "integrity": "sha512-W8xeTUwaln8i3K/cY1nGXzdnVZlidBcagyNFtBdD5kxnb4TvGKR7FfSIS3mYpwWS1QUCutfKz8IY8RjftB0+1A==", + "requires": { + "is-map": "^2.0.1", + "is-set": "^2.0.1", + "is-weakmap": "^2.0.1", + "is-weakset": "^2.0.1" + } + }, "which-module": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz", "integrity": "sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==", "dev": true }, + "which-typed-array": { + "version": "1.1.11", + "resolved": "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz", + "integrity": "sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew==", + "requires": { + "available-typed-arrays": "^1.0.5", + "call-bind": "^1.0.2", + "for-each": "^0.3.3", + "gopd": "^1.0.1", + "has-tostringtag": "^1.0.0" + } + }, "workerpool": { "version": "6.2.1", "resolved": "https://registry.npmjs.org/workerpool/-/workerpool-6.2.1.tgz", @@ -5200,16 +8445,24 @@ "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 + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==" }, "ws": { "version": "7.4.6", "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz", "integrity": "sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==", - "peer": true, "requires": {} }, + "xmlhttprequest-ssl": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz", + "integrity": "sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A==" + }, + "xtend": { + "version": "4.0.2", + "resolved": "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz", + "integrity": "sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==" + }, "y18n": { "version": "5.0.8", "resolved": "https://registry.npmjs.org/y18n/-/y18n-5.0.8.tgz", @@ -5260,6 +8513,14 @@ "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", "dev": true + }, + "zustand": { + "version": "4.4.1", + "resolved": "https://registry.npmjs.org/zustand/-/zustand-4.4.1.tgz", + "integrity": "sha512-QCPfstAS4EBiTQzlaGP1gmorkh/UL1Leaj2tdj+zZCZ/9bm0WS7sI2wnfD5lpOszFqWJ1DcPnGoY8RDL61uokw==", + "requires": { + "use-sync-external-store": "1.2.0" + } } } } diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 9e96e0e89..304663e7e 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -11,6 +11,7 @@ "dependencies": { "@ambire/signature-validator": "^1.3.1", "@metamask/eth-sig-util": "^5.0.2", + "@pushprotocol/socket": "^0.5.2", "buffer": "^6.0.3", "crypto-js": "^4.1.1", "immer": "^10.0.2", diff --git a/packages/restapi/src/lib/chat/getGroupMemberStatus.ts b/packages/restapi/src/lib/chat/getGroupMemberStatus.ts new file mode 100644 index 000000000..8c9f0282c --- /dev/null +++ b/packages/restapi/src/lib/chat/getGroupMemberStatus.ts @@ -0,0 +1,54 @@ +import axios from 'axios'; +import { getAPIBaseUrls } from '../helpers'; +import Constants, { ENV } from '../constants'; +import { GroupAccess, GroupMemberStatus } from '../types'; +import { getUserDID } from './helpers'; + +/** + * GET /v1/chat/groups/:chatId/access/:did + */ + +export interface GetGroupMemberStatusType { + chatId: string; + did: string; // Decentralized Identifier + env?: ENV; +} + +export const getGroupMemberStatus = async ( + options: GetGroupMemberStatusType +): Promise => { + // Replace "any" with the actual response type + const { chatId, did, env = Constants.ENV.PROD } = options || {}; + try { + if (chatId == null || chatId.length === 0) { + throw new Error(`chatId cannot be null or empty`); + } + + if (did == null || did.length === 0) { + throw new Error(`did cannot be null or empty`); + } + + const user = await getUserDID(did, env); + + const API_BASE_URL = getAPIBaseUrls(env); + const requestUrl = `${API_BASE_URL}/v1/chat/groups/${chatId}/members/${user}/status`; + + return axios + .get(requestUrl) + .then((response) => { + return response.data; + }) + .catch((err) => { + if (err?.response?.data) throw new Error(err?.response?.data); + throw new Error(err); + }); + } catch (err) { + console.error( + `[Push SDK] - API - Error - API ${getGroupMemberStatus.name} -: `, + err + ); + throw Error( + `[Push SDK] - API - Error - API ${getGroupMemberStatus.name} -: ${err}` + ); + } +}; diff --git a/packages/restapi/src/lib/chat/helpers/inbox.ts b/packages/restapi/src/lib/chat/helpers/inbox.ts index b243e2b78..f73f9a735 100644 --- a/packages/restapi/src/lib/chat/helpers/inbox.ts +++ b/packages/restapi/src/lib/chat/helpers/inbox.ts @@ -171,23 +171,31 @@ export const decryptConversation = async (options: DecryptConverationType) => { const message = messages[i]; let gotOtherPeer = false; if (message.encType !== 'PlainText') { - if (!pgpPrivateKey) { - throw Error('Decrypted private key is necessary'); - } - if (message.fromCAIP10 !== connectedUser.wallets.split(',')[0]) { - if (!gotOtherPeer) { - otherPeer = await getUser({ account: message.fromCAIP10, env }); - gotOtherPeer = true; + // check if message is already decrypted + if ( + // legacy messages ( no way to know if they are decrypted or not ) + message.messageObj === undefined || + // new messages ( if messageObj is string then it is not decrypted ) + typeof message.messageObj === 'string' + ) { + if (!pgpPrivateKey) { + throw Error('Decrypted private key is necessary'); + } + if (message.fromCAIP10 !== connectedUser.wallets.split(',')[0]) { + if (!gotOtherPeer) { + otherPeer = await getUser({ account: message.fromCAIP10, env }); + gotOtherPeer = true; + } + signatureValidationPubliKey = otherPeer!.publicKey; + } else { + signatureValidationPubliKey = connectedUser.publicKey; } - signatureValidationPubliKey = otherPeer!.publicKey; - } else { - signatureValidationPubliKey = connectedUser.publicKey; + messages[i] = await decryptAndVerifyMessage( + message, + signatureValidationPubliKey, + pgpPrivateKey + ); } - messages[i] = await decryptAndVerifyMessage( - message, - signatureValidationPubliKey, - pgpPrivateKey - ); } } return messages; diff --git a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts index eeb318dff..16d8eaaf4 100644 --- a/packages/restapi/src/lib/chat/helpers/payloadHelper.ts +++ b/packages/restapi/src/lib/chat/helpers/payloadHelper.ts @@ -280,10 +280,10 @@ export const convertRulesToSpaceRules = (rules: Rules): SpaceRules => { export const groupAccessToSpaceAccess = (group: GroupAccess): SpaceAccess => { const spaceAccess: SpaceAccess = { - entry: group.groupAccess, + entry: group.entry, }; - // If rules are present in the groupAccess, map them to the spaceAccess + // If rules are present in the entry, map them to the spaceAccess if (group.rules) { spaceAccess.rules = convertRulesToSpaceRules(group.rules); } diff --git a/packages/restapi/src/lib/chat/index.ts b/packages/restapi/src/lib/chat/index.ts index 54660ee0c..64512ed4b 100644 --- a/packages/restapi/src/lib/chat/index.ts +++ b/packages/restapi/src/lib/chat/index.ts @@ -21,3 +21,4 @@ export * from './removeAdmins'; export * from './getGroupAccess'; export * from './searchGroups'; export * from './rejectRequest'; +export * from './getGroupMemberStatus'; diff --git a/packages/restapi/src/lib/chat/rejectRequest.ts b/packages/restapi/src/lib/chat/rejectRequest.ts index 05bf8226f..57c884e3d 100644 --- a/packages/restapi/src/lib/chat/rejectRequest.ts +++ b/packages/restapi/src/lib/chat/rejectRequest.ts @@ -80,7 +80,7 @@ export const reject = async ( signature ); - axios + return axios .put(apiEndpoint, body) .then((response) => { return response.data; diff --git a/packages/restapi/src/lib/index.ts b/packages/restapi/src/lib/index.ts index eecc148e5..cbb11f040 100644 --- a/packages/restapi/src/lib/index.ts +++ b/packages/restapi/src/lib/index.ts @@ -9,7 +9,6 @@ import * as video from "./video" export * from './types'; export { PushAPI } from './pushapi/PushAPI'; -export { PushNotification } from './pushNotification/PushNotification' export { alias, channels, diff --git a/packages/restapi/src/lib/pushNotification/PushNotification.ts b/packages/restapi/src/lib/pushNotification/PushNotification.ts deleted file mode 100644 index 6352f8497..000000000 --- a/packages/restapi/src/lib/pushNotification/PushNotification.ts +++ /dev/null @@ -1,1333 +0,0 @@ -import Constants, { ENV } from '../constants'; -import { - SignerType, - ISendNotificationInputOptions, - ProgressHookType, - ProgressHookTypeFunction, -} from '../types'; -import { - ChannelInfoOptions, - SubscribeUnsubscribeOptions, - SubscriptionOptions, - AliasOptions, - FeedType, - FeedsOptions, - ChannelSearchOptions, - NotificationOptions, - CreateChannelOptions, - NotificationSettings, -} from './PushNotificationTypes'; -import CONFIG, * as config from '../config'; -import * as PUSH_USER from '../user'; -import * as PUSH_PAYLOAD from '../payloads'; -import * as PUSH_CHANNEL from '../channels'; -import * as PUSH_ALIAS from '../alias'; -import { getAccountAddress } from '../chat/helpers'; -import { - getCAIPDetails, - getCAIPWithChainId, - validateCAIP, - getFallbackETHCAIPAddress, -} from '../helpers'; -import PROGRESSHOOK from '../progressHook'; -import { IDENTITY_TYPE, NOTIFICATION_TYPE } from '../payloads/constants'; -import { ethers, Contract, Signer, BigNumber } from 'ethers'; -import axios from 'axios'; -import { - createPublicClient, - http, - getContract, - WalletClient, - Chain, -} from 'viem'; - -// ERROR CONSTANTS -const ERROR_ACCOUNT_NEEDED = 'Account is required'; -const ERROR_SIGNER_NEEDED = 'Signer object is required'; -const ERROR_CHANNEL_NEEDED = 'Channel is needed'; -const ERROR_INVALID_CAIP = 'Invalid CAIP format'; - -const BROADCAST_TYPE = '*'; -const LENGTH_UPPER_LIMIT = 125; -const LENGTH_LOWER_LIMTI = 1; -const SETTING_DELIMITER = '-'; -const SETTING_SEPARATOR = '+'; - -export const FEED_MAP = { - INBOX: false, - SPAM: true, -}; -export class PushNotification { - private signer: SignerType | undefined; - private account: string | undefined; - private env: ENV | undefined; - private guestMode: boolean; - private coreContract: Contract | undefined; - - constructor( - signer?: SignerType, - env?: ENV, - account?: string, - coreContract?: any - ) { - this.signer = signer; - this.env = env; - this.guestMode = !!(account && signer); - this.account = account; - this.coreContract = coreContract; - } - static async initialize( - signer?: SignerType, - options?: { env?: ENV } - ): Promise { - const { env = ENV.STAGING } = options || {}; - // Derives account from signer if not provided - let derivedAccount; - let coreContract; - if (signer) { - if (!('_signTypedData' in signer!) && !('signTypedData' in signer!)) { - throw new Error('Unsupported signer type'); - } else if ('_signTypedData' in signer) { - derivedAccount = await getAccountAddress({ - account: null, - signer: signer, - }); - if (signer?.provider) { - coreContract = new ethers.Contract( - config.CORE_CONFIG[env].EPNS_CORE_CONTRACT, - config.ABIS.CORE, - signer as unknown as Signer - ); - } - } else if ('signTypedData' in signer) { - derivedAccount = await getAccountAddress({ - account: null, - signer: signer, - }); - const client = createPublicClient({ - chain: config.TOKEN_VIEM_NETWORK_MAP[env], - transport: http(), - }); - coreContract = getContract({ - abi: config.ABIS.CORE, - address: config.CORE_CONFIG[env].EPNS_CORE_CONTRACT as `0x${string}`, - publicClient: client, - walletClient: signer as unknown as WalletClient, - }); - } - } - - // Initialize PushNotifications instance - return new PushNotification( - signer, - env as ENV, - derivedAccount, - coreContract - ); - } - - // check if addresses is supplied either by user or derived from signer object or if its guest mode - private checkUserAddressExists(user?: string) { - if (!user && !this.account && !this.guestMode) - throw new Error(ERROR_ACCOUNT_NEEDED); - return true; - } - - // checks if the signer object is supplied - private checkSignerObjectExists() { - if (!this.signer) throw new Error(ERROR_SIGNER_NEEDED); - return true; - } - - // get type of notification from recipient - private getNotificationType( - recipient: string[], - channel: string - ): { recipient: string[] | string; type: number } { - if (recipient.length == 1) { - if (recipient[0] == BROADCAST_TYPE) { - return { recipient: channel, type: NOTIFICATION_TYPE['BROADCAST'] }; - } else { - return { - recipient: recipient[0], - type: NOTIFICATION_TYPE['TARGETTED'], - }; - } - } - return { recipient, type: NOTIFICATION_TYPE['SUBSET'] }; - } - - // get identity type for lowlevel call - private generateNotificationLowLevelPayload({ - signer, - env, - recipients, - options, - channel, - }: { - signer: SignerType; - env: ENV; - recipients: string[]; - options: NotificationOptions; - channel?: string; - }): ISendNotificationInputOptions { - if (!channel) { - channel = `${this.account}`; - } - const notificationType = this.getNotificationType(recipients, channel); - const identityType = IDENTITY_TYPE.DIRECT_PAYLOAD; - const notificationPayload: ISendNotificationInputOptions = { - signer: signer, - channel: channel, - type: notificationType.type, - identityType: identityType, - notification: options.notification, - payload: { - title: options.payload?.title ?? options.notification.title, - body: options.payload?.body ?? options.notification.body, - cta: options.payload?.cta ?? '', - img: options.payload?.embed ?? '', - hidden: options.config?.hidden, - etime: options.config?.expiry, - silent: options.config?.silent, - additionalMeta: options.payload?.meta, - }, - recipients: notificationType.recipient, - graph: options.advanced?.graph, - ipfsHash: options.advanced?.ipfs, - env: env, - chatId: options.advanced?.chatid, - pgpPrivateKey: options.advanced?.pgpPrivateKey, - }; - - return notificationPayload; - } - - // check if the fields are empty - private isEmpty(field: string) { - if (field.trim().length == 0) { - return true; - } - - return false; - } - - // check if the length is valid - private isValidLength( - data: string, - upperLen: number = LENGTH_UPPER_LIMIT, - lowerLen: number = LENGTH_LOWER_LIMTI - ): boolean { - return data.length >= lowerLen && data.length <= upperLen!; - } - - // check if url is valid - private isValidUrl(urlString: string): boolean { - const urlPattern = new RegExp( - '^((?:https|http):\\/\\/)' + // validate protocol - '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|' + // validate domain name - '((\\d{1,3}\\.){3}\\d{1,3}))' + // validate OR ip (v4) address - '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + // validate port and path - '(\\?[;&a-z\\d%_.~+=-]*)?' + // validate query string - '(\\#[-a-z\\d_]*)?$', - 'i' - ); // validate fragment locator - return !!urlPattern.test(urlString); - } - - // check all the fields of channel - private verifyEmptyChannelParameters(options: CreateChannelOptions): boolean { - if (this.isEmpty(options.name)) { - throw new Error('Channel name cannot be empty'); - } else if (this.isEmpty(options.description)) { - throw new Error('Channel description cannot be empty'); - } else if (this.isEmpty(options.icon)) { - throw new Error('Channel icon cannot be empty'); - } else if (this.isEmpty(options.url)) { - throw new Error('Channel url cannot ne empty'); - } else { - return true; - } - } - - // check for valid length and url - private validateParameterLength(options: CreateChannelOptions): boolean { - if (!this.isValidLength(options.name)) { - throw new Error( - `Channel name should not exceed ${LENGTH_UPPER_LIMIT} characters` - ); - } else if (!this.isValidLength(options.description)) { - throw new Error( - `Channel description should not exceed ${LENGTH_UPPER_LIMIT} characters` - ); - } else if ( - !this.isValidLength(options.url) || - !this.isValidUrl(options.url) - ) { - throw new Error( - `Channel url either excees ${LENGTH_UPPER_LIMIT} characters or is not a valid url` - ); - } else { - return true; - } - } - - private validateChannelParameters(options: CreateChannelOptions): boolean { - return ( - this.verifyEmptyChannelParameters(options) && - this.validateParameterLength(options) - ); - } - - // create contract instance - public createContractInstance( - contractAddress: string | `0x${string}`, - contractABI: any, - network: Chain - ) { - let contract: any; - if ( - !('_signTypedData' in this.signer!) && - !('signTypedData' in this.signer!) - ) { - throw new Error('Unsupported signer type'); - } else if ('_signTypedData' in this.signer) { - if (!this.signer?.provider) { - throw new Error('Provider is required'); - } - contract = new ethers.Contract( - contractAddress, - contractABI, - this.signer as unknown as Signer - ); - } else if ('signTypedData' in this.signer) { - const client = createPublicClient({ - chain: network, - transport: http(), - }); - contract = getContract({ - abi: contractABI, - address: contractAddress as `0x${string}`, - publicClient: client, - walletClient: this.signer as unknown as WalletClient, - }); - } else { - throw new Error('Unsupported signer type'); - } - return contract; - } - - private async fetchBalance(contract: any, userAddress: string) { - let balance: BigNumber; - try { - if ('_signTypedData' in this.signer!) { - balance = await contract!['balanceOf'](userAddress); - } else if ('signTypedData' in this.signer!) { - const balanceInBigInt = await contract.read.balanceOf({ - args: [userAddress], - }); - balance = ethers.BigNumber.from(balanceInBigInt); - } else { - throw new Error('Unsupported signer'); - } - return balance; - } catch (error) { - console.log(error); - throw new Error(JSON.stringify(error)); - } - } - - private async fetchAllownace( - contract: any, - userAddress: string, - spenderAddress: string - ) { - let allowance: BigNumber; - try { - if ('_signTypedData' in this.signer!) { - allowance = await contract!['allowance'](userAddress, spenderAddress); - } else if ('signTypedData' in this.signer!) { - const allowanceInBigInt = await contract.read.allowance({ - args: [userAddress, spenderAddress], - }); - allowance = ethers.BigNumber.from(allowanceInBigInt); - } else { - throw new Error('Unsupported signer'); - } - return allowance; - } catch (error) { - throw new Error(JSON.stringify(error)); - } - } - - private async approveToken( - contract: any, - spenderAddress: string, - amount: string | BigNumber - ) { - try { - if ('_signTypedData' in this.signer!) { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - const approvalTrxPromise = contract!['approve'](spenderAddress, amount); - const approvalTrx = await approvalTrxPromise; - await this.signer?.provider?.waitForTransaction(approvalTrx.hash); - // console.log(approvalTrx.hash) - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const approvalTrxPromise = contract.write.approve({ - args: [spenderAddress, amount], - }); - const approvalTrxRes = await approvalTrxPromise; - // console.log(approvalTrxRes); - } else { - throw new Error('Unsupported signer'); - } - return true; - } catch (error) { - console.log(error); - return false; - } - } - - private async createChannel( - contract: any, - channelType: number, - identityBytes: Uint8Array, - fees: BigNumber - ) { - let createChannelRes; - try { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - if ('_signTypedData' in this.signer!) { - const createChannelPromise = contract!['createChannelWithPUSH']( - channelType, - identityBytes, - fees, - this.getTimeBound(), - { - gasLimit: 1000000, - } - ); - const createChannelTrx = await createChannelPromise; - const createChannelTrxStatus = - await this.signer?.provider?.waitForTransaction( - createChannelTrx.hash - ); - if (createChannelTrxStatus?.status == 0) { - throw new Error('Something Went wrong while creating your channel'); - } - createChannelRes = createChannelTrx.hash; - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const createChannelPromise = contract.write.createChannelWithPUSH({ - args: [channelType, identityBytes, fees, this.getTimeBound()], - }); - createChannelRes = await createChannelPromise; - } - - return createChannelRes; - } catch (error: any) { - throw new Error(error?.message); - } - } - - private async updateChannel( - contract: any, - account: string, - identityBytes: Uint8Array, - fees: BigNumber - ) { - let updateChannelRes; - try { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - if ('_signTypedData' in this.signer!) { - const updateChannelPromise = contract!['updateChannelMeta']( - account, - identityBytes, - fees, - { - gasLimit: 1000000, - } - ); - const updateChannelTrx = await updateChannelPromise; - const updateChannelTrxStatus = - await this.signer?.provider?.waitForTransaction( - updateChannelTrx.hash - ); - if (updateChannelTrxStatus?.status == 0) { - throw new Error('Something Went wrong while creating your channel'); - } - updateChannelRes = updateChannelTrx.hash; - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const updateChannelPromise = contract.write.createChannelWithPUSH({ - args: [account, identityBytes, fees], - }); - updateChannelRes = await updateChannelPromise; - } - - return updateChannelRes; - } catch (error: any) { - throw new Error(error?.message); - } - } - - private async verifyChannel(contract: any, channelToBeVerified: string) { - try { - let verifyTrxRes; - if ('_signTypedData' in this.signer!) { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - const verifyTrxPromise = contract!['verify'](channelToBeVerified); - const verifyTrx = await verifyTrxPromise; - await this.signer?.provider?.waitForTransaction(verifyTrx.hash); - verifyTrxRes = verifyTrx.hash; - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const verifyTrxPromise = contract.write.verify({ - args: [channelToBeVerified], - }); - verifyTrxRes = await verifyTrxPromise; - } else { - throw new Error('Unsupported signer'); - } - return verifyTrxRes; - } catch (error: any) { - throw new Error(error.message); - } - } - - private async createChanelSettings( - contract: any, - numberOfSettings: number, - settings: string, - description: string, - fees: BigNumber - ) { - try { - let createSettingsRes; - if ('_signTypedData' in this.signer!) { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - const createSettingsPromise = contract!['createChannelSettings']( - numberOfSettings, - settings, - description, - fees - ); - const createSettings = await createSettingsPromise; - await this.signer?.provider?.waitForTransaction(createSettings.hash); - createSettingsRes = createSettings.hash; - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const createSettingsTrxPromise = contract.write.createChannelSettings({ - args: [numberOfSettings, settings, description, fees], - }); - createSettingsRes = await createSettingsTrxPromise; - } else { - throw new Error('Unsupported signer'); - } - return createSettingsRes; - } catch (error: any) { - throw new Error(error.message); - } - } - - private async addDelegator(contract: any, delegatee: string) { - try { - let addDelegateRes; - if ('_signTypedData' in this.signer!) { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - const addDelegateTrxPromise = contract!['addDelegate'](delegatee); - const addDelegateTrx = await addDelegateTrxPromise; - await this.signer?.provider?.waitForTransaction(addDelegateTrx.hash); - addDelegateRes = addDelegateTrx.hash; - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const addDelegateTrxPromise = contract.write.addDelegate({ - args: [delegatee], - }); - addDelegateRes = await addDelegateTrxPromise; - } else { - throw new Error('Unsupported signer'); - } - return addDelegateRes; - } catch (error: any) { - throw new Error(error.message); - } - } - - private async removeDelegator(contract: any, delegatee: string) { - try { - let removeDelegateRes; - if ('_signTypedData' in this.signer!) { - if (!this.signer || !this.signer.provider) { - throw new Error('ethers provider/signer is not provided'); - } - const removeDelegateTrxPromise = contract!['removeDelegate'](delegatee); - const removeDelegateTrx = await removeDelegateTrxPromise; - await this.signer?.provider?.waitForTransaction(removeDelegateTrx.hash); - removeDelegateRes = removeDelegateTrx.hash; - } else if ('signTypedData' in this.signer!) { - if (!contract.write) { - throw new Error('viem signer is not provided'); - } - const removeDelegateTrxPromise = contract.write.removeDelegate({ - args: [delegatee], - }); - removeDelegateRes = await removeDelegateTrxPromise; - } else { - throw new Error('Unsupported signer'); - } - return removeDelegateRes; - } catch (error: any) { - throw new Error(error.message); - } - } - - private async getChianId(signer: SignerType) { - let chainId; - if ('_signTypedData' in signer!) { - const chainDetails = await signer?.provider?.getNetwork(); - chainId = chainDetails?.chainId; - } else if ('signTypedData' in signer!) { - chainId = await signer.getChainId(); - } - return chainId; - } - - private async uploadToIPFSViaPushNode(data: string): Promise { - try { - const response = await axios.post( - `${config.CORE_CONFIG[this.env!].API_BASE_URL}/v1/ipfs/upload`, - { data } - ); - return response.data.cid as string; - } catch (error) { - throw new Error('Something went wrong while uploading data to IPFS'); - } - } - - private getTimeBound(timeStamp?: number) { - // for now returns 0 for non-time bound. Later it can be modified to handle time bound channels - return 0; - } - - private getMinimalSetting(configuration: NotificationSettings): { - setting: string; - description: string; - } { - let notificationSetting = ''; - let notificationSettingDescription = ''; - for (let i = 0; i < configuration.length; i++) { - const ele = configuration[i]; - if (ele.type == 0) { - notificationSetting = - notificationSetting + - SETTING_SEPARATOR + - ele.type + - SETTING_DELIMITER + - ele.default; - notificationSettingDescription = - notificationSettingDescription + ele.description; - } - if (ele.type == 1) { - if (ele.data) { - notificationSetting = - notificationSetting + - SETTING_SEPARATOR + - ele.type + - SETTING_DELIMITER + - ele.default + - SETTING_DELIMITER + - ele.data.lower + - SETTING_DELIMITER + - ele.data.upper; - - notificationSettingDescription = - notificationSettingDescription + ele.description; - } - } - } - return { - setting: notificationSetting.replace(/^\+/, ''), - description: notificationSettingDescription, - }; - } - notification = { - /** - * @description - Fetches feeds and spam feeds for a specific user - * @param {enums} spam - indicates if its a spam or not. `INBOX` for non-spam and `SPAM` for spam. default `INBOX` - * @param {string} [options.user] - user address, defaults to address from signer - * @param {number} [options.page] - page number. default is set to Constants.PAGINATION.INITIAL_PAGE - * @param {number} [options.limit] - number of feeds per page. default is set to Constants.PAGINATION.LIMIT - * @param {boolean} [options.raw] - indicates if the response should be raw or formatted. defaults is set to false - * @returns feeds for a specific address - */ - list: async ( - spam: `${FeedType}` = FeedType.INBOX, - options?: FeedsOptions - ) => { - const { - account = this.account - ? getFallbackETHCAIPAddress(this.env!, this.account!) - : null, - page = Constants.PAGINATION.INITIAL_PAGE, - limit = Constants.PAGINATION.LIMIT, - channels = [], - raw = false, - } = options || {}; - try { - // guest mode and valid address check - this.checkUserAddressExists(account!); - if (!validateCAIP(account!)) { - throw new Error('Invalid CAIP'); - } - const nonCaipAccount = - account?.split(':')[account?.split(':').length - 1]; - if (channels.length == 0) { - // else return the response - return await PUSH_USER.getFeeds({ - user: nonCaipAccount!, - page: page, - limit: limit, - spam: FEED_MAP[spam], - raw: raw, - env: this.env, - }); - } else { - return await PUSH_USER.getFeedsPerChannel({ - user: nonCaipAccount!, - page: page, - limit: limit, - spam: FEED_MAP[spam], - raw: raw, - env: this.env, - channels: channels, - }); - } - } catch (error) { - throw new Error(`Push SDK Error: API : notifcaiton::list : ${error}`); - } - }, - - subscriptions: async (options?: SubscriptionOptions) => { - try { - const { - account = this.account, - // TODO: to be used once pagination is implemeted at API level - page = Constants.PAGINATION.INITIAL_PAGE, - limit = Constants.PAGINATION.LIMIT, - } = options || {}; - this.checkUserAddressExists(account!); - return await PUSH_USER.getSubscriptions({ - user: account!, - env: this.env, - }); - } catch (error) { - throw new Error( - `Push SDK Error: API : notifcaiton::subscriptions : ${error}` - ); - } - }, - /** - * Subscribes a user to a channel - * @param {string} channel - channel address in caip format - * @param {function} [options.onSuccess] - callback function when a user successfully subscribes to a channel - * @param {function} [options.onError] - callback function incase a user was not able to subscribe to a channel - * @returns Subscribe status object - */ - subscribe: async ( - channel: string, - options?: SubscribeUnsubscribeOptions - ) => { - try { - const { onSuccess, onError } = options || {}; - // Vaidatiions - // validates if signer object is present - this.checkSignerObjectExists(); - // validates if the user address exists - this.checkUserAddressExists(); - // validates if channel exists - if (!channel && channel != '') { - throw new Error(ERROR_CHANNEL_NEEDED); - } - // validates if caip is correct - if (!validateCAIP(channel)) { - throw new Error(ERROR_INVALID_CAIP); - } - // get channel caip - const caipDetail = getCAIPDetails(channel); - // based on the caip, construct the user caip - const userAddressInCaip = getCAIPWithChainId( - this.account!, - parseInt(caipDetail?.networkId as string) - ); - return await PUSH_CHANNEL.subscribe({ - signer: this.signer!, - channelAddress: channel, - userAddress: userAddressInCaip, - env: this.env, - onSuccess: onSuccess, - onError: onError, - }); - } catch (error) { - throw new Error( - `Push SDK Error: API : notifcaiton::subscribe : ${error}` - ); - } - }, - - /** - * Unsubscribes a user to a channel - * @param {string} channel - channel address in caip format - * @param {function} [options.onSuccess] - callback function when a user successfully unsubscribes to a channel - * @param {function} [options.onError] - callback function incase a user was not able to unsubscribe to a channel - * @returns Unsubscribe status object - */ - unsubscribe: async ( - channel: string, - options?: SubscribeUnsubscribeOptions - ) => { - try { - const { onSuccess, onError } = options || {}; - // Vaidatiions - // validates if the user address exists - this.checkUserAddressExists(); - // validates if signer object is present - this.checkSignerObjectExists(); - // validates if channel exists - if (!channel && channel != '') { - return new Error(ERROR_CHANNEL_NEEDED); - } - // validates if caip is correct - if (!validateCAIP(channel)) { - return new Error(ERROR_INVALID_CAIP); - } - const caipDetail = getCAIPDetails(channel); - const userAddressInCaip = getCAIPWithChainId( - this.account!, - parseInt(caipDetail?.networkId as string) - ); - return await PUSH_CHANNEL.unsubscribe({ - signer: this.signer!, - channelAddress: channel, - userAddress: userAddressInCaip, - env: this.env, - onSuccess: onSuccess, - onError: onError, - }); - } catch (error) { - throw new Error( - `Push SDK Error: API : notifcaiton::unsubscribe : ${error}` - ); - } - }, - }; - - channel = { - /** - * @description - returns information about a channel - * @param {string} [options.channel] - channel address in caip, defaults to eth caip address - * @returns information about the channel if it exists - */ - info: async (channel?: string) => { - try { - this.checkUserAddressExists(channel); - channel = - channel ?? getFallbackETHCAIPAddress(this.env!, this.account!); - return await PUSH_CHANNEL.getChannel({ - channel: channel as string, - env: this.env, - }); - } catch (error) { - throw new Error(`Push SDK Error: API : channel::info : ${error}`); - } - }, - - /** - * @description - returns relevant information as per the query that was passed - * @param {string} query - search query - * @param {number} [options.page] - page number. default is set to Constants.PAGINATION.INITIAL_PAGE - * @param {number} [options.limit] - number of feeds per page. default is set to Constants.PAGINATION.LIMIT - * @returns Array of results relevant to the serach query - */ - search: async (query: string, options?: ChannelSearchOptions) => { - try { - const { - page = Constants.PAGINATION.INITIAL_PAGE, - limit = Constants.PAGINATION.LIMIT, - } = options || {}; - return await PUSH_CHANNEL.search({ - query: query, - page: page, - limit: limit, - env: this.env, - }); - } catch (error) { - throw new Error(`Push SDK Error: API : channel::search : ${error}`); - } - }, - /** - * @description - Get subscribers of a channell - * @param {string} [options.channel] - channel in caip. defaults to account from signer with eth caip - * @returns array of subscribers - */ - subscribers: async (options?: ChannelInfoOptions) => { - try { - const { - channel = this.account - ? getFallbackETHCAIPAddress(this.env!, this.account!) - : null, - } = options || {}; - - this.checkUserAddressExists(channel!); - if (!validateCAIP(channel!)) { - throw new Error('Invalid CAIP'); - } - return await PUSH_CHANNEL._getSubscribers({ - channel: channel!, - env: this.env, - }); - } catch (error) { - throw new Error( - `Push SDK Error: API : channel::subscribers : ${error}` - ); - } - }, - /** - * - * @param {string[]} recipients - Array of recipients. `['0x1'] -> TARGET`, `['0x1, 0x2'] -> SUBSET`, `['*'] -> BROADCAST` - * @param {object} options - Notification options - * @returns - */ - send: async (recipients: string[], options: NotificationOptions) => { - try { - this.checkSignerObjectExists(); - const lowLevelPayload = this.generateNotificationLowLevelPayload({ - signer: this.signer!, - env: this.env!, - recipients: recipients, - options: options, - channel: options.channel ?? this.account, - }); - return await PUSH_PAYLOAD.sendNotification(lowLevelPayload); - } catch (error) { - throw new Error(`Push SDK Error: API : channel::send : ${error}`); - } - }, - - create: async (options: CreateChannelOptions) => { - const { - name, - description, - url, - icon, - alias = null, - progressHook, - } = options || {}; - try { - // create push token instance - let aliasInfo; - this.checkSignerObjectExists(); - if (!this.signer || !this.signer?.provider) { - throw new Error('Provider is required'); - } - // validate all the parameters and length - this.validateChannelParameters(options); - // check for PUSH balance - const pushTokenContract = await this.createContractInstance( - config.TOKEN[this.env!], - config.ABIS.TOKEN, - config.TOKEN_VIEM_NETWORK_MAP[this.env!] - ); - const balance = await this.fetchBalance( - pushTokenContract, - this.account! - ); - const fees = ethers.utils.parseUnits( - config.MIN_TOKEN_BALANCE[this.env!].toString(), - 18 - ); - if (fees.gte(balance)) { - throw new Error('Insufficient PUSH balance'); - } - // if alias is passed, check for the caip - if (alias) { - if (!validateCAIP(alias)) { - throw new Error('Invalid alias CAIP'); - } - const aliasDetails = getCAIPDetails(alias); - aliasInfo = { - [`${aliasDetails?.blockchain}:${aliasDetails?.networkId}`]: - aliasDetails?.address, - }; - } - // construct channel identity - progressHook?.(PROGRESSHOOK['PUSH-CREATE-01'] as ProgressHookType); - const input = { - name: name, - info: description, - url: url, - icon: icon, - aliasDetails: aliasInfo ?? {}, - }; - const cid = await this.uploadToIPFSViaPushNode(JSON.stringify(input)); - const allowanceAmount = await this.fetchAllownace( - pushTokenContract, - this.account!, - config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT - ); - if (!allowanceAmount.gte(fees)) { - progressHook?.(PROGRESSHOOK['PUSH-CREATE-02'] as ProgressHookType); - const approvalRes = await this.approveToken( - pushTokenContract, - config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, - fees - ); - if (!approvalRes) { - throw new Error('Something went wrong while approving the token'); - } - } - // generate the contract parameters - const channelType = config.CHANNEL_TYPE['GENERAL']; - const identity = '1+' + cid; - const identityBytes = ethers.utils.toUtf8Bytes(identity); - // call contract - progressHook?.(PROGRESSHOOK['PUSH-CREATE-03'] as ProgressHookType); - const createChannelRes = await this.createChannel( - this.coreContract, - channelType, - identityBytes, - fees - ); - progressHook?.(PROGRESSHOOK['PUSH-CREATE-04'] as ProgressHookType); - return { transactionHash: createChannelRes }; - } catch (error) { - const errorProgressHook = PROGRESSHOOK[ - 'PUSH-ERROR-02' - ] as ProgressHookTypeFunction; - progressHook?.(errorProgressHook('Create Channel', error)); - throw new Error( - `Push SDK Error: Contract : createChannelWithPUSH : ${error}` - ); - } - }, - - update: async (options: CreateChannelOptions) => { - const { - name, - description, - url, - icon, - alias = null, - progressHook, - } = options || {}; - try { - // create push token instance - let aliasInfo; - this.checkSignerObjectExists(); - if (!this.signer || !this.signer.provider) { - throw new Error('Provider is required'); - } - // validate all the parameters and length - this.validateChannelParameters(options); - // check for PUSH balance - const pushTokenContract = await this.createContractInstance( - config.TOKEN[this.env!], - config.ABIS.TOKEN, - config.TOKEN_VIEM_NETWORK_MAP[this.env!] - ); - const balance = await this.fetchBalance( - pushTokenContract, - this.account! - ); - const fees = ethers.utils.parseUnits( - config.MIN_TOKEN_BALANCE[this.env!].toString(), - 18 - ); - if (fees.gt(balance)) { - throw new Error('Insufficient PUSH balance'); - } - // if alias is passed, check for the caip - if (alias) { - if (!validateCAIP(alias)) { - throw new Error('Invalid alias CAIP'); - } - const aliasDetails = getCAIPDetails(alias); - aliasInfo = { - [`${aliasDetails?.blockchain}:${aliasDetails?.networkId}`]: - aliasDetails?.address, - }; - } - // construct channel identity - progressHook?.(PROGRESSHOOK['PUSH-UPDATE-01'] as ProgressHookType); - const input = { - name: name, - info: description, - url: url, - icon: icon, - aliasDetails: aliasInfo ?? {}, - }; - const cid = await this.uploadToIPFSViaPushNode(JSON.stringify(input)); - // approve the tokens to core contract - const allowanceAmount = await this.fetchAllownace( - pushTokenContract, - this.account!, - config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT - ); - // if allowance is not greater than the fees, dont call approval again - if (!allowanceAmount.gte(fees)) { - progressHook?.(PROGRESSHOOK['PUSH-UPDATE-02'] as ProgressHookType); - const approvalRes = await this.approveToken( - pushTokenContract, - config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, - fees - ); - if (!approvalRes) { - throw new Error('Something went wrong while approving the token'); - } - } - // generate the contract parameters - const identity = '1+' + cid; - const identityBytes = ethers.utils.toUtf8Bytes(identity); - // call contract - progressHook?.(PROGRESSHOOK['PUSH-UPDATE-03'] as ProgressHookType); - const updateChannelRes = await this.updateChannel( - this.coreContract, - this.account!, - identityBytes, - fees - ); - progressHook?.(PROGRESSHOOK['PUSH-UPDATE-04'] as ProgressHookType); - return { transactionHash: updateChannelRes }; - } catch (error) { - const errorProgressHook = PROGRESSHOOK[ - 'PUSH-ERROR-02' - ] as ProgressHookTypeFunction; - progressHook?.(errorProgressHook('Update Channel', error)); - throw new Error(`Push SDK Error: Contract channel::update : ${error}`); - } - }, - /** - * @description verifies a channel - * @param {string} channelToBeVerified - address of the channel to be verified - * @returns the transaction hash if the transaction is successful - */ - verify: async (channelToBeVerified: string) => { - try { - this.checkSignerObjectExists(); - if (validateCAIP(channelToBeVerified)) { - channelToBeVerified = channelToBeVerified.split(':')[2]; - } - // checks if it is a valid address - if (!ethers.utils.isAddress(channelToBeVerified)) { - throw new Error('Invalid channel address'); - } - // if valid, continue with it - const res = await this.verifyChannel( - this.coreContract, - channelToBeVerified - ); - if (!res) { - throw new Error('Something went wrong while verifying the channel'); - } - return { transactionHash: res }; - } catch (error) { - throw new Error(`Push SDK Error: Contract channel::verify : ${error}`); - } - }, - - setting: async (configuration: NotificationSettings) => { - try { - this.checkSignerObjectExists(); - // check for PUSH balance - const pushTokenContract = await this.createContractInstance( - config.TOKEN[this.env!], - config.ABIS.TOKEN, - config.TOKEN_VIEM_NETWORK_MAP[this.env!] - ); - const balance = await this.fetchBalance( - pushTokenContract, - this.account! - ); - const fees = ethers.utils.parseUnits( - config.MIN_TOKEN_BALANCE[this.env!].toString(), - 18 - ); - if (fees.gte(balance)) { - throw new Error('Insufficient PUSH balance'); - } - const allowanceAmount = await this.fetchAllownace( - pushTokenContract, - this.account!, - config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT - ); - // if allowance is not greater than the fees, dont call approval again - if (!allowanceAmount.gte(fees)) { - const approveRes = this.approveToken( - pushTokenContract, - config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, - fees - ); - if (!approveRes) { - throw new Error('Something went wrong while approving your token'); - } - } - const { setting, description } = this.getMinimalSetting(configuration); - const createSettingsRes = await this.createChanelSettings( - this.coreContract, - configuration.length, - setting, - description, - fees - ); - return { transactionHash: createSettingsRes }; - } catch (error) { - throw new Error( - `Push SDK Error: Contract : channel::setting : ${error}` - ); - } - }, - }; - - delegate = { - /** - * @description - Get delegates of a channell - * @param {string} [options.channel] - channel in caip. defaults to account from signer with eth caip - * @returns array of delegates - */ - get: async (options?: ChannelInfoOptions) => { - try { - const { - channel = this.account - ? getFallbackETHCAIPAddress(this.env!, this.account!) - : null, - } = options || {}; - this.checkUserAddressExists(channel!); - if (!validateCAIP(channel!)) { - throw new Error('Invalid CAIP'); - } - return await PUSH_CHANNEL.getDelegates({ - channel: channel!, - env: this.env, - }); - } catch (error) { - throw new Error(`Push SDK Error: API : delegate::get : ${error}`); - } - }, - - /** - * @description adds a delegate - * @param {string} delegate - delegate address in caip to be added - * @returns the transaction hash if the transaction is successfull - */ - add: async (delegate: string) => { - try { - if (!validateCAIP(delegate)) { - throw new Error('Invalid CAIP'); - } - - const networkDetails = await this.getChianId(this.signer!); - if (networkDetails !== parseInt(delegate.split(':')[1])) { - return new Error('Signer and CAIP chain id doesnt match'); - } - const caip = `eip155:${networkDetails}`; - if (!CONFIG[this.env!][caip] || !config.VIEM_CONFIG[this.env!][caip]) { - throw new Error('Unsupported Chainid'); - } - const commAddress = CONFIG[this.env!][caip].EPNS_COMMUNICATOR_CONTRACT; - const commContract = this.createContractInstance( - commAddress, - config.ABIS.COMM, - config.VIEM_CONFIG[this.env!][caip].NETWORK - ); - const addDelegateRes = await this.addDelegator( - commContract, - delegate.split(':')[2] - ); - return { transactionHash: addDelegateRes }; - } catch (error) { - throw new Error(`Push SDK Error: Contract : delegate::add : ${error}`); - } - }, - - /** - * @description removes a delegate - * @param {string} delegate - caip address of the delegate to be removed - * @returns the transaction hash if the transaction is successfull - */ - remove: async (delegate: string) => { - try { - this.checkSignerObjectExists(); - if (this.signer && !this.signer.provider) { - throw new Error('Provider is required'); - } - if (!validateCAIP(delegate)) { - throw new Error('Invalid CAIP'); - } - - const networkDetails = await this.getChianId(this.signer!); - if (networkDetails !== parseInt(delegate.split(':')[1])) { - return new Error('Signer and CAIP chain id doesnt match'); - } - const caip = `eip155:${networkDetails}`; - if (!CONFIG[this.env!][caip] || !config.VIEM_CONFIG[this.env!][caip]) { - throw new Error('Unsupported Chainid'); - } - const commAddress = CONFIG[this.env!][caip].EPNS_COMMUNICATOR_CONTRACT; - const commContract = this.createContractInstance( - commAddress, - config.ABIS.COMM, - config.VIEM_CONFIG[this.env!][caip].NETWORK - ); - const removeDelegateRes = await this.removeDelegator( - commContract, - delegate.split(':')[2] - ); - return { transactionHash: removeDelegateRes }; - } catch (error) { - throw new Error( - `Push SDK Error: Contract : delegate::remove : ${error}` - ); - } - }, - }; - - alias = { - /** - * @description - fetches alias information - * @param {AliasOptions} options - options related to alias - * @returns Alias details - */ - info: async (options: AliasOptions) => { - try { - return await PUSH_ALIAS.getAliasInfo({ ...options, env: this.env }); - } catch (error) { - throw new Error(`Push SDK Error: API : alias::info : ${error}`); - } - }, - }; -} diff --git a/packages/restapi/src/lib/pushNotification/alias.ts b/packages/restapi/src/lib/pushNotification/alias.ts new file mode 100644 index 000000000..d23522cc8 --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/alias.ts @@ -0,0 +1,27 @@ +import { ENV } from '../constants'; +import { SignerType } from '../types'; +import { AliasOptions } from './PushNotificationTypes'; + +import * as PUSH_ALIAS from '../alias'; + +import { PushNotificationBaseClass } from './pushNotificationBase'; + +export class Alias { + private env: ENV + constructor(env: ENV) { + this.env = env + } + + /** + * @description - fetches alias information + * @param {AliasOptions} options - options related to alias + * @returns Alias details + */ + info = async (options: AliasOptions) => { + try { + return await PUSH_ALIAS.getAliasInfo({ ...options, env: this.env }); + } catch (error) { + throw new Error(`Push SDK Error: API : alias::info : ${error}`); + } + }; +} diff --git a/packages/restapi/src/lib/pushNotification/channel.ts b/packages/restapi/src/lib/pushNotification/channel.ts new file mode 100644 index 000000000..6fc5ea0d3 --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/channel.ts @@ -0,0 +1,418 @@ +import Constants, { ENV } from '../constants'; +import { + SignerType, + ProgressHookType, + ProgressHookTypeFunction, +} from '../types'; +import { + ChannelInfoOptions, + ChannelSearchOptions, + NotificationOptions, + CreateChannelOptions, + NotificationSettings, +} from './PushNotificationTypes'; +import * as config from '../config'; +import * as PUSH_PAYLOAD from '../payloads'; +import * as PUSH_CHANNEL from '../channels'; +import { + getCAIPDetails, + validateCAIP, + getFallbackETHCAIPAddress, +} from '../helpers'; +import PROGRESSHOOK from '../progressHook'; +import { ethers } from 'ethers'; + +import { PushNotificationBaseClass } from './pushNotificationBase'; + +export class Channel extends PushNotificationBaseClass { + constructor(signer?: SignerType, env?: ENV, account?: string) { + super(signer, env, account); + } + + /** + * @description - returns information about a channel + * @param {string} [options.channel] - channel address in caip, defaults to eth caip address + * @returns information about the channel if it exists + */ + info = async (channel?: string) => { + try { + this.checkUserAddressExists(channel); + channel = channel ?? getFallbackETHCAIPAddress(this.env!, this.account!); + return await PUSH_CHANNEL.getChannel({ + channel: channel as string, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::info : ${error}`); + } + }; + + /** + * @description - returns relevant information as per the query that was passed + * @param {string} query - search query + * @param {number} [options.page] - page number. default is set to Constants.PAGINATION.INITIAL_PAGE + * @param {number} [options.limit] - number of feeds per page. default is set to Constants.PAGINATION.LIMIT + * @returns Array of results relevant to the serach query + */ + search = async (query: string, options?: ChannelSearchOptions) => { + try { + const { + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + } = options || {}; + return await PUSH_CHANNEL.search({ + query: query, + page: page, + limit: limit, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::search : ${error}`); + } + }; + /** + * @description - Get subscribers of a channell + * @param {string} [options.channel] - channel in caip. defaults to account from signer with eth caip + * @returns array of subscribers + */ + subscribers = async (options?: ChannelInfoOptions) => { + try { + const { + channel = this.account + ? getFallbackETHCAIPAddress(this.env!, this.account!) + : null, + } = options || {}; + + this.checkUserAddressExists(channel!); + if (!validateCAIP(channel!)) { + throw new Error('Invalid CAIP'); + } + return await PUSH_CHANNEL._getSubscribers({ + channel: channel!, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::subscribers : ${error}`); + } + }; + /** + * + * @param {string[]} recipients - Array of recipients. `['0x1'] -> TARGET`, `['0x1, 0x2'] -> SUBSET`, `['*'] -> BROADCAST` + * @param {object} options - Notification options + * @returns + */ + send = async (recipients: string[], options: NotificationOptions) => { + try { + this.checkSignerObjectExists(); + const lowLevelPayload = this.generateNotificationLowLevelPayload({ + signer: this.signer!, + env: this.env!, + recipients: recipients, + options: options, + channel: options.channel ?? this.account, + }); + return await PUSH_PAYLOAD.sendNotification(lowLevelPayload); + } catch (error) { + throw new Error(`Push SDK Error: API : channel::send : ${error}`); + } + }; + + create = async (options: CreateChannelOptions) => { + const { + name, + description, + url, + icon, + alias = null, + progressHook, + } = options || {}; + try { + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + } else if ('signTypedData' in this.signer!) { + if (!this.coreContract.write) { + throw new Error('viem signer is not provided'); + } + } else { + throw new Error('Unsupported Signer'); + } + // create push token instance + let aliasInfo; + // validate all the parameters and length + this.validateChannelParameters(options); + // check for PUSH balance + const pushTokenContract = await this.createContractInstance( + config.TOKEN[this.env!], + config.ABIS.TOKEN, + config.TOKEN_VIEM_NETWORK_MAP[this.env!] + ); + const balance = await this.fetchBalance(pushTokenContract, this.account!); + const fees = ethers.utils.parseUnits( + config.MIN_TOKEN_BALANCE[this.env!].toString(), + 18 + ); + if (fees.gte(balance)) { + throw new Error('Insufficient PUSH balance'); + } + // if alias is passed, check for the caip + if (alias) { + if (!validateCAIP(alias)) { + throw new Error('Invalid alias CAIP'); + } + const aliasDetails = getCAIPDetails(alias); + aliasInfo = { + [`${aliasDetails?.blockchain}:${aliasDetails?.networkId}`]: + aliasDetails?.address, + }; + } + // construct channel identity + progressHook?.(PROGRESSHOOK['PUSH-CREATE-01'] as ProgressHookType); + const input = { + name: name, + info: description, + url: url, + icon: icon, + aliasDetails: aliasInfo ?? {}, + }; + const cid = await this.uploadToIPFSViaPushNode(JSON.stringify(input)); + const allowanceAmount = await this.fetchAllownace( + pushTokenContract, + this.account!, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT + ); + if (!allowanceAmount.gte(fees)) { + progressHook?.(PROGRESSHOOK['PUSH-CREATE-02'] as ProgressHookType); + const approvalRes = await this.approveToken( + pushTokenContract, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, + fees + ); + if (!approvalRes) { + throw new Error('Something went wrong while approving the token'); + } + } + // generate the contract parameters + const channelType = config.CHANNEL_TYPE['GENERAL']; + const identity = '1+' + cid; + const identityBytes = ethers.utils.toUtf8Bytes(identity); + // call contract + progressHook?.(PROGRESSHOOK['PUSH-CREATE-03'] as ProgressHookType); + const createChannelRes = await this.createChannel( + this.coreContract, + channelType, + identityBytes, + fees + ); + progressHook?.(PROGRESSHOOK['PUSH-CREATE-04'] as ProgressHookType); + return { transactionHash: createChannelRes }; + } catch (error) { + const errorProgressHook = PROGRESSHOOK[ + 'PUSH-ERROR-02' + ] as ProgressHookTypeFunction; + progressHook?.(errorProgressHook('Create Channel', error)); + throw new Error( + `Push SDK Error: Contract : createChannelWithPUSH : ${error}` + ); + } + }; + + update = async (options: CreateChannelOptions) => { + const { + name, + description, + url, + icon, + alias = null, + progressHook, + } = options || {}; + try { + // create push token instance + let aliasInfo; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + } else if ('signTypedData' in this.signer!) { + if (!this.coreContract.write) { + throw new Error('viem signer is not provided'); + } + } else { + throw new Error('Unsupported Signer'); + } + // validate all the parameters and length + this.validateChannelParameters(options); + // check for PUSH balance + const pushTokenContract = await this.createContractInstance( + config.TOKEN[this.env!], + config.ABIS.TOKEN, + config.TOKEN_VIEM_NETWORK_MAP[this.env!] + ); + const balance = await this.fetchBalance(pushTokenContract, this.account!); + const fees = ethers.utils.parseUnits( + config.MIN_TOKEN_BALANCE[this.env!].toString(), + 18 + ); + if (fees.gt(balance)) { + throw new Error('Insufficient PUSH balance'); + } + // if alias is passed, check for the caip + if (alias) { + if (!validateCAIP(alias)) { + throw new Error('Invalid alias CAIP'); + } + const aliasDetails = getCAIPDetails(alias); + aliasInfo = { + [`${aliasDetails?.blockchain}:${aliasDetails?.networkId}`]: + aliasDetails?.address, + }; + } + // construct channel identity + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-01'] as ProgressHookType); + const input = { + name: name, + info: description, + url: url, + icon: icon, + aliasDetails: aliasInfo ?? {}, + }; + const cid = await this.uploadToIPFSViaPushNode(JSON.stringify(input)); + // approve the tokens to core contract + const allowanceAmount = await this.fetchAllownace( + pushTokenContract, + this.account!, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT + ); + // if allowance is not greater than the fees, dont call approval again + if (!allowanceAmount.gte(fees)) { + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-02'] as ProgressHookType); + const approvalRes = await this.approveToken( + pushTokenContract, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, + fees + ); + if (!approvalRes) { + throw new Error('Something went wrong while approving the token'); + } + } + // generate the contract parameters + const identity = '1+' + cid; + const identityBytes = ethers.utils.toUtf8Bytes(identity); + // call contract + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-03'] as ProgressHookType); + const updateChannelRes = await this.updateChannel( + this.coreContract, + this.account!, + identityBytes, + fees + ); + progressHook?.(PROGRESSHOOK['PUSH-UPDATE-04'] as ProgressHookType); + return { transactionHash: updateChannelRes }; + } catch (error) { + const errorProgressHook = PROGRESSHOOK[ + 'PUSH-ERROR-02' + ] as ProgressHookTypeFunction; + progressHook?.(errorProgressHook('Update Channel', error)); + throw new Error(`Push SDK Error: Contract channel::update : ${error}`); + } + }; + /** + * @description verifies a channel + * @param {string} channelToBeVerified - address of the channel to be verified + * @returns the transaction hash if the transaction is successful + */ + verify = async (channelToBeVerified: string) => { + try { + this.checkSignerObjectExists(); + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + } else if ('signTypedData' in this.signer!) { + if (!this.coreContract.write) { + throw new Error('viem signer is not provided'); + } + } else { + throw new Error('Unsupported Signer'); + } + if (validateCAIP(channelToBeVerified)) { + channelToBeVerified = channelToBeVerified.split(':')[2]; + } + // checks if it is a valid address + if (!ethers.utils.isAddress(channelToBeVerified)) { + throw new Error('Invalid channel address'); + } + // if valid, continue with it + const res = await this.verifyChannel( + this.coreContract, + channelToBeVerified + ); + if (!res) { + throw new Error('Something went wrong while verifying the channel'); + } + return { transactionHash: res }; + } catch (error) { + throw new Error(`Push SDK Error: Contract channel::verify : ${error}`); + } + }; + + setting = async (configuration: NotificationSettings) => { + try { + this.checkSignerObjectExists(); + //TODO: create a separate function later + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + } else if ('signTypedData' in this.signer!) { + if (!this.coreContract.write) { + throw new Error('viem signer is not provided'); + } + } else { + throw new Error('Unsupported Signer'); + } + // check for PUSH balance + const pushTokenContract = await this.createContractInstance( + config.TOKEN[this.env!], + config.ABIS.TOKEN, + config.TOKEN_VIEM_NETWORK_MAP[this.env!] + ); + const balance = await this.fetchBalance(pushTokenContract, this.account!); + const fees = ethers.utils.parseUnits( + config.MIN_TOKEN_BALANCE[this.env!].toString(), + 18 + ); + if (fees.gte(balance)) { + throw new Error('Insufficient PUSH balance'); + } + const allowanceAmount = await this.fetchAllownace( + pushTokenContract, + this.account!, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT + ); + // if allowance is not greater than the fees, dont call approval again + if (!allowanceAmount.gte(fees)) { + const approveRes = this.approveToken( + pushTokenContract, + config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, + fees + ); + if (!approveRes) { + throw new Error('Something went wrong while approving your token'); + } + } + const { setting, description } = this.getMinimalSetting(configuration); + const createSettingsRes = await this.createChanelSettings( + this.coreContract, + configuration.length, + setting, + description, + fees + ); + return { transactionHash: createSettingsRes }; + } catch (error) { + throw new Error(`Push SDK Error: Contract : channel::setting : ${error}`); + } + }; +} diff --git a/packages/restapi/src/lib/pushNotification/delegate.ts b/packages/restapi/src/lib/pushNotification/delegate.ts new file mode 100644 index 000000000..1d2f31d87 --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/delegate.ts @@ -0,0 +1,112 @@ +import Constants, { ENV } from '../constants'; +import { SignerType } from '../types'; +import { ChannelInfoOptions } from './PushNotificationTypes'; +import CONFIG, * as config from '../config'; +import * as PUSH_CHANNEL from '../channels'; +import { validateCAIP, getFallbackETHCAIPAddress } from '../helpers'; +import { PushNotificationBaseClass } from './pushNotificationBase'; + +export class Delegate extends PushNotificationBaseClass { + constructor(signer?: SignerType, env?: ENV, account?: string) { + super(signer, env, account); + } + + /** + * @description - Get delegates of a channell + * @param {string} [options.channel] - channel in caip. defaults to account from signer with eth caip + * @returns array of delegates + */ + get = async (options?: ChannelInfoOptions) => { + try { + const { + channel = this.account + ? getFallbackETHCAIPAddress(this.env!, this.account!) + : null, + } = options || {}; + this.checkUserAddressExists(channel!); + if (!validateCAIP(channel!)) { + throw new Error('Invalid CAIP'); + } + return await PUSH_CHANNEL.getDelegates({ + channel: channel!, + env: this.env, + }); + } catch (error) { + throw new Error(`Push SDK Error: API : delegate::get : ${error}`); + } + }; + + /** + * @description adds a delegate + * @param {string} delegate - delegate address in caip to be added + * @returns the transaction hash if the transaction is successfull + */ + add = async (delegate: string) => { + try { + if (!validateCAIP(delegate)) { + throw new Error('Invalid CAIP'); + } + + const networkDetails = await this.getChianId(this.signer!); + if (networkDetails !== parseInt(delegate.split(':')[1])) { + return new Error('Signer and CAIP chain id doesnt match'); + } + const caip = `eip155:${networkDetails}`; + if (!CONFIG[this.env!][caip] || !config.VIEM_CONFIG[this.env!][caip]) { + throw new Error('Unsupported Chainid'); + } + const commAddress = CONFIG[this.env!][caip].EPNS_COMMUNICATOR_CONTRACT; + const commContract = this.createContractInstance( + commAddress, + config.ABIS.COMM, + config.VIEM_CONFIG[this.env!][caip].NETWORK + ); + const addDelegateRes = await this.addDelegator( + commContract, + delegate.split(':')[2] + ); + return { transactionHash: addDelegateRes }; + } catch (error) { + throw new Error(`Push SDK Error: Contract : delegate::add : ${error}`); + } + }; + + /** + * @description removes a delegate + * @param {string} delegate - caip address of the delegate to be removed + * @returns the transaction hash if the transaction is successfull + */ + remove = async (delegate: string) => { + try { + this.checkSignerObjectExists(); + if (this.signer && !this.signer.provider) { + throw new Error('Provider is required'); + } + if (!validateCAIP(delegate)) { + throw new Error('Invalid CAIP'); + } + + const networkDetails = await this.getChianId(this.signer!); + if (networkDetails !== parseInt(delegate.split(':')[1])) { + return new Error('Signer and CAIP chain id doesnt match'); + } + const caip = `eip155:${networkDetails}`; + if (!CONFIG[this.env!][caip] || !config.VIEM_CONFIG[this.env!][caip]) { + throw new Error('Unsupported Chainid'); + } + const commAddress = CONFIG[this.env!][caip].EPNS_COMMUNICATOR_CONTRACT; + const commContract = this.createContractInstance( + commAddress, + config.ABIS.COMM, + config.VIEM_CONFIG[this.env!][caip].NETWORK + ); + const removeDelegateRes = await this.removeDelegator( + commContract, + delegate.split(':')[2] + ); + return { transactionHash: removeDelegateRes }; + } catch (error) { + throw new Error(`Push SDK Error: Contract : delegate::remove : ${error}`); + } + }; +} diff --git a/packages/restapi/src/lib/pushNotification/notification.ts b/packages/restapi/src/lib/pushNotification/notification.ts new file mode 100644 index 000000000..2de0da631 --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/notification.ts @@ -0,0 +1,216 @@ +import Constants, { ENV } from '../constants'; +import { + SignerType, + ProgressHookType, + ProgressHookTypeFunction, +} from '../types'; +import { + ChannelInfoOptions, + SubscribeUnsubscribeOptions, + SubscriptionOptions, + AliasOptions, + FeedType, + FeedsOptions, + ChannelSearchOptions, + NotificationOptions, + CreateChannelOptions, + NotificationSettings, +} from './PushNotificationTypes'; +import CONFIG, * as config from '../config'; +import * as PUSH_USER from '../user'; +import * as PUSH_PAYLOAD from '../payloads'; +import * as PUSH_CHANNEL from '../channels'; +import * as PUSH_ALIAS from '../alias'; + +import { + getCAIPDetails, + getCAIPWithChainId, + validateCAIP, + getFallbackETHCAIPAddress, +} from '../helpers'; +import PROGRESSHOOK from '../progressHook'; +import { ethers } from 'ethers'; + +import { PushNotificationBaseClass } from './pushNotificationBase'; +// ERROR CONSTANTS +const ERROR_CHANNEL_NEEDED = 'Channel is needed'; +const ERROR_INVALID_CAIP = 'Invalid CAIP format'; + +export const FEED_MAP = { + INBOX: false, + SPAM: true, +}; +export class Notification extends PushNotificationBaseClass { + constructor(signer?: SignerType, env?: ENV, account?: string) { + super(signer, env, account); + } + + /** + * @description - Fetches feeds and spam feeds for a specific user + * @param {enums} spam - indicates if its a spam or not. `INBOX` for non-spam and `SPAM` for spam. default `INBOX` + * @param {string} [options.user] - user address, defaults to address from signer + * @param {number} [options.page] - page number. default is set to Constants.PAGINATION.INITIAL_PAGE + * @param {number} [options.limit] - number of feeds per page. default is set to Constants.PAGINATION.LIMIT + * @param {boolean} [options.raw] - indicates if the response should be raw or formatted. defaults is set to false + * @returns feeds for a specific address + */ + list = async ( + spam: `${FeedType}` = FeedType.INBOX, + options?: FeedsOptions + ) => { + const { + account = this.account + ? getFallbackETHCAIPAddress(this.env!, this.account!) + : null, + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + channels = [], + raw = false, + } = options || {}; + try { + // guest mode and valid address check + this.checkUserAddressExists(account!); + if (!validateCAIP(account!)) { + throw new Error('Invalid CAIP'); + } + const nonCaipAccount = + account?.split(':')[account?.split(':').length - 1]; + if (channels.length == 0) { + // else return the response + return await PUSH_USER.getFeeds({ + user: nonCaipAccount!, + page: page, + limit: limit, + spam: FEED_MAP[spam], + raw: raw, + env: this.env, + }); + } else { + return await PUSH_USER.getFeedsPerChannel({ + user: nonCaipAccount!, + page: page, + limit: limit, + spam: FEED_MAP[spam], + raw: raw, + env: this.env, + channels: channels, + }); + } + } catch (error) { + throw new Error(`Push SDK Error: API : notifcaiton::list : ${error}`); + } + }; + + subscriptions = async (options?: SubscriptionOptions) => { + try { + const { + account = this.account, + // TODO: to be used once pagination is implemeted at API level + page = Constants.PAGINATION.INITIAL_PAGE, + limit = Constants.PAGINATION.LIMIT, + } = options || {}; + this.checkUserAddressExists(account!); + return await PUSH_USER.getSubscriptions({ + user: account!, + env: this.env, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : notifcaiton::subscriptions : ${error}` + ); + } + }; + /** + * Subscribes a user to a channel + * @param {string} channel - channel address in caip format + * @param {function} [options.onSuccess] - callback function when a user successfully subscribes to a channel + * @param {function} [options.onError] - callback function incase a user was not able to subscribe to a channel + * @returns Subscribe status object + */ + subscribe = async ( + channel: string, + options?: SubscribeUnsubscribeOptions + ) => { + try { + const { onSuccess, onError } = options || {}; + // Vaidatiions + // validates if signer object is present + this.checkSignerObjectExists(); + // validates if the user address exists + this.checkUserAddressExists(); + // validates if channel exists + if (!channel && channel != '') { + throw new Error(ERROR_CHANNEL_NEEDED); + } + // validates if caip is correct + if (!validateCAIP(channel)) { + throw new Error(ERROR_INVALID_CAIP); + } + // get channel caip + const caipDetail = getCAIPDetails(channel); + // based on the caip, construct the user caip + const userAddressInCaip = getCAIPWithChainId( + this.account!, + parseInt(caipDetail?.networkId as string) + ); + return await PUSH_CHANNEL.subscribe({ + signer: this.signer!, + channelAddress: channel, + userAddress: userAddressInCaip, + env: this.env, + onSuccess: onSuccess, + onError: onError, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : notifcaiton::subscribe : ${error}` + ); + } + }; + + /** + * Unsubscribes a user to a channel + * @param {string} channel - channel address in caip format + * @param {function} [options.onSuccess] - callback function when a user successfully unsubscribes to a channel + * @param {function} [options.onError] - callback function incase a user was not able to unsubscribe to a channel + * @returns Unsubscribe status object + */ + unsubscribe = async ( + channel: string, + options?: SubscribeUnsubscribeOptions + ) => { + try { + const { onSuccess, onError } = options || {}; + // Vaidatiions + // validates if the user address exists + this.checkUserAddressExists(); + // validates if signer object is present + this.checkSignerObjectExists(); + // validates if channel exists + if (!channel && channel != '') { + return new Error(ERROR_CHANNEL_NEEDED); + } + // validates if caip is correct + if (!validateCAIP(channel)) { + return new Error(ERROR_INVALID_CAIP); + } + const caipDetail = getCAIPDetails(channel); + const userAddressInCaip = getCAIPWithChainId( + this.account!, + parseInt(caipDetail?.networkId as string) + ); + return await PUSH_CHANNEL.unsubscribe({ + signer: this.signer!, + channelAddress: channel, + userAddress: userAddressInCaip, + env: this.env, + onSuccess: onSuccess, + onError: onError, + }); + } catch (error) { + throw new Error( + `Push SDK Error: API : notifcaiton::unsubscribe : ${error}` + ); + } + }; +} diff --git a/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts b/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts new file mode 100644 index 000000000..59fc4df4d --- /dev/null +++ b/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts @@ -0,0 +1,662 @@ +import { ENV } from '../constants'; +import { SignerType, ISendNotificationInputOptions } from '../types'; +import { + NotificationOptions, + CreateChannelOptions, + NotificationSettings, +} from './PushNotificationTypes'; +import CONFIG, * as config from '../config'; +import { getAccountAddress } from '../chat/helpers'; +import { IDENTITY_TYPE, NOTIFICATION_TYPE } from '../payloads/constants'; +import { ethers, Signer, BigNumber } from 'ethers'; +import axios from 'axios'; +import { + createPublicClient, + http, + getContract, + WalletClient, + Chain, +} from 'viem'; + +// ERROR CONSTANTS +const ERROR_ACCOUNT_NEEDED = 'Account is required'; +const ERROR_SIGNER_NEEDED = 'Signer object is required'; + +const BROADCAST_TYPE = '*'; +const LENGTH_UPPER_LIMIT = 125; +const LENGTH_LOWER_LIMTI = 1; +const SETTING_DELIMITER = '-'; +const SETTING_SEPARATOR = '+'; + +export const FEED_MAP = { + INBOX: false, + SPAM: true, +}; +export class PushNotificationBaseClass { + protected signer: SignerType | undefined; + protected account: string | undefined; + protected env: ENV | undefined; + protected guestMode: boolean; + protected coreContract: any; + + constructor(signer?: SignerType, env?: ENV, account?: string) { + this.signer = signer; + this.env = env; + this.guestMode = !!(account && signer); + this.account = account; + this.initializeCoreContract({ signer: this.signer, env: this.env }); + } + + private async initializeCoreContract(options?: { + signer?: SignerType; + env?: ENV; + }) { + const { env = ENV.STAGING, signer = null } = options || {}; + // Derives account from signer if not provided + let derivedAccount; + let coreContract; + if (signer) { + if (!('_signTypedData' in signer!) && !('signTypedData' in signer!)) { + throw new Error('Unsupported signer type'); + } else if ('_signTypedData' in signer) { + derivedAccount = await getAccountAddress({ + account: null, + signer: signer, + }); + if (signer?.provider) { + coreContract = new ethers.Contract( + config.CORE_CONFIG[env].EPNS_CORE_CONTRACT, + config.ABIS.CORE, + signer as unknown as Signer + ); + } + } else if ('signTypedData' in signer) { + derivedAccount = await getAccountAddress({ + account: null, + signer: signer, + }); + const client = createPublicClient({ + chain: config.TOKEN_VIEM_NETWORK_MAP[env], + transport: http(), + }); + coreContract = getContract({ + abi: config.ABIS.CORE, + address: config.CORE_CONFIG[env].EPNS_CORE_CONTRACT as `0x${string}`, + publicClient: client, + walletClient: signer as unknown as WalletClient, + }); + } + } + + // Initialize PushNotifications instance + this.coreContract = coreContract; + } + + // check if addresses is supplied either by user or derived from signer object or if its guest mode + protected checkUserAddressExists(user?: string) { + if (!user && !this.account && !this.guestMode) + throw new Error(ERROR_ACCOUNT_NEEDED); + return true; + } + + // checks if the signer object is supplied + protected checkSignerObjectExists() { + if (!this.signer) throw new Error(ERROR_SIGNER_NEEDED); + return true; + } + + // get type of notification from recipient + protected getNotificationType( + recipient: string[], + channel: string + ): { recipient: string[] | string; type: number } { + if (recipient.length == 1) { + if (recipient[0] == BROADCAST_TYPE) { + return { recipient: channel, type: NOTIFICATION_TYPE['BROADCAST'] }; + } else { + return { + recipient: recipient[0], + type: NOTIFICATION_TYPE['TARGETTED'], + }; + } + } + return { recipient, type: NOTIFICATION_TYPE['SUBSET'] }; + } + + // get identity type for lowlevel call + protected generateNotificationLowLevelPayload({ + signer, + env, + recipients, + options, + channel, + }: { + signer: SignerType; + env: ENV; + recipients: string[]; + options: NotificationOptions; + channel?: string; + }): ISendNotificationInputOptions { + if (!channel) { + channel = `${this.account}`; + } + const notificationType = this.getNotificationType(recipients, channel); + const identityType = IDENTITY_TYPE.DIRECT_PAYLOAD; + const notificationPayload: ISendNotificationInputOptions = { + signer: signer, + channel: channel, + type: notificationType.type, + identityType: identityType, + notification: options.notification, + payload: { + title: options.payload?.title ?? options.notification.title, + body: options.payload?.body ?? options.notification.body, + cta: options.payload?.cta ?? '', + img: options.payload?.embed ?? '', + hidden: options.config?.hidden, + etime: options.config?.expiry, + silent: options.config?.silent, + additionalMeta: options.payload?.meta, + }, + recipients: notificationType.recipient, + graph: options.advanced?.graph, + ipfsHash: options.advanced?.ipfs, + env: env, + chatId: options.advanced?.chatid, + pgpPrivateKey: options.advanced?.pgpPrivateKey, + }; + + return notificationPayload; + } + + // check if the fields are empty + protected isEmpty(field: string) { + if (field.trim().length == 0) { + return true; + } + + return false; + } + + // check if the length is valid + protected isValidLength( + data: string, + upperLen: number = LENGTH_UPPER_LIMIT, + lowerLen: number = LENGTH_LOWER_LIMTI + ): boolean { + return data.length >= lowerLen && data.length <= upperLen!; + } + + // check if url is valid + protected isValidUrl(urlString: string): boolean { + const urlPattern = new RegExp( + '^((?:https|http):\\/\\/)' + // validate protocol + '((([a-z\\d]([a-z\\d-]*[a-z\\d])*)\\.)+[a-z]{2,}|' + // validate domain name + '((\\d{1,3}\\.){3}\\d{1,3}))' + // validate OR ip (v4) address + '(\\:\\d+)?(\\/[-a-z\\d%_.~+]*)*' + // validate port and path + '(\\?[;&a-z\\d%_.~+=-]*)?' + // validate query string + '(\\#[-a-z\\d_]*)?$', + 'i' + ); // validate fragment locator + return !!urlPattern.test(urlString); + } + + // check all the fields of channel + protected verifyEmptyChannelParameters( + options: CreateChannelOptions + ): boolean { + if (this.isEmpty(options.name)) { + throw new Error('Channel name cannot be empty'); + } else if (this.isEmpty(options.description)) { + throw new Error('Channel description cannot be empty'); + } else if (this.isEmpty(options.icon)) { + throw new Error('Channel icon cannot be empty'); + } else if (this.isEmpty(options.url)) { + throw new Error('Channel url cannot ne empty'); + } else { + return true; + } + } + + // check for valid length and url + protected validateParameterLength(options: CreateChannelOptions): boolean { + if (!this.isValidLength(options.name)) { + throw new Error( + `Channel name should not exceed ${LENGTH_UPPER_LIMIT} characters` + ); + } else if (!this.isValidLength(options.description)) { + throw new Error( + `Channel description should not exceed ${LENGTH_UPPER_LIMIT} characters` + ); + } else if ( + !this.isValidLength(options.url) || + !this.isValidUrl(options.url) + ) { + throw new Error( + `Channel url either excees ${LENGTH_UPPER_LIMIT} characters or is not a valid url` + ); + } else { + return true; + } + } + + protected validateChannelParameters(options: CreateChannelOptions): boolean { + return ( + this.verifyEmptyChannelParameters(options) && + this.validateParameterLength(options) + ); + } + + // create contract instance + protected createContractInstance( + contractAddress: string | `0x${string}`, + contractABI: any, + network: Chain + ) { + let contract: any; + if ( + !('_signTypedData' in this.signer!) && + !('signTypedData' in this.signer!) + ) { + throw new Error('Unsupported signer type'); + } else if ('_signTypedData' in this.signer) { + if (!this.signer?.provider) { + throw new Error('Provider is required'); + } + contract = new ethers.Contract( + contractAddress, + contractABI, + this.signer as unknown as Signer + ); + } else if ('signTypedData' in this.signer) { + const client = createPublicClient({ + chain: network, + transport: http(), + }); + contract = getContract({ + abi: contractABI, + address: contractAddress as `0x${string}`, + publicClient: client, + walletClient: this.signer as unknown as WalletClient, + }); + } else { + throw new Error('Unsupported signer type'); + } + return contract; + } + + protected async fetchBalance(contract: any, userAddress: string) { + let balance: BigNumber; + try { + if ('_signTypedData' in this.signer!) { + balance = await contract!['balanceOf'](userAddress); + } else if ('signTypedData' in this.signer!) { + const balanceInBigInt = await contract.read.balanceOf({ + args: [userAddress], + }); + balance = ethers.BigNumber.from(balanceInBigInt); + } else { + throw new Error('Unsupported signer'); + } + return balance; + } catch (error) { + console.log(error); + throw new Error(JSON.stringify(error)); + } + } + + protected async fetchAllownace( + contract: any, + userAddress: string, + spenderAddress: string + ) { + let allowance: BigNumber; + try { + if ('_signTypedData' in this.signer!) { + allowance = await contract!['allowance'](userAddress, spenderAddress); + } else if ('signTypedData' in this.signer!) { + const allowanceInBigInt = await contract.read.allowance({ + args: [userAddress, spenderAddress], + }); + allowance = ethers.BigNumber.from(allowanceInBigInt); + } else { + throw new Error('Unsupported signer'); + } + return allowance; + } catch (error) { + throw new Error(JSON.stringify(error)); + } + } + + protected async approveToken( + contract: any, + spenderAddress: string, + amount: string | BigNumber + ) { + try { + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const approvalTrxPromise = contract!['approve'](spenderAddress, amount); + const approvalTrx = await approvalTrxPromise; + await this.signer?.provider?.waitForTransaction(approvalTrx.hash); + // console.log(approvalTrx.hash) + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const approvalTrxPromise = contract.write.approve({ + args: [spenderAddress, amount], + }); + const approvalTrxRes = await approvalTrxPromise; + // console.log(approvalTrxRes); + } else { + throw new Error('Unsupported signer'); + } + return true; + } catch (error) { + console.log(error); + return false; + } + } + + protected async createChannel( + contract: any, + channelType: number, + identityBytes: Uint8Array, + fees: BigNumber + ) { + let createChannelRes; + try { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + if ('_signTypedData' in this.signer!) { + const createChannelPromise = contract!['createChannelWithPUSH']( + channelType, + identityBytes, + fees, + this.getTimeBound(), + { + gasLimit: 1000000, + } + ); + const createChannelTrx = await createChannelPromise; + const createChannelTrxStatus = + await this.signer?.provider?.waitForTransaction( + createChannelTrx.hash + ); + if (createChannelTrxStatus?.status == 0) { + throw new Error('Something Went wrong while creating your channel'); + } + createChannelRes = createChannelTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const createChannelPromise = contract.write.createChannelWithPUSH({ + args: [channelType, identityBytes, fees, this.getTimeBound()], + }); + createChannelRes = await createChannelPromise; + } + + return createChannelRes; + } catch (error: any) { + throw new Error(error?.message); + } + } + + protected async updateChannel( + contract: any, + account: string, + identityBytes: Uint8Array, + fees: BigNumber + ) { + let updateChannelRes; + try { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + if ('_signTypedData' in this.signer!) { + const updateChannelPromise = contract!['updateChannelMeta']( + account, + identityBytes, + fees, + { + gasLimit: 1000000, + } + ); + const updateChannelTrx = await updateChannelPromise; + const updateChannelTrxStatus = + await this.signer?.provider?.waitForTransaction( + updateChannelTrx.hash + ); + if (updateChannelTrxStatus?.status == 0) { + throw new Error('Something Went wrong while updating your channel'); + } + updateChannelRes = updateChannelTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const updateChannelPromise = contract.write.createChannelWithPUSH({ + args: [account, identityBytes, fees], + }); + updateChannelRes = await updateChannelPromise; + } + + return updateChannelRes; + } catch (error: any) { + throw new Error(error?.message); + } + } + + protected async verifyChannel(contract: any, channelToBeVerified: string) { + try { + let verifyTrxRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const verifyTrxPromise = contract!['verify'](channelToBeVerified); + const verifyTrx = await verifyTrxPromise; + await this.signer?.provider?.waitForTransaction(verifyTrx.hash); + verifyTrxRes = verifyTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const verifyTrxPromise = contract.write.verify({ + args: [channelToBeVerified], + }); + verifyTrxRes = await verifyTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return verifyTrxRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + protected async createChanelSettings( + contract: any, + numberOfSettings: number, + settings: string, + description: string, + fees: BigNumber + ) { + try { + let createSettingsRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const createSettingsPromise = contract!['createChannelSettings']( + numberOfSettings, + settings, + description, + fees + ); + const createSettings = await createSettingsPromise; + await this.signer?.provider?.waitForTransaction(createSettings.hash); + createSettingsRes = createSettings.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const createSettingsTrxPromise = contract.write.createChannelSettings({ + args: [numberOfSettings, settings, description, fees], + }); + createSettingsRes = await createSettingsTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return createSettingsRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + protected async addDelegator(contract: any, delegatee: string) { + try { + let addDelegateRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const addDelegateTrxPromise = contract!['addDelegate'](delegatee); + const addDelegateTrx = await addDelegateTrxPromise; + await this.signer?.provider?.waitForTransaction(addDelegateTrx.hash); + addDelegateRes = addDelegateTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const addDelegateTrxPromise = contract.write.addDelegate({ + args: [delegatee], + }); + addDelegateRes = await addDelegateTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return addDelegateRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + protected async removeDelegator(contract: any, delegatee: string) { + try { + let removeDelegateRes; + if ('_signTypedData' in this.signer!) { + if (!this.signer || !this.signer.provider) { + throw new Error('ethers provider/signer is not provided'); + } + const removeDelegateTrxPromise = contract!['removeDelegate'](delegatee); + const removeDelegateTrx = await removeDelegateTrxPromise; + await this.signer?.provider?.waitForTransaction(removeDelegateTrx.hash); + removeDelegateRes = removeDelegateTrx.hash; + } else if ('signTypedData' in this.signer!) { + if (!contract.write) { + throw new Error('viem signer is not provided'); + } + const removeDelegateTrxPromise = contract.write.removeDelegate({ + args: [delegatee], + }); + removeDelegateRes = await removeDelegateTrxPromise; + } else { + throw new Error('Unsupported signer'); + } + return removeDelegateRes; + } catch (error: any) { + throw new Error(error.message); + } + } + + protected async getChianId(signer: SignerType) { + let chainId; + const isProviderExists = await this.checkProvider(signer); + if (!isProviderExists) { + throw new Error('Provider doesnt exists'); + } + if ('_signTypedData' in signer!) { + const chainDetails = await signer?.provider?.getNetwork(); + chainId = chainDetails?.chainId; + } else if ('signTypedData' in signer!) { + chainId = await signer.getChainId(); + } + return chainId; + } + + protected async checkProvider(signer: SignerType) { + let res = false; + if ('_signTypedData' in signer!) { + res = signer && signer?.provider ? true : false; + } else if ('signTypedData' in signer!) { + const chainId = await signer.getChainId(); + res = !!chainId; + } + return res; + } + + protected async uploadToIPFSViaPushNode(data: string): Promise { + try { + const response = await axios.post( + `${config.CORE_CONFIG[this.env!].API_BASE_URL}/v1/ipfs/upload`, + { data } + ); + return response.data.cid as string; + } catch (error) { + throw new Error('Something went wrong while uploading data to IPFS'); + } + } + + protected getTimeBound(timeStamp?: number) { + // for now returns 0 for non-time bound. Later it can be modified to handle time bound channels + return 0; + } + + protected getMinimalSetting(configuration: NotificationSettings): { + setting: string; + description: string; + } { + let notificationSetting = ''; + let notificationSettingDescription = ''; + for (let i = 0; i < configuration.length; i++) { + const ele = configuration[i]; + if (ele.type == 0) { + notificationSetting = + notificationSetting + + SETTING_SEPARATOR + + ele.type + + SETTING_DELIMITER + + ele.default; + notificationSettingDescription = + notificationSettingDescription + ele.description; + } + if (ele.type == 1) { + if (ele.data) { + notificationSetting = + notificationSetting + + SETTING_SEPARATOR + + ele.type + + SETTING_DELIMITER + + ele.default + + SETTING_DELIMITER + + ele.data.lower + + SETTING_DELIMITER + + ele.data.upper; + + notificationSettingDescription = + notificationSettingDescription + ele.description; + } + } + } + return { + setting: notificationSetting.replace(/^\+/, ''), + description: notificationSettingDescription, + }; + } +} diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index f47ee89cc..71665b4b5 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -1,31 +1,18 @@ -import Constants, { ENCRYPTION_TYPE, ENV, MessageType } from '../constants'; -import { - ChatSendOptionsType, - GroupAccess, - GroupDTO, - IFeeds, - MessageWithCID, - SignerType, - Message, - ProgressHookType, - IUser, -} from '../types'; -import { - GroupUpdateOptions, - ChatListType, - GroupCreationOptions, - ManageGroupOptions, - PushAPIInitializeProps, -} from './pushAPITypes'; +import Constants, { ENV } from '../constants'; +import { SignerType, ProgressHookType } from '../types'; +import { PushAPIInitializeProps } from './pushAPITypes'; import * as PUSH_USER from '../user'; import * as PUSH_CHAT from '../chat'; -import { getAccountAddress, getUserDID, getWallet } from '../chat/helpers'; -import { isValidETHAddress } from '../helpers'; -import { - ChatUpdateGroupProfileType, - updateGroupProfile, -} from '../chat/updateGroupProfile'; - +import { getAccountAddress, getWallet } from '../chat/helpers'; +import { Chat } from './chat'; +import { Profile } from './profile'; +import { Encryption } from './encryption'; +import { User } from './user'; +import { PushStream } from '../pushstream/PushStream'; +import { Channel } from '../pushNotification/channel'; +import { Alias } from '../pushNotification/alias'; +import { Delegate } from '../pushNotification/delegate'; +import { Notification } from '../pushNotification/notification'; export class PushAPI { private signer: SignerType; private account: string; @@ -34,6 +21,17 @@ export class PushAPI { private env: ENV; private progressHook?: (progress: ProgressHookType) => void; + public chat: Chat; // Public instances to be accessed from outside the class + public profile: Profile; + public encryption: Encryption; + public user: User; + public stream!: PushStream; + // Notification + public channel!: Channel; + public alias!: Alias; + public delegate!: Delegate; + public notification!: Notification; + private constructor( signer: SignerType, env: ENV, @@ -48,541 +46,142 @@ export class PushAPI { this.decryptedPgpPvtKey = decryptedPgpPvtKey; this.pgpPublicKey = pgpPublicKey; this.progressHook = progressHook; - + // Instantiate the notification classes + this.channel = new Channel( + this.signer, + this.env, + this.account + ) + this.alias = new Alias( + this.env + ) + this.delegate = new Delegate( + this.signer, + this.env, + this.account + ) + this.notification = new Notification( + this.signer, + this.env, + this.account + ) + // Initialize the instances of the four classes + this.chat = new Chat( + this.account, + this.decryptedPgpPvtKey, + this.env, + this.signer, + this.progressHook + ); + this.profile = new Profile( + this.account, + this.decryptedPgpPvtKey, + this.env, + this.progressHook + ); + this.encryption = new Encryption( + this.account, + this.decryptedPgpPvtKey, + this.pgpPublicKey, + this.env, + this.signer, + this.progressHook + ); + this.user = new User(this.account, this.env); } static async initialize( signer: SignerType, options?: PushAPIInitializeProps ): Promise { - // Default options - const defaultOptions: PushAPIInitializeProps = { - env: ENV.STAGING, - version: Constants.ENC_TYPE_V3, - autoUpgrade: true, - account: null, - }; - - // Settings object - // Default options are overwritten by the options passed in the initialize method - const settings = { - ...defaultOptions, - ...options, - }; - - // Get account - // Derives account from signer if not provided - const derivedAccount = await getAccountAddress( - getWallet({ - account: settings.account as string | null, - signer: signer, - }) - ); - - let decryptedPGPPrivateKey: string; - let pgpPublicKey: string; - - /** - * Decrypt PGP private key - * If user exists, decrypts the PGP private key - * If user does not exist, creates a new user and returns the decrypted PGP private key - */ - const user = await PUSH_USER.get({ - account: derivedAccount, - env: settings.env, - }); - if (user && user.encryptedPrivateKey) { - decryptedPGPPrivateKey = await PUSH_CHAT.decryptPGPKey({ - encryptedPGPPrivateKey: user.encryptedPrivateKey, - signer: signer, - toUpgrade: settings.autoUpgrade, - additionalMeta: settings.versionMeta, - progressHook: settings.progressHook, - env: settings.env, - }); - pgpPublicKey = user.publicKey; - } else { - const newUser = await PUSH_USER.create({ - env: settings.env, - account: derivedAccount, - signer, - version: settings.version, - additionalMeta: settings.versionMeta, - origin: settings.origin, - progressHook: settings.progressHook, - }); - decryptedPGPPrivateKey = newUser.decryptedPrivateKey as string; - pgpPublicKey = newUser.publicKey; - } - - // Initialize PushAPI instance - return new PushAPI( - signer, - settings.env as ENV, - derivedAccount, - decryptedPGPPrivateKey, - pgpPublicKey, - settings.progressHook - ); - } - - info = async () => { - return await PUSH_USER.get({ - account: this.account, - env: this.env, - }); - }; - - profile = { - info: async () => { - const response = await PUSH_USER.get({ - account: this.account, - env: this.env, - }); - return response.profile; - }, - - update: async (options: { - name?: string; - desc?: string; - picture?: string; - }) => { - const { name, desc, picture } = options; - const response = await PUSH_USER.profile.update({ - pgpPrivateKey: this.decryptedPgpPvtKey, - account: this.account, - profile: { - name: name, - desc: desc, - picture: picture, - }, - env: this.env, - progressHook: this.progressHook, - }); - return response.profile; - }, - }; - - chat = { - list: async ( - type: `${ChatListType}`, - options?: { - /** - * @default 1 - */ - page?: number; - limit?: number; - } - ): Promise => { - const listParams = { - account: this.account, - pgpPrivateKey: this.decryptedPgpPvtKey, - page: options?.page, - limit: options?.limit, - env: this.env, - toDecrypt: true, + try { + // Default options + const defaultOptions: PushAPIInitializeProps = { + env: ENV.STAGING, + version: Constants.ENC_TYPE_V3, + autoUpgrade: true, + account: null, }; - switch (type) { - case ChatListType.CHATS: - return await PUSH_CHAT.chats(listParams); - case ChatListType.REQUESTS: - return await PUSH_CHAT.requests(listParams); - default: - throw new Error('Invalid Chat List Type'); - } - }, - - latest: async (target: string) => { - const { threadHash } = await PUSH_CHAT.conversationHash({ - conversationId: target, - account: this.account, - env: this.env, - }); - if (!threadHash) return {}; - - return await PUSH_CHAT.latest({ - threadhash: threadHash, - toDecrypt: true, - pgpPrivateKey: this.decryptedPgpPvtKey, - account: this.account, - env: this.env, - }); - }, - - history: async ( - target: string, - options?: { - reference?: string | null; - limit?: number; - } - ) => { - let reference: string; - - if (!options?.reference) { - const { threadHash } = await PUSH_CHAT.conversationHash({ - conversationId: target, - account: this.account, - env: this.env, - }); - reference = threadHash; - } else { - reference = options.reference; - } - - if (!reference) return []; - - return await PUSH_CHAT.history({ - account: this.account, - env: this.env, - threadhash: reference, - pgpPrivateKey: this.decryptedPgpPvtKey, - toDecrypt: true, - limit: options?.limit, - }); - }, - - send: async ( - recipient: string, - options: Message - ): Promise => { - if (!options.type) { - options.type = MessageType.TEXT; - } - const sendParams: ChatSendOptionsType = { - message: options, - to: recipient, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - env: this.env, + // Settings object + // Default options are overwritten by the options passed in the initialize method + const settings = { + ...defaultOptions, + ...options, }; - return await PUSH_CHAT.send(sendParams); - }, - - accept: async (target: string): Promise => { - return await PUSH_CHAT.approve({ - senderAddress: target, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - }, - - reject: async (target: string): Promise => { - await PUSH_CHAT.reject({ - senderAddress: target, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - }, - block: async (users: Array): Promise => { - const user = await PUSH_USER.get({ - account: this.account, - env: this.env, - }); - - for (const element of users) { - if (!isValidETHAddress(element)) { - throw new Error('Invalid address in the users: ' + element); - } - } - - if (!user.profile.blockedUsersList) { - user.profile.blockedUsersList = []; - } - - user.profile.blockedUsersList = [ - ...new Set([...user.profile.blockedUsersList, ...users]), - ]; + // Get account + // Derives account from signer if not provided + const derivedAccount = await getAccountAddress( + getWallet({ + account: settings.account as string | null, + signer: signer, + }) + ); - return await PUSH_USER.profile.update({ - pgpPrivateKey: this.decryptedPgpPvtKey, - account: this.account, - profile: { - name: user.profile.name!, - desc: user.profile.desc!, - picture: user.profile.picture!, - blockedUsersList: user.profile.blockedUsersList, - }, - env: this.env, - progressHook: this.progressHook, - }); - }, + let decryptedPGPPrivateKey: string; + let pgpPublicKey: string; - unblock: async (users: Array): Promise => { + /** + * Decrypt PGP private key + * If user exists, decrypts the PGP private key + * If user does not exist, creates a new user and returns the decrypted PGP private key + */ const user = await PUSH_USER.get({ - account: this.account, - env: this.env, - }); - - for (const element of users) { - if (!isValidETHAddress(element)) { - throw new Error('Invalid address in the users: ' + element); - } - } - - if (!user.profile.blockedUsersList) { - return user; - } - - const userDIDsPromises = users.map(async (user) => { - return (await getUserDID(user, this.env)).toLowerCase(); - }); - const userDIDs = await Promise.all(userDIDsPromises); - - user.profile.blockedUsersList = user.profile.blockedUsersList.filter( - (blockedUser) => { - !userDIDs.includes(blockedUser.toLowerCase()); - } - ); - - return await PUSH_USER.profile.update({ - pgpPrivateKey: this.decryptedPgpPvtKey, - account: this.account, - profile: { - name: user.profile.name!, - desc: user.profile.desc!, - picture: user.profile.picture!, - blockedUsersList: user.profile.blockedUsersList, - }, - env: this.env, - progressHook: this.progressHook, + account: derivedAccount, + env: settings.env, }); - }, - - group: { - create: async (name: string, options?: GroupCreationOptions) => { - const groupParams: PUSH_CHAT.ChatCreateGroupType = { - groupName: name, - groupDescription: options?.description, - members: options?.members ? options.members : [], - groupImage: options?.image, - admins: options?.admins ? options.admins : [], - rules: { - entry: options?.rules?.entry, - chat: options?.rules?.chat, - }, - isPublic: !options?.private, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - env: this.env, - }; - - return await PUSH_CHAT.createGroup(groupParams); - }, - - permissions: async (chatId: string): Promise => { - const getGroupAccessOptions: PUSH_CHAT.GetGroupAccessType = { - chatId, - did: this.account, - env: this.env, - }; - return await PUSH_CHAT.getGroupAccess(getGroupAccessOptions); - }, - - info: async (chatId: string): Promise => { - return await PUSH_CHAT.getGroup({ - chatId: chatId, - env: this.env, - }); - }, - - update: async ( - chatId: string, - options: GroupUpdateOptions - ): Promise => { - // Fetch Group Details - const group = await PUSH_CHAT.getGroup({ - chatId: chatId, - env: this.env, - }); - if (!group) { - throw new Error('Group not found'); - } - - const updateGroupProfileOptions: ChatUpdateGroupProfileType = { - chatId: chatId, - groupName: options.name ? options.name : group.groupName, - groupImage: options.image ? options.image : group.groupImage, - groupDescription: options.description - ? options.description - : group.groupDescription, - scheduleAt: options.scheduleAt - ? options.scheduleAt - : group.scheduleAt, - scheduleEnd: options.scheduleEnd - ? options.scheduleEnd - : group.scheduleEnd, - status: options.status ? options.status : group.status, - meta: options.meta ? options.meta : group.meta, - rules: options.rules ? options.rules : group.rules, - account: this.account, - pgpPrivateKey: this.decryptedPgpPvtKey, - env: this.env, - }; - return await updateGroupProfile(updateGroupProfileOptions); - }, - - add: async (chatId: string, options: ManageGroupOptions) => { - const { role, accounts } = options; - - const validRoles = ['ADMIN', 'MEMBER']; - if (!validRoles.includes(role)) { - throw new Error('Invalid role provided.'); - } - - if (!accounts || accounts.length === 0) { - throw new Error('accounts array cannot be empty!'); - } - - accounts.forEach((account) => { - if (!isValidETHAddress(account)) { - throw new Error(`Invalid account address: ${account}`); - } + if (user && user.encryptedPrivateKey) { + decryptedPGPPrivateKey = await PUSH_CHAT.decryptPGPKey({ + encryptedPGPPrivateKey: user.encryptedPrivateKey, + signer: signer, + toUpgrade: settings.autoUpgrade, + additionalMeta: settings.versionMeta, + progressHook: settings.progressHook, + env: settings.env, }); - - if (role === 'ADMIN') { - return await PUSH_CHAT.addAdmins({ - chatId: chatId, - admins: accounts, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - } else { - return await PUSH_CHAT.addMembers({ - chatId: chatId, - members: accounts, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - } - }, - - remove: async (chatId: string, options: ManageGroupOptions) => { - const { role, accounts } = options; - - const validRoles = ['ADMIN', 'MEMBER']; - if (!validRoles.includes(role)) { - throw new Error('Invalid role provided.'); - } - - if (!accounts || accounts.length === 0) { - throw new Error('accounts array cannot be empty!'); - } - - accounts.forEach((account) => { - if (!isValidETHAddress(account)) { - throw new Error(`Invalid account address: ${account}`); - } - }); - - if (role === 'ADMIN') { - return await PUSH_CHAT.removeAdmins({ - chatId: chatId, - admins: accounts, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - } else { - return await PUSH_CHAT.removeMembers({ - chatId: chatId, - members: accounts, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - } - }, - - join: async (target: string): Promise => { - return await PUSH_CHAT.addMembers({ - chatId: target, - members: [this.account], - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - }, - - leave: async (target: string): Promise => { - return await PUSH_CHAT.removeMembers({ - chatId: target, - members: [this.account], - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, - }); - }, - - reject: async (target: string): Promise => { - await PUSH_CHAT.reject({ - senderAddress: target, - env: this.env, - account: this.account, - signer: this.signer, - pgpPrivateKey: this.decryptedPgpPvtKey, + pgpPublicKey = user.publicKey; + } else { + const newUser = await PUSH_USER.create({ + env: settings.env, + account: derivedAccount, + signer, + version: settings.version, + additionalMeta: settings.versionMeta, + origin: settings.origin, + progressHook: settings.progressHook, }); - }, - }, - }; - - encryption = { - info: async () => { - const userInfo = await this.info(); - const decryptedPassword = await PUSH_USER.decryptAuth({ - account: this.account, - env: this.env, - signer: this.signer, - progressHook: this.progressHook, - additionalMeta: { - NFTPGP_V1: { - encryptedPassword: JSON.stringify( - JSON.parse(userInfo.encryptedPrivateKey).encryptedPassword - ), - }, - }, - }); + decryptedPGPPrivateKey = newUser.decryptedPrivateKey as string; + pgpPublicKey = newUser.publicKey; + } - return { - decryptedPgpPrivateKey: this.decryptedPgpPvtKey, - pgpPublicKey: this.pgpPublicKey, - ...(decryptedPassword !== undefined && decryptedPassword !== null - ? { decryptedPassword: decryptedPassword } - : {}), - }; - }, + // Initialize PushAPI instance + const api = new PushAPI( + signer, + settings.env as ENV, + derivedAccount, + decryptedPGPPrivateKey, + pgpPublicKey, + settings.progressHook + ); - update: async ( - updatedEncryptionType: ENCRYPTION_TYPE, - options?: { - versionMeta?: { - NFTPGP_V1?: { password: string }; - }; + const streamInstance = await PushStream.initialize( + api.account, + decryptedPGPPrivateKey, + signer, + settings.progressHook, + settings.streamOptions + ); + if (streamInstance) { + api.stream = streamInstance; + } else { + throw new Error('Failed to initialize PushStream.'); } - ) => { - return await PUSH_USER.auth.update({ - account: this.account, - pgpEncryptionVersion: updatedEncryptionType, - additionalMeta: options?.versionMeta, - progressHook: this.progressHook, - signer: this.signer, - env: this.env, - pgpPrivateKey: this.decryptedPgpPvtKey, - pgpPublicKey: this.pgpPublicKey, - }); - }, - }; -} \ No newline at end of file + + return api; + } catch (error) { + console.error('Error initializing PushAPI:', error); + throw error; // or handle it more gracefully if desired + } + } +} diff --git a/packages/restapi/src/lib/pushapi/chat.ts b/packages/restapi/src/lib/pushapi/chat.ts new file mode 100644 index 000000000..7eaccda38 --- /dev/null +++ b/packages/restapi/src/lib/pushapi/chat.ts @@ -0,0 +1,449 @@ +import { ENV, MessageType } from '../constants'; +import { + ChatSendOptionsType, + GroupAccess, + GroupDTO, + IFeeds, + MessageWithCID, + SignerType, + Message, + ProgressHookType, + IUser, + IMessageIPFS, +} from '../types'; +import { + GroupUpdateOptions, + ChatListType, + GroupCreationOptions, + ManageGroupOptions, +} from './pushAPITypes'; +import * as PUSH_USER from '../user'; +import * as PUSH_CHAT from '../chat'; +import { getUserDID } from '../chat/helpers'; +import { isValidETHAddress } from '../helpers'; +import { + ChatUpdateGroupProfileType, + updateGroupProfile, +} from '../chat/updateGroupProfile'; +import { UserInfo } from './user'; +export class Chat { + private userInfoInstance: UserInfo; + + constructor( + private account: string, + private decryptedPgpPvtKey: string, + private env: ENV, + private signer: SignerType, + private progressHook?: (progress: ProgressHookType) => void + ) { this.userInfoInstance = new UserInfo(this.account, this.env); +} + + async list( + type: `${ChatListType}`, + options?: { + /** + * @default 1 + */ + page?: number; + limit?: number; + } + ): Promise { + const listParams = { + account: this.account, + pgpPrivateKey: this.decryptedPgpPvtKey, + page: options?.page, + limit: options?.limit, + env: this.env, + toDecrypt: true, + }; + + switch (type) { + case ChatListType.CHATS: + return await PUSH_CHAT.chats(listParams); + case ChatListType.REQUESTS: + return await PUSH_CHAT.requests(listParams); + default: + throw new Error('Invalid Chat List Type'); + } + } + async latest(target: string) { + const { threadHash } = await PUSH_CHAT.conversationHash({ + conversationId: target, + account: this.account, + env: this.env, + }); + if (!threadHash) return {}; + + return await PUSH_CHAT.latest({ + threadhash: threadHash, + toDecrypt: true, + pgpPrivateKey: this.decryptedPgpPvtKey, + account: this.account, + env: this.env, + }); + } + + async history( + target: string, + options?: { + reference?: string | null; + limit?: number; + } + ) { + let reference: string; + + if (!options?.reference) { + const { threadHash } = await PUSH_CHAT.conversationHash({ + conversationId: target, + account: this.account, + env: this.env, + }); + reference = threadHash; + } else { + reference = options.reference; + } + + if (!reference) return []; + + return await PUSH_CHAT.history({ + account: this.account, + env: this.env, + threadhash: reference, + pgpPrivateKey: this.decryptedPgpPvtKey, + toDecrypt: true, + limit: options?.limit, + }); + } + + async send(recipient: string, options: Message): Promise { + if (!options.type) { + options.type = MessageType.TEXT; + } + const sendParams: ChatSendOptionsType = { + message: options, + to: recipient, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + env: this.env, + }; + return await PUSH_CHAT.send(sendParams); + } + + async decrypt(messagePayloads: IMessageIPFS[]) { + return await PUSH_CHAT.decryptConversation({ + pgpPrivateKey: this.decryptedPgpPvtKey, + env: this.env, + messages: messagePayloads, + connectedUser: await this.userInfoInstance.info(), + }); + } + + async accept(target: string): Promise { + return await PUSH_CHAT.approve({ + senderAddress: target, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } + + async reject(target: string): Promise { + await PUSH_CHAT.reject({ + senderAddress: target, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } + + async block(users: Array): Promise { + const user = await PUSH_USER.get({ + account: this.account, + env: this.env, + }); + + for (const element of users) { + if (!isValidETHAddress(element)) { + throw new Error('Invalid address in the users: ' + element); + } + } + + if (!user.profile.blockedUsersList) { + user.profile.blockedUsersList = []; + } + + user.profile.blockedUsersList = [ + ...new Set([...user.profile.blockedUsersList, ...users]), + ]; + + return await PUSH_USER.profile.update({ + pgpPrivateKey: this.decryptedPgpPvtKey, + account: this.account, + profile: { + name: user.profile.name!, + desc: user.profile.desc!, + picture: user.profile.picture!, + blockedUsersList: user.profile.blockedUsersList, + }, + env: this.env, + progressHook: this.progressHook, + }); + } + + async unblock(users: Array): Promise { + const user = await PUSH_USER.get({ + account: this.account, + env: this.env, + }); + + for (const element of users) { + if (!isValidETHAddress(element)) { + throw new Error('Invalid address in the users: ' + element); + } + } + + if (!user.profile.blockedUsersList) { + return user; + } + + const userDIDsPromises = users.map(async (user) => { + return (await getUserDID(user, this.env)).toLowerCase(); + }); + const userDIDs = await Promise.all(userDIDsPromises); + + user.profile.blockedUsersList = user.profile.blockedUsersList.filter( + (blockedUser) => { + !userDIDs.includes(blockedUser.toLowerCase()); + } + ); + + return await PUSH_USER.profile.update({ + pgpPrivateKey: this.decryptedPgpPvtKey, + account: this.account, + profile: { + name: user.profile.name!, + desc: user.profile.desc!, + picture: user.profile.picture!, + blockedUsersList: user.profile.blockedUsersList, + }, + env: this.env, + progressHook: this.progressHook, + }); + } + + group = { + create: async (name: string, options?: GroupCreationOptions) => { + const groupParams: PUSH_CHAT.ChatCreateGroupType = { + groupName: name, + groupDescription: options?.description, + members: options?.members ? options.members : [], + groupImage: options?.image, + admins: options?.admins ? options.admins : [], + rules: options?.rules, + isPublic: !options?.private, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + env: this.env, + }; + + return await PUSH_CHAT.createGroup(groupParams); + }, + + permissions: async (chatId: string): Promise => { + const getGroupAccessOptions: PUSH_CHAT.GetGroupAccessType = { + chatId, + did: this.account, + env: this.env, + }; + return await PUSH_CHAT.getGroupAccess(getGroupAccessOptions); + }, + + info: async (chatId: string): Promise => { + return await PUSH_CHAT.getGroup({ + chatId: chatId, + env: this.env, + }); + }, + update: async ( + chatId: string, + options: GroupUpdateOptions + ): Promise => { + const group = await PUSH_CHAT.getGroup({ + chatId: chatId, + env: this.env, + }); + if (!group) { + throw new Error('Group not found'); + } + + const updateGroupProfileOptions: ChatUpdateGroupProfileType = { + chatId: chatId, + groupName: options.name ? options.name : group.groupName, + groupImage: options.image ? options.image : group.groupImage, + groupDescription: options.description + ? options.description + : group.groupDescription, + scheduleAt: options.scheduleAt ? options.scheduleAt : group.scheduleAt, + scheduleEnd: options.scheduleEnd + ? options.scheduleEnd + : group.scheduleEnd, + status: options.status ? options.status : group.status, + meta: options.meta ? options.meta : group.meta, + rules: options.rules ? options.rules : group.rules, + account: this.account, + pgpPrivateKey: this.decryptedPgpPvtKey, + env: this.env, + }; + return await updateGroupProfile(updateGroupProfileOptions); + }, + + add: async (chatId: string, options: ManageGroupOptions) => { + const { role, accounts } = options; + + const validRoles = ['ADMIN', 'MEMBER']; + if (!validRoles.includes(role)) { + throw new Error('Invalid role provided.'); + } + + if (!accounts || accounts.length === 0) { + throw new Error('accounts array cannot be empty!'); + } + + accounts.forEach((account) => { + if (!isValidETHAddress(account)) { + throw new Error(`Invalid account address: ${account}`); + } + }); + + if (role === 'ADMIN') { + return await PUSH_CHAT.addAdmins({ + chatId: chatId, + admins: accounts, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } else { + return await PUSH_CHAT.addMembers({ + chatId: chatId, + members: accounts, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } + }, + + remove: async (chatId: string, options: ManageGroupOptions) => { + const { role, accounts } = options; + + const validRoles = ['ADMIN', 'MEMBER']; + if (!validRoles.includes(role)) { + throw new Error('Invalid role provided.'); + } + + if (!accounts || accounts.length === 0) { + throw new Error('accounts array cannot be empty!'); + } + + accounts.forEach((account) => { + if (!isValidETHAddress(account)) { + throw new Error(`Invalid account address: ${account}`); + } + }); + + if (role === 'ADMIN') { + return await PUSH_CHAT.removeAdmins({ + chatId: chatId, + admins: accounts, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } else { + return await PUSH_CHAT.removeMembers({ + chatId: chatId, + members: accounts, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } + }, + + join: async (target: string): Promise => { + const status = await PUSH_CHAT.getGroupMemberStatus({ + chatId: target, + did: this.account, + env: this.env, + }); + + if (status.isPending) { + await PUSH_CHAT.approve({ + senderAddress: target, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } else if (!status.isMember) { + return await PUSH_CHAT.addMembers({ + chatId: target, + members: [this.account], + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } + + return await PUSH_CHAT.getGroup({ + chatId: target, + env: this.env, + }); + }, + + leave: async (target: string): Promise => { + const status = await PUSH_CHAT.getGroupMemberStatus({ + chatId: target, + did: this.account, + env: this.env, + }); + + if (status.isAdmin) { + return await PUSH_CHAT.removeAdmins({ + chatId: target, + admins: [this.account], + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } else { + return await PUSH_CHAT.removeMembers({ + chatId: target, + members: [this.account], + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + } + }, + reject: async (target: string): Promise => { + await PUSH_CHAT.reject({ + senderAddress: target, + env: this.env, + account: this.account, + signer: this.signer, + pgpPrivateKey: this.decryptedPgpPvtKey, + }); + }, + }; +} diff --git a/packages/restapi/src/lib/pushapi/encryption.ts b/packages/restapi/src/lib/pushapi/encryption.ts new file mode 100644 index 000000000..14e1ec286 --- /dev/null +++ b/packages/restapi/src/lib/pushapi/encryption.ts @@ -0,0 +1,67 @@ +import { ENCRYPTION_TYPE, ENV } from '../constants'; +import { + SignerType, + ProgressHookType, +} from '../types'; +import * as PUSH_USER from '../user'; +import { User } from './user'; + +export class Encryption { + private userInstance: User; + + constructor( + private account: string, + private decryptedPgpPvtKey: string, + private pgpPublicKey: string, + private env: ENV, + private signer: SignerType, + private progressHook?: (progress: ProgressHookType) => void + ) { + this.userInstance = new User(this.account, this.env); + } + + async info() { + const userInfo = await this.userInstance.info(); + const decryptedPassword = await PUSH_USER.decryptAuth({ + account: this.account, + env: this.env, + signer: this.signer, + progressHook: this.progressHook, + additionalMeta: { + NFTPGP_V1: { + encryptedPassword: JSON.stringify( + JSON.parse(userInfo.encryptedPrivateKey).encryptedPassword + ), + }, + }, + }); + + return { + decryptedPgpPrivateKey: this.decryptedPgpPvtKey, + pgpPublicKey: this.pgpPublicKey, + ...(decryptedPassword !== undefined && decryptedPassword !== null + ? { decryptedPassword: decryptedPassword } + : {}), + }; + } + + async update( + updatedEncryptionType: ENCRYPTION_TYPE, + options?: { + versionMeta?: { + NFTPGP_V1?: { password: string }; + }; + } + ) { + return await PUSH_USER.auth.update({ + account: this.account, + pgpEncryptionVersion: updatedEncryptionType, + additionalMeta: options?.versionMeta, + progressHook: this.progressHook, + signer: this.signer, + env: this.env, + pgpPrivateKey: this.decryptedPgpPvtKey, + pgpPublicKey: this.pgpPublicKey, + }); + } +} diff --git a/packages/restapi/src/lib/pushapi/profile.ts b/packages/restapi/src/lib/pushapi/profile.ts new file mode 100644 index 000000000..f3a8861b0 --- /dev/null +++ b/packages/restapi/src/lib/pushapi/profile.ts @@ -0,0 +1,36 @@ +import { ProgressHookType } from '../types'; +import * as PUSH_USER from '../user'; +import { ENV } from '../constants'; + +export class Profile { + constructor( + private account: string, + private decryptedPgpPvtKey: string, + private env: ENV, + private progressHook?: (progress: ProgressHookType) => void + ) {} + + async info() { + const response = await PUSH_USER.get({ + account: this.account, + env: this.env, + }); + return response.profile; + } + + async update(options: { name?: string; desc?: string; picture?: string }) { + const { name, desc, picture } = options; + const response = await PUSH_USER.profile.update({ + pgpPrivateKey: this.decryptedPgpPvtKey, + account: this.account, + profile: { + name: name, + desc: desc, + picture: picture, + }, + env: this.env, + progressHook: this.progressHook, + }); + return response.profile; + } +} diff --git a/packages/restapi/src/lib/pushapi/pushAPITypes.ts b/packages/restapi/src/lib/pushapi/pushAPITypes.ts index dc6717a79..c620dae1c 100644 --- a/packages/restapi/src/lib/pushapi/pushAPITypes.ts +++ b/packages/restapi/src/lib/pushapi/pushAPITypes.ts @@ -1,4 +1,5 @@ import Constants, { ENV } from '../constants'; +import { PushStreamInitializeProps } from '../pushstream/pushStreamTypes'; import { ChatStatus, ProgressHookType, Rules } from '../types'; export enum ChatListType { @@ -13,6 +14,7 @@ export interface PushAPIInitializeProps { versionMeta?: { NFTPGP_V1?: { password: string } }; autoUpgrade?: boolean; origin?: string; + streamOptions?: PushStreamInitializeProps; } export interface GroupCreationOptions { @@ -21,14 +23,7 @@ export interface GroupCreationOptions { members?: string[]; admins?: string[]; private?: boolean; - rules?: { - entry?: { - conditions: any[]; - }; - chat?: { - conditions: any[]; - }; - }; + rules?: Rules | null; } export interface ManageGroupOptions { diff --git a/packages/restapi/src/lib/pushapi/user.ts b/packages/restapi/src/lib/pushapi/user.ts new file mode 100644 index 000000000..4a485e787 --- /dev/null +++ b/packages/restapi/src/lib/pushapi/user.ts @@ -0,0 +1,13 @@ +import * as PUSH_USER from '../user'; +import { ENV } from '../constants'; + +export class User { + constructor(private account: string, private env: ENV) {} + + async info() { + return await PUSH_USER.get({ + account: this.account, + env: this.env, + }); + } +} diff --git a/packages/restapi/src/lib/pushstream/DataModifier.ts b/packages/restapi/src/lib/pushstream/DataModifier.ts new file mode 100644 index 000000000..cb8054005 --- /dev/null +++ b/packages/restapi/src/lib/pushstream/DataModifier.ts @@ -0,0 +1,291 @@ +import { + CreateGroupEvent, + GroupMeta, + GroupEventRawData, + UpdateGroupEvent, + MessageRawData, + MessageEvent, + MessageEventType, + Member, + GroupEventType, + LeaveGroupEvent, + JoinGroupEvent, + ProposedEventNames, + RequestEvent, + RemoveEvent, +} from './pushStreamTypes'; + +export class DataModifier { + public static handleChatGroupEvent(data: any, includeRaw = false): any { + switch (data.eventType) { + case 'create': + return this.mapToCreateGroupEvent(data, includeRaw); + case 'update': + return this.mapToUpdateGroupEvent(data, includeRaw); + case GroupEventType.JoinGroup: + return this.mapToJoinGroupEvent(data, includeRaw); + case GroupEventType.LeaveGroup: + return this.mapToLeaveGroupEvent(data, includeRaw); + case MessageEventType.Request: + return this.mapToRequestEvent(data, includeRaw); + case GroupEventType.Remove: + return this.mapToRemoveEvent(data, includeRaw); + default: + console.warn('Unknown eventType:', data.eventType); + return data; + } + } + + private static mapToJoinGroupEvent( + data: any, + includeRaw: boolean + ): JoinGroupEvent { + const baseEventData: JoinGroupEvent = { + origin: data.messageOrigin, + timestamp: data.timestamp, + chatId: data.chatId, + from: data.from, + to: data.to, + event: GroupEventType.JoinGroup, + }; + + return includeRaw + ? { + ...baseEventData, + raw: { verificationProof: data.verificationProof }, + } + : baseEventData; + } + + private static mapToLeaveGroupEvent( + data: any, + includeRaw: boolean + ): LeaveGroupEvent { + const baseEventData: LeaveGroupEvent = { + origin: data.messageOrigin, + timestamp: data.timestamp, + chatId: data.chatId, + from: data.from, + to: data.to, + event: GroupEventType.LeaveGroup, + }; + + return includeRaw + ? { + ...baseEventData, + raw: { verificationProof: data.verificationProof }, + } + : baseEventData; + } + + private static mapToRequestEvent(data: any, includeRaw: boolean): any { + const eventData: RequestEvent = { + origin: data.messageOrigin, + timestamp: data.timestamp, + chatId: data.chatId, + from: data.from, + to: data.to, + event: MessageEventType.Request, + meta: { + group: data.isGroup || false, + }, + }; + + if (includeRaw) { + eventData.raw = { verificationProof: data.verificationProof }; + } + return eventData; + } + + private static mapToRemoveEvent(data: any, includeRaw: boolean): any { + // Whatever the structure of your RemoveEvent, modify accordingly + const eventData: RemoveEvent = { + origin: data.messageOrigin, + timestamp: data.timestamp, + chatId: data.chatId, + from: data.from, + to: data.to, + event: GroupEventType.Remove, + }; + + if (includeRaw) { + eventData.raw = { verificationProof: data.verificationProof }; + } + return eventData; + } + + private static buildChatGroupEventMetaAndRaw( + incomingData: any, + includeRaw: boolean + ): { + meta: GroupMeta; + raw?: GroupEventRawData; + } { + const mapMembersAdmins = (arr: any[]): Member[] => { + return arr.map((item) => ({ + address: item.wallet, + profile: { + image: item.image, + publicKey: item.publicKey, + }, + })); + }; + + const mapPendingMembersAdmins = (arr: any[]): Member[] => { + return arr.map((item) => ({ + address: item.wallet, + profile: { + image: item.image, + publicKey: item.publicKey, + }, + })); + }; + + const meta: GroupMeta = { + name: incomingData.groupName, + description: incomingData.groupDescription, + image: incomingData.groupImage, + owner: incomingData.groupCreator, + members: mapMembersAdmins( + incomingData.members.filter((m: any) => !m.isAdmin) + ), + admins: mapMembersAdmins( + incomingData.members.filter((m: any) => m.isAdmin) + ), + pending: { + members: mapPendingMembersAdmins( + incomingData.pendingMembers.filter((m: any) => !m.isAdmin) + ), + admins: mapPendingMembersAdmins( + incomingData.pendingMembers.filter((m: any) => m.isAdmin) + ), + }, + private: !incomingData.isPublic, + rules: incomingData.rules || {}, + }; + + if (includeRaw) { + const raw: GroupEventRawData = { + verificationProof: incomingData.verificationProof, + }; + return { meta, raw }; + } + + return { meta }; + } + + public static mapToGroupEvent( + eventType: GroupEventType, + incomingData: any, + includeRaw: boolean + ): CreateGroupEvent | UpdateGroupEvent { + const { meta, raw } = this.buildChatGroupEventMetaAndRaw( + incomingData, + includeRaw + ); + + const groupEvent: any = { + event: eventType, + origin: incomingData.messageOrigin, + timestamp: incomingData.timestamp, + chatId: incomingData.chatId, + from: incomingData.from, + meta, + }; + + if (includeRaw) { + groupEvent.raw = raw; + } + + return groupEvent as CreateGroupEvent | UpdateGroupEvent; + } + + public static mapToCreateGroupEvent( + incomingData: any, + includeRaw: boolean + ): CreateGroupEvent { + return this.mapToGroupEvent( + GroupEventType.CreateGroup, + incomingData, + includeRaw + ) as CreateGroupEvent; + } + + public static mapToUpdateGroupEvent( + incomingData: any, + includeRaw: boolean + ): UpdateGroupEvent { + return this.mapToGroupEvent( + GroupEventType.UpdateGroup, + incomingData, + includeRaw + ) as UpdateGroupEvent; + } + + public static mapToMessageEvent( + data: any, + includeRaw = false, + eventType: MessageEventType + ): MessageEvent { + const messageEvent: MessageEvent = { + event: eventType, + origin: data.messageOrigin, + timestamp: data.timestamp.toString(), + chatId: data.chatId, // TODO: ChatId not working for w2w + from: data.fromCAIP10, + to: [data.toCAIP10], // TODO: Assuming 'to' is an array in MessageEvent. Update as necessary. + message: { + type: data.messageType, + content: data.messageContent, + }, + meta: { + group: data.isGroup || false, + }, + reference: data.cid, + }; + + if (includeRaw) { + const rawData: MessageRawData = { + fromCAIP10: data.fromCAIP10, + toCAIP10: data.toCAIP10, + fromDID: data.fromDID, + toDID: data.toDID, + encType: data.encType, + encryptedSecret: data.encryptedSecret, + signature: data.signature, + sigType: data.sigType, + verificationProof: data.verificationProof, + previousReference: data.link, + }; + messageEvent.raw = rawData; + } + + return messageEvent; + } + + public static handleChatEvent(data: any, includeRaw = false): any { + const eventTypeMap: { [key: string]: MessageEventType } = { + Chat: MessageEventType.Message, + Request: MessageEventType.Request, + Approve: MessageEventType.Accept, + Reject: MessageEventType.Reject, + }; + + const eventType: MessageEventType | undefined = + eventTypeMap[data.eventType || data.messageCategory]; + + if (eventType) { + return this.mapToMessageEvent( + data, + includeRaw, + eventType as MessageEventType + ); + } else { + console.warn( + 'Unknown eventType:', + data.eventType || data.messageCategory + ); + return data; + } + } +} diff --git a/packages/restapi/src/lib/pushstream/PushStream.ts b/packages/restapi/src/lib/pushstream/PushStream.ts new file mode 100644 index 000000000..dfc95ea87 --- /dev/null +++ b/packages/restapi/src/lib/pushstream/PushStream.ts @@ -0,0 +1,215 @@ +import { EventEmitter } from 'events'; +import { createSocketConnection, EVENTS } from '@pushprotocol/socket'; +import { ENV } from '../constants'; +import { + GroupEventType, + MessageEventType, + ProposedEventNames, + PushStreamInitializeProps, + STREAM, +} from './pushStreamTypes'; +import { DataModifier } from './DataModifier'; +import { pCAIP10ToWallet, walletToPCAIP10 } from '../helpers'; +import { Chat } from '../pushapi/chat'; +import { ProgressHookType, SignerType } from '../types'; + +export class PushStream extends EventEmitter { + private pushChatSocket: any; + private pushNotificationSocket: any; + + private account: string; + private raw: boolean; + private options: PushStreamInitializeProps; + private chatInstance: Chat; + + constructor( + account: string, + private decryptedPgpPvtKey: string, + private signer: SignerType, + options: PushStreamInitializeProps, + private progressHook?: (progress: ProgressHookType) => void + ) { + super(); + + this.account = account; + this.pushChatSocket = createSocketConnection({ + user: walletToPCAIP10(account), + socketType: 'chat', + socketOptions: { + autoConnect: options.connection?.auto ?? true, + reconnectionAttempts: options.connection?.retries ?? 3, + }, + env: options.env as ENV, + }); + + this.pushNotificationSocket = createSocketConnection({ + user: pCAIP10ToWallet(this.account), + env: options.env as ENV, + socketOptions: { + autoConnect: options.connection?.auto ?? true, + reconnectionAttempts: options.connection?.retries ?? 3, + }, + }); + + if (!this.pushNotificationSocket) { + throw new Error('Push notification socket not connected'); + } + + if (!this.pushChatSocket) { + throw new Error('Push chat socket not connected'); + } + + this.raw = options.raw ?? false; + this.options = options; + + this.chatInstance = new Chat( + this.account, + this.decryptedPgpPvtKey, + this.options.env as ENV, + this.signer, + this.progressHook + ); + } + + static async initialize( + account: string, + decryptedPgpPvtKey: string, + signer: SignerType, + progressHook?: (progress: ProgressHookType) => void, + options?: PushStreamInitializeProps + ): Promise { + const defaultOptions: PushStreamInitializeProps = { + listen: [], + env: ENV.LOCAL, + raw: false, + connection: { + auto: true, + retries: 3, + }, + }; + + const settings = { + ...defaultOptions, + ...options, + }; + + const stream = new PushStream( + account, + decryptedPgpPvtKey, + signer, + settings, + progressHook + ); + await stream.init(); + return stream; + } + + private convertToProposedName(currentEventName: string): ProposedEventNames { + switch (currentEventName) { + case 'message': + return ProposedEventNames.Message; + case 'request': + return ProposedEventNames.Request; + case 'accept': + return ProposedEventNames.Accept; + case 'reject': + return ProposedEventNames.Reject; + case 'leaveGroup': + return ProposedEventNames.LeaveGroup; + case 'joinGroup': + return ProposedEventNames.JoinGroup; + case 'createGroup': + return ProposedEventNames.CreateGroup; + case 'updateGroup': + return ProposedEventNames.UpdateGroup; + case 'remove': + return ProposedEventNames.Remove; + default: + throw new Error(`Unknown current event name: ${currentEventName}`); + } + } + + private handleToField(data: any): void { + switch (data.event) { + case ProposedEventNames.LeaveGroup: + case ProposedEventNames.JoinGroup: + data.to = null; + break; + + case ProposedEventNames.Accept: + case ProposedEventNames.Reject: + if (data.meta?.group) { + data.to = null; + } + break; + + default: + break; + } + } + + private shouldEmitChat(dataChatId: string): boolean { + if (!this.options.filter?.chats || this.options.filter.chats.length === 0) { + return true; + } + return this.options.filter.chats.includes(dataChatId); + } + + public async init(): Promise { + const shouldEmit = (eventType: STREAM): boolean => { + if (!this.options.listen || this.options.listen.length === 0) { + return true; + } + return this.options.listen.includes(eventType); + }; + + this.pushChatSocket.on(EVENTS.CHAT_GROUPS, (data: any) => { + const modifiedData = DataModifier.handleChatGroupEvent(data, this.raw); + modifiedData.event = this.convertToProposedName(modifiedData.event); + this.handleToField(modifiedData); + if (this.shouldEmitChat(data.chatId)) { + if ( + data.eventType === GroupEventType.JoinGroup || + data.eventType === GroupEventType.LeaveGroup || + data.eventType === MessageEventType.Request || + data.eventType === GroupEventType.Remove + ) { + if (shouldEmit(STREAM.CHAT)) { + this.emit(STREAM.CHAT, modifiedData); + } + } else { + if (shouldEmit(STREAM.CHAT_OPS)) { + this.emit(STREAM.CHAT_OPS, modifiedData); + } + } + } + }); + + this.pushChatSocket.on(EVENTS.CHAT_RECEIVED_MESSAGE, async (data: any) => { + if (data.messageCategory == 'Chat' || data.messageCategory == 'Request') { + data = await this.chatInstance.decrypt([data]); + } + + const modifiedData = DataModifier.handleChatEvent(data[0], this.raw); + modifiedData.event = this.convertToProposedName(modifiedData.event); + this.handleToField(modifiedData); + if (this.shouldEmitChat(data.chatId)) { + if (shouldEmit(STREAM.CHAT)) { + this.emit(STREAM.CHAT, modifiedData); + } + } + }); + + this.pushNotificationSocket.on(EVENTS.USER_FEEDS, (data: any) => { + console.log('Incoming Feed from Socket'); + console.log(data); + this.emit(STREAM.NOTIF, data); + }); + + this.pushNotificationSocket.on(EVENTS.USER_SPAM_FEEDS, (data: any) => { + console.log('Incoming Spam Feed from Socket'); + console.log(data); + this.emit(STREAM.NOTIF, data); + }); + } +} diff --git a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts new file mode 100644 index 000000000..8d703789e --- /dev/null +++ b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts @@ -0,0 +1,168 @@ +import { ENV } from "../constants"; +import { Rules } from "../types"; + +export type PushStreamInitializeProps = { + listen?: STREAM[]; + filter?: { + channels?: string[]; + chats?: string[]; + }; + connection?: { + auto?: boolean; + retries?: number; + }; + raw?: boolean; + env?: ENV; +}; + +export enum STREAM { + PROFILE = 'STREAM.PROFILE', + ENCRYPTION = 'STREAM.ENCRYPTION', + NOTIF = 'STREAM.NOTIF', + NOTIF_OPS = 'STREAM.NOTIF_OPS', + CHAT = 'STREAM.CHAT', + CHAT_OPS = 'STREAM.CHAT_OPS', +} + +export enum MessageOrigin { + Other = 'other', + Self = 'self', +} + +export enum MessageEventType { + Message = 'message', + Request = 'request', + Accept = 'accept', + Reject = 'reject', +} + +export enum GroupEventType { + CreateGroup = 'createGroup', + UpdateGroup = 'updateGroup', + JoinGroup = 'joinGroup', + LeaveGroup = 'leaveGroup', + Remove = 'remove', +} + +export enum ProposedEventNames { + Message = 'chat.message', + Request = 'chat.request', + Accept = 'chat.accept', + Reject = 'chat.reject', + LeaveGroup = 'chat.group.participant.leave', + JoinGroup = 'chat.group.participant.join', + CreateGroup = 'chat.group.create', + UpdateGroup = 'chat.group.update', + Remove = 'chat.group.participant.remove', +} + + +export interface Profile { + image: string; + publicKey: string; +} + +export interface Member { + address: string; + profile: Profile; +} + +export interface Pending { + members: Member[]; + admins: Member[]; +} + +export interface GroupMeta { + name: string; + description: string; + image: string; + owner: string; + members: Member[]; + admins: Member[]; + pending: Pending; + private: boolean; + rules: Rules; +} + +export interface GroupEventRawData { + verificationProof: string; +} + +export interface GroupEventBase { + origin: MessageOrigin; + timestamp: string; + chatId: string; + from: string; + meta: GroupMeta; + raw?: GroupEventRawData; + event: GroupEventType; +} + +export interface CreateGroupEvent extends GroupEventBase { + event: GroupEventType.CreateGroup; +} + +export interface UpdateGroupEvent extends GroupEventBase { + event: GroupEventType.UpdateGroup; +} + +export interface GroupMemberEventBase { + event: GroupEventType | MessageEventType; + origin: MessageOrigin; + timestamp: string; + chatId: string; + from: string; + to: string[]; + raw?: GroupEventRawData; +} + +export interface JoinGroupEvent extends GroupMemberEventBase { + event: GroupEventType.JoinGroup; +} + +export interface LeaveGroupEvent extends GroupMemberEventBase { + event: GroupEventType.LeaveGroup; +} + +export interface RequestEvent extends GroupMemberEventBase { + event: MessageEventType.Request; + meta: { + group: boolean; + }; +} + +export interface RemoveEvent extends GroupMemberEventBase { + event: GroupEventType.Remove; +} + + +export interface MessageEvent { + event: MessageEventType; + origin: MessageOrigin; + timestamp: string; + chatId: string; + from: string; + to: string[]; + message: { + type: string; + content: string; + }; + meta: { + group: boolean; + }; + reference: string; + raw?: MessageRawData; +} + +export interface MessageRawData { + fromCAIP10: string; + toCAIP10: string; + fromDID: string; + toDID: string; + encType: string; + encryptedSecret: string; + signature: string; + sigType: string; + verificationProof: string; + previousReference: string; +} \ No newline at end of file diff --git a/packages/restapi/src/lib/types/index.ts b/packages/restapi/src/lib/types/index.ts index 2ca869d70..e75a057a5 100644 --- a/packages/restapi/src/lib/types/index.ts +++ b/packages/restapi/src/lib/types/index.ts @@ -315,10 +315,10 @@ export type Data = { contract?: string; amount?: number; decimals?: number; - guildId?: string; - guildRoleId?: string; + id?: string; + role?: string; url?: string; - comparison?: '>' | '<' | '>=' | '<=' | '==' | '!='; + comparison?: '>' | '<' | '>=' | '<=' | '==' | '!=' | 'all' | 'any'; }; export type ConditionBase = { @@ -337,25 +337,32 @@ export type Condition = ConditionBase & { export interface Rules { entry?: { - conditions: Array; + conditions: Array | (Condition | ConditionBase); }; chat?: { - conditions: Array; + conditions: Array | (Condition | ConditionBase); }; } + export interface SpaceRules { entry?: { - conditions: Array; + conditions: Array | (Condition | ConditionBase); }; } export interface GroupAccess { - groupAccess: boolean; + entry: boolean; chat: boolean; rules?: Rules; } +export interface GroupMemberStatus { + isMember: boolean; + isPending: boolean; + isAdmin: boolean; +} + export interface SpaceAccess { entry: boolean; rules?: SpaceRules; diff --git a/packages/restapi/tests/lib/chat/updateGroup.test.ts b/packages/restapi/tests/lib/chat/updateGroup.test.ts index 1ad448a69..436c10bd6 100644 --- a/packages/restapi/tests/lib/chat/updateGroup.test.ts +++ b/packages/restapi/tests/lib/chat/updateGroup.test.ts @@ -191,7 +191,6 @@ const expectGroup = async ( expect(group.scheduleEnd).to.be.null; expect(group.groupType).to.equal('default'); expect((group as any).status).to.be.null; - expect((group as any).eventType).to.equal('update'); if (!HasMeta) { expect((group as any).meta).to.be.null; } else { diff --git a/packages/restapi/tests/lib/pushNotification/alias.test.ts b/packages/restapi/tests/lib/pushNotification/alias.test.ts new file mode 100644 index 000000000..1bd9c5cfb --- /dev/null +++ b/packages/restapi/tests/lib/pushNotification/alias.test.ts @@ -0,0 +1,53 @@ +import * as path from 'path'; +import * as dotenv from 'dotenv'; +dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); + +import { PushAPI } from '../../../src/lib/pushapi/PushAPI'; +import { expect } from 'chai'; +import { ethers } from 'ethers'; + +describe('PushAPI.alias functionality', () => { + let userAlice: PushAPI; + let userBob: PushAPI; + let userKate: PushAPI; + let signer1: any; + let account1: string; + let signer2: any; + let account2: string; + + beforeEach(async () => { + signer1 = new ethers.Wallet(`0x${process.env['WALLET_PRIVATE_KEY']}`); + account1 = await signer1.getAddress(); + + const provider = new ethers.providers.JsonRpcProvider( + // PUBLIC RPC + 'https://goerli.blockpi.network/v1/rpc/public' + ); + + signer2 = new ethers.Wallet( + `0x${process.env['WALLET_PRIVATE_KEY']}`, + provider + ); + account2 = await signer2.getAddress(); + + // initialisation with signer and provider + userKate = await PushAPI.initialize(signer2); + // initialisation with signer + userAlice = await PushAPI.initialize(signer2); + // TODO: remove signer1 after chat makes signer as optional + //initialisation without signer + userBob = await PushAPI.initialize(signer1); + }); + + describe('alias :: info', () => { + // TODO: remove skip after signer becomes optional + it('Should return response', async () => { + const res = await userBob.alias.info({ + alias: '0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', + aliasChain: 'POLYGON', + }); + // console.log(res) + expect(res).not.null; + }); + }); +}); diff --git a/packages/restapi/tests/lib/pushNotification/channel.test.ts b/packages/restapi/tests/lib/pushNotification/channel.test.ts index f8438e62c..5f70e1036 100644 --- a/packages/restapi/tests/lib/pushNotification/channel.test.ts +++ b/packages/restapi/tests/lib/pushNotification/channel.test.ts @@ -2,14 +2,15 @@ import * as path from 'path'; import * as dotenv from 'dotenv'; dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); -import { PushNotification } from '../../../src/lib/pushNotification/PushNotification'; // Ensure correct import path + +import { PushAPI } from '../../../src/lib/pushapi/PushAPI'; import { expect } from 'chai'; import { ethers } from 'ethers'; describe('PushAPI.channel functionality', () => { - let userAlice: PushNotification; - let userBob: PushNotification; - let userKate: PushNotification; + let userAlice: PushAPI; + let userBob: PushAPI; + let userKate: PushAPI; let signer1: any; let account1: string; let signer2: any; @@ -31,30 +32,33 @@ describe('PushAPI.channel functionality', () => { account2 = await signer2.getAddress(); // initialisation with signer and provider - userKate = await PushNotification.initialize(signer2); + userKate = await PushAPI.initialize(signer2) // initialisation with signer - userAlice = await PushNotification.initialize(signer1); - // initialisation without signer - userBob = await PushNotification.initialize(); + userAlice = await PushAPI.initialize(signer2); + // TODO: remove signer1 after chat makes signer as optional + //initialisation without signer + userBob = await PushAPI.initialize(signer1); }); describe('channel :: info', () => { - it('Without signer and account: Should throw error', async () => { + // TODO: remove skip after signer becomes optional + it.skip('Without signer and account: Should throw error', async () => { await expect(() => userBob.channel.info()).to.Throw; }); it('Without signer but with non-caip account: Should return response', async () => { const res = await userBob.channel.info( - '0xD8634C39BBFd4033c0d3289C4515275102423681' + '0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5' ); + // console.log(res) expect(res).not.null; }); it('Without signer and with valid caip account: Should return response', async () => { const res = await userBob.channel.info( - 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' + 'eip155:5:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5' ); - // console.log(res); + // console.log(res); expect(res).not.null; }); }); @@ -62,7 +66,7 @@ describe('PushAPI.channel functionality', () => { describe('channel :: search', () => { it('Without signer and account : Should return response', async () => { const res = await userBob.channel.search(' '); - // console.log(res); + // console.log(res); expect(res).not.null; }); @@ -73,19 +77,22 @@ describe('PushAPI.channel functionality', () => { }); it('Should throw error for empty query', async () => { + // const res = await userBob.channel.search('') await expect(() => userBob.channel.search('')).to.Throw; }); }); describe('channel :: subscribers', () => { - it('Without signer and account : Should throw error', async () => { + // TODO: remove skip after signer becomes optional + it.skip('Without signer and account : Should throw error', async () => { await expect(() => userBob.channel.subscribers()).to.Throw; }); it('Without signer and account : Should return response as address is passed', async () => { const res = await userBob.channel.subscribers({ - channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', + channel: 'eip155:5:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', }); + // console.log(res) expect(res).not.null; }); @@ -93,6 +100,7 @@ describe('PushAPI.channel functionality', () => { const res = await userBob.channel.subscribers({ channel: 'eip155:80001:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', }); + // console.log(res) expect(res).not.null; }); @@ -111,7 +119,8 @@ describe('PushAPI.channel functionality', () => { }); describe('channel :: send', () => { - it('Without signer and account : Should throw error', async () => { + // TODO: remove skip after signer becomes optional + it.skip('Without signer and account : Should throw error', async () => { await expect(() => { userBob.channel.send(['*'], { notification: { @@ -129,6 +138,7 @@ describe('PushAPI.channel functionality', () => { body: 'test', }, }); + // console.log(res) expect(res.status).to.equal(204); }); @@ -147,7 +157,7 @@ describe('PushAPI.channel functionality', () => { it('With signer : targeted : Should send notification with title and body', async () => { const res = await userAlice.channel.send( - ['eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681'], + ['eip155:5:0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5'], { notification: { title: 'hi', diff --git a/packages/restapi/tests/lib/pushNotification/delegate.test.ts b/packages/restapi/tests/lib/pushNotification/delegate.test.ts index 5a9f12811..9f99794df 100644 --- a/packages/restapi/tests/lib/pushNotification/delegate.test.ts +++ b/packages/restapi/tests/lib/pushNotification/delegate.test.ts @@ -2,14 +2,14 @@ import * as path from 'path'; import * as dotenv from 'dotenv'; dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); -import { PushNotification } from '../../../src/lib/pushNotification/PushNotification'; // Ensure correct import path +import { PushAPI } from '../../../src/lib/pushapi/PushAPI'; // Ensure correct import path import { expect } from 'chai'; import { ethers } from 'ethers'; // import tokenABI from './tokenABI'; -describe('PushAPI.notification functionality', () => { - let userAlice: PushNotification; - let userBob: PushNotification; - let userKate: PushNotification; +describe('PushAPI.delegate functionality', () => { + let userAlice: PushAPI; + let userBob: PushAPI; + let userKate: PushAPI; let signer1: any; let account1: string; let signer2: any; @@ -30,15 +30,16 @@ describe('PushAPI.notification functionality', () => { account2 = await signer2.getAddress(); // initialisation with signer and provider - userKate = await PushNotification.initialize(signer2); + userKate = await PushAPI.initialize(signer2); // initialisation with signer - userAlice = await PushNotification.initialize(signer1); + userAlice = await PushAPI.initialize(signer1); // initialisation without signer - userBob = await PushNotification.initialize(); + userBob = await PushAPI.initialize(signer1); }); describe('delegate :: add', () => { - it('Without signer and account :: should throw error', async () => { + // TODO: remove skip after signer becomes optional + it.skip('Without signer and account :: should throw error', async () => { await expect(() => userBob.delegate.add( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' @@ -70,7 +71,7 @@ describe('PushAPI.notification functionality', () => { ).to.Throw; }); - it('With signer and provider :: should throw error as delegate caip and provider doesnt match', async () => { + it('With viem signer: Should add delegate', async () => { // create polygon mumbai provider const provider = new ethers.providers.JsonRpcProvider( 'https://rpc-mumbai.maticvigil.com' @@ -80,7 +81,7 @@ describe('PushAPI.notification functionality', () => { `0x${process.env['WALLET_PRIVATE_KEY']}`, provider ); - userKate = await PushNotification.initialize(signer2); + userKate = await PushAPI.initialize(signer2); const res = await userKate.delegate.add( 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); @@ -89,8 +90,61 @@ describe('PushAPI.notification functionality', () => { }, 10000000); }); + describe('delegate :: remove', () => { + // TODO: remove skip after signer becomes optional + it.skip('Without signer and account :: should throw error', async () => { + await expect(() => + userBob.delegate.remove( + 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ) + ).to.Throw; + }); + + it('With signer and without provider :: should throw error', async () => { + await expect(() => + userAlice.delegate.remove( + 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ) + ).to.Throw; + }); + + it('With signer and provider :: should add delegate', async () => { + const res = await userKate.delegate.remove( + 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ); + console.log(res); + expect(res).not.null; + }, 100000000); + + it('With signer and provider :: should throw error as delegate caip and provider doesnt match', async () => { + await expect(() => + userKate.delegate.remove( + 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ) + ).to.Throw; + }); + + it('With viem signer: Should add delegate', async () => { + // create polygon mumbai provider + const provider = new ethers.providers.JsonRpcProvider( + 'https://rpc-mumbai.maticvigil.com' + ); + + signer2 = new ethers.Wallet( + `0x${process.env['WALLET_PRIVATE_KEY']}`, + provider + ); + userKate = await PushAPI.initialize(signer2); + const res = await userKate.delegate.remove( + 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' + ); + // console.log(res); + expect(res).not.null; + }, 10000000); + }); + describe('delegate :: get', () => { - it('Without signer and account : Should throw error', async () => { + it.skip('Without signer and account : Should throw error', async () => { await expect(() => userBob.delegate.get()).to.Throw; }); it('Without signer : Should throw error for non-caip format', async () => { @@ -105,7 +159,7 @@ describe('PushAPI.notification functionality', () => { const res = await userBob.delegate.get({ channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', }); - // console.log(res) + console.log(res); expect(res).not.null; }); @@ -119,7 +173,7 @@ describe('PushAPI.notification functionality', () => { it('With signer : Should fetch delegates for channel', async () => { const res = await userKate.delegate.get(); - // console.log(res); + // console.log(res); expect(res).not.null; }); }); diff --git a/packages/restapi/tests/lib/pushNotification/notification.test.ts b/packages/restapi/tests/lib/pushNotification/notification.test.ts index 283f1e726..c0abb64de 100644 --- a/packages/restapi/tests/lib/pushNotification/notification.test.ts +++ b/packages/restapi/tests/lib/pushNotification/notification.test.ts @@ -2,23 +2,23 @@ import * as path from 'path'; import * as dotenv from 'dotenv'; dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); -import { PushNotification } from '../../../src/lib/pushNotification/PushNotification'; // Ensure correct import path +import { PushAPI } from '../../../src/lib/pushapi/PushAPI'; // Ensure correct import path import { expect } from 'chai'; import { ethers } from 'ethers'; import { createWalletClient, http } from 'viem'; import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; import { goerli } from 'viem/chains'; // import tokenABI from './tokenABI'; -describe('PushAPI.notification functionality', () => { - let userAlice: PushNotification; - let userBob: PushNotification; - let userKate: PushNotification; +describe.only('PushAPI.notification functionality', () => { + let userAlice: PushAPI; + let userBob: PushAPI; + let userKate: PushAPI; let signer1: any; let account1: string; let signer2: any; let account2: string; let viemSigner: any; - let userViem: PushNotification; + let userViem: PushAPI; beforeEach(async () => { signer1 = new ethers.Wallet( `0x${process.env['NFT_HOLDER_WALLET_PRIVATE_KEY_1']}` @@ -42,13 +42,14 @@ describe('PushAPI.notification functionality', () => { transport: http(), }); // initialisation with signer and provider - userKate = await PushNotification.initialize(signer2); + userKate = await PushAPI.initialize(signer2); // initialisation with signer - userAlice = await PushNotification.initialize(signer1); + userAlice = await PushAPI.initialize(signer1); + // TODO: remove signer1 after signer becomes optional // initialisation without signer - userBob = await PushNotification.initialize(); + userBob = await PushAPI.initialize(signer1); // initialisation with viem - userViem = await PushNotification.initialize(viemSigner); + userViem = await PushAPI.initialize(viemSigner); }); describe('notification :: list', () => { @@ -73,7 +74,7 @@ describe('PushAPI.notification functionality', () => { expect(response.length).not.equal(0); }); - it('Should throw error without signer object when an account is not passed', async () => { + it.skip('Should throw error without signer object when an account is not passed', async () => { await expect(() => userBob.notification.list('SPAM')).to.Throw; }); @@ -84,6 +85,7 @@ describe('PushAPI.notification functionality', () => { it('Should return feeds when viem is used', async () => { const response = await userViem.notification.list('SPAM'); + console.log(response) expect(response).not.null; }); @@ -93,7 +95,7 @@ describe('PushAPI.notification functionality', () => { channels: ['0xD8634C39BBFd4033c0d3289C4515275102423681'], raw: true, }); - // console.log(response) + // console.log(response) expect(response).not.null; }); }); @@ -118,7 +120,7 @@ describe('PushAPI.notification functionality', () => { 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' ); }); - it('Without signer object: should throw error', async () => { + it.skip('Without signer object: should throw error', async () => { await expect(() => userBob.notification.subscribe( 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' @@ -126,7 +128,7 @@ describe('PushAPI.notification functionality', () => { ).to.Throw; }); - it('With signer object: should throw error for invalid channel caip', async () => { + it.skip('With signer object: should throw error for invalid channel caip', async () => { await expect(() => { userAlice.notification.subscribe( '0xD8634C39BBFd4033c0d3289C4515275102423681' @@ -138,6 +140,7 @@ describe('PushAPI.notification functionality', () => { const res = await userAlice.notification.subscribe( 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' ); + console.log(res) expect(res).not.null; }); @@ -159,13 +162,13 @@ describe('PushAPI.notification functionality', () => { }); describe('notification :: subscriptions', () => { - it('No signer or account: Should throw error', async () => { + it.skip('No signer or account: Should throw error', async () => { await expect(() => userBob.notification.subscriptions()).to.Throw; }); it('Signer with no account: Should return response', async () => { const response = await userAlice.notification.subscriptions(); - // console.log(response); + console.log(response); expect(response).not.null; }); diff --git a/packages/restapi/tests/lib/pushapi/chat.test.ts b/packages/restapi/tests/lib/pushapi/chat.test.ts index b7ebbf683..c98e3e0ca 100644 --- a/packages/restapi/tests/lib/pushapi/chat.test.ts +++ b/packages/restapi/tests/lib/pushapi/chat.test.ts @@ -52,4 +52,15 @@ describe('PushAPI.chat functionality', () => { }); expect(response).to.be.an('object'); }); + it('Should decrypt message ', async () => { + await userAlice.chat.send(account2, { + content: 'Hello', + type: MessageType.TEXT, + }); + const messagePayloads = await userAlice.chat.history(account2); + const decryptedMessagePayloads = await userBob.chat.decrypt( + messagePayloads + ); + expect(decryptedMessagePayloads).to.be.an('array'); + }); }); diff --git a/packages/restapi/tests/lib/pushstream/initialize.test.ts b/packages/restapi/tests/lib/pushstream/initialize.test.ts new file mode 100644 index 000000000..a82618466 --- /dev/null +++ b/packages/restapi/tests/lib/pushstream/initialize.test.ts @@ -0,0 +1,363 @@ +import * as path from 'path'; +import * as dotenv from 'dotenv'; +dotenv.config({ path: path.resolve(__dirname, '../../.env') }); +import { expect } from 'chai'; // Assuming you're using chai for assertions +import { ethers } from 'ethers'; +import { PushAPI } from '../../../src/lib/pushapi/PushAPI'; +import { sendNotification } from '../../../src/lib/payloads/sendNotifications'; +import { subscribe, unsubscribe } from '../../../src/lib/channels'; + +import { ENV } from '../../../src/lib/constants'; +import { STREAM } from '../../../src/lib/pushstream/pushStreamTypes'; +import * as util from 'util'; +import { ConditionType } from '../../../src/lib'; + +describe('PushStream.initialize functionality', () => { + it('Should initialize new stream and listen to events', async () => { + const MESSAGE = 'Hey There!!!'; + + const provider = ethers.getDefaultProvider(); + + const WALLET = ethers.Wallet.createRandom(); + const signer = new ethers.Wallet(WALLET.privateKey, provider); + const user = await PushAPI.initialize(signer, { + env: ENV.LOCAL, + streamOptions: { raw: true }, + }); + + const WALLET2 = ethers.Wallet.createRandom(); + const signer2 = new ethers.Wallet(WALLET2.privateKey, provider); + const user2 = await PushAPI.initialize(signer2, { + env: ENV.LOCAL, + }); + + const WALLET3 = ethers.Wallet.createRandom(); + const signer3 = new ethers.Wallet(WALLET3.privateKey, provider); + const user3 = await PushAPI.initialize(signer3, { + env: ENV.LOCAL, + }); + + const WALLET4 = ethers.Wallet.createRandom(); + const signer4 = new ethers.Wallet(WALLET4.privateKey, provider); + const user4 = await PushAPI.initialize(signer4, { + env: ENV.LOCAL, + }); + + const GROUP_RULES = { + entry: { + conditions: [ + { + any: [ + { + type: 'PUSH', + category: 'CustomEndpoint', + subcategory: 'GET', + data: { + url: 'https://api.ud-staging.com/profile/badges/dead_pixel/validate/{{user_address}}?rule=join', + }, + }, + ], + }, + ], + }, + chat: { + conditions: [ + { + any: [ + { + type: 'PUSH', + category: 'CustomEndpoint', + subcategory: 'GET', + data: { + url: 'https://api.ud-staging.com/profile/badges/dead_pixel/validate/{{user_address}}?rule=chat', + }, + }, + ], + }, + ], + }, + }; + + const CREATE_GROUP_REQUEST = { + description: 'test', + image: 'test', + members: [], + admins: [], + private: false, + rules: { + chat: { + conditions: { + any: [ + { + type: ConditionType.PUSH, + category: 'ERC20', + subcategory: 'holder', + data: { + contract: + 'eip155:1:0xf418588522d5dd018b425E472991E52EBBeEEEEE', + amount: 1, + decimals: 18, + }, + }, + { + type: ConditionType.PUSH, + category: 'INVITE', + subcategory: 'DEFAULT', + data: { + inviterRoles: ['ADMIN', 'OWNER'], + }, + }, + ], + }, + }, + }, + }; + + const CREATE_GROUP_REQUEST_2 = { + description: 'test', + image: 'test', + members: [], + admins: [], + private: false, + rules: {}, + }; + + const stream = user.stream; + + const createEventPromise = ( + expectedEvent: string, + eventType: string, + expectedEventCount: number + ) => { + return new Promise((resolve, reject) => { + let eventCount = 0; + if (expectedEventCount == 0) { + resolve('Done'); + } + const receivedEvents: any[] = []; + stream.on(eventType, (data: any) => { + try { + receivedEvents.push(data); + eventCount++; + + console.log( + `Event ${eventCount} for ${expectedEvent}:`, + util.inspect(data, { + showHidden: false, + depth: null, + colors: true, + }) + ); + expect(data).to.not.be.null; + + if (eventCount === expectedEventCount) { + resolve(receivedEvents); + } + } catch (error) { + console.error('An error occurred:', error); + reject(error); + } + }); + }); + }; + + // leave admin bug + // group creator check remove add + + const onDataReceived = createEventPromise('CHAT_OPS', STREAM.CHAT_OPS, 5); + const onMessageReceived = createEventPromise('CHAT', STREAM.CHAT, 4); + const onNoitificationsReceived = createEventPromise('NOTIF', STREAM.NOTIF, 4); + + // Create and update group + /*const createdGroup = await user.chat.group.create( + 'test', + CREATE_GROUP_REQUEST_2 + );*/ + + /*const w2wMessageResponse = await user2.chat.send(signer.address, { + content: MESSAGE, + }); + const w2wAcceptsRequest = await user.chat.accept(signer2.address); + + const w2wMessageResponse2 = await user2.chat.send(signer.address, { + content: MESSAGE, + });*/ + + const channelPrivateKey = process.env['WALLET_PRIVATE_KEY']; + + const signerChannel = new ethers.Wallet(`0x${channelPrivateKey}`); + const channelAddress = signerChannel.address; + + console.log(channelAddress); + + const response = await subscribe({ + signer: signer, + channelAddress: `eip155:5:${channelAddress}`, // channel address in CAIP + userAddress: `eip155:5:${signer.address}`, // user address in CAIP + onSuccess: () => { + console.log('opt in success'); + }, + onError: () => { + console.error('opt in error'); + }, + env: ENV.LOCAL, + }); + + + const apiResponse = await sendNotification({ + signer: signerChannel, // Needs to resolve to channel address + type: 1, // broadcast + identityType: 2, // direct payload + notification: { + title: `notification TITLE:`, + body: `notification BODY`, + }, + payload: { + title: `payload title`, + body: `sample msg body`, + cta: '', + img: '', + }, + channel: `eip155:5:${channelAddress}`, // your channel address + env: ENV.LOCAL, + }); + + + const response2 = await unsubscribe({ + signer: signer, + channelAddress: `eip155:5:${channelAddress}`, // channel address in CAIP + userAddress: `eip155:5:${signer.address}`, // user address in CAIP + onSuccess: () => { + console.log('opt out success'); + }, + onError: () => { + console.error('opt out error'); + }, + env: ENV.LOCAL, + }); + + + const apiResponse2 = await sendNotification({ + signer: signerChannel, // Needs to resolve to channel address + type: 3, // broadcast + identityType: 2, // direct payload + notification: { + title: `notification TITLE:`, + body: `notification BODY`, + }, + payload: { + title: `payload title`, + body: `sample msg body`, + cta: '', + img: '', + }, + recipients: `eip155:5:${signer.address}`, + channel: `eip155:5:${channelAddress}`, // your channel address + env: ENV.LOCAL, + }); + + + /*const updatedGroup = await user.chat.group.update(createdGroup.chatId, { + description: 'Updated Description', + });*/ + + //const w2wRejectRequest = await user2.chat.group.join(createdGroup.chatId); + //const updatedGroup2 = await user2.chat.group.leave(createdGroup.chatId); + + /*const updatedGroup3 = await user.chat.group.add(createdGroup.chatId, { + role: 'ADMIN', + accounts: [signer2.address], + }); + + + + const w2wAcceptsRequest = await user2.chat.group.join(createdGroup.chatId); + + /* const updatedGroup4 = await user.chat.group.add( + createdGroup.chatId, + { + role: 'ADMIN', + accounts: [signer3.address], + } + );*/ + + /*const w2wMessageResponse = await user2.chat.send(signer.address, { + content: MESSAGE, + }); + const w2wAcceptsRequest = await user.chat.accept(signer2.address); + + const w2wMessageResponse2 = await user2.chat.send(signer.address, { + content: MESSAGE, + }); + + //const w2wRejectRequest = await user2.chat.group.join(createdGroup.chatId); + + /* + + const updatedGroup = await user.chat.group.add(createdGroup.chatId, { + role: 'ADMIN', + accounts: [signer2.address, signer3.address, signer4.address], + }); + + const w2wRejectRequest = await user2.chat.group.join(createdGroup.chatId); + + const updatedGroup2 = await user2.chat.group.leave(createdGroup.chatId); + + + + const updatedGroup = await user.chat.group.update(createdGroup.chatId, { + description: 'Updated Description', + }); + + const groupMessageResponse = await user.chat.send(createdGroup.chatId, { + content: 'Hello', + type: MessageType.TEXT, + }); + + + + const w2wMessageResponse2 = await user2.chat.send(signer.address, { + content: MESSAGE, + }); + + const w2wMessageResponse2 = await user3.chat.send(signer.address, { + content: MESSAGE, + }); + const w2wRejectRequest = await user.chat.reject(signer3.address);*/ + + let timeoutTriggered = false; + + const timeout = new Promise((_, reject) => { + setTimeout(() => { + timeoutTriggered = true; + reject(new Error('Timeout after 5 seconds')); + }, 5000); + }); + + // Wrap the Promise.allSettled inside a Promise.race with the timeout + try { + const result = await Promise.race([ + Promise.allSettled([ + onDataReceived, + onMessageReceived, + onNoitificationsReceived, + ]), + timeout, + ]); + + if (timeoutTriggered) { + console.error('Timeout reached before events were emitted.'); + } else { + (result as PromiseSettledResult[]).forEach((outcome) => { + if (outcome.status === 'fulfilled') { + //console.log(outcome.value); + } else if (outcome.status === 'rejected') { + console.error(outcome.reason); + } + }); + } + } catch (error) { + console.error(error); + } + }); +}); diff --git a/packages/restapi/yarn.lock b/packages/restapi/yarn.lock index de55ed8e8..1a2318580 100644 --- a/packages/restapi/yarn.lock +++ b/packages/restapi/yarn.lock @@ -397,12 +397,12 @@ "@hapi/hoek@^9.0.0": version "9.3.0" - resolved "https://registry.yarnpkg.com/@hapi/hoek/-/hoek-9.3.0.tgz#8368869dcb735be2e7f5cb7647de78e167a251fb" + resolved "https://registry.npmjs.org/@hapi/hoek/-/hoek-9.3.0.tgz" integrity sha512-/c6rf4UJlmHlC9b5BaNvzAcFv7HZ2QHaV0D4/HNlBdvFnvQq8RI4kYdhyPCl7Xj+oWvTWQ8ujhqS53LIgAe6KQ== "@hapi/topo@^5.0.0": version "5.1.0" - resolved "https://registry.yarnpkg.com/@hapi/topo/-/topo-5.1.0.tgz#dc448e332c6c6e37a4dc02fd84ba8d44b9afb012" + resolved "https://registry.npmjs.org/@hapi/topo/-/topo-5.1.0.tgz" integrity sha512-foQZKJig7Ob0BMAYBfcJk8d77QtOe7Wo4ox7ff1lQYoNNAb6jwcY1ncdoy2e9wQZzvNy7ODZCYJkK8kzmcAnAg== dependencies: "@hapi/hoek" "^9.0.0" @@ -425,10 +425,10 @@ "@jridgewell/resolve-uri" "^3.0.3" "@jridgewell/sourcemap-codec" "^1.4.10" -"@livepeer/core@^1.8.0": - version "1.8.0" - resolved "https://registry.npmjs.org/@livepeer/core/-/core-1.8.0.tgz" - integrity sha512-Sr+DplfGfhpv2Arh53tTTL9DyPEzlVAzy+eXd8+PMIlXLVOHTgGfDgpfpaeSCB8v8WlJtrgX50vFdSWyUyxi3g== +"@livepeer/core@^1.8.6": + version "1.8.6" + resolved "https://registry.npmjs.org/@livepeer/core/-/core-1.8.6.tgz" + integrity sha512-VWMHaHMzNCr8YuC9hD87Ju+fwnpldEoe3y9CqOXrQPyyIgiAWfraZBA6Ard67f09X9UBGaaRcAMgMcCUs9HtKA== dependencies: cross-fetch "^4.0.0" ms "^3.0.0-canary.1" @@ -470,6 +470,14 @@ resolved "https://registry.npmjs.org/@noble/secp256k1/-/secp256k1-1.7.1.tgz" integrity sha512-hOUk6AyBFmqVrv7k5WAw/LpszxVbj9gGN4JRkIX52fdFAj1UA61KXmZDvqVEm+pOyec3+fIeZB02LYa/pWOArw== +"@pushprotocol/socket@^0.5.2": + version "0.5.2" + resolved "https://registry.npmjs.org/@pushprotocol/socket/-/socket-0.5.2.tgz" + integrity sha512-lVGMT3q8T5by6qwAhQ+zIeE/yv7oUC9eIlFux8M7WaKu/ArLBrrojD5REbr9QXXwpJIP3Q8GJUKyClZl4uGsJw== + dependencies: + socket.io-client "^4.5.2" + tslib "^2.3.0" + "@scure/base@~1.1.0": version "1.1.1" resolved "https://registry.npmjs.org/@scure/base/-/base-1.1.1.tgz" @@ -494,21 +502,26 @@ "@sideway/address@^4.1.3": version "4.1.4" - resolved "https://registry.yarnpkg.com/@sideway/address/-/address-4.1.4.tgz#03dccebc6ea47fdc226f7d3d1ad512955d4783f0" + resolved "https://registry.npmjs.org/@sideway/address/-/address-4.1.4.tgz" integrity sha512-7vwq+rOHVWjyXxVlR76Agnvhy8I9rpzjosTESvmhNeXOXdZZB15Fl+TI9x1SiHZH5Jv2wTGduSxFDIaq0m3DUw== dependencies: "@hapi/hoek" "^9.0.0" "@sideway/formula@^3.0.1": version "3.0.1" - resolved "https://registry.yarnpkg.com/@sideway/formula/-/formula-3.0.1.tgz#80fcbcbaf7ce031e0ef2dd29b1bfc7c3f583611f" + resolved "https://registry.npmjs.org/@sideway/formula/-/formula-3.0.1.tgz" integrity sha512-/poHZJJVjx3L+zVD6g9KgHfYnb443oi7wLu/XKojDviHy6HOEOA6z1Trk5aR1dGcmPenJEgb2sK2I80LeS3MIg== "@sideway/pinpoint@^2.0.0": version "2.0.0" - resolved "https://registry.yarnpkg.com/@sideway/pinpoint/-/pinpoint-2.0.0.tgz#cff8ffadc372ad29fd3f78277aeb29e632cc70df" + resolved "https://registry.npmjs.org/@sideway/pinpoint/-/pinpoint-2.0.0.tgz" integrity sha512-RNiOoTPkptFtSVzQevY/yWtZwf/RxyVnPy/OcA9HBM3MlGDnBEYL5B41H0MTn0Uec8Hi+2qUtTfG2WWZBmMejQ== +"@socket.io/component-emitter@~3.1.0": + version "3.1.0" + resolved "https://registry.npmjs.org/@socket.io/component-emitter/-/component-emitter-3.1.0.tgz" + integrity sha512-+9jVqKhRSpsc591z5vX+X5Yyw+he/HCB4iQ/RYxw35CEPaY1gnsNE43nf9n9AaYjAQrTiI/mOwKUKdUs9vf7Xg== + "@stitches/core@^1.2.8": version "1.2.8" resolved "https://registry.npmjs.org/@stitches/core/-/core-1.2.8.tgz" @@ -642,23 +655,24 @@ array-buffer-byte-length@^1.0.0: is-array-buffer "^3.0.1" array.prototype.every@^1.1.4: - version "1.1.4" - resolved "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.4.tgz" - integrity sha512-Aui35iRZk1HHLRAyF7QP0KAnOnduaQ6fo6k1NVWfRc0xTs2AZ70ytlXvOmkC6Di4JmUs2Wv3DYzGtCQFSk5uGg== + version "1.1.5" + resolved "https://registry.npmjs.org/array.prototype.every/-/array.prototype.every-1.1.5.tgz" + integrity sha512-FfMQJ+/joFGXpRCltbzV3znaP5QxIhLFySo0fEPn3GuoYlud9LhknMCIxdYKC2qsM/6VHoSp6YGwe3EZXrEcwQ== dependencies: call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" + define-properties "^1.2.0" + es-abstract "^1.22.1" is-string "^1.0.7" -arraybuffer.prototype.slice@^1.0.1: - version "1.0.1" - resolved "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.1.tgz" - integrity sha512-09x0ZWFEjj4WD8PDbykUwo3t9arLn8NIzmmYEJFpYekOAQjpkGSyrQhNoRTcwwcFRu+ycWF78QZ63oWTqSjBcw== +arraybuffer.prototype.slice@^1.0.2: + version "1.0.2" + resolved "https://registry.npmjs.org/arraybuffer.prototype.slice/-/arraybuffer.prototype.slice-1.0.2.tgz" + integrity sha512-yMBKppFur/fbHu9/6USUe03bZ4knMYiwFBcyiaXB8Go0qNehwX6inYPzK9U0NeQvGxKthcmHcaR8P5MStSRBAw== dependencies: array-buffer-byte-length "^1.0.0" call-bind "^1.0.2" define-properties "^1.2.0" + es-abstract "^1.22.1" get-intrinsic "^1.2.1" is-array-buffer "^3.0.2" is-shared-array-buffer "^1.0.2" @@ -915,9 +929,9 @@ concat-map@0.0.1: integrity sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg== core-js@^3.31.1: - version "3.32.0" - resolved "https://registry.npmjs.org/core-js/-/core-js-3.32.0.tgz" - integrity sha512-rd4rYZNlF3WuoYuRIDEmbR/ga9CeuWX9U05umAvgrrZoHY4Z++cp/xwPQMvUpBB4Ag6J8KfD80G0zwCyaSxDww== + version "3.32.2" + resolved "https://registry.npmjs.org/core-js/-/core-js-3.32.2.tgz" + integrity sha512-pxXSw1mYZPDGvTQqEc5vgIb83jGQKFGYWY76z4a7weZXUolw3G+OvpZqSRcfYOoOVUQJYEPsWeQK8pKEnUtWxQ== core-util-is@~1.0.0: version "1.0.3" @@ -957,7 +971,7 @@ custom-error-instance@2.1.1: resolved "https://registry.npmjs.org/custom-error-instance/-/custom-error-instance-2.1.1.tgz" integrity sha512-p6JFxJc3M4OTD2li2qaHkDCw9SfMw82Ldr6OC9Je1aXiGfhx2W8p3GaoeaGrPJTUN9NirTM/KTxHWMUdR1rsUg== -debug@4.3.4, debug@^4.3.2: +debug@4.3.4, debug@^4.3.2, debug@~4.3.1, debug@~4.3.2: version "4.3.4" resolved "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== @@ -1005,11 +1019,21 @@ deep-equal@^2.2.2: which-collection "^1.0.1" which-typed-array "^1.1.9" +define-data-property@^1.0.1: + version "1.1.0" + resolved "https://registry.npmjs.org/define-data-property/-/define-data-property-1.1.0.tgz" + integrity sha512-UzGwzcjyv3OtAvolTj1GoyNYzfFR+iqbGjcnBEENZVCpM4/Ng1yhGNvS3lR/xDS74Tb2wGG9WzNSNIOS9UVb2g== + dependencies: + get-intrinsic "^1.2.1" + gopd "^1.0.1" + has-property-descriptors "^1.0.0" + define-properties@^1.1.3, define-properties@^1.1.4, define-properties@^1.2.0: - version "1.2.0" - resolved "https://registry.npmjs.org/define-properties/-/define-properties-1.2.0.tgz" - integrity sha512-xvqAVKGfT1+UAvPwKTVw/njhdQ8ZhXK4lI0bCIuCMrp2up9nPnaDftrLtmpTazqd1o+UY4zgzU+avtMbDP+ldA== + version "1.2.1" + resolved "https://registry.npmjs.org/define-properties/-/define-properties-1.2.1.tgz" + integrity sha512-8QmQKqEASLd5nx0U1B1okLElbUuuttJ/AnYmRXbbbGDWh6uS208EjD4Xqq/I9wK7u0v6O08XhTWnt5XtEbR6Dg== dependencies: + define-data-property "^1.0.1" has-property-descriptors "^1.0.0" object-keys "^1.1.1" @@ -1065,23 +1089,39 @@ end-of-stream@^1.1.0: dependencies: once "^1.4.0" +engine.io-client@~6.5.2: + version "6.5.2" + resolved "https://registry.npmjs.org/engine.io-client/-/engine.io-client-6.5.2.tgz" + integrity sha512-CQZqbrpEYnrpGqC07a9dJDz4gePZUgTPMU3NKJPSeQOyw27Tst4Pl3FemKoFGAlHzgZmKjoRmiJvbWfhCXUlIg== + dependencies: + "@socket.io/component-emitter" "~3.1.0" + debug "~4.3.1" + engine.io-parser "~5.2.1" + ws "~8.11.0" + xmlhttprequest-ssl "~2.0.0" + +engine.io-parser@~5.2.1: + version "5.2.1" + resolved "https://registry.npmjs.org/engine.io-parser/-/engine.io-parser-5.2.1.tgz" + integrity sha512-9JktcM3u18nU9N2Lz3bWeBgxVgOKpw7yhRaoxQA3FUDZzzw+9WlA6p4G4u0RixNkg14fH7EfEc/RhpurtiROTQ== + err-code@^3.0.1: version "3.0.1" resolved "https://registry.npmjs.org/err-code/-/err-code-3.0.1.tgz" integrity sha512-GiaH0KJUewYok+eeY05IIgjtAe4Yltygk9Wqp1V5yVWLdhf0hYZchRjNIT9bb0mSwRcIusT3cx7PJUf3zEIfUA== -es-abstract@^1.19.0, es-abstract@^1.20.4: - version "1.22.1" - resolved "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.1.tgz" - integrity sha512-ioRRcXMO6OFyRpyzV3kE1IIBd4WG5/kltnzdxSCqoP8CMGs/Li+M1uF5o7lOkZVFjDs+NLesthnF66Pg/0q0Lw== +es-abstract@^1.22.1: + version "1.22.2" + resolved "https://registry.npmjs.org/es-abstract/-/es-abstract-1.22.2.tgz" + integrity sha512-YoxfFcDmhjOgWPWsV13+2RNjq1F6UQnfs+8TftwNqtzlmFzEXvlUwdrNrYeaizfjQzRMxkZ6ElWMOJIFKdVqwA== dependencies: array-buffer-byte-length "^1.0.0" - arraybuffer.prototype.slice "^1.0.1" + arraybuffer.prototype.slice "^1.0.2" available-typed-arrays "^1.0.5" call-bind "^1.0.2" es-set-tostringtag "^2.0.1" es-to-primitive "^1.2.1" - function.prototype.name "^1.1.5" + function.prototype.name "^1.1.6" get-intrinsic "^1.2.1" get-symbol-description "^1.0.0" globalthis "^1.0.3" @@ -1097,23 +1137,23 @@ es-abstract@^1.19.0, es-abstract@^1.20.4: is-regex "^1.1.4" is-shared-array-buffer "^1.0.2" is-string "^1.0.7" - is-typed-array "^1.1.10" + is-typed-array "^1.1.12" is-weakref "^1.0.2" object-inspect "^1.12.3" object-keys "^1.1.1" object.assign "^4.1.4" - regexp.prototype.flags "^1.5.0" - safe-array-concat "^1.0.0" + regexp.prototype.flags "^1.5.1" + safe-array-concat "^1.0.1" safe-regex-test "^1.0.0" - string.prototype.trim "^1.2.7" - string.prototype.trimend "^1.0.6" - string.prototype.trimstart "^1.0.6" + string.prototype.trim "^1.2.8" + string.prototype.trimend "^1.0.7" + string.prototype.trimstart "^1.0.7" typed-array-buffer "^1.0.0" typed-array-byte-length "^1.0.0" typed-array-byte-offset "^1.0.0" typed-array-length "^1.0.4" unbox-primitive "^1.0.2" - which-typed-array "^1.1.10" + which-typed-array "^1.1.11" es-get-iterator@^1.1.3: version "1.1.3" @@ -1232,7 +1272,7 @@ execa@^1.0.0: figures@^1.4.0: version "1.7.0" - resolved "https://registry.yarnpkg.com/figures/-/figures-1.7.0.tgz#cbe1e3affcf1cd44b80cadfed28dc793a9701d2e" + resolved "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz" integrity sha512-UxKlfCRuCBxSXU4C6t9scbDyWZ4VlaFFdojKtzJuSkuOBQ5CNFum+zZXFwHjo+CxBC1t6zlYPgHIgFjL8ggoEQ== dependencies: escape-string-regexp "^1.0.5" @@ -1267,7 +1307,7 @@ flat@^5.0.2: for-each@^0.3.3: version "0.3.3" - resolved "https://registry.yarnpkg.com/for-each/-/for-each-0.3.3.tgz#69b447e88a0a5d32c3e7084f3f1710034b21376e" + resolved "https://registry.npmjs.org/for-each/-/for-each-0.3.3.tgz" integrity sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw== dependencies: is-callable "^1.1.3" @@ -1284,22 +1324,22 @@ fsevents@~2.3.2: function-bind@^1.1.1: version "1.1.1" - resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.1.tgz#a56899d3ea3c9bab874bb9773b7c5ede92f4895d" + resolved "https://registry.npmjs.org/function-bind/-/function-bind-1.1.1.tgz" integrity sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A== -function.prototype.name@^1.1.5: - version "1.1.5" - resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.1.5.tgz#cce0505fe1ffb80503e6f9e46cc64e46a12a9621" - integrity sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA== +function.prototype.name@^1.1.6: + version "1.1.6" + resolved "https://registry.npmjs.org/function.prototype.name/-/function.prototype.name-1.1.6.tgz" + integrity sha512-Z5kx79swU5P27WEayXM1tBi5Ze/lbIyiNgU3qyXUOf9b2rgXYyF9Dy9Cx+IQv/Lc8WCG6L82zwUPpSS9hGehIg== dependencies: call-bind "^1.0.2" - define-properties "^1.1.3" - es-abstract "^1.19.0" - functions-have-names "^1.2.2" + define-properties "^1.2.0" + es-abstract "^1.22.1" + functions-have-names "^1.2.3" -functions-have-names@^1.2.2, functions-have-names@^1.2.3: +functions-have-names@^1.2.3: version "1.2.3" - resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" + resolved "https://registry.npmjs.org/functions-have-names/-/functions-have-names-1.2.3.tgz" integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== get-browser-rtc@^1.1.0: @@ -1324,7 +1364,7 @@ get-func-name@^2.0.0: get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@^1.2.0, get-intrinsic@^1.2.1: version "1.2.1" - resolved "https://registry.yarnpkg.com/get-intrinsic/-/get-intrinsic-1.2.1.tgz#d295644fed4505fc9cde952c37ee12b477a83d82" + resolved "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.2.1.tgz" integrity sha512-2DcsyfABl+gVHEfCOaTrWgyt+tb6MSEGmKq+kI5HwLbIYgjgmMcV8KQ41uaKz1xxUcn9tJtgFbQUEVcEbd0FYw== dependencies: function-bind "^1.1.1" @@ -1334,7 +1374,7 @@ get-intrinsic@^1.0.2, get-intrinsic@^1.1.1, get-intrinsic@^1.1.3, get-intrinsic@ get-package-type@^0.1.0: version "0.1.0" - resolved "https://registry.yarnpkg.com/get-package-type/-/get-package-type-0.1.0.tgz#8de2d803cff44df3bc6c456e6668b36c3926e11a" + resolved "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz" integrity sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q== get-stream@^4.0.0: @@ -1346,7 +1386,7 @@ get-stream@^4.0.0: get-symbol-description@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.0.tgz#7fdb81c900101fbd564dd5f1a30af5aadc1e58d6" + resolved "https://registry.npmjs.org/get-symbol-description/-/get-symbol-description-1.0.0.tgz" integrity sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw== dependencies: call-bind "^1.0.2" @@ -1373,7 +1413,7 @@ glob@7.2.0: glob@^7.2.3: version "7.2.3" - resolved "https://registry.yarnpkg.com/glob/-/glob-7.2.3.tgz#b8df0fb802bbfa8e89bd1d938b4e16578ed44f2b" + resolved "https://registry.npmjs.org/glob/-/glob-7.2.3.tgz" integrity sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q== dependencies: fs.realpath "^1.0.0" @@ -1385,38 +1425,38 @@ glob@^7.2.3: globalthis@^1.0.3: version "1.0.3" - resolved "https://registry.yarnpkg.com/globalthis/-/globalthis-1.0.3.tgz#5852882a52b80dc301b0660273e1ed082f0b6ccf" + resolved "https://registry.npmjs.org/globalthis/-/globalthis-1.0.3.tgz" integrity sha512-sFdI5LyBiNTHjRd7cGPWapiHWMOXKyuBNX/cWJ3NfzrZQVa8GI/8cofCl74AOVqq9W5kNmguTIzJ/1s2gyI9wA== dependencies: define-properties "^1.1.3" gopd@^1.0.1: version "1.0.1" - resolved "https://registry.yarnpkg.com/gopd/-/gopd-1.0.1.tgz#29ff76de69dac7489b7c0918a5788e56477c332c" + resolved "https://registry.npmjs.org/gopd/-/gopd-1.0.1.tgz" integrity sha512-d65bNlIadxvpb/A2abVdlqKqV563juRnZ1Wtk6s1sIR8uNsXR70xqIzVqxVf1eTqDunwT2MkczEeaezCKTZhwA== dependencies: get-intrinsic "^1.1.3" graceful-fs@^4.2.4: version "4.2.11" - resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" + resolved "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.11.tgz" integrity sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ== has-ansi@^2.0.0: version "2.0.0" - resolved "https://registry.yarnpkg.com/has-ansi/-/has-ansi-2.0.0.tgz#34f5049ce1ecdf2b0649af3ef24e45ed35416d91" + resolved "https://registry.npmjs.org/has-ansi/-/has-ansi-2.0.0.tgz" integrity sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg== dependencies: ansi-regex "^2.0.0" has-bigints@^1.0.1, has-bigints@^1.0.2: version "1.0.2" - resolved "https://registry.yarnpkg.com/has-bigints/-/has-bigints-1.0.2.tgz#0871bd3e3d51626f6ca0966668ba35d5602d6eaa" + resolved "https://registry.npmjs.org/has-bigints/-/has-bigints-1.0.2.tgz" integrity sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ== has-dynamic-import@^2.0.1: version "2.0.1" - resolved "https://registry.yarnpkg.com/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz#9bca87846aa264f2ad224fcd014946f5e5182f52" + resolved "https://registry.npmjs.org/has-dynamic-import/-/has-dynamic-import-2.0.1.tgz" integrity sha512-X3fbtsZmwb6W7fJGR9o7x65fZoodygCrZ3TVycvghP62yYQfS0t4RS0Qcz+j5tQYUKeSWS09tHkWW6WhFV3XhQ== dependencies: call-bind "^1.0.2" @@ -1434,38 +1474,38 @@ has-flag@^4.0.0: has-property-descriptors@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz#610708600606d36961ed04c196193b6a607fa861" + resolved "https://registry.npmjs.org/has-property-descriptors/-/has-property-descriptors-1.0.0.tgz" integrity sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ== dependencies: get-intrinsic "^1.1.1" has-proto@^1.0.1: version "1.0.1" - resolved "https://registry.yarnpkg.com/has-proto/-/has-proto-1.0.1.tgz#1885c1305538958aff469fef37937c22795408e0" + resolved "https://registry.npmjs.org/has-proto/-/has-proto-1.0.1.tgz" integrity sha512-7qE+iP+O+bgF9clE5+UoBFzE65mlBiVj3tKCrlNQ0Ogwm0BjpT/gK4SlLYDMybDh5I3TCTKnPPa0oMG7JDYrhg== has-symbols@^1.0.2, has-symbols@^1.0.3: version "1.0.3" - resolved "https://registry.yarnpkg.com/has-symbols/-/has-symbols-1.0.3.tgz#bb7b2c4349251dce87b125f7bdf874aa7c8b39f8" + resolved "https://registry.npmjs.org/has-symbols/-/has-symbols-1.0.3.tgz" integrity sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A== has-tostringtag@^1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/has-tostringtag/-/has-tostringtag-1.0.0.tgz#7e133818a7d394734f941e73c3d3f9291e658b25" + resolved "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.0.tgz" integrity sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ== dependencies: has-symbols "^1.0.2" has@^1.0.3: version "1.0.3" - resolved "https://registry.yarnpkg.com/has/-/has-1.0.3.tgz#722d7cbfc1f6aa8241f16dd814e011e1f41e8796" + resolved "https://registry.npmjs.org/has/-/has-1.0.3.tgz" integrity sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw== dependencies: function-bind "^1.1.1" hash.js@1.1.7, hash.js@^1.0.0, hash.js@^1.0.3: version "1.1.7" - resolved "https://registry.yarnpkg.com/hash.js/-/hash.js-1.1.7.tgz#0babca538e8d4ee4a0f8988d68866537a003cf42" + resolved "https://registry.npmjs.org/hash.js/-/hash.js-1.1.7.tgz" integrity sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA== dependencies: inherits "^2.0.3" @@ -1477,13 +1517,13 @@ he@1.2.0: integrity sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw== hls.js@^1.4.9: - version "1.4.10" - resolved "https://registry.yarnpkg.com/hls.js/-/hls.js-1.4.10.tgz#3feac40f21a558453b243b5b926b7317e70624e1" - integrity sha512-wAVSj4Fm2MqOHy5+BlYnlKxXvJlv5IuZHjlzHu18QmjRzSDFQiUDWdHs5+NsFMQrgKEBwuWDcyvaMC9dUzJ5Uw== + version "1.4.12" + resolved "https://registry.npmjs.org/hls.js/-/hls.js-1.4.12.tgz" + integrity sha512-1RBpx2VihibzE3WE9kGoVCtrhhDWTzydzElk/kyRbEOLnb1WIE+3ZabM/L8BqKFTCL3pUy4QzhXgD1Q6Igr1JA== hmac-drbg@^1.0.1: version "1.0.1" - resolved "https://registry.yarnpkg.com/hmac-drbg/-/hmac-drbg-1.0.1.tgz#d2745701025a6c775a6c545793ed502fc0c649a1" + resolved "https://registry.npmjs.org/hmac-drbg/-/hmac-drbg-1.0.1.tgz" integrity sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg== dependencies: hash.js "^1.0.3" @@ -1515,7 +1555,7 @@ inherits@2, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.1, internal-slot@^1.0.4, internal-slot@^1.0.5: version "1.0.5" - resolved "https://registry.yarnpkg.com/internal-slot/-/internal-slot-1.0.5.tgz#f2a2ee21f668f8627a4667f309dc0f4fb6674986" + resolved "https://registry.npmjs.org/internal-slot/-/internal-slot-1.0.5.tgz" integrity sha512-Y+R5hJrzs52QCG2laLn4udYVnxsfny9CpOhNhUvk/SSSVyF6T27FzRbF0sroPidSu3X8oEAkOn2K804mjpt6UQ== dependencies: get-intrinsic "^1.2.0" @@ -1529,7 +1569,7 @@ invert-kv@^2.0.0: is-arguments@^1.1.1: version "1.1.1" - resolved "https://registry.yarnpkg.com/is-arguments/-/is-arguments-1.1.1.tgz#15b3f88fda01f2a97fec84ca761a560f123efa9b" + resolved "https://registry.npmjs.org/is-arguments/-/is-arguments-1.1.1.tgz" integrity sha512-8Q7EARjzEnKpt/PCD7e1cgUS0a6X8u5tdSiMqXhojOdoV9TsMsiO+9VLC5vAmO8N7/GmXn7yjR8qnA6bVAEzfA== dependencies: call-bind "^1.0.2" @@ -1537,7 +1577,7 @@ is-arguments@^1.1.1: is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: version "3.0.2" - resolved "https://registry.yarnpkg.com/is-array-buffer/-/is-array-buffer-3.0.2.tgz#f2653ced8412081638ecb0ebbd0c41c6e0aecbbe" + resolved "https://registry.npmjs.org/is-array-buffer/-/is-array-buffer-3.0.2.tgz" integrity sha512-y+FyyR/w8vfIRq4eQcM1EYgSTnmHXPqaF+IgzgraytCFq5Xh8lllDVmAZolPJiZttZLeFSINPYMaEJ7/vWUa1w== dependencies: call-bind "^1.0.2" @@ -1546,7 +1586,7 @@ is-array-buffer@^3.0.1, is-array-buffer@^3.0.2: is-bigint@^1.0.1: version "1.0.4" - resolved "https://registry.yarnpkg.com/is-bigint/-/is-bigint-1.0.4.tgz#08147a1875bc2b32005d41ccd8291dffc6691df3" + resolved "https://registry.npmjs.org/is-bigint/-/is-bigint-1.0.4.tgz" integrity sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg== dependencies: has-bigints "^1.0.1" @@ -1560,7 +1600,7 @@ is-binary-path@~2.1.0: is-boolean-object@^1.1.0: version "1.1.2" - resolved "https://registry.yarnpkg.com/is-boolean-object/-/is-boolean-object-1.1.2.tgz#5c6dc200246dd9321ae4b885a114bb1f75f63719" + resolved "https://registry.npmjs.org/is-boolean-object/-/is-boolean-object-1.1.2.tgz" integrity sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA== dependencies: call-bind "^1.0.2" @@ -1568,19 +1608,19 @@ is-boolean-object@^1.1.0: is-callable@^1.1.3, is-callable@^1.1.4, is-callable@^1.2.7: version "1.2.7" - resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.2.7.tgz#3bc2a85ea742d9e36205dcacdd72ca1fdc51b055" + resolved "https://registry.npmjs.org/is-callable/-/is-callable-1.2.7.tgz" integrity sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA== is-core-module@^2.9.0: - version "2.12.1" - resolved "https://registry.yarnpkg.com/is-core-module/-/is-core-module-2.12.1.tgz#0c0b6885b6f80011c71541ce15c8d66cf5a4f9fd" - integrity sha512-Q4ZuBAe2FUsKtyQJoQHlvP8OvBERxO3jEmy1I7hcRXcJBGGHFh/aJBswbXuS9sgrDH2QUO8ilkwNPHvHMd8clg== + version "2.13.0" + resolved "https://registry.npmjs.org/is-core-module/-/is-core-module-2.13.0.tgz" + integrity sha512-Z7dk6Qo8pOCp3l4tsX2C5ZVas4V+UxwQodwZhLopL91TX8UyyHEXafPcyoeeWuLrwzHcr3igO78wNLwHJHsMCQ== dependencies: has "^1.0.3" is-date-object@^1.0.1, is-date-object@^1.0.5: version "1.0.5" - resolved "https://registry.yarnpkg.com/is-date-object/-/is-date-object-1.0.5.tgz#0841d5536e724c25597bf6ea62e1bd38298df31f" + resolved "https://registry.npmjs.org/is-date-object/-/is-date-object-1.0.5.tgz" integrity sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ== dependencies: has-tostringtag "^1.0.0" @@ -1592,7 +1632,7 @@ is-extglob@^2.1.1: is-finite@^1.0.1: version "1.1.0" - resolved "https://registry.yarnpkg.com/is-finite/-/is-finite-1.1.0.tgz#904135c77fb42c0641d6aa1bcdbc4daa8da082f3" + resolved "https://registry.npmjs.org/is-finite/-/is-finite-1.1.0.tgz" integrity sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w== is-fullwidth-code-point@^1.0.0: @@ -1626,17 +1666,17 @@ is-hex-prefixed@1.0.0: is-map@^2.0.1, is-map@^2.0.2: version "2.0.2" - resolved "https://registry.yarnpkg.com/is-map/-/is-map-2.0.2.tgz#00922db8c9bf73e81b7a335827bc2a43f2b91127" + resolved "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz" integrity sha512-cOZFQQozTha1f4MxLFzlgKYPTyj26picdZTx82hbc/Xf4K/tZOOXSCkMvU4pKioRXGDLJRn0GM7Upe7kR721yg== is-negative-zero@^2.0.2: version "2.0.2" - resolved "https://registry.yarnpkg.com/is-negative-zero/-/is-negative-zero-2.0.2.tgz#7bf6f03a28003b8b3965de3ac26f664d765f3150" + resolved "https://registry.npmjs.org/is-negative-zero/-/is-negative-zero-2.0.2.tgz" integrity sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA== is-number-object@^1.0.4: version "1.0.7" - resolved "https://registry.yarnpkg.com/is-number-object/-/is-number-object-1.0.7.tgz#59d50ada4c45251784e9904f5246c742f07a42fc" + resolved "https://registry.npmjs.org/is-number-object/-/is-number-object-1.0.7.tgz" integrity sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ== dependencies: has-tostringtag "^1.0.0" @@ -1653,7 +1693,7 @@ is-plain-obj@^2.1.0: is-regex@^1.1.4: version "1.1.4" - resolved "https://registry.yarnpkg.com/is-regex/-/is-regex-1.1.4.tgz#eef5663cd59fa4c0ae339505323df6854bb15958" + resolved "https://registry.npmjs.org/is-regex/-/is-regex-1.1.4.tgz" integrity sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg== dependencies: call-bind "^1.0.2" @@ -1661,12 +1701,12 @@ is-regex@^1.1.4: is-set@^2.0.1, is-set@^2.0.2: version "2.0.2" - resolved "https://registry.yarnpkg.com/is-set/-/is-set-2.0.2.tgz#90755fa4c2562dc1c5d4024760d6119b94ca18ec" + resolved "https://registry.npmjs.org/is-set/-/is-set-2.0.2.tgz" integrity sha512-+2cnTEZeY5z/iXGbLhPrOAaK/Mau5k5eXq9j14CpRTftq0pAJu2MwVRSZhyZWBzx3o6X795Lz6Bpb6R0GKf37g== is-shared-array-buffer@^1.0.2: version "1.0.2" - resolved "https://registry.yarnpkg.com/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz#8f259c573b60b6a32d4058a1a07430c0a7344c79" + resolved "https://registry.npmjs.org/is-shared-array-buffer/-/is-shared-array-buffer-1.0.2.tgz" integrity sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA== dependencies: call-bind "^1.0.2" @@ -1678,26 +1718,26 @@ is-stream@^1.1.0: is-stream@^2.0.0: version "2.0.1" - resolved "https://registry.yarnpkg.com/is-stream/-/is-stream-2.0.1.tgz#fac1e3d53b97ad5a9d0ae9cef2389f5810a5c077" + resolved "https://registry.npmjs.org/is-stream/-/is-stream-2.0.1.tgz" integrity sha512-hFoiJiTl63nn+kstHGBtewWSKnQLpyb155KHheA1l39uvtO9nWIop1p3udqPcUd/xbF1VLMO4n7OI6p7RbngDg== is-string@^1.0.5, is-string@^1.0.7: version "1.0.7" - resolved "https://registry.yarnpkg.com/is-string/-/is-string-1.0.7.tgz#0dd12bf2006f255bb58f695110eff7491eebc0fd" + resolved "https://registry.npmjs.org/is-string/-/is-string-1.0.7.tgz" integrity sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg== dependencies: has-tostringtag "^1.0.0" is-symbol@^1.0.2, is-symbol@^1.0.3: version "1.0.4" - resolved "https://registry.yarnpkg.com/is-symbol/-/is-symbol-1.0.4.tgz#a6dac93b635b063ca6872236de88910a57af139c" + resolved "https://registry.npmjs.org/is-symbol/-/is-symbol-1.0.4.tgz" integrity sha512-C/CPBqKWnvdcxqIARxyOh4v1UUEOCHpgDa0WYgpKDFMszcrPcffg5uhwSgPCLD2WWxmq6isisz87tzT01tuGhg== dependencies: has-symbols "^1.0.2" -is-typed-array@^1.1.10, is-typed-array@^1.1.9: +is-typed-array@^1.1.10, is-typed-array@^1.1.12, is-typed-array@^1.1.9: version "1.1.12" - resolved "https://registry.yarnpkg.com/is-typed-array/-/is-typed-array-1.1.12.tgz#d0bab5686ef4a76f7a73097b95470ab199c57d4a" + resolved "https://registry.npmjs.org/is-typed-array/-/is-typed-array-1.1.12.tgz" integrity sha512-Z14TF2JNG8Lss5/HMqt0//T9JeHXttXy5pH/DBU4vi98ozO2btxzq9MwYDZYnKwU8nRsz/+GVFVRDq3DkVuSPg== dependencies: which-typed-array "^1.1.11" @@ -1709,19 +1749,19 @@ is-unicode-supported@^0.1.0: is-weakmap@^2.0.1: version "2.0.1" - resolved "https://registry.yarnpkg.com/is-weakmap/-/is-weakmap-2.0.1.tgz#5008b59bdc43b698201d18f62b37b2ca243e8cf2" + resolved "https://registry.npmjs.org/is-weakmap/-/is-weakmap-2.0.1.tgz" integrity sha512-NSBR4kH5oVj1Uwvv970ruUkCV7O1mzgVFO4/rev2cLRda9Tm9HrL70ZPut4rOHgY0FNrUu9BCbXA2sdQ+x0chA== is-weakref@^1.0.2: version "1.0.2" - resolved "https://registry.yarnpkg.com/is-weakref/-/is-weakref-1.0.2.tgz#9529f383a9338205e89765e0392efc2f100f06f2" + resolved "https://registry.npmjs.org/is-weakref/-/is-weakref-1.0.2.tgz" integrity sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ== dependencies: call-bind "^1.0.2" is-weakset@^2.0.1: version "2.0.2" - resolved "https://registry.yarnpkg.com/is-weakset/-/is-weakset-2.0.2.tgz#4569d67a747a1ce5a994dfd4ef6dcea76e7c0a1d" + resolved "https://registry.npmjs.org/is-weakset/-/is-weakset-2.0.2.tgz" integrity sha512-t2yVvttHkQktwnNNmBQ98AhENLdPUTDTE21uPqAQ0ARwQfGeQKRVS0NNurH7bTf7RrvcVn1OOge45CnBeHCSmg== dependencies: call-bind "^1.0.2" @@ -1729,12 +1769,12 @@ is-weakset@^2.0.1: isarray@^2.0.5: version "2.0.5" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.5.tgz#8af1e4c1221244cc62459faf38940d4e644a5723" + resolved "https://registry.npmjs.org/isarray/-/isarray-2.0.5.tgz" integrity sha512-xHjhDr3cNBK0BzdUJSPXZntQUx/mwMS5Rw4A7lPJ90XGAO6ISP/ePDNuo0vhqOZU+UD5JoodwCAAoZQd3FeAKw== isarray@~1.0.0: version "1.0.0" - resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11" + resolved "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz" integrity sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ== isexe@^2.0.0: @@ -1743,9 +1783,9 @@ isexe@^2.0.0: integrity sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw== joi@^17.9.2: - version "17.9.2" - resolved "https://registry.yarnpkg.com/joi/-/joi-17.9.2.tgz#8b2e4724188369f55451aebd1d0b1d9482470690" - integrity sha512-Itk/r+V4Dx0V3c7RLFdRh12IOjySm2/WGPMubBT92cQvRfYZhPM2W0hZlctjj72iES8jsRCwp7S/cRmWBnJ4nw== + version "17.10.2" + resolved "https://registry.npmjs.org/joi/-/joi-17.10.2.tgz" + integrity sha512-hcVhjBxRNW/is3nNLdGLIjkgXetkeGc2wyhydhz8KumG23Aerk4HPjU5zaPAMRqXQFc0xNqXTC7+zQjxr0GlKA== dependencies: "@hapi/hoek" "^9.0.0" "@hapi/topo" "^5.0.0" @@ -1755,7 +1795,7 @@ joi@^17.9.2: js-base64@^3.7.2: version "3.7.5" - resolved "https://registry.yarnpkg.com/js-base64/-/js-base64-3.7.5.tgz#21e24cf6b886f76d6f5f165bfcd69cc55b9e3fca" + resolved "https://registry.npmjs.org/js-base64/-/js-base64-3.7.5.tgz" integrity sha512-3MEt5DTINKqfScXKfJFrRbxkrnk2AxPWGBL/ycjz4dK8iqiSJ06UxD8jh8xuh6p10TX4t2+7FsBYVxxQbMg+qA== js-sha3@0.8.0: @@ -1778,11 +1818,11 @@ lcid@^2.0.0: invert-kv "^2.0.0" livepeer@^2.5.8: - version "2.8.0" - resolved "https://registry.npmjs.org/livepeer/-/livepeer-2.8.0.tgz" - integrity sha512-ZYw/bew356VZ1MZE6T7NBV6xgQ6yukqutb/GiSk9Yz+vjJvxy2npu4sEhgZ1pkHFVVczcGVwjZidWWaZ+oMwGg== + version "2.8.6" + resolved "https://registry.npmjs.org/livepeer/-/livepeer-2.8.6.tgz" + integrity sha512-8K2lRtpgZKbv6l6cGYYMJW9qpdRKkGUuy7R7xTLkS6NaRQzaeW08vubftmbMHil8v8GX/nDmodcW2vA4oIkP0w== dependencies: - "@livepeer/core" "^1.8.0" + "@livepeer/core" "^1.8.6" "@stitches/core" "^1.2.8" core-js "^3.31.1" cross-fetch "^4.0.0" @@ -1999,9 +2039,9 @@ nice-try@^1.0.4: integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== node-fetch@^2.6.12: - version "2.6.12" - resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.6.12.tgz" - integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== + version "2.7.0" + resolved "https://registry.npmjs.org/node-fetch/-/node-fetch-2.7.0.tgz" + integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== dependencies: whatwg-url "^5.0.0" @@ -2271,14 +2311,14 @@ readdirp@~3.6.0: dependencies: picomatch "^2.2.1" -regexp.prototype.flags@^1.5.0: - version "1.5.0" - resolved "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.0.tgz" - integrity sha512-0SutC3pNudRKgquxGoRGIz946MZVHqbNfPjBdxeOhBrdgDKlRoXmYLQN9xRbrR09ZXWeGAdPuif7egofn6v5LA== +regexp.prototype.flags@^1.5.0, regexp.prototype.flags@^1.5.1: + version "1.5.1" + resolved "https://registry.npmjs.org/regexp.prototype.flags/-/regexp.prototype.flags-1.5.1.tgz" + integrity sha512-sy6TXMN+hnP/wMy+ISxg3krXx7BAtWVO4UouuCN/ziM9UEne0euamVNafDfvC83bRNr95y0V5iijeDQFUNpvrg== dependencies: call-bind "^1.0.2" define-properties "^1.2.0" - functions-have-names "^1.2.3" + set-function-name "^2.0.0" repeat-string@^1.5.2: version "1.6.1" @@ -2314,13 +2354,13 @@ retry@^0.12.0: resolved "https://registry.npmjs.org/retry/-/retry-0.12.0.tgz" integrity sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow== -safe-array-concat@^1.0.0: - version "1.0.0" - resolved "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.0.tgz" - integrity sha512-9dVEFruWIsnie89yym+xWTAYASdpw3CJV7Li/6zBewGf9z2i1j31rP6jnY0pHEO4QZh6N0K11bFjWmdR8UGdPQ== +safe-array-concat@^1.0.1: + version "1.0.1" + resolved "https://registry.npmjs.org/safe-array-concat/-/safe-array-concat-1.0.1.tgz" + integrity sha512-6XbUAseYE2KtOuGueyeobCySj9L4+66Tn6KQMOPQJrAJEowYKW/YR/MGJZl7FdydUdaFu4LYyDZjxf4/Nmo23Q== dependencies: call-bind "^1.0.2" - get-intrinsic "^1.2.0" + get-intrinsic "^1.2.1" has-symbols "^1.0.3" isarray "^2.0.5" @@ -2370,6 +2410,15 @@ set-blocking@^2.0.0: resolved "https://registry.npmjs.org/set-blocking/-/set-blocking-2.0.0.tgz" integrity sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw== +set-function-name@^2.0.0: + version "2.0.1" + resolved "https://registry.npmjs.org/set-function-name/-/set-function-name-2.0.1.tgz" + integrity sha512-tMNCiqYVkXIZgc2Hnoy2IvC/f8ezc5koaRFkCjrpWzGpCd3qbZXPzVy9MAZzK1ch/X0jvSkojys3oqJN0qCmdA== + dependencies: + define-data-property "^1.0.1" + functions-have-names "^1.2.3" + has-property-descriptors "^1.0.0" + shebang-command@^1.2.0: version "1.2.0" resolved "https://registry.npmjs.org/shebang-command/-/shebang-command-1.2.0.tgz" @@ -2409,6 +2458,24 @@ simple-peer@^9.11.1: randombytes "^2.1.0" readable-stream "^3.6.0" +socket.io-client@^4.5.2: + version "4.7.2" + resolved "https://registry.npmjs.org/socket.io-client/-/socket.io-client-4.7.2.tgz" + integrity sha512-vtA0uD4ibrYD793SOIAwlo8cj6haOeMHrGvwPxJsxH7CeIksqJ+3Zc06RvWTIFgiSqx4A3sOnTXpfAEE2Zyz6w== + dependencies: + "@socket.io/component-emitter" "~3.1.0" + debug "~4.3.2" + engine.io-client "~6.5.2" + socket.io-parser "~4.2.4" + +socket.io-parser@~4.2.4: + version "4.2.4" + resolved "https://registry.npmjs.org/socket.io-parser/-/socket.io-parser-4.2.4.tgz" + integrity sha512-/GbIKmo8ioc+NIWIhwdecY0ge+qVBSMdgxGygevmdHj24bsfgtCmcUUcQ5ZzcylGFHsN3k4HB4Cgkl96KVnuew== + dependencies: + "@socket.io/component-emitter" "~3.1.0" + debug "~4.3.1" + split@1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/split/-/split-1.0.0.tgz" @@ -2449,32 +2516,32 @@ string-width@^4.1.0, string-width@^4.2.0: is-fullwidth-code-point "^3.0.0" strip-ansi "^6.0.1" -string.prototype.trim@^1.2.7: - version "1.2.7" - resolved "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.7.tgz" - integrity sha512-p6TmeT1T3411M8Cgg9wBTMRtY2q9+PNy9EV1i2lIXUN/btt763oIfxwN3RR8VU6wHX8j/1CFy0L+YuThm6bgOg== +string.prototype.trim@^1.2.7, string.prototype.trim@^1.2.8: + version "1.2.8" + resolved "https://registry.npmjs.org/string.prototype.trim/-/string.prototype.trim-1.2.8.tgz" + integrity sha512-lfjY4HcixfQXOfaqCvcBuOIapyaroTXhbkfJN3gcB1OtyupngWK4sEET9Knd0cXd28kTUqu/kHoV4HKSJdnjiQ== dependencies: call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" + define-properties "^1.2.0" + es-abstract "^1.22.1" -string.prototype.trimend@^1.0.6: - version "1.0.6" - resolved "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.6.tgz" - integrity sha512-JySq+4mrPf9EsDBEDYMOb/lM7XQLulwg5R/m1r0PXEFqrV0qHvl58sdTilSXtKOflCsK2E8jxf+GKC0T07RWwQ== +string.prototype.trimend@^1.0.7: + version "1.0.7" + resolved "https://registry.npmjs.org/string.prototype.trimend/-/string.prototype.trimend-1.0.7.tgz" + integrity sha512-Ni79DqeB72ZFq1uH/L6zJ+DKZTkOtPIHovb3YZHQViE+HDouuU4mBrLOLDn5Dde3RF8qw5qVETEjhu9locMLvA== dependencies: call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" + define-properties "^1.2.0" + es-abstract "^1.22.1" -string.prototype.trimstart@^1.0.6: - version "1.0.6" - resolved "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.6.tgz" - integrity sha512-omqjMDaY92pbn5HOX7f9IccLA+U1tA9GvtU4JrodiXFfYB7jPzzHpRzpglLAjtUV6bB557zwClJezTqnAiYnQA== +string.prototype.trimstart@^1.0.7: + version "1.0.7" + resolved "https://registry.npmjs.org/string.prototype.trimstart/-/string.prototype.trimstart-1.0.7.tgz" + integrity sha512-NGhtDFu3jCEm7B4Fy0DpLewdJQOZcQ0rGbwQ/+stjnrp2i+rlKeCvos9hOIeCmqwratM47OBxY7uFZzjxHXmrg== dependencies: call-bind "^1.0.2" - define-properties "^1.1.4" - es-abstract "^1.20.4" + define-properties "^1.2.0" + es-abstract "^1.22.1" string_decoder@^1.1.1: version "1.3.0" @@ -2666,6 +2733,11 @@ ts-node@^10.9.1: v8-compile-cache-lib "^3.0.1" yn "3.1.1" +tslib@^2.3.0: + version "2.6.2" + resolved "https://registry.npmjs.org/tslib/-/tslib-2.6.2.tgz" + integrity sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q== + tus-js-client@^3.1.0: version "3.1.1" resolved "https://registry.npmjs.org/tus-js-client/-/tus-js-client-3.1.1.tgz" @@ -2815,7 +2887,7 @@ which-module@^2.0.0: resolved "https://registry.npmjs.org/which-module/-/which-module-2.0.0.tgz" integrity sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q== -which-typed-array@^1.1.10, which-typed-array@^1.1.11, which-typed-array@^1.1.9: +which-typed-array@^1.1.11, which-typed-array@^1.1.9: version "1.1.11" resolved "https://registry.npmjs.org/which-typed-array/-/which-typed-array-1.1.11.tgz" integrity sha512-qe9UWWpkeG5yzZ0tNYxDmd7vo58HDBc39mZ0xWWpolAGADdFOzkfamWLDxkOWcvHQKVmdTyQdLD4NOfjLWTKew== @@ -2865,6 +2937,16 @@ ws@7.4.6: resolved "https://registry.npmjs.org/ws/-/ws-7.4.6.tgz" integrity sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A== +ws@~8.11.0: + version "8.11.0" + resolved "https://registry.npmjs.org/ws/-/ws-8.11.0.tgz" + integrity sha512-HPG3wQd9sNQoT9xHyNCXoDUa+Xw/VevmY9FoHyQ+g+rrMn4j6FB4np7Z0OhdTgjx6MgQLK7jwSy1YecU1+4Asg== + +xmlhttprequest-ssl@~2.0.0: + version "2.0.0" + resolved "https://registry.npmjs.org/xmlhttprequest-ssl/-/xmlhttprequest-ssl-2.0.0.tgz" + integrity sha512-QKxVRxiRACQcVuQEYFsI1hhkrMlrXHPegbbd1yn9UHOmRxY+si12nQYzri3vbzt8VdTTRviqcKxcyllFas5z2A== + xtend@~4.0.1: version "4.0.2" resolved "https://registry.npmjs.org/xtend/-/xtend-4.0.2.tgz" From 09524c793ecdef095f90c54bc5895ca1c6adba01 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 28 Sep 2023 23:19:20 +0530 Subject: [PATCH 257/298] fix: remove only from test --- .../restapi/tests/lib/pushNotification/notification.test.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/restapi/tests/lib/pushNotification/notification.test.ts b/packages/restapi/tests/lib/pushNotification/notification.test.ts index c0abb64de..d9a6ec2c3 100644 --- a/packages/restapi/tests/lib/pushNotification/notification.test.ts +++ b/packages/restapi/tests/lib/pushNotification/notification.test.ts @@ -9,7 +9,7 @@ import { createWalletClient, http } from 'viem'; import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; import { goerli } from 'viem/chains'; // import tokenABI from './tokenABI'; -describe.only('PushAPI.notification functionality', () => { +describe('PushAPI.notification functionality', () => { let userAlice: PushAPI; let userBob: PushAPI; let userKate: PushAPI; @@ -52,7 +52,7 @@ describe.only('PushAPI.notification functionality', () => { userViem = await PushAPI.initialize(viemSigner); }); - describe('notification :: list', () => { + describe('', () => { it('Should return feeds with signer object', async () => { const response = await userAlice.notification.list('SPAM'); expect(response).not.null; From 99163b3338940dd9904630007868ca01faf4190c Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 28 Sep 2023 23:24:16 +0530 Subject: [PATCH 258/298] fix: error fixed --- packages/restapi/src/lib/pushapi/chat.ts | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/restapi/src/lib/pushapi/chat.ts b/packages/restapi/src/lib/pushapi/chat.ts index 7eaccda38..193db597a 100644 --- a/packages/restapi/src/lib/pushapi/chat.ts +++ b/packages/restapi/src/lib/pushapi/chat.ts @@ -25,9 +25,9 @@ import { ChatUpdateGroupProfileType, updateGroupProfile, } from '../chat/updateGroupProfile'; -import { UserInfo } from './user'; +import { User } from './user'; export class Chat { - private userInfoInstance: UserInfo; + private userInstance: User; constructor( private account: string, @@ -35,8 +35,9 @@ export class Chat { private env: ENV, private signer: SignerType, private progressHook?: (progress: ProgressHookType) => void - ) { this.userInfoInstance = new UserInfo(this.account, this.env); -} + ) { + this.userInstance = new User(this.account, this.env); + } async list( type: `${ChatListType}`, @@ -134,7 +135,7 @@ export class Chat { pgpPrivateKey: this.decryptedPgpPvtKey, env: this.env, messages: messagePayloads, - connectedUser: await this.userInfoInstance.info(), + connectedUser: await this.userInstance.info(), }); } From 58f05eb334cb686ac5d0f9b6ec85652cb2b0e0a1 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Thu, 28 Sep 2023 23:52:56 +0530 Subject: [PATCH 259/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.35?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 14 ++++++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 5bd6d3477..72ca948ae 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,20 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.35](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.34...restapi-0.0.1-alpha.35) (2023-09-28) + + +### Bug Fixes + +* added chat.decrypt ([#726](https://github.com/ethereum-push-notification-service/push-sdk/issues/726)) ([995042b](https://github.com/ethereum-push-notification-service/push-sdk/commit/995042b789b19d487b5e2953463cae60e75199b8)) +* error fixed ([99163b3](https://github.com/ethereum-push-notification-service/push-sdk/commit/99163b3338940dd9904630007868ca01faf4190c)) +* Merge branch 'alpha' into alpha-deployment ([be03539](https://github.com/ethereum-push-notification-service/push-sdk/commit/be035393a90a50ac2b9115b8f0a817a988f395f9)) +* Merge branch 'alpha' into alpha-deployment ([8d56ee8](https://github.com/ethereum-push-notification-service/push-sdk/commit/8d56ee882719a65391e7e51abfb0b7f86c2ae5ad)) +* Merge branch 'main' into alpha ([b6887db](https://github.com/ethereum-push-notification-service/push-sdk/commit/b6887db0aa76126a47efa6ec88fc9841d7c3ae06)) +* remove only from test ([09524c7](https://github.com/ethereum-push-notification-service/push-sdk/commit/09524c793ecdef095f90c54bc5895ca1c6adba01)) + + + ## [0.0.1-alpha.34](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.33...restapi-0.0.1-alpha.34) (2023-09-27) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 7fb912427..4ae85b6ae 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.34", + "version": "0.0.1-alpha.35", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 78d3df217f705b8bc4483c25ac25589ae56958e2 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 12:24:08 +0530 Subject: [PATCH 260/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.35?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 72ca948ae..d50d8a71c 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,20 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.35](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.34...restapi-0.0.1-alpha.35) (2023-09-29) + + +### Bug Fixes + +* added chat.decrypt ([#726](https://github.com/ethereum-push-notification-service/push-sdk/issues/726)) ([995042b](https://github.com/ethereum-push-notification-service/push-sdk/commit/995042b789b19d487b5e2953463cae60e75199b8)) +* error fixed ([99163b3](https://github.com/ethereum-push-notification-service/push-sdk/commit/99163b3338940dd9904630007868ca01faf4190c)) +* Merge branch 'alpha' into alpha-deployment ([be03539](https://github.com/ethereum-push-notification-service/push-sdk/commit/be035393a90a50ac2b9115b8f0a817a988f395f9)) +* Merge branch 'alpha' into alpha-deployment ([8d56ee8](https://github.com/ethereum-push-notification-service/push-sdk/commit/8d56ee882719a65391e7e51abfb0b7f86c2ae5ad)) +* Merge branch 'main' into alpha ([b6887db](https://github.com/ethereum-push-notification-service/push-sdk/commit/b6887db0aa76126a47efa6ec88fc9841d7c3ae06)) +* remove only from test ([09524c7](https://github.com/ethereum-push-notification-service/push-sdk/commit/09524c793ecdef095f90c54bc5895ca1c6adba01)) + + + ## [0.0.1-alpha.35](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.34...restapi-0.0.1-alpha.35) (2023-09-28) From 3ca0496396a9796568973376ee99e26b65f1abed Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 12:52:45 +0530 Subject: [PATCH 261/298] fix: stream cases --- packages/restapi/project.json | 2 +- .../tests/lib/pushstream/initialize.test.ts | 38 +++++++++++-------- 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/packages/restapi/project.json b/packages/restapi/project.json index 90d27ba83..48ed574a1 100644 --- a/packages/restapi/project.json +++ b/packages/restapi/project.json @@ -43,7 +43,7 @@ "options": { "preset": "angular", "commitMessageFormat": "ci(${projectName}): 🎉 cut beta release to ${projectName}-v${version}", - "postTargets": ["restapi:build", "restapi:ci-publish"], + "postTargets": ["socket:build", "restapi:build", "restapi:ci-publish"], "version": "prerelease", "preid": "alpha" } diff --git a/packages/restapi/tests/lib/pushstream/initialize.test.ts b/packages/restapi/tests/lib/pushstream/initialize.test.ts index a82618466..a0a7445db 100644 --- a/packages/restapi/tests/lib/pushstream/initialize.test.ts +++ b/packages/restapi/tests/lib/pushstream/initialize.test.ts @@ -12,7 +12,7 @@ import { STREAM } from '../../../src/lib/pushstream/pushStreamTypes'; import * as util from 'util'; import { ConditionType } from '../../../src/lib'; -describe('PushStream.initialize functionality', () => { +describe.only('PushStream.initialize functionality', () => { it('Should initialize new stream and listen to events', async () => { const MESSAGE = 'Hey There!!!'; @@ -142,7 +142,7 @@ describe('PushStream.initialize functionality', () => { console.log( `Event ${eventCount} for ${expectedEvent}:`, - util.inspect(data, { + util.inspect(JSON.stringify(data), { showHidden: false, depth: null, colors: true, @@ -169,10 +169,25 @@ describe('PushStream.initialize functionality', () => { const onNoitificationsReceived = createEventPromise('NOTIF', STREAM.NOTIF, 4); // Create and update group - /*const createdGroup = await user.chat.group.create( + const createdGroup = await user.chat.group.create( 'test', CREATE_GROUP_REQUEST_2 - );*/ + ); + + const updatedGroup = await user.chat.group.update(createdGroup.chatId, { + description: 'Updated Description', + }); + + const updatedGroup2 = await user.chat.group.add(createdGroup.chatId, { + role: 'ADMIN', + accounts: [signer2.address, signer3.address, signer4.address], + }); + + const w2wRejectRequest = await user2.chat.group.join( + createdGroup.chatId + ); + + /*const w2wMessageResponse = await user2.chat.send(signer.address, { content: MESSAGE, @@ -183,7 +198,7 @@ describe('PushStream.initialize functionality', () => { content: MESSAGE, });*/ - const channelPrivateKey = process.env['WALLET_PRIVATE_KEY']; + /*const channelPrivateKey = process.env['WALLET_PRIVATE_KEY']; const signerChannel = new ethers.Wallet(`0x${channelPrivateKey}`); const channelAddress = signerChannel.address; @@ -257,10 +272,7 @@ describe('PushStream.initialize functionality', () => { }); - /*const updatedGroup = await user.chat.group.update(createdGroup.chatId, { - description: 'Updated Description', - });*/ - + //const w2wRejectRequest = await user2.chat.group.join(createdGroup.chatId); //const updatedGroup2 = await user2.chat.group.leave(createdGroup.chatId); @@ -294,13 +306,7 @@ describe('PushStream.initialize functionality', () => { /* - const updatedGroup = await user.chat.group.add(createdGroup.chatId, { - role: 'ADMIN', - accounts: [signer2.address, signer3.address, signer4.address], - }); - - const w2wRejectRequest = await user2.chat.group.join(createdGroup.chatId); - + const updatedGroup2 = await user2.chat.group.leave(createdGroup.chatId); From edee24a77cc7baf61b75f3d2c542f77f6c3750a5 Mon Sep 17 00:00:00 2001 From: Ashis Kumar Pradhan <38760485+akp111@users.noreply.github.com> Date: Fri, 29 Sep 2023 14:13:58 +0530 Subject: [PATCH 262/298] 720 pushstream class implementation (#737) * fix: stream changes * fix: stream changes * fix: stream changes * fix: PUSH Stream Changes * fix: chat classes split * fix: Notification socket initialisations and rules backward compatibility * fix: added message decrypt * fix: review comments * fix: socket events * fix: test case fix and UserInfo to user * fix: rip PushNotification class * fix: additional check * fix: minor fixes --------- Co-authored-by: Mohammed S --- packages/restapi/src/lib/config.ts | 14 +++--- .../src/lib/pushNotification/channel.ts | 2 +- .../pushNotification/pushNotificationBase.ts | 6 +-- .../lib/pushNotification/channel.test.ts | 45 ++++++++++++++++--- 4 files changed, 49 insertions(+), 18 deletions(-) diff --git a/packages/restapi/src/lib/config.ts b/packages/restapi/src/lib/config.ts index 96a80c793..e597c22bc 100644 --- a/packages/restapi/src/lib/config.ts +++ b/packages/restapi/src/lib/config.ts @@ -108,7 +108,7 @@ export const VIEM_CORE_CONFIG = { [ENV.PROD]: { NETWORK: mainnet, API_BASE_URL: API_BASE_URL[ENV.PROD], - EPNS_CORE_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + EPNS_CORE_CONTRACT: '0x66329Fdd4042928BfCAB60b179e1538D56eeeeeE', }, [ENV.STAGING]: { NETWORK: goerli, @@ -118,19 +118,19 @@ export const VIEM_CORE_CONFIG = { [ENV.DEV]: { NETWORK: goerli, API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + EPNS_CORE_CONTRACT: '0x23346B732d56d34EC4e890419fBFB8548216a799', }, [ENV.LOCAL]: { NETWORK: goerli, API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + EPNS_CORE_CONTRACT: '0x23346B732d56d34EC4e890419fBFB8548216a799', }, }; export const CORE_CONFIG = { [ENV.PROD]: { API_BASE_URL: API_BASE_URL[ENV.PROD], - EPNS_CORE_CONTRACT: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + EPNS_CORE_CONTRACT: '0x66329Fdd4042928BfCAB60b179e1538D56eeeeeE', }, [ENV.STAGING]: { API_BASE_URL: API_BASE_URL[ENV.STAGING], @@ -138,11 +138,11 @@ export const CORE_CONFIG = { }, [ENV.DEV]: { API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + EPNS_CORE_CONTRACT: '0x23346B732d56d34EC4e890419fBFB8548216a799', }, [ENV.LOCAL]: { API_BASE_URL: API_BASE_URL[ENV.DEV], - EPNS_CORE_CONTRACT: '0xc064F30bac07e84500c97A04D21a9d1bfFC72Ec0', + EPNS_CORE_CONTRACT: '0x23346B732d56d34EC4e890419fBFB8548216a799', }, }; @@ -239,7 +239,7 @@ const CONFIG = { export default CONFIG; export const TOKEN = { - [ENV.PROD]: '0xb3971BCef2D791bc4027BbfedFb47319A4AAaaAa', + [ENV.PROD]: '0xf418588522d5dd018b425E472991E52EBBeEEEEE', [ENV.STAGING]: '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', [ENV.DEV]: '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', [ENV.LOCAL]: '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', diff --git a/packages/restapi/src/lib/pushNotification/channel.ts b/packages/restapi/src/lib/pushNotification/channel.ts index 6fc5ea0d3..b21fa4e3a 100644 --- a/packages/restapi/src/lib/pushNotification/channel.ts +++ b/packages/restapi/src/lib/pushNotification/channel.ts @@ -393,7 +393,7 @@ export class Channel extends PushNotificationBaseClass { ); // if allowance is not greater than the fees, dont call approval again if (!allowanceAmount.gte(fees)) { - const approveRes = this.approveToken( + const approveRes = await this.approveToken( pushTokenContract, config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, fees diff --git a/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts b/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts index 59fc4df4d..c081b2f0e 100644 --- a/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts +++ b/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts @@ -634,7 +634,7 @@ export class PushNotificationBaseClass { SETTING_DELIMITER + ele.default; notificationSettingDescription = - notificationSettingDescription + ele.description; + notificationSettingDescription + SETTING_SEPARATOR + ele.description; } if (ele.type == 1) { if (ele.data) { @@ -650,13 +650,13 @@ export class PushNotificationBaseClass { ele.data.upper; notificationSettingDescription = - notificationSettingDescription + ele.description; + notificationSettingDescription + SETTING_SEPARATOR + ele.description; } } } return { setting: notificationSetting.replace(/^\+/, ''), - description: notificationSettingDescription, + description: notificationSettingDescription.replace(/^\+/, ''), }; } } diff --git a/packages/restapi/tests/lib/pushNotification/channel.test.ts b/packages/restapi/tests/lib/pushNotification/channel.test.ts index 5f70e1036..579fcb3c4 100644 --- a/packages/restapi/tests/lib/pushNotification/channel.test.ts +++ b/packages/restapi/tests/lib/pushNotification/channel.test.ts @@ -2,7 +2,6 @@ import * as path from 'path'; import * as dotenv from 'dotenv'; dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); - import { PushAPI } from '../../../src/lib/pushapi/PushAPI'; import { expect } from 'chai'; import { ethers } from 'ethers'; @@ -30,7 +29,15 @@ describe('PushAPI.channel functionality', () => { provider ); account2 = await signer2.getAddress(); - + enum ENV { + PROD = 'prod', + STAGING = 'staging', + DEV = 'dev', + /** + * **This is for local development only** + */ + LOCAL = 'local', + } // initialisation with signer and provider userKate = await PushAPI.initialize(signer2) // initialisation with signer @@ -105,9 +112,9 @@ describe('PushAPI.channel functionality', () => { }); it('Without signer and account : Should return response without passing the options', async () => { - const res = await userKate.channel.subscribers(); - expect(res).not.null; - }); + const res = await userKate.channel.subscribers(); + expect(res).not.null; + }); it('Without signer and account : Should throw error for invalid caip', async () => { await expect(() => @@ -260,8 +267,32 @@ describe('PushAPI.channel functionality', () => { url: 'https://google.com', icon: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAz0lEQVR4AcXBsU0EQQyG0e+saWJ7oACiKYDMEZVs6GgSpC2BIhzRwAS0sgk9HKn3gpFOAv3v3V4/3+4U4Z1q5KTy42Ql940qvFONnFSGmCFmiN2+fj7uCBlihpgh1ngwcvKfwjuVIWaIGWKNB+GdauSk8uNkJfeNKryzYogZYoZY40m5b/wlQ8wQM8TayMlKeKcaOVkJ71QjJyuGmCFmiDUe+HFy4VyEd57hx0mV+0ZliBlihlgL71w4FyMnVXhnZeSkiu93qheuDDFDzBD7BcCyMAOfy204AAAAAElFTkSuQmCC', }); - // console.log(res) - expect(res).not.null + // console.log(res) + expect(res).not.null; + }, 10000000000); + }); + + describe.skip('channel :: create', () => { + it('Should create channel', async () => { + const res = await userKate.channel.create({ + name: 'SDK Test', + description: 'Testing new description', + url: 'https://google.com', + icon: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAz0lEQVR4AcXBsU0EQQyG0e+saWJ7oACiKYDMEZVs6GgSpC2BIhzRwAS0sgk9HKn3gpFOAv3v3V4/3+4U4Z1q5KTy42Ql940qvFONnFSGmCFmiN2+fj7uCBlihpgh1ngwcvKfwjuVIWaIGWKNB+GdauSk8uNkJfeNKryzYogZYoZY40m5b/wlQ8wQM8TayMlKeKcaOVkJ71QjJyuGmCFmiDUe+HFy4VyEd57hx0mV+0ZliBlihlgL71w4FyMnVXhnZeSkiu93qheuDDFDzBD7BcCyMAOfy204AAAAAElFTkSuQmCC', + }); + // console.log(res) + expect(res).not.null; + }, 10000000000); + }); + + describe.skip('channel :: settings', () => { + it('Should create channel', async () => { + const res = await userKate.channel.setting([ + { type: 0, default: 1, description: 'My Notif Settings' }, + {type: 1, default: 5, description: "My notif setting 2", data: {upper:100, lower:5}} + ]); + // console.log(res) + expect(res).not.null; }, 10000000000); }); }); From 629d02faff84139595d36f3efb7e5edfd12b5719 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 14:17:14 +0530 Subject: [PATCH 263/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20rel?= =?UTF-8?q?ease=20to=20restapi-v1.4.21?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 0fddb05ca..a53fee864 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.4.21](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.20...restapi-1.4.21) (2023-09-29) + + +### Bug Fixes + +* Merge branch 'main' into deployment ([f9bb113](https://github.com/ethereum-push-notification-service/push-sdk/commit/f9bb113702f47132dc512910e5060286e985f4bf)) + + + ## [1.4.20](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-1.4.19...restapi-1.4.20) (2023-09-22) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index cb236e058..7985893a2 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "1.4.20", + "version": "1.4.21", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From e93f8761d70ea4c26c3a89272619070560b595a8 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 15:26:35 +0530 Subject: [PATCH 264/298] fix: corrected example --- packages/examples/sdk-backend-node/pushAPI/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/examples/sdk-backend-node/pushAPI/index.ts b/packages/examples/sdk-backend-node/pushAPI/index.ts index 60fdd8285..2b02dca10 100644 --- a/packages/examples/sdk-backend-node/pushAPI/index.ts +++ b/packages/examples/sdk-backend-node/pushAPI/index.ts @@ -71,7 +71,7 @@ export const runPushAPICases = async (): Promise => { // ------------------------------------------------------------------- // ------------------------------------------------------------------- console.log('PushAPI.info'); - const userAliceInfo = await userAlice.info(); + const userAliceInfo = await userAlice.user.info(); if (showAPIResponse) { console.log(userAliceInfo); } From 92a220264e15dad6636b1e7a34ca6f0871849b14 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 15:58:55 +0530 Subject: [PATCH 265/298] fix: some changes on stream --- .../restapi/src/lib/pushNotification/alias.ts | 2 - .../src/lib/pushNotification/delegate.ts | 2 +- .../src/lib/pushNotification/notification.ts | 11 --- packages/restapi/src/lib/pushapi/PushAPI.ts | 71 ++++++++++--------- .../restapi/src/lib/pushapi/pushAPITypes.ts | 8 +-- .../src/lib/pushstream/DataModifier.ts | 1 - .../restapi/src/lib/pushstream/PushStream.ts | 2 + .../src/lib/pushstream/pushStreamTypes.ts | 9 ++- .../tests/lib/pushstream/initialize.test.ts | 2 +- 9 files changed, 51 insertions(+), 57 deletions(-) diff --git a/packages/restapi/src/lib/pushNotification/alias.ts b/packages/restapi/src/lib/pushNotification/alias.ts index d23522cc8..487d8ad20 100644 --- a/packages/restapi/src/lib/pushNotification/alias.ts +++ b/packages/restapi/src/lib/pushNotification/alias.ts @@ -1,10 +1,8 @@ import { ENV } from '../constants'; -import { SignerType } from '../types'; import { AliasOptions } from './PushNotificationTypes'; import * as PUSH_ALIAS from '../alias'; -import { PushNotificationBaseClass } from './pushNotificationBase'; export class Alias { private env: ENV diff --git a/packages/restapi/src/lib/pushNotification/delegate.ts b/packages/restapi/src/lib/pushNotification/delegate.ts index 1d2f31d87..3d08bcd3a 100644 --- a/packages/restapi/src/lib/pushNotification/delegate.ts +++ b/packages/restapi/src/lib/pushNotification/delegate.ts @@ -1,4 +1,4 @@ -import Constants, { ENV } from '../constants'; +import { ENV } from '../constants'; import { SignerType } from '../types'; import { ChannelInfoOptions } from './PushNotificationTypes'; import CONFIG, * as config from '../config'; diff --git a/packages/restapi/src/lib/pushNotification/notification.ts b/packages/restapi/src/lib/pushNotification/notification.ts index 2de0da631..67abdd976 100644 --- a/packages/restapi/src/lib/pushNotification/notification.ts +++ b/packages/restapi/src/lib/pushNotification/notification.ts @@ -1,26 +1,15 @@ import Constants, { ENV } from '../constants'; import { SignerType, - ProgressHookType, - ProgressHookTypeFunction, } from '../types'; import { - ChannelInfoOptions, SubscribeUnsubscribeOptions, SubscriptionOptions, - AliasOptions, FeedType, FeedsOptions, - ChannelSearchOptions, - NotificationOptions, - CreateChannelOptions, - NotificationSettings, } from './PushNotificationTypes'; -import CONFIG, * as config from '../config'; import * as PUSH_USER from '../user'; -import * as PUSH_PAYLOAD from '../payloads'; import * as PUSH_CHANNEL from '../channels'; -import * as PUSH_ALIAS from '../alias'; import { getCAIPDetails, diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index 71665b4b5..c785dead4 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -47,24 +47,10 @@ export class PushAPI { this.pgpPublicKey = pgpPublicKey; this.progressHook = progressHook; // Instantiate the notification classes - this.channel = new Channel( - this.signer, - this.env, - this.account - ) - this.alias = new Alias( - this.env - ) - this.delegate = new Delegate( - this.signer, - this.env, - this.account - ) - this.notification = new Notification( - this.signer, - this.env, - this.account - ) + this.channel = new Channel(this.signer, this.env, this.account); + this.alias = new Alias(this.env); + this.delegate = new Delegate(this.signer, this.env, this.account); + this.notification = new Notification(this.signer, this.env, this.account); // Initialize the instances of the four classes this.chat = new Chat( this.account, @@ -98,9 +84,14 @@ export class PushAPI { // Default options const defaultOptions: PushAPIInitializeProps = { env: ENV.STAGING, - version: Constants.ENC_TYPE_V3, - autoUpgrade: true, + chatOptions: { + version: Constants.ENC_TYPE_V3, + autoUpgrade: true, + }, account: null, + streamOptions: { + socketEnabled: true, // Default value + }, }; // Settings object @@ -108,6 +99,14 @@ export class PushAPI { const settings = { ...defaultOptions, ...options, + chatOptions: { + ...defaultOptions.chatOptions, + ...(options?.chatOptions ?? {}), + }, + streamOptions: { + ...defaultOptions.streamOptions, + ...(options?.streamOptions ?? {}), + }, }; // Get account @@ -135,8 +134,8 @@ export class PushAPI { decryptedPGPPrivateKey = await PUSH_CHAT.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: signer, - toUpgrade: settings.autoUpgrade, - additionalMeta: settings.versionMeta, + toUpgrade: settings.chatOptions.autoUpgrade, + additionalMeta: settings.chatOptions.versionMeta, progressHook: settings.progressHook, env: settings.env, }); @@ -146,8 +145,8 @@ export class PushAPI { env: settings.env, account: derivedAccount, signer, - version: settings.version, - additionalMeta: settings.versionMeta, + version: settings.chatOptions.version, + additionalMeta: settings.chatOptions.versionMeta, origin: settings.origin, progressHook: settings.progressHook, }); @@ -165,17 +164,19 @@ export class PushAPI { settings.progressHook ); - const streamInstance = await PushStream.initialize( - api.account, - decryptedPGPPrivateKey, - signer, - settings.progressHook, - settings.streamOptions - ); - if (streamInstance) { - api.stream = streamInstance; - } else { - throw new Error('Failed to initialize PushStream.'); + if (settings.streamOptions.socketEnabled) { + const streamInstance = await PushStream.initialize( + api.account, + decryptedPGPPrivateKey, + signer, + settings.progressHook, + settings.streamOptions + ); + if (streamInstance) { + api.stream = streamInstance; + } else { + throw new Error('Failed to initialize PushStream.'); + } } return api; diff --git a/packages/restapi/src/lib/pushapi/pushAPITypes.ts b/packages/restapi/src/lib/pushapi/pushAPITypes.ts index c620dae1c..8eec0a338 100644 --- a/packages/restapi/src/lib/pushapi/pushAPITypes.ts +++ b/packages/restapi/src/lib/pushapi/pushAPITypes.ts @@ -1,5 +1,5 @@ -import Constants, { ENV } from '../constants'; -import { PushStreamInitializeProps } from '../pushstream/pushStreamTypes'; +import { ENV } from '../constants'; +import { PushChatInitializeProps, PushStreamInitializeProps } from '../pushstream/pushStreamTypes'; import { ChatStatus, ProgressHookType, Rules } from '../types'; export enum ChatListType { @@ -10,9 +10,7 @@ export interface PushAPIInitializeProps { env?: ENV; progressHook?: (progress: ProgressHookType) => void; account?: string | null; - version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3; - versionMeta?: { NFTPGP_V1?: { password: string } }; - autoUpgrade?: boolean; + chatOptions?: PushChatInitializeProps; origin?: string; streamOptions?: PushStreamInitializeProps; } diff --git a/packages/restapi/src/lib/pushstream/DataModifier.ts b/packages/restapi/src/lib/pushstream/DataModifier.ts index cb8054005..887d09b2f 100644 --- a/packages/restapi/src/lib/pushstream/DataModifier.ts +++ b/packages/restapi/src/lib/pushstream/DataModifier.ts @@ -10,7 +10,6 @@ import { GroupEventType, LeaveGroupEvent, JoinGroupEvent, - ProposedEventNames, RequestEvent, RemoveEvent, } from './pushStreamTypes'; diff --git a/packages/restapi/src/lib/pushstream/PushStream.ts b/packages/restapi/src/lib/pushstream/PushStream.ts index dfc95ea87..55b70fd0c 100644 --- a/packages/restapi/src/lib/pushstream/PushStream.ts +++ b/packages/restapi/src/lib/pushstream/PushStream.ts @@ -190,6 +190,8 @@ export class PushStream extends EventEmitter { data = await this.chatInstance.decrypt([data]); } + console.log(data); + const modifiedData = DataModifier.handleChatEvent(data[0], this.raw); modifiedData.event = this.convertToProposedName(modifiedData.event); this.handleToField(modifiedData); diff --git a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts index 8d703789e..b8fee4e9b 100644 --- a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts +++ b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts @@ -1,5 +1,5 @@ -import { ENV } from "../constants"; import { Rules } from "../types"; +import Constants, { ENV } from '../constants'; export type PushStreamInitializeProps = { listen?: STREAM[]; @@ -13,8 +13,15 @@ export type PushStreamInitializeProps = { }; raw?: boolean; env?: ENV; + socketEnabled?: boolean; }; +export type PushChatInitializeProps = { + version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3; + versionMeta?: { NFTPGP_V1?: { password: string } }; + autoUpgrade?: boolean; +} + export enum STREAM { PROFILE = 'STREAM.PROFILE', ENCRYPTION = 'STREAM.ENCRYPTION', diff --git a/packages/restapi/tests/lib/pushstream/initialize.test.ts b/packages/restapi/tests/lib/pushstream/initialize.test.ts index a0a7445db..260bdd667 100644 --- a/packages/restapi/tests/lib/pushstream/initialize.test.ts +++ b/packages/restapi/tests/lib/pushstream/initialize.test.ts @@ -183,7 +183,7 @@ describe.only('PushStream.initialize functionality', () => { accounts: [signer2.address, signer3.address, signer4.address], }); - const w2wRejectRequest = await user2.chat.group.join( + const w2wRejectRequest = await user2.chat.group.join( createdGroup.chatId ); From aa93fea017a4fd8c7e2fe1e8512547a2c9df9718 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 15:59:32 +0530 Subject: [PATCH 266/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.36?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 11 +++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d50d8a71c..d061edc89 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,17 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.36](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.35...restapi-0.0.1-alpha.36) (2023-09-29) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([c4d2cff](https://github.com/ethereum-push-notification-service/push-sdk/commit/c4d2cff0d7ecf909ab9dd993f54ffa9f4ce9d7b4)) +* some changes on stream ([92a2202](https://github.com/ethereum-push-notification-service/push-sdk/commit/92a220264e15dad6636b1e7a34ca6f0871849b14)) +* stream cases ([3ca0496](https://github.com/ethereum-push-notification-service/push-sdk/commit/3ca0496396a9796568973376ee99e26b65f1abed)) + + + ## [0.0.1-alpha.35](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.34...restapi-0.0.1-alpha.35) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 4ae85b6ae..7dcefdb11 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.35", + "version": "0.0.1-alpha.36", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 12e3ca542aa11f7640ba5b84492707eb6e8bc3fc Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:09:51 +0530 Subject: [PATCH 267/298] fix: minor fixes --- packages/examples/sdk-backend-node/package.json | 2 +- packages/restapi/src/lib/pushstream/DataModifier.ts | 13 +++++++++++-- .../restapi/tests/lib/pushstream/initialize.test.ts | 2 +- 3 files changed, 13 insertions(+), 4 deletions(-) diff --git a/packages/examples/sdk-backend-node/package.json b/packages/examples/sdk-backend-node/package.json index 47b5d3196..f12ea8e77 100644 --- a/packages/examples/sdk-backend-node/package.json +++ b/packages/examples/sdk-backend-node/package.json @@ -11,7 +11,7 @@ "author": "", "license": "ISC", "dependencies": { - "@pushprotocol/restapi": "@latest", + "@pushprotocol/restapi": "0.0.1-alpha.36", "@pushprotocol/socket": "^0.5.2" } } diff --git a/packages/restapi/src/lib/pushstream/DataModifier.ts b/packages/restapi/src/lib/pushstream/DataModifier.ts index 887d09b2f..e6b4d1ab8 100644 --- a/packages/restapi/src/lib/pushstream/DataModifier.ts +++ b/packages/restapi/src/lib/pushstream/DataModifier.ts @@ -270,8 +270,17 @@ export class DataModifier { Reject: MessageEventType.Reject, }; - const eventType: MessageEventType | undefined = - eventTypeMap[data.eventType || data.messageCategory]; + const key = data.eventType || data.messageCategory; + + if (!eventTypeMap[key]) { + console.error( + 'Error in handleChatEvent: Invalid eventType or messageCategory', + JSON.stringify(data) + ); + throw new Error('Invalid eventType or messageCategory in data'); + } + + const eventType: MessageEventType = eventTypeMap[key]; if (eventType) { return this.mapToMessageEvent( diff --git a/packages/restapi/tests/lib/pushstream/initialize.test.ts b/packages/restapi/tests/lib/pushstream/initialize.test.ts index 260bdd667..9ae1527f6 100644 --- a/packages/restapi/tests/lib/pushstream/initialize.test.ts +++ b/packages/restapi/tests/lib/pushstream/initialize.test.ts @@ -12,7 +12,7 @@ import { STREAM } from '../../../src/lib/pushstream/pushStreamTypes'; import * as util from 'util'; import { ConditionType } from '../../../src/lib'; -describe.only('PushStream.initialize functionality', () => { +describe('PushStream.initialize functionality', () => { it('Should initialize new stream and listen to events', async () => { const MESSAGE = 'Hey There!!!'; From f855ce95044c6f1d2d6f3081ba77f2a52a517e76 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:10:51 +0530 Subject: [PATCH 268/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.37?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index d061edc89..c8cdeb08a 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.37](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.36...restapi-0.0.1-alpha.37) (2023-09-29) + + +### Bug Fixes + +* minor fixes ([12e3ca5](https://github.com/ethereum-push-notification-service/push-sdk/commit/12e3ca542aa11f7640ba5b84492707eb6e8bc3fc)) + + + ## [0.0.1-alpha.36](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.35...restapi-0.0.1-alpha.36) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 7dcefdb11..aa2f83028 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.36", + "version": "0.0.1-alpha.37", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 399d1fe396ce19f764c9fc80dea3a3852216837a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:17:54 +0530 Subject: [PATCH 269/298] fix: error handling in socket events --- .../examples/sdk-backend-node/package.json | 2 +- .../restapi/src/lib/pushstream/PushStream.ts | 101 +++++++++++------- 2 files changed, 66 insertions(+), 37 deletions(-) diff --git a/packages/examples/sdk-backend-node/package.json b/packages/examples/sdk-backend-node/package.json index f12ea8e77..6d291ece1 100644 --- a/packages/examples/sdk-backend-node/package.json +++ b/packages/examples/sdk-backend-node/package.json @@ -11,7 +11,7 @@ "author": "", "license": "ISC", "dependencies": { - "@pushprotocol/restapi": "0.0.1-alpha.36", + "@pushprotocol/restapi": "0.0.1-alpha.37", "@pushprotocol/socket": "^0.5.2" } } diff --git a/packages/restapi/src/lib/pushstream/PushStream.ts b/packages/restapi/src/lib/pushstream/PushStream.ts index 55b70fd0c..2a30149fe 100644 --- a/packages/restapi/src/lib/pushstream/PushStream.ts +++ b/packages/restapi/src/lib/pushstream/PushStream.ts @@ -164,54 +164,83 @@ export class PushStream extends EventEmitter { }; this.pushChatSocket.on(EVENTS.CHAT_GROUPS, (data: any) => { - const modifiedData = DataModifier.handleChatGroupEvent(data, this.raw); - modifiedData.event = this.convertToProposedName(modifiedData.event); - this.handleToField(modifiedData); - if (this.shouldEmitChat(data.chatId)) { - if ( - data.eventType === GroupEventType.JoinGroup || - data.eventType === GroupEventType.LeaveGroup || - data.eventType === MessageEventType.Request || - data.eventType === GroupEventType.Remove - ) { - if (shouldEmit(STREAM.CHAT)) { - this.emit(STREAM.CHAT, modifiedData); - } - } else { - if (shouldEmit(STREAM.CHAT_OPS)) { - this.emit(STREAM.CHAT_OPS, modifiedData); - } - } - } + try { + const modifiedData = DataModifier.handleChatGroupEvent(data, this.raw); + modifiedData.event = this.convertToProposedName(modifiedData.event); + this.handleToField(modifiedData); + if (this.shouldEmitChat(data.chatId)) { + if ( + data.eventType === GroupEventType.JoinGroup || + data.eventType === GroupEventType.LeaveGroup || + data.eventType === MessageEventType.Request || + data.eventType === GroupEventType.Remove + ) { + if (shouldEmit(STREAM.CHAT)) { + this.emit(STREAM.CHAT, modifiedData); + } + } else { + if (shouldEmit(STREAM.CHAT_OPS)) { + this.emit(STREAM.CHAT_OPS, modifiedData); + } + } + } + } catch (error) { + console.error('Error handling CHAT_GROUPS event:', error, 'Data:', data); + } }); this.pushChatSocket.on(EVENTS.CHAT_RECEIVED_MESSAGE, async (data: any) => { - if (data.messageCategory == 'Chat' || data.messageCategory == 'Request') { - data = await this.chatInstance.decrypt([data]); - } + try { + if ( + data.messageCategory == 'Chat' || + data.messageCategory == 'Request' + ) { + data = await this.chatInstance.decrypt([data]); + } - console.log(data); + console.log(data); - const modifiedData = DataModifier.handleChatEvent(data[0], this.raw); - modifiedData.event = this.convertToProposedName(modifiedData.event); - this.handleToField(modifiedData); - if (this.shouldEmitChat(data.chatId)) { - if (shouldEmit(STREAM.CHAT)) { - this.emit(STREAM.CHAT, modifiedData); + const modifiedData = DataModifier.handleChatEvent(data[0], this.raw); + modifiedData.event = this.convertToProposedName(modifiedData.event); + this.handleToField(modifiedData); + if (this.shouldEmitChat(data.chatId)) { + if (shouldEmit(STREAM.CHAT)) { + this.emit(STREAM.CHAT, modifiedData); + } + } + } catch (error) { + console.error( + 'Error handling CHAT_RECEIVED_MESSAGE event:', + error, + 'Data:', + data + ); } - } }); this.pushNotificationSocket.on(EVENTS.USER_FEEDS, (data: any) => { - console.log('Incoming Feed from Socket'); - console.log(data); - this.emit(STREAM.NOTIF, data); + try { + console.log('Incoming Feed from Socket'); + console.log(data); + this.emit(STREAM.NOTIF, data); + } catch (error) { + console.error('Error handling USER_FEEDS event:', error, 'Data:', data); + } }); this.pushNotificationSocket.on(EVENTS.USER_SPAM_FEEDS, (data: any) => { - console.log('Incoming Spam Feed from Socket'); - console.log(data); - this.emit(STREAM.NOTIF, data); + try { + console.log('Incoming Spam Feed from Socket'); + console.log(data); + this.emit(STREAM.NOTIF, data); + } catch (error) { + console.error( + 'Error handling USER_SPAM_FEEDS event:', + error, + 'Data:', + data + ); + } }); } } From e5c874331fd7cb18a546d2cf0c7f13db61cd4a9a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:18:29 +0530 Subject: [PATCH 270/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.38?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index c8cdeb08a..254383f95 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.38](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.37...restapi-0.0.1-alpha.38) (2023-09-29) + + +### Bug Fixes + +* error handling in socket events ([399d1fe](https://github.com/ethereum-push-notification-service/push-sdk/commit/399d1fe396ce19f764c9fc80dea3a3852216837a)) + + + ## [0.0.1-alpha.37](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.36...restapi-0.0.1-alpha.37) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index aa2f83028..2eebdf67c 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.37", + "version": "0.0.1-alpha.38", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From fe0ad486338d1cc57508e5ccc1c3b2aeece9624a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:25:21 +0530 Subject: [PATCH 271/298] fix: more fixes --- .../examples/sdk-backend-node/package.json | 2 +- .../src/lib/pushstream/DataModifier.ts | 23 +++++++++++-------- .../restapi/src/lib/pushstream/PushStream.ts | 5 ++-- 3 files changed, 18 insertions(+), 12 deletions(-) diff --git a/packages/examples/sdk-backend-node/package.json b/packages/examples/sdk-backend-node/package.json index 6d291ece1..671761258 100644 --- a/packages/examples/sdk-backend-node/package.json +++ b/packages/examples/sdk-backend-node/package.json @@ -11,7 +11,7 @@ "author": "", "license": "ISC", "dependencies": { - "@pushprotocol/restapi": "0.0.1-alpha.37", + "@pushprotocol/restapi": "0.0.1-alpha.38", "@pushprotocol/socket": "^0.5.2" } } diff --git a/packages/restapi/src/lib/pushstream/DataModifier.ts b/packages/restapi/src/lib/pushstream/DataModifier.ts index e6b4d1ab8..12751e953 100644 --- a/packages/restapi/src/lib/pushstream/DataModifier.ts +++ b/packages/restapi/src/lib/pushstream/DataModifier.ts @@ -263,6 +263,11 @@ export class DataModifier { } public static handleChatEvent(data: any, includeRaw = false): any { + if (!data) { + console.error('Error in handleChatEvent: data is undefined or null'); + throw new Error('data is undefined or null'); + } + const eventTypeMap: { [key: string]: MessageEventType } = { Chat: MessageEventType.Message, Request: MessageEventType.Request, @@ -270,17 +275,17 @@ export class DataModifier { Reject: MessageEventType.Reject, }; - const key = data.eventType || data.messageCategory; + const key = data.eventType || data.messageCategory; - if (!eventTypeMap[key]) { - console.error( - 'Error in handleChatEvent: Invalid eventType or messageCategory', - JSON.stringify(data) - ); - throw new Error('Invalid eventType or messageCategory in data'); - } + if (!eventTypeMap[key]) { + console.error( + 'Error in handleChatEvent: Invalid eventType or messageCategory', + JSON.stringify(data) + ); + throw new Error('Invalid eventType or messageCategory in data'); + } - const eventType: MessageEventType = eventTypeMap[key]; + const eventType: MessageEventType = eventTypeMap[key]; if (eventType) { return this.mapToMessageEvent( diff --git a/packages/restapi/src/lib/pushstream/PushStream.ts b/packages/restapi/src/lib/pushstream/PushStream.ts index 2a30149fe..bee4577a2 100644 --- a/packages/restapi/src/lib/pushstream/PushStream.ts +++ b/packages/restapi/src/lib/pushstream/PushStream.ts @@ -196,11 +196,12 @@ export class PushStream extends EventEmitter { data.messageCategory == 'Request' ) { data = await this.chatInstance.decrypt([data]); + data = data[0] } - + console.log("Hola") console.log(data); - const modifiedData = DataModifier.handleChatEvent(data[0], this.raw); + const modifiedData = DataModifier.handleChatEvent(data, this.raw); modifiedData.event = this.convertToProposedName(modifiedData.event); this.handleToField(modifiedData); if (this.shouldEmitChat(data.chatId)) { From 24e938ed95921b7777c946386c51991dabef6bb2 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:25:28 +0530 Subject: [PATCH 272/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.39?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 254383f95..bfc90450a 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.39](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.38...restapi-0.0.1-alpha.39) (2023-09-29) + + +### Bug Fixes + +* more fixes ([fe0ad48](https://github.com/ethereum-push-notification-service/push-sdk/commit/fe0ad486338d1cc57508e5ccc1c3b2aeece9624a)) + + + ## [0.0.1-alpha.38](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.37...restapi-0.0.1-alpha.38) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 2eebdf67c..43ca05bab 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.38", + "version": "0.0.1-alpha.39", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From be3e90ae43625eac56cc82548e150a6296a09777 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:28:00 +0530 Subject: [PATCH 273/298] fix: minor fixes --- packages/examples/sdk-backend-node/package.json | 2 +- packages/restapi/src/lib/pushstream/PushStream.ts | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/examples/sdk-backend-node/package.json b/packages/examples/sdk-backend-node/package.json index 671761258..64da4f88a 100644 --- a/packages/examples/sdk-backend-node/package.json +++ b/packages/examples/sdk-backend-node/package.json @@ -11,7 +11,7 @@ "author": "", "license": "ISC", "dependencies": { - "@pushprotocol/restapi": "0.0.1-alpha.38", + "@pushprotocol/restapi": "0.0.1-alpha.39", "@pushprotocol/socket": "^0.5.2" } } diff --git a/packages/restapi/src/lib/pushstream/PushStream.ts b/packages/restapi/src/lib/pushstream/PushStream.ts index bee4577a2..794fa6a0e 100644 --- a/packages/restapi/src/lib/pushstream/PushStream.ts +++ b/packages/restapi/src/lib/pushstream/PushStream.ts @@ -198,8 +198,6 @@ export class PushStream extends EventEmitter { data = await this.chatInstance.decrypt([data]); data = data[0] } - console.log("Hola") - console.log(data); const modifiedData = DataModifier.handleChatEvent(data, this.raw); modifiedData.event = this.convertToProposedName(modifiedData.event); From fa4fc0ae78898432232031df85a1ec04cc9027c8 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:29:02 +0530 Subject: [PATCH 274/298] fix: socket enabled --- packages/restapi/src/lib/pushapi/PushAPI.ts | 4 ++-- packages/restapi/src/lib/pushstream/pushStreamTypes.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index c785dead4..58968273a 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -90,7 +90,7 @@ export class PushAPI { }, account: null, streamOptions: { - socketEnabled: true, // Default value + enabled: true, // Default value }, }; @@ -164,7 +164,7 @@ export class PushAPI { settings.progressHook ); - if (settings.streamOptions.socketEnabled) { + if (settings.streamOptions.enabled) { const streamInstance = await PushStream.initialize( api.account, decryptedPGPPrivateKey, diff --git a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts index b8fee4e9b..d00a4ba97 100644 --- a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts +++ b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts @@ -13,7 +13,7 @@ export type PushStreamInitializeProps = { }; raw?: boolean; env?: ENV; - socketEnabled?: boolean; + enabled?: boolean; }; export type PushChatInitializeProps = { From 786789a534f46d324d3018b20d6447f10eea0eab Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 17:29:54 +0530 Subject: [PATCH 275/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.40?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index bfc90450a..aa1aab5e1 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.40](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.39...restapi-0.0.1-alpha.40) (2023-09-29) + + +### Bug Fixes + +* minor fixes ([be3e90a](https://github.com/ethereum-push-notification-service/push-sdk/commit/be3e90ae43625eac56cc82548e150a6296a09777)) +* socket enabled ([fa4fc0a](https://github.com/ethereum-push-notification-service/push-sdk/commit/fa4fc0ae78898432232031df85a1ec04cc9027c8)) + + + ## [0.0.1-alpha.39](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.38...restapi-0.0.1-alpha.39) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 43ca05bab..0fa5e240f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.39", + "version": "0.0.1-alpha.40", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 4338d18e07dbb51245331547442014eff2b54707 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 19:01:42 +0530 Subject: [PATCH 276/298] fix: minor fixes --- packages/restapi/src/lib/pushapi/PushAPI.ts | 30 +++++++++++-------- .../restapi/src/lib/pushapi/pushAPITypes.ts | 10 ++++--- .../src/lib/pushstream/pushStreamTypes.ts | 6 ---- 3 files changed, 24 insertions(+), 22 deletions(-) diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index 58968273a..2e959a20d 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -24,7 +24,7 @@ export class PushAPI { public chat: Chat; // Public instances to be accessed from outside the class public profile: Profile; public encryption: Encryption; - public user: User; + private user: User; public stream!: PushStream; // Notification public channel!: Channel; @@ -78,16 +78,19 @@ export class PushAPI { static async initialize( signer: SignerType, - options?: PushAPIInitializeProps + options?: PushAPIInitializeProps, + version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3, + versionMeta?: { NFTPGP_V1?: { password: string } }, + autoUpgrade?: boolean ): Promise { try { // Default options const defaultOptions: PushAPIInitializeProps = { env: ENV.STAGING, - chatOptions: { + version: Constants.ENC_TYPE_V3, autoUpgrade: true, - }, + account: null, streamOptions: { enabled: true, // Default value @@ -99,10 +102,6 @@ export class PushAPI { const settings = { ...defaultOptions, ...options, - chatOptions: { - ...defaultOptions.chatOptions, - ...(options?.chatOptions ?? {}), - }, streamOptions: { ...defaultOptions.streamOptions, ...(options?.streamOptions ?? {}), @@ -134,8 +133,8 @@ export class PushAPI { decryptedPGPPrivateKey = await PUSH_CHAT.decryptPGPKey({ encryptedPGPPrivateKey: user.encryptedPrivateKey, signer: signer, - toUpgrade: settings.chatOptions.autoUpgrade, - additionalMeta: settings.chatOptions.versionMeta, + toUpgrade: settings.autoUpgrade, + additionalMeta: settings.versionMeta, progressHook: settings.progressHook, env: settings.env, }); @@ -145,8 +144,8 @@ export class PushAPI { env: settings.env, account: derivedAccount, signer, - version: settings.chatOptions.version, - additionalMeta: settings.chatOptions.versionMeta, + version: settings.version, + additionalMeta: settings.versionMeta, origin: settings.origin, progressHook: settings.progressHook, }); @@ -185,4 +184,11 @@ export class PushAPI { throw error; // or handle it more gracefully if desired } } + + async info() { + return await PUSH_USER.get({ + account: this.account, + env: this.env, + }); + } } diff --git a/packages/restapi/src/lib/pushapi/pushAPITypes.ts b/packages/restapi/src/lib/pushapi/pushAPITypes.ts index 8eec0a338..094b16488 100644 --- a/packages/restapi/src/lib/pushapi/pushAPITypes.ts +++ b/packages/restapi/src/lib/pushapi/pushAPITypes.ts @@ -1,5 +1,5 @@ -import { ENV } from '../constants'; -import { PushChatInitializeProps, PushStreamInitializeProps } from '../pushstream/pushStreamTypes'; +import Constants, { ENV } from '../constants'; +import { PushStreamInitializeProps } from '../pushstream/pushStreamTypes'; import { ChatStatus, ProgressHookType, Rules } from '../types'; export enum ChatListType { @@ -10,7 +10,9 @@ export interface PushAPIInitializeProps { env?: ENV; progressHook?: (progress: ProgressHookType) => void; account?: string | null; - chatOptions?: PushChatInitializeProps; + version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3; + versionMeta?: { NFTPGP_V1?: { password: string } }; + autoUpgrade?: boolean; origin?: string; streamOptions?: PushStreamInitializeProps; } @@ -38,4 +40,4 @@ export interface GroupUpdateOptions { status?: ChatStatus | null; meta?: string | null; rules?: Rules | null; -} \ No newline at end of file +} diff --git a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts index d00a4ba97..036b65017 100644 --- a/packages/restapi/src/lib/pushstream/pushStreamTypes.ts +++ b/packages/restapi/src/lib/pushstream/pushStreamTypes.ts @@ -16,12 +16,6 @@ export type PushStreamInitializeProps = { enabled?: boolean; }; -export type PushChatInitializeProps = { - version?: typeof Constants.ENC_TYPE_V1 | typeof Constants.ENC_TYPE_V3; - versionMeta?: { NFTPGP_V1?: { password: string } }; - autoUpgrade?: boolean; -} - export enum STREAM { PROFILE = 'STREAM.PROFILE', ENCRYPTION = 'STREAM.ENCRYPTION', From 313a46e8f8655e9e3484acb779dc8c2a1bd70b8f Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 19:02:47 +0530 Subject: [PATCH 277/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.41?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index aa1aab5e1..e853945c7 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.41](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.40...restapi-0.0.1-alpha.41) (2023-09-29) + + +### Bug Fixes + +* minor fixes ([4338d18](https://github.com/ethereum-push-notification-service/push-sdk/commit/4338d18e07dbb51245331547442014eff2b54707)) + + + ## [0.0.1-alpha.40](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.39...restapi-0.0.1-alpha.40) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 0fa5e240f..76dcd8f19 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.40", + "version": "0.0.1-alpha.41", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From 5e6e9050aa0e09f699f9d9fc96595bdaad7f4552 Mon Sep 17 00:00:00 2001 From: Ashis Kumar Pradhan <38760485+akp111@users.noreply.github.com> Date: Fri, 29 Sep 2023 20:54:41 +0530 Subject: [PATCH 278/298] Add counter for update channel (#740) * fix: added counter to update group * fix: added counter logic, moved delegate and alias function to channel class --- .../src/lib/pushNotification/channel.ts | 21 ++++-- .../pushNotification/pushNotificationBase.ts | 24 ++++++- packages/restapi/src/lib/pushapi/PushAPI.ts | 7 +- .../tests/lib/pushNotification/alias.test.ts | 2 +- .../lib/pushNotification/delegate.test.ts | 32 ++++----- .../lib/pushNotification/notification.test.ts | 2 +- .../lib/pushNotification/onchain.test.ts | 66 ++++++++++++------- 7 files changed, 100 insertions(+), 54 deletions(-) diff --git a/packages/restapi/src/lib/pushNotification/channel.ts b/packages/restapi/src/lib/pushNotification/channel.ts index b21fa4e3a..da57c04bb 100644 --- a/packages/restapi/src/lib/pushNotification/channel.ts +++ b/packages/restapi/src/lib/pushNotification/channel.ts @@ -23,10 +23,16 @@ import PROGRESSHOOK from '../progressHook'; import { ethers } from 'ethers'; import { PushNotificationBaseClass } from './pushNotificationBase'; +import { Delegate } from './delegate'; +import { Alias } from './alias'; export class Channel extends PushNotificationBaseClass { + public delegate!: Delegate + public alias!: Alias constructor(signer?: SignerType, env?: ENV, account?: string) { super(signer, env, account); + this.delegate = new Delegate(signer, env, account) + this.alias = new Alias(env!); } /** @@ -250,11 +256,14 @@ export class Channel extends PushNotificationBaseClass { config.TOKEN_VIEM_NETWORK_MAP[this.env!] ); const balance = await this.fetchBalance(pushTokenContract, this.account!); + // get counter + const counter = await this.fetchUpdateCounter(this.coreContract, this.account!); const fees = ethers.utils.parseUnits( config.MIN_TOKEN_BALANCE[this.env!].toString(), 18 ); - if (fees.gt(balance)) { + const totalFees = fees.mul(counter) + if (totalFees.gte(balance)) { throw new Error('Insufficient PUSH balance'); } // if alias is passed, check for the caip @@ -285,12 +294,12 @@ export class Channel extends PushNotificationBaseClass { config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT ); // if allowance is not greater than the fees, dont call approval again - if (!allowanceAmount.gte(fees)) { + if (!allowanceAmount.gte(totalFees)) { progressHook?.(PROGRESSHOOK['PUSH-UPDATE-02'] as ProgressHookType); const approvalRes = await this.approveToken( pushTokenContract, config.CORE_CONFIG[this.env!].EPNS_CORE_CONTRACT, - fees + totalFees ); if (!approvalRes) { throw new Error('Something went wrong while approving the token'); @@ -305,7 +314,7 @@ export class Channel extends PushNotificationBaseClass { this.coreContract, this.account!, identityBytes, - fees + totalFees ); progressHook?.(PROGRESSHOOK['PUSH-UPDATE-04'] as ProgressHookType); return { transactionHash: updateChannelRes }; @@ -343,6 +352,10 @@ export class Channel extends PushNotificationBaseClass { if (!ethers.utils.isAddress(channelToBeVerified)) { throw new Error('Invalid channel address'); } + const channelDetails = await this.info(this.account); + if(channelDetails?.verified_status == 0){ + throw new Error("Only verified channel can verify other channel") + } // if valid, continue with it const res = await this.verifyChannel( this.coreContract, diff --git a/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts b/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts index c081b2f0e..1d9aab9ab 100644 --- a/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts +++ b/packages/restapi/src/lib/pushNotification/pushNotificationBase.ts @@ -328,6 +328,26 @@ export class PushNotificationBaseClass { } } + protected async fetchUpdateCounter(contract: any, userAddress: string) { + let count: BigNumber; + try { + if ('_signTypedData' in this.signer!) { + count = await contract!['channelUpdateCounter'](userAddress); + } else if ('signTypedData' in this.signer!) { + const countInBigInt = await contract.read.channelUpdateCounter({ + args: [userAddress], + }); + count = ethers.BigNumber.from(countInBigInt); + } else { + throw new Error('Unsupported signer'); + } + // add one and return the count + return count.add(ethers.BigNumber.from(1)); + } catch (error) { + throw new Error(JSON.stringify(error)); + } + } + protected async approveToken( contract: any, spenderAddress: string, @@ -650,7 +670,9 @@ export class PushNotificationBaseClass { ele.data.upper; notificationSettingDescription = - notificationSettingDescription + SETTING_SEPARATOR + ele.description; + notificationSettingDescription + + SETTING_SEPARATOR + + ele.description; } } } diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index 2e959a20d..5606e391d 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -10,9 +10,8 @@ import { Encryption } from './encryption'; import { User } from './user'; import { PushStream } from '../pushstream/PushStream'; import { Channel } from '../pushNotification/channel'; -import { Alias } from '../pushNotification/alias'; -import { Delegate } from '../pushNotification/delegate'; import { Notification } from '../pushNotification/notification'; + export class PushAPI { private signer: SignerType; private account: string; @@ -28,8 +27,6 @@ export class PushAPI { public stream!: PushStream; // Notification public channel!: Channel; - public alias!: Alias; - public delegate!: Delegate; public notification!: Notification; private constructor( @@ -48,8 +45,6 @@ export class PushAPI { this.progressHook = progressHook; // Instantiate the notification classes this.channel = new Channel(this.signer, this.env, this.account); - this.alias = new Alias(this.env); - this.delegate = new Delegate(this.signer, this.env, this.account); this.notification = new Notification(this.signer, this.env, this.account); // Initialize the instances of the four classes this.chat = new Chat( diff --git a/packages/restapi/tests/lib/pushNotification/alias.test.ts b/packages/restapi/tests/lib/pushNotification/alias.test.ts index 1bd9c5cfb..ae62cf864 100644 --- a/packages/restapi/tests/lib/pushNotification/alias.test.ts +++ b/packages/restapi/tests/lib/pushNotification/alias.test.ts @@ -42,7 +42,7 @@ describe('PushAPI.alias functionality', () => { describe('alias :: info', () => { // TODO: remove skip after signer becomes optional it('Should return response', async () => { - const res = await userBob.alias.info({ + const res = await userBob.channel.alias.info({ alias: '0x93A829d16DE51745Db0530A0F8E8A9B8CA5370E5', aliasChain: 'POLYGON', }); diff --git a/packages/restapi/tests/lib/pushNotification/delegate.test.ts b/packages/restapi/tests/lib/pushNotification/delegate.test.ts index 9f99794df..71a723cd2 100644 --- a/packages/restapi/tests/lib/pushNotification/delegate.test.ts +++ b/packages/restapi/tests/lib/pushNotification/delegate.test.ts @@ -41,7 +41,7 @@ describe('PushAPI.delegate functionality', () => { // TODO: remove skip after signer becomes optional it.skip('Without signer and account :: should throw error', async () => { await expect(() => - userBob.delegate.add( + userBob.channel.delegate.add( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ) ).to.Throw; @@ -49,14 +49,14 @@ describe('PushAPI.delegate functionality', () => { it('With signer and without provider :: should throw error', async () => { await expect(() => - userAlice.delegate.add( + userAlice.channel.delegate.add( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ) ).to.Throw; }); it('With signer and provider :: should add delegate', async () => { - const res = await userKate.delegate.add( + const res = await userKate.channel.delegate.add( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); // console.log(res); @@ -65,7 +65,7 @@ describe('PushAPI.delegate functionality', () => { it('With signer and provider :: should throw error as delegate caip and provider doesnt match', async () => { await expect(() => - userKate.delegate.add( + userKate.channel.delegate.add( 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ) ).to.Throw; @@ -82,7 +82,7 @@ describe('PushAPI.delegate functionality', () => { provider ); userKate = await PushAPI.initialize(signer2); - const res = await userKate.delegate.add( + const res = await userKate.channel.delegate.add( 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); // console.log(res); @@ -94,7 +94,7 @@ describe('PushAPI.delegate functionality', () => { // TODO: remove skip after signer becomes optional it.skip('Without signer and account :: should throw error', async () => { await expect(() => - userBob.delegate.remove( + userBob.channel.delegate.remove( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ) ).to.Throw; @@ -102,14 +102,14 @@ describe('PushAPI.delegate functionality', () => { it('With signer and without provider :: should throw error', async () => { await expect(() => - userAlice.delegate.remove( + userAlice.channel.delegate.remove( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ) ).to.Throw; }); it('With signer and provider :: should add delegate', async () => { - const res = await userKate.delegate.remove( + const res = await userKate.channel.delegate.remove( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); console.log(res); @@ -118,13 +118,13 @@ describe('PushAPI.delegate functionality', () => { it('With signer and provider :: should throw error as delegate caip and provider doesnt match', async () => { await expect(() => - userKate.delegate.remove( + userKate.channel.delegate.remove( 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ) ).to.Throw; }); - it('With viem signer: Should add delegate', async () => { + it.only('With viem signer: Should remove delegate', async () => { // create polygon mumbai provider const provider = new ethers.providers.JsonRpcProvider( 'https://rpc-mumbai.maticvigil.com' @@ -135,7 +135,7 @@ describe('PushAPI.delegate functionality', () => { provider ); userKate = await PushAPI.initialize(signer2); - const res = await userKate.delegate.remove( + const res = await userKate.channel.delegate.remove( 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); // console.log(res); @@ -145,18 +145,18 @@ describe('PushAPI.delegate functionality', () => { describe('delegate :: get', () => { it.skip('Without signer and account : Should throw error', async () => { - await expect(() => userBob.delegate.get()).to.Throw; + await expect(() => userBob.channel.delegate.get()).to.Throw; }); it('Without signer : Should throw error for non-caip format', async () => { await expect(() => - userBob.delegate.get({ + userBob.channel.delegate.get({ channel: '0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924', }) ).to.Throw; }); it('Without signer : Should fetch delegates', async () => { - const res = await userBob.delegate.get({ + const res = await userBob.channel.delegate.get({ channel: 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681', }); console.log(res); @@ -164,7 +164,7 @@ describe('PushAPI.delegate functionality', () => { }); it('Without signer : Should fetch delegates for alias', async () => { - const res = await userBob.delegate.get({ + const res = await userBob.channel.delegate.get({ channel: 'eip155:80001:0xD8634C39BBFd4033c0d3289C4515275102423681', }); // console.log(res) @@ -172,7 +172,7 @@ describe('PushAPI.delegate functionality', () => { }); it('With signer : Should fetch delegates for channel', async () => { - const res = await userKate.delegate.get(); + const res = await userKate.channel.delegate.get(); // console.log(res); expect(res).not.null; }); diff --git a/packages/restapi/tests/lib/pushNotification/notification.test.ts b/packages/restapi/tests/lib/pushNotification/notification.test.ts index d9a6ec2c3..31442a287 100644 --- a/packages/restapi/tests/lib/pushNotification/notification.test.ts +++ b/packages/restapi/tests/lib/pushNotification/notification.test.ts @@ -52,7 +52,7 @@ describe('PushAPI.notification functionality', () => { userViem = await PushAPI.initialize(viemSigner); }); - describe('', () => { + describe('PushAPI.notification functionality', () => { it('Should return feeds with signer object', async () => { const response = await userAlice.notification.list('SPAM'); expect(response).not.null; diff --git a/packages/restapi/tests/lib/pushNotification/onchain.test.ts b/packages/restapi/tests/lib/pushNotification/onchain.test.ts index e5412da59..c8e91058c 100644 --- a/packages/restapi/tests/lib/pushNotification/onchain.test.ts +++ b/packages/restapi/tests/lib/pushNotification/onchain.test.ts @@ -3,8 +3,8 @@ // dotenv.config({ path: path.resolve(__dirname, '../../../.env') }); // import { expect } from 'chai'; // import { generatePrivateKey, privateKeyToAccount } from 'viem/accounts'; - -// import { PushNotification } from '../../../../src/lib/pushNotification/PushNotification'; +// import { PushNotificationBaseClass } from '../../../src/lib/pushNotification/pushNotificationBase'; +// import * as config from "../../../src/lib/config" // import { // createWalletClient, // http, @@ -15,6 +15,15 @@ // import { goerli, polygonMumbai } from 'viem/chains'; // import { BigNumber, ethers } from 'ethers'; +// enum ENV { +// PROD = 'prod', +// STAGING = 'staging', +// DEV = 'dev', +// /** +// * **This is for local development only** +// */ +// LOCAL = 'local', +// } // describe.only('test', () => { // const signer = createWalletClient({ // account: privateKeyToAccount(`0x${process.env['WALLET_PRIVATE_KEY']}`), @@ -37,32 +46,35 @@ // `0x${process.env['WALLET_PRIVATE_KEY']}`, // provider // ); - -// it.only('testing with viem', async () => { -// const userViem = await PushNotification.initialize(signer); +// it('testing with viem', async () => { +// const account2 = await signer2.getAddress(); +// const viemUser = new PushNotificationBaseClass(signer, ENV.STAGING, account2) +// const contract = viemUser.createContractInstance("0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C", config.ABIS.CORE, goerli) +// const res = await viemUser.fetchUpdateCounter(contract, account2); +// console.log(res) // const viemContract = await userViem.createContractInstance( // '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', // abi, // goerli // ); -// // const balance = await userViem.fetchBalance( -// // viemContract, -// // '0xD8634C39BBFd4033c0d3289C4515275102423681' -// // ); -// // console.log(balance); -// // const allowance = await userViem.fetchAllownace( -// // viemContract, -// // '0xD8634C39BBFd4033c0d3289C4515275102423681', -// // '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C' -// // ); -// // console.log(allowance); -// // const approveAmount = ethers.BigNumber.from(10000); -// // const approveRes = await userViem.approveToken( -// // viemContract, -// // '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C', -// // approveAmount -// // ); -// // console.log(approveRes); +// const balance = await userViem.fetchBalance( +// viemContract, +// '0xD8634C39BBFd4033c0d3289C4515275102423681' +// ); +// console.log(balance); +// const allowance = await userViem.fetchAllownace( +// viemContract, +// '0xD8634C39BBFd4033c0d3289C4515275102423681', +// '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C' +// ); +// console.log(allowance); +// const approveAmount = ethers.BigNumber.from(10000); +// const approveRes = await userViem.approveToken( +// viemContract, +// '0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C', +// approveAmount +// ); +// console.log(approveRes); // const addDelegate = await userViem.delegate.add( // 'eip155:5:0xD8634C39BBFd4033c0d3289C4515275102423681' @@ -70,8 +82,12 @@ // console.log(addDelegate); // }); -// it('test with ethers', async () => { -// const userEthers = await PushNotification.initialize(signer2); +// it.only('test with ethers', async () => { +// const account2 = await signer2.getAddress(); +// const userEthers = new PushNotificationBaseClass(signer2, ENV.STAGING, account2,); +// const contract = userEthers.createContractInstance("0xd4E3ceC407cD36d9e3767cD189ccCaFBF549202C", config.ABIS.CORE, goerli) +// const res = await userEthers.fetchUpdateCounter(contract, account2); +// console.log(res) // const ethersContract = await userEthers.createContractInstance( // '0x2b9bE9259a4F5Ba6344c1b1c07911539642a2D33', // abi, From 806b48717c8786c328d4e00223ac9107c5f3f23e Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 20:57:35 +0530 Subject: [PATCH 279/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.42?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index e853945c7..055a5d3cd 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.42](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.41...restapi-0.0.1-alpha.42) (2023-09-29) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([6c3b91d](https://github.com/ethereum-push-notification-service/push-sdk/commit/6c3b91d79622e695808e38afb1e5dbdccab2f3eb)) + + + ## [0.0.1-alpha.41](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.40...restapi-0.0.1-alpha.41) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 76dcd8f19..707f63591 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.41", + "version": "0.0.1-alpha.42", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From bb487a6711984b67a8005cb0bc64fb9e65af3033 Mon Sep 17 00:00:00 2001 From: Ashis Kumar Pradhan <38760485+akp111@users.noreply.github.com> Date: Fri, 29 Sep 2023 21:10:27 +0530 Subject: [PATCH 280/298] Add counter for update channel (#741) * fix: added counter to update group * fix: added counter logic, moved delegate and alias function to channel class * fix: added readme for notification --- packages/restapi/README.md | 332 +++++++++++++++++++++++++++++++++++++ 1 file changed, 332 insertions(+) diff --git a/packages/restapi/README.md b/packages/restapi/README.md index 281487e32..1aa9dffde 100644 --- a/packages/restapi/README.md +++ b/packages/restapi/README.md @@ -6461,3 +6461,335 @@ const aliceUpdateEncryption = await userAlice.encryption.update( --- + + +### **Fetch Inbox /Spam notifications** + +```tsx +// lists feeds +const aliceInfo = await userAlice.notification.list(); + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| spam | INBOX or SPAM | INBOX | A string representing the type of feed to retrieve. | +| options* | object | - | An object containing additional options for filtering and pagination. | +| options.account* | string | - | Account in full CAIP | +| options.channels* | [string] | - | An array of channels to filter feeds by. | +| options.page* | number | - | A number representing the page of results to retrieve. | +| options.limit* | number | - | A number representing the maximum number of feeds to retrieve per page. | +| options.raw* | boolean | - | A boolean indicating whether to retrieve raw feed data. | + +\* - Optional + +--- + +### **Fetch user subscriptions** + +```tsx +// fetches list of channels to which the user is subscribed +const subscriptions = await userAlice.notification.subscriptions(); + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| options* | object | - | An object containing additional options for subscriptions. | +| options.account* | string | - | Account in CAIP . | +| options.page* | number | - | page of results to retrieve. | +| options.limit* | number | - | represents the maximum number of subscriptions to retrieve per page. | + +\* - Optional + +--- + +### **Subscribe to a channel** + +```tsx +// subscribes to a channel +const subscribeStatus = await userAlice.notification.subscribe(channelInCAIP) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| channel | string | - | Channel/Alias address in CAIP format | +| options* | SubscribeUnsubscribeOptions | - | Optional configuration | +| options.onSuccess* | () => void | - | A callback function to execute when the subscription is successful. | +| options.onError* | (err: Error) => void | - | A callback function to execute when an error occurs during subscription. | + +\* - Optional + +--- + +### **Unsubscribe to a channel** + +```tsx +// unsubscribes to the channel +const unsubscribeStatus = await userAlice.notification.unsubscribe(channelInCAIP) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| channel | string | - | Channel/Alias address in CAIP format | +| options* | SubscribeUnsubscribeOptions | - | Optional configuration | +| options.onSuccess* | () => void | - | A callback function to execute when the unsubscription is successful. | +| options.onError* | (err: Error) => void | - | A callback function to execute when an error occurs during unsubscription. | + +\* - Optional + +--- + +### **Channel information** + +```tsx +// fetches information about the channel +const channelInfo = await userAlice.channel.info(pushChannelInCAIP) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| channel* | string | - | Channel address in CAIP format | + +\* - Optional + +--- + +### **Search Channels** + +```tsx +// returns channel matching the query +const searchResult = await userAlice.channel.search("push") + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| query | string | - | The search query to find channels. | +| options* | ChannelSearchOptions | - | Configuration options for the search. | +| options.page* | number | - | The page of results to retrieve. Default is set to 1 | +| options.limit* | number | - | The maximum number of channels to retrieve per page. Default is set to 10 | + +\* - Optional + +### **Get a channel's subscribers** + +```tsx +// fetches subscribers of a channel +const subscribersResult = await userAlice.channel.subscribers() + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| options* | ChannelInfoOptions | - | Configuration options for retrieving subscribers. | +| options.channel* | string | - | Channel address in CAIP | + +\* - Optional + +### **Send a notification** + +```tsx +// sends a notification +const sendNotifRes = await userAlice.channel.send(['*'], {notification: {title: 'test',body: 'test',},}) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| recipients | string[] | - | An array of recipient addresses. Possible values are: Broadcast -> [*], Targeted -> [0xA], Subset -> [0xA, 0xB] | +| options | NotificationOptions | - | Configuration options for sending notifications. | +| options.notification | INotification | - | An object containing the notification's title and body. (Mandatory) | +| options.payload* | IPayload | - | An object containing additional payload information for the notification. | +| options.payload.title* | string | - | The title for the notification. If not provided, it is taken from notification.title. | +| options.payload.body* | string | - | The body of the notification. If not provided, it is taken from notification.body. | +| options.payload.cta* | string | - | Call to action for the notification. | +| options.payload.embed | string | - | Media information like image/video links | +| options.payload.meta* | { domain?: string, type: string, data: string } | - | Metadata for the notification, including domain, type, and data. | +| options.config* | IConfig | - | An object containing configuration options for the notification. | +| options.config.expiry* | number | - | Expiry time for the notification in seconds | +| options.config.silent* | boolean | - | Indicates whether the notification is silent. | +| options.config.hidden* | boolean | - | Indicates whether the notification is hidden. | +| options.advanced* | IAdvance | - | An object containing advanced options for the notification. | +| options.advanced.graph* | { id: string, counter: number } | - | Advanced options related to the graph based notification. | +| options.advanced.ipfs* | string | - | IPFS information for the notification. | +| options.advanced.minimal* | string | - | Minimal Payload type notification. | +| options.advanced.chatid* | string | - | For chat based notification. | +| options.advanced.pgpPrivateKey* | string | - | PGP private key for chat based notification. | +| options.channel* | string | - | Channel address in CAIP. Mostly used when a delegator sends a notification on behalf of the channel | + +\* - Optional + +--- + +### **Create a channel** + +```tsx +// creates a channel +const createChannelRes = await userAlice.channel.create({name: channelName, description: channelDescription, url: channelURL, icon: base64FormatImage, alias?: aliasAddressInCAIP}) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| options | CreateChannelOptions | - | Configuration options for creating a channel. | +| options.name | string | - | The name of the channel. | +| options.description | string | - | A description of the channel. | +| options.icon | string (base64 encoded) | - | The channel's icon in base64 encoded string format. | +| options.url | string | - | The URL associated with the channel. | +| options.alias* | string | - | alias address in CAIP | +| options.progresshook* | () => void | - | (Optional) A callback function to execute when the channel creation progresses. | + +**Note**: Support for contract interaction via `viem` is coming soon +\* - Optional + +--- + +### **Update a channel's information** + +```tsx +// updates channel info +const updateChannelRes = await userAlice.channel.update({name: newChannelName, description: newChannelDescription, url: newChannelURL, icon: newBase64FormatImage, alias?: newAliasAddressInCAIP}) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| options | - | - | Configuration options for creating a channel. | +| options.name | string | - | New name of the channel. | +| options.description | string | - | New description of the channel. | +| options.icon | string (base64 encoded) | - | The channel's new icon in base64 encoded string format. | +| options.url | string | - | New URL associated with the channel. | +| options.alias* | string | - | New alias address in CAIP | +| options.progresshook* | () => void | - | A callback function to execute when the channel updation progresses. | +| Note: Support for contract interaction via viem is coming soon | | | | + +\* - Optional + +--- + +### **Verify a channel** + +```tsx +const verifyChannelRes = await userAlice.channel.verify(channelToBeVerified) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| channelToBeVerified | string | - | Channel address in CAIP to be verified | + +--- + +### **Create channel Setting** + +```tsx +// creates channel settings +const createChannelSettingRes = userAlice.channel.settings([{ type: 0, default: 1, description: 'marketing' }, {type: 2, default: 10, description: 'loan liquidation threshold', data: {upper: 100, lower: 5}}]) + +``` + +**Parameters:** + +| Property | Type | Default | Description | +| --- | --- | --- | --- | +| type | number | - | The type of notification setting. 1 for boolean type and 2 for slider type | +| default | number | - | The default value for the setting. | +| description | string | - | A description of the setting. | +| data.upper* | number | - | Valid for slider type only. The upper limit for the setting. | +| data.lower* | number | - | Valid for slider type only. The lower limit for the setting. | +| Note: Support for contract interaction via viem is coming soon | | | | +| \* - Optional | | | | + +--- + +### **Get delegators information** + +```tsx +// fetch delegate information +const delegatorsInfo = userAlice.channel.delegate.get() + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| options* | ChannelInfoOptions | - | Configuration options for retrieving delegator information. | +| options.channel* | string | - | channel address in CAIP | +| \* - Optional | | | | + +--- + +### **Add delegator to a channel/alias** + +```tsx +// adds a delegate +const addDelegatorRes = userAlice.channel.delegate.add(delegatorAddressInCAIP) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| delegate | string | - | delegator address in CAIP | +| Note: Support for contract interaction via viem is coming soon | | | | + +--- + +### **Remove delegator from a channel/alias** + +```tsx +// removes a delegate +const removeDelegatorRes = userAlice.channel.delegate.remove(delegatorAddressInCAIP) + +``` + +**Parameters:** + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| delegate | string | - | delegator address in CAIP | +| Note: Support for contract interaction via viem is coming soon | | | | + +--- + +### **Alias Information** + +```tsx +// fetch alias info +const aliasInfo = userAlice.channel.alias.info({alias: '0xABC', aliasChain:'POLYGON'}) + +``` + +| Parameter | Type | Default | Description | +| --- | --- | --- | --- | +| options | AliasOptions | - | Configuration options for retrieving alias information. | +| options.alias | string | - | The alias address | +| options.aliasChain | ALIAS_CHAIN | - | The name of the alias chain, which can be 'POLYGON' or 'BSC' or 'OPTIMISM' or 'POLYGONZKEVM' | \ No newline at end of file From 6954ab94155806d3cf808597fd8a4061acdd9330 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Fri, 29 Sep 2023 21:11:18 +0530 Subject: [PATCH 281/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.43?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 9 +++++++++ packages/restapi/package.json | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 055a5d3cd..75bd24d96 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,15 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.43](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.42...restapi-0.0.1-alpha.43) (2023-09-29) + + +### Bug Fixes + +* Merge branch 'alpha' into alpha-deployment ([0bf9a2d](https://github.com/ethereum-push-notification-service/push-sdk/commit/0bf9a2d6e0e8ff19af34e5e53ee6e05f35bc0479)) + + + ## [0.0.1-alpha.42](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.41...restapi-0.0.1-alpha.42) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index 707f63591..d7ca1cc0f 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.42", + "version": "0.0.1-alpha.43", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From c73b6ccfb510dfc38150a4207f806ccee7b44efb Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 3 Oct 2023 11:04:30 +0530 Subject: [PATCH 282/298] fix: minor fix --- packages/restapi/src/lib/pushapi/PushAPI.ts | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/packages/restapi/src/lib/pushapi/PushAPI.ts b/packages/restapi/src/lib/pushapi/PushAPI.ts index 5606e391d..e79fd5dc9 100644 --- a/packages/restapi/src/lib/pushapi/PushAPI.ts +++ b/packages/restapi/src/lib/pushapi/PushAPI.ts @@ -82,10 +82,10 @@ export class PushAPI { // Default options const defaultOptions: PushAPIInitializeProps = { env: ENV.STAGING, - - version: Constants.ENC_TYPE_V3, - autoUpgrade: true, - + + version: Constants.ENC_TYPE_V3, + autoUpgrade: true, + account: null, streamOptions: { enabled: true, // Default value @@ -97,6 +97,10 @@ export class PushAPI { const settings = { ...defaultOptions, ...options, + version: version || defaultOptions.version, + versionMeta: versionMeta || defaultOptions.versionMeta, + autoUpgrade: + autoUpgrade !== undefined ? autoUpgrade : defaultOptions.autoUpgrade, streamOptions: { ...defaultOptions.streamOptions, ...(options?.streamOptions ?? {}), From 8cdf4a34d93aa74b626cddb65fc45a9f5fd6a360 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 3 Oct 2023 12:37:59 +0530 Subject: [PATCH 283/298] =?UTF-8?q?ci(uiweb):=20=F0=9F=8E=89=20cut=20relea?= =?UTF-8?q?se=20to=20uiweb-v1.1.14?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/uiweb/CHANGELOG.md | 12 ++++++++++++ packages/uiweb/package.json | 2 +- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/packages/uiweb/CHANGELOG.md b/packages/uiweb/CHANGELOG.md index 460f32368..2047ce575 100644 --- a/packages/uiweb/CHANGELOG.md +++ b/packages/uiweb/CHANGELOG.md @@ -2,6 +2,18 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [1.1.14](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.13...uiweb-1.1.14) (2023-10-03) + + +### Bug Fixes + +* fixed typo ([3c6b14d](https://github.com/ethereum-push-notification-service/push-sdk/commit/3c6b14d1ae68ce74c91864d898e3d646898655bb)) +* Merge branch 'main' into deployment ([afdc6f8](https://github.com/ethereum-push-notification-service/push-sdk/commit/afdc6f8669dd0cd9ece859f4c8f6dc4181872e2c)) +* Merge branch 'main' into deployment ([f9bb113](https://github.com/ethereum-push-notification-service/push-sdk/commit/f9bb113702f47132dc512910e5060286e985f4bf)) +* minor fixes ([6737403](https://github.com/ethereum-push-notification-service/push-sdk/commit/6737403738dd70ad4056f9d10b4ab363fc172094)) + + + ## [1.1.13](https://github.com/ethereum-push-notification-service/push-sdk/compare/uiweb-1.1.12...uiweb-1.1.13) (2023-08-24) diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 04a0fc8d3..6bc4576fb 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/uiweb", - "version": "1.1.13", + "version": "1.1.14", "publishConfig": { "registry": "https://registry.npmjs.org/" }, From 68b38e91a1afacb21baa0ee29f8967d86ce4b7f7 Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 3 Oct 2023 12:51:27 +0530 Subject: [PATCH 284/298] fix: log removed --- packages/restapi/src/lib/pushstream/PushStream.ts | 4 ---- 1 file changed, 4 deletions(-) diff --git a/packages/restapi/src/lib/pushstream/PushStream.ts b/packages/restapi/src/lib/pushstream/PushStream.ts index 794fa6a0e..71dd36b00 100644 --- a/packages/restapi/src/lib/pushstream/PushStream.ts +++ b/packages/restapi/src/lib/pushstream/PushStream.ts @@ -219,8 +219,6 @@ export class PushStream extends EventEmitter { this.pushNotificationSocket.on(EVENTS.USER_FEEDS, (data: any) => { try { - console.log('Incoming Feed from Socket'); - console.log(data); this.emit(STREAM.NOTIF, data); } catch (error) { console.error('Error handling USER_FEEDS event:', error, 'Data:', data); @@ -229,8 +227,6 @@ export class PushStream extends EventEmitter { this.pushNotificationSocket.on(EVENTS.USER_SPAM_FEEDS, (data: any) => { try { - console.log('Incoming Spam Feed from Socket'); - console.log(data); this.emit(STREAM.NOTIF, data); } catch (error) { console.error( From 71350915fe346b4410246ca7fb1a45b884ecc75a Mon Sep 17 00:00:00 2001 From: Mohammed S Date: Tue, 3 Oct 2023 13:05:12 +0530 Subject: [PATCH 285/298] =?UTF-8?q?ci(restapi):=20=F0=9F=8E=89=20cut=20bet?= =?UTF-8?q?a=20release=20to=20restapi-v0.0.1-alpha.44?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/restapi/CHANGELOG.md | 10 ++++++++++ packages/restapi/package.json | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/packages/restapi/CHANGELOG.md b/packages/restapi/CHANGELOG.md index 75bd24d96..393b1c1be 100644 --- a/packages/restapi/CHANGELOG.md +++ b/packages/restapi/CHANGELOG.md @@ -2,6 +2,16 @@ This file was generated using [@jscutlery/semver](https://github.com/jscutlery/semver). +## [0.0.1-alpha.44](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.43...restapi-0.0.1-alpha.44) (2023-10-03) + + +### Bug Fixes + +* log removed ([68b38e9](https://github.com/ethereum-push-notification-service/push-sdk/commit/68b38e91a1afacb21baa0ee29f8967d86ce4b7f7)) +* minor fix ([c73b6cc](https://github.com/ethereum-push-notification-service/push-sdk/commit/c73b6ccfb510dfc38150a4207f806ccee7b44efb)) + + + ## [0.0.1-alpha.43](https://github.com/ethereum-push-notification-service/push-sdk/compare/restapi-0.0.1-alpha.42...restapi-0.0.1-alpha.43) (2023-09-29) diff --git a/packages/restapi/package.json b/packages/restapi/package.json index d7ca1cc0f..c9d214e70 100644 --- a/packages/restapi/package.json +++ b/packages/restapi/package.json @@ -1,6 +1,6 @@ { "name": "@pushprotocol/restapi", - "version": "0.0.1-alpha.43", + "version": "0.0.1-alpha.44", "type": "commonjs", "publishConfig": { "registry": "https://registry.npmjs.org/" From ec08686eb6a86065e248b8c2a6bd5c7e3028ffe7 Mon Sep 17 00:00:00 2001 From: aman035 Date: Tue, 3 Oct 2023 13:36:07 +0530 Subject: [PATCH 286/298] docs: fix tests --- .../restapi/tests/lib/pushNotification/delegate.test.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/restapi/tests/lib/pushNotification/delegate.test.ts b/packages/restapi/tests/lib/pushNotification/delegate.test.ts index 71a723cd2..bc43c9986 100644 --- a/packages/restapi/tests/lib/pushNotification/delegate.test.ts +++ b/packages/restapi/tests/lib/pushNotification/delegate.test.ts @@ -112,7 +112,7 @@ describe('PushAPI.delegate functionality', () => { const res = await userKate.channel.delegate.remove( 'eip155:5:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); - console.log(res); + console.log(res); expect(res).not.null; }, 100000000); @@ -124,7 +124,7 @@ describe('PushAPI.delegate functionality', () => { ).to.Throw; }); - it.only('With viem signer: Should remove delegate', async () => { + it('With viem signer: Should remove delegate', async () => { // create polygon mumbai provider const provider = new ethers.providers.JsonRpcProvider( 'https://rpc-mumbai.maticvigil.com' @@ -138,7 +138,7 @@ describe('PushAPI.delegate functionality', () => { const res = await userKate.channel.delegate.remove( 'eip155:80001:0x74415Bc4C4Bf4Baecc2DD372426F0a1D016Fa924' ); - // console.log(res); + // console.log(res); expect(res).not.null; }, 10000000); }); From f64b275def9d335e3dfd412c6bcbb032f5f21ee6 Mon Sep 17 00:00:00 2001 From: Arnab Chatterjee <60937304+arn4b@users.noreply.github.com> Date: Tue, 3 Oct 2023 17:52:10 +0530 Subject: [PATCH 287/298] Feat/space backup (#746) * refactor: added code for joining livekit room for listeners (#731) * feat: drop in livekit inplace of livepeer (#736) * feat: drop in livekit inplace of livepeer * feat: added microphone * feat: added mic * feat: added access control --------- Co-authored-by: Nilesh Gupta --- .../src/lib/space/acceptPromotionRequest.ts | 20 +- packages/restapi/src/lib/space/start.ts | 217 +++++++++--------- packages/uiweb/package.json | 6 +- .../space/SpaceWidget/LiveWidgetContent.tsx | 180 +++++++++++---- .../space/SpaceWidget/Microphone.tsx | 45 ++++ .../SpaceWidget/ScheduledWidgetContent.tsx | 41 +++- .../space/SpaceWidget/WidgetContent.tsx | 1 + packages/uiweb/src/lib/config/constants.ts | 7 +- .../src/lib/services/getLivekitRoomToken.ts | 25 ++ packages/uiweb/src/lib/services/index.ts | 2 + .../uiweb/src/lib/services/performAction.ts | 15 ++ packages/uiweb/yarn.lock | 135 ++++++++++- 12 files changed, 521 insertions(+), 173 deletions(-) create mode 100644 packages/uiweb/src/lib/components/space/SpaceWidget/Microphone.tsx create mode 100644 packages/uiweb/src/lib/services/getLivekitRoomToken.ts create mode 100644 packages/uiweb/src/lib/services/index.ts create mode 100644 packages/uiweb/src/lib/services/performAction.ts diff --git a/packages/restapi/src/lib/space/acceptPromotionRequest.ts b/packages/restapi/src/lib/space/acceptPromotionRequest.ts index 0a5ea4ea3..6ed125b25 100644 --- a/packages/restapi/src/lib/space/acceptPromotionRequest.ts +++ b/packages/restapi/src/lib/space/acceptPromotionRequest.ts @@ -36,14 +36,14 @@ export async function acceptPromotionRequest( }); // accept the promotion request - this.acceptRequest({ - signalData, - senderAddress: this.data.local.address, - recipientAddress: pCAIP10ToWallet(promoteeAddress), - chatId: spaceId, - details: { - type: SPACE_ACCEPT_REQUEST_TYPE.ACCEPT_PROMOTION, - data: {}, - }, - }); + // this.acceptRequest({ + // signalData, + // senderAddress: this.data.local.address, + // recipientAddress: pCAIP10ToWallet(promoteeAddress), + // chatId: spaceId, + // details: { + // type: SPACE_ACCEPT_REQUEST_TYPE.ACCEPT_PROMOTION, + // data: {}, + // }, + // }); } diff --git a/packages/restapi/src/lib/space/start.ts b/packages/restapi/src/lib/space/start.ts index 6a14791e7..23ac20bc9 100644 --- a/packages/restapi/src/lib/space/start.ts +++ b/packages/restapi/src/lib/space/start.ts @@ -31,14 +31,15 @@ type StartType = { livepeerApiKey: string; }; -export async function start(this: Space, options: StartType): Promise { - const { livepeerApiKey } = options || {}; +// export async function start(this: Space, options: StartType): Promise { +export async function start(this: Space): Promise { + // const { livepeerApiKey } = options || {}; try { // host should have there audio stream - if (!this.data.local.stream) { - throw new Error('Local audio stream not found'); - } + // if (!this.data.local.stream) { + // throw new Error('Local audio stream not found'); + // } const space = await get({ spaceId: this.spaceSpecificData.spaceId, @@ -115,109 +116,109 @@ export async function start(this: Space, options: StartType): Promise { }); }); - // start the livepeer playback and store the playback URL group meta - // send a notification/meta message to all the added listeners (members) telling the space has started - - // create the mergeStream object - const mergedStream = getMergeStreamObject(this.data.local.stream); - // store the mergeStreamObject - this.mergedStream = mergedStream; - - const url = 'https://livepeer.studio/api/stream'; - const data = { - name: this.spaceSpecificData.spaceName, - record: true, - }; - - const { data: responseData } = await axios.post(url, data, { - headers: { - Authorization: 'Bearer ' + livepeerApiKey, - }, - }); - - const { streamKey, playbackId } = responseData; - - console.log('livepeer details', streamKey, playbackId); - - this.update({ meta: playbackId }); - - let redirectUrl; - try { - console.log('Ignore the following error'); - - // the redirect URL from the above GET request - await axios.get(`https://livepeer.studio/webrtc/${streamKey}`); - } catch (err: any) { - console.log('redirectUrl error', err); - redirectUrl = err.request.responseURL; - } - - // we use the host from the redirect URL in the ICE server configuration - const host = new URL(redirectUrl).host; - - const iceServers = [ - { - urls: `stun:${host}`, - }, - { - urls: `turn:${host}`, - username: 'livepeer', - credential: 'livepeer', - }, - ]; - - const peerConnection = new RTCPeerConnection({ iceServers }); - - const newAudioTrack = mergedStream.result?.getAudioTracks?.()?.[0] ?? null; - - if (newAudioTrack) { - peerConnection?.addTransceiver(newAudioTrack, { - direction: 'sendonly', - }); - } - - /** - * https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/createOffer - * We create an SDP offer here which will be shared with the server - */ - const offer = await peerConnection.createOffer(); - /** https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/setLocalDescription */ - await peerConnection.setLocalDescription(offer); - - /** Wait for ICE gathering to complete */ - const ofr = await new Promise((resolve) => { - /** Wait at most five seconds for ICE gathering. */ - setTimeout(() => { - resolve(peerConnection.localDescription); - }, 5000); - peerConnection.onicegatheringstatechange = (_ev) => { - if (peerConnection.iceGatheringState === 'complete') { - resolve(peerConnection.localDescription); - } - }; - }); - if (!ofr) { - throw Error('failed to gather ICE candidates for offer'); - } - /** - * This response contains the server's SDP offer. - * This specifies how the client should communicate, - * and what kind of media client and server have negotiated to exchange. - */ - const sdpResponse = await fetch(redirectUrl, { - method: 'POST', - mode: 'cors', - headers: { - 'content-type': 'application/sdp', - }, - body: ofr.sdp, - }); - if (sdpResponse.ok) { - const answerSDP = await sdpResponse.text(); - await peerConnection.setRemoteDescription( - new RTCSessionDescription({ type: 'answer', sdp: answerSDP }) - ); - } + // // start the livepeer playback and store the playback URL group meta + // // send a notification/meta message to all the added listeners (members) telling the space has started + + // // create the mergeStream object + // const mergedStream = getMergeStreamObject(this.data.local.stream); + // // store the mergeStreamObject + // this.mergedStream = mergedStream; + + // const url = 'https://livepeer.studio/api/stream'; + // const data = { + // name: this.spaceSpecificData.spaceName, + // record: true, + // }; + + // const { data: responseData } = await axios.post(url, data, { + // headers: { + // Authorization: 'Bearer ' + livepeerApiKey, + // }, + // }); + + // const { streamKey, playbackId } = responseData; + + // console.log('livepeer details', streamKey, playbackId); + + // this.update({ meta: playbackId }); + + // let redirectUrl; + // try { + // console.log('Ignore the following error'); + + // // the redirect URL from the above GET request + // await axios.get(`https://livepeer.studio/webrtc/${streamKey}`); + // } catch (err: any) { + // console.log('redirectUrl error', err); + // redirectUrl = err.request.responseURL; + // } + + // // we use the host from the redirect URL in the ICE server configuration + // const host = new URL(redirectUrl).host; + + // const iceServers = [ + // { + // urls: `stun:${host}`, + // }, + // { + // urls: `turn:${host}`, + // username: 'livepeer', + // credential: 'livepeer', + // }, + // ]; + + // const peerConnection = new RTCPeerConnection({ iceServers }); + + // const newAudioTrack = mergedStream.result?.getAudioTracks?.()?.[0] ?? null; + + // if (newAudioTrack) { + // peerConnection?.addTransceiver(newAudioTrack, { + // direction: 'sendonly', + // }); + // } + + // /** + // * https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/createOffer + // * We create an SDP offer here which will be shared with the server + // */ + // const offer = await peerConnection.createOffer(); + // /** https://developer.mozilla.org/en-US/docs/Web/API/RTCPeerConnection/setLocalDescription */ + // await peerConnection.setLocalDescription(offer); + + // /** Wait for ICE gathering to complete */ + // const ofr = await new Promise((resolve) => { + // /** Wait at most five seconds for ICE gathering. */ + // setTimeout(() => { + // resolve(peerConnection.localDescription); + // }, 5000); + // peerConnection.onicegatheringstatechange = (_ev) => { + // if (peerConnection.iceGatheringState === 'complete') { + // resolve(peerConnection.localDescription); + // } + // }; + // }); + // if (!ofr) { + // throw Error('failed to gather ICE candidates for offer'); + // } + // /** + // * This response contains the server's SDP offer. + // * This specifies how the client should communicate, + // * and what kind of media client and server have negotiated to exchange. + // */ + // const sdpResponse = await fetch(redirectUrl, { + // method: 'POST', + // mode: 'cors', + // headers: { + // 'content-type': 'application/sdp', + // }, + // body: ofr.sdp, + // }); + // if (sdpResponse.ok) { + // const answerSDP = await sdpResponse.text(); + // await peerConnection.setRemoteDescription( + // new RTCSessionDescription({ type: 'answer', sdp: answerSDP }) + // ); + // } console.log('Live Stream started'); } catch (err) { diff --git a/packages/uiweb/package.json b/packages/uiweb/package.json index 10f3afd3d..6645e2d69 100644 --- a/packages/uiweb/package.json +++ b/packages/uiweb/package.json @@ -5,6 +5,8 @@ "registry": "https://registry.npmjs.org/" }, "dependencies": { + "@livekit/components-react": "^1.2.2", + "@livekit/components-styles": "^1.0.6", "@livepeer/react": "^2.6.0", "@pushprotocol/socket": "^0.5.0", "@unstoppabledomains/resolution": "^8.5.0", @@ -20,10 +22,12 @@ "font-awesome": "^4.7.0", "gif-picker-react": "^1.1.0", "html-react-parser": "^1.4.13", + "livekit-client": "^1.13.3", "moment": "^2.29.4", "react-icons": "^4.10.1", "react-toastify": "^9.1.3", - "react-twitter-embed": "^4.0.4" + "react-twitter-embed": "^4.0.4", + "uuid": "^9.0.1" }, "peerDependencies": { "@pushprotocol/restapi": "^1.2.15", diff --git a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx index 2e996e542..a4b8fcf06 100644 --- a/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx +++ b/packages/uiweb/src/lib/components/space/SpaceWidget/LiveWidgetContent.tsx @@ -1,9 +1,13 @@ -import React, { useEffect, useState, useContext } from 'react'; +import React, { useEffect, useState, useContext, useMemo } from 'react'; import styled, { ThemeProvider } from 'styled-components'; import { Player } from '@livepeer/react'; import * as PushAPI from '@pushprotocol/restapi'; import { SpaceDTO } from '@pushprotocol/restapi'; +// livekit imports +import { LiveKitRoom, ConnectionState, RoomAudioRenderer, TrackToggle, ConnectionStateToast } from '@livekit/components-react'; +import { Room, Track } from 'livekit-client'; + import { LiveSpaceProfileContainer } from './LiveSpaceProfileContainer'; import { SpaceMembersSectionModal } from './SpaceMembersSectionModal'; @@ -12,7 +16,7 @@ import { ThemeContext } from '../theme/ThemeProvider'; import CircularProgressSpinner from '../../loader/loader'; -import { Button, Image, Item, Text } from '../../../config'; +import { Button, Image, Item, LIVEKIT_SERVER_URL, Text } from '../../../config'; import MicOnIcon from '../../../icons/micon.svg'; import MicEngagedIcon from '../../../icons/MicEngage.svg'; import MuteIcon from '../../../icons/Muted.svg'; @@ -21,18 +25,22 @@ import MembersIcon from '../../../icons/Members.svg'; import { useSpaceData } from '../../../hooks'; import { SpaceStatus } from './WidgetContent'; import { pCAIP10ToWallet } from '../../../helpers'; +import { getLivekitRoomToken, performAction } from '../../../services'; +import Microphone from './Microphone'; interface LiveWidgetContentProps { spaceData?: SpaceDTO; // temp props only for testing demo purpose for now isHost?: boolean; setSpaceStatusState: React.Dispatch>; + account: string | undefined; } export const LiveWidgetContent: React.FC = ({ spaceData, isHost, setSpaceStatusState, + account }) => { const [showMembersModal, setShowMembersModal] = useState(false); const [playBackUrl, setPlayBackUrl] = useState(''); @@ -41,6 +49,7 @@ export const LiveWidgetContent: React.FC = ({ const [isRequestedForMic, setIsRequestedForMic] = useState(false); const [promotedListener, setPromotedListener] = useState(''); + const [livekitToken, setLivekitToken] = useState(null); const theme = useContext(ThemeContext); @@ -57,12 +66,27 @@ export const LiveWidgetContent: React.FC = ({ const isMicOn = spaceObjectData?.connectionData?.local?.audio; - const numberOfRequests = spaceObjectData.liveSpaceData.listeners.filter((listener: any) => listener.handRaised).length; + // const numberOfRequests = spaceObjectData.liveSpaceData.listeners.filter((listener: any) => listener.handRaised).length; const handleMicState = async () => { await spacesObjectRef?.current?.enableAudio?.({ state: !isMicOn }); }; + useEffect(() => { + (async function () { + const removeEIP155 = (input: string) => input.substring(7); + const nonEIPAddress = removeEIP155(account as string); + + if ((isHost || isSpeaker) && spaceData?.spaceId) { + const livekitToken = await getLivekitRoomToken({ userType: "sender", roomId: spaceData?.spaceId, userId: nonEIPAddress }); + setLivekitToken(livekitToken.data); + } else if (isListener && spaceData?.spaceId) { + const livekitToken = await getLivekitRoomToken({ userType: "receiver", roomId: spaceData?.spaceId, userId: nonEIPAddress }); + setLivekitToken(livekitToken.data); + } + })(); + }, [isListener, isHost, spaceData]); + useEffect(() => { if (!spaceObjectData?.connectionData?.local?.stream || !isRequestedForMic) return; @@ -83,11 +107,13 @@ export const LiveWidgetContent: React.FC = ({ }; useEffect(() => { - if (!spaceObjectData?.connectionData?.local?.stream || promotedListener.length === 0) + // if (!spaceObjectData?.connectionData?.local?.stream || promotedListener.length === 0) + // return; + if (promotedListener.length === 0) return; const options = { - signalData: raisedHandInfo[promotedListener].signalData, + // signalData: raisedHandInfo[promotedListener].signalData, promoteeAddress: pCAIP10ToWallet( raisedHandInfo[promotedListener].senderAddress ), @@ -102,14 +128,16 @@ export const LiveWidgetContent: React.FC = ({ }, [promotedListener]); const handleAcceptPromotion = async (requesterAddress: any) => { - await spacesObjectRef?.current?.createAudioStream?.(); + // await spacesObjectRef?.current?.createAudioStream?.(); setPromotedListener(requesterAddress); + await performAction({ roomId: spaceData?.spaceId, userId: requesterAddress, canPublish: true }); }; const handleRejectPromotion = async (requesterAddress: any) => { await spacesObjectRef?.current?.rejectPromotionRequest?.({ promoteeAddress: pCAIP10ToWallet(requesterAddress), }); + await performAction({ roomId: spaceData?.spaceId, userId: requesterAddress, canPublish: false }); }; const handleJoinSpace = async () => { @@ -204,6 +232,8 @@ export const LiveWidgetContent: React.FC = ({ setPlayBackUrl(spaceObjectData?.meta); }, [spaceObjectData?.meta]); + const livekitRoom = useMemo(() => new Room(), []); + return ( = ({ justifyContent={'space-between'} padding={'6px 8px'} > - - isHost || isSpeaker ? handleMicState() : handleRequest() - } - > - Mic Icon - + + {isHost || isSpeaker - ? isMicOn - ? 'Speaking' - : 'Muted' - : isRequestedForMic - ? 'Requested' - : 'Request' + ? + + + + : + handleRequest()} + > + Mic Icon + + { + isRequestedForMic + ? 'Requested' + : 'Request' + } + + } - - + + )} + {/* + isHost || isSpeaker ? handleMicState() : handleRequest() + } + > + Mic Icon + + {isHost || isSpeaker + ? isMicOn + ? 'Speaking' + : 'Muted' + : isRequestedForMic + ? 'Requested' + : 'Request' + } + + */} - { + {/* { isHost && numberOfRequests ? {numberOfRequests} : null - } + } */} = ({ {!isHost ? 'Leave' : 'End space'} - {isListener && !isHost && playBackUrl.length > 0 && ( + {/* {isListener && !isHost && playBackUrl.length > 0 && ( - )} + )} */} ) : (