@dynamic-labs/solana 4.5.3 → 4.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,29 @@
|
|
|
1
1
|
|
|
2
|
+
### [4.6.1](https://github.com/dynamic-labs/dynamic-auth/compare/v4.6.0...v4.6.1) (2025-02-11)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Bug Fixes
|
|
6
|
+
|
|
7
|
+
* do not show undefined subdomains ([#8060](https://github.com/dynamic-labs/dynamic-auth/issues/8060)) ([ec7ca3d](https://github.com/dynamic-labs/dynamic-auth/commit/ec7ca3d1284422f54f3a1275e1983d50912bcc34))
|
|
8
|
+
* ensure project settings is present on is-cookie-enabled ([#8057](https://github.com/dynamic-labs/dynamic-auth/issues/8057)) ([81c6495](https://github.com/dynamic-labs/dynamic-auth/commit/81c64957031633c00c9e5ecaf304269605202abb))
|
|
9
|
+
* prevent user profile widget from automatically opening when linking a new wallet ([#8020](https://github.com/dynamic-labs/dynamic-auth/issues/8020)) ([4f05ac9](https://github.com/dynamic-labs/dynamic-auth/commit/4f05ac9fdc5a2fc415567dff1b33ddffd0478804))
|
|
10
|
+
* project settings loading and cookie setting check ([#8056](https://github.com/dynamic-labs/dynamic-auth/issues/8056)) ([457a298](https://github.com/dynamic-labs/dynamic-auth/commit/457a298ff11387ca858f85fb19d6c421e02fcc88))
|
|
11
|
+
|
|
12
|
+
## [4.6.0](https://github.com/dynamic-labs/dynamic-auth/compare/v4.5.3...v4.6.0) (2025-02-10)
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Features
|
|
16
|
+
|
|
17
|
+
* expose method to refetch project settings ([#8048](https://github.com/dynamic-labs/dynamic-auth/issues/8048)) ([10af30c](https://github.com/dynamic-labs/dynamic-auth/commit/10af30cb5caf39b95eaae39ad831466f6f73b98a))
|
|
18
|
+
* add new hook to delete user ([#8013](https://github.com/dynamic-labs/dynamic-auth/issues/8013)) ([c312285](https://github.com/dynamic-labs/dynamic-auth/commit/c312285b4e4663eedf83a4c8c043715ba6c1a9ed))
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
### Bug Fixes
|
|
22
|
+
|
|
23
|
+
* add memos and fix state updates to prevent rerenders ([#8024](https://github.com/dynamic-labs/dynamic-auth/issues/8024)) ([89504c0](https://github.com/dynamic-labs/dynamic-auth/commit/89504c0efa29ed846a55d7eb3213a1b9b070368a))
|
|
24
|
+
* back button not working properly in the farcaster connect view ([#8051](https://github.com/dynamic-labs/dynamic-auth/issues/8051)) ([5fe4631](https://github.com/dynamic-labs/dynamic-auth/commit/5fe463105ce43dd7ec31cd90ee6922bd917ed9de))
|
|
25
|
+
* update wallet address when switching networks in cosmos ([#8016](https://github.com/dynamic-labs/dynamic-auth/issues/8016)) ([2925784](https://github.com/dynamic-labs/dynamic-auth/commit/29257846fa99600a67cf010447248451cd17ae60))
|
|
26
|
+
|
|
2
27
|
### [4.5.3](https://github.com/dynamic-labs/dynamic-auth/compare/v4.5.2...v4.5.3) (2025-02-09)
|
|
3
28
|
|
|
4
29
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/solana",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.6.1",
|
|
4
4
|
"description": "A React SDK for implementing wallet web3 authentication and authorization to your website.",
|
|
5
5
|
"author": "Dynamic Labs, Inc.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -25,16 +25,16 @@
|
|
|
25
25
|
"@wallet-standard/experimental-features": "0.1.1",
|
|
26
26
|
"bs58": "5.0.0",
|
|
27
27
|
"tweetnacl": "1.0.3",
|
|
28
|
-
"@dynamic-labs/assert-package-version": "4.
|
|
29
|
-
"@dynamic-labs/embedded-wallet-solana": "4.
|
|
30
|
-
"@dynamic-labs/logger": "4.
|
|
31
|
-
"@dynamic-labs/rpc-providers": "4.
|
|
32
|
-
"@dynamic-labs/sdk-api-core": "0.0.
|
|
33
|
-
"@dynamic-labs/solana-core": "4.
|
|
34
|
-
"@dynamic-labs/types": "4.
|
|
35
|
-
"@dynamic-labs/utils": "4.
|
|
36
|
-
"@dynamic-labs/wallet-book": "4.
|
|
37
|
-
"@dynamic-labs/wallet-connector-core": "4.
|
|
28
|
+
"@dynamic-labs/assert-package-version": "4.6.1",
|
|
29
|
+
"@dynamic-labs/embedded-wallet-solana": "4.6.1",
|
|
30
|
+
"@dynamic-labs/logger": "4.6.1",
|
|
31
|
+
"@dynamic-labs/rpc-providers": "4.6.1",
|
|
32
|
+
"@dynamic-labs/sdk-api-core": "0.0.622",
|
|
33
|
+
"@dynamic-labs/solana-core": "4.6.1",
|
|
34
|
+
"@dynamic-labs/types": "4.6.1",
|
|
35
|
+
"@dynamic-labs/utils": "4.6.1",
|
|
36
|
+
"@dynamic-labs/wallet-book": "4.6.1",
|
|
37
|
+
"@dynamic-labs/wallet-connector-core": "4.6.1"
|
|
38
38
|
},
|
|
39
39
|
"peerDependencies": {}
|
|
40
40
|
}
|
|
@@ -8,6 +8,7 @@ var web3_js = require('@solana/web3.js');
|
|
|
8
8
|
var bs58 = require('bs58');
|
|
9
9
|
var nacl = require('tweetnacl');
|
|
10
10
|
var solanaCore = require('@dynamic-labs/solana-core');
|
|
11
|
+
var utils = require('@dynamic-labs/utils');
|
|
11
12
|
var buildUrl = require('../buildUrl/buildUrl.cjs');
|
|
12
13
|
var decryptPayload = require('../decryptPayload/decryptPayload.cjs');
|
|
13
14
|
var encryptPayload = require('../encryptPayload/encryptPayload.cjs');
|
|
@@ -41,6 +42,18 @@ class PhantomRedirect extends solanaCore.SolanaWalletConnector {
|
|
|
41
42
|
connect() {
|
|
42
43
|
return _tslib.__awaiter(this, void 0, void 0, function* () {
|
|
43
44
|
var _a, _b;
|
|
45
|
+
// Consume the connection type
|
|
46
|
+
const connectionType = utils.StorageService.getItem(utils.PHANTOM_REDIRECT_CONNECTION_TYPE_KEY);
|
|
47
|
+
if (connectionType) {
|
|
48
|
+
// If this has already been consumed, then we must discard it
|
|
49
|
+
if (connectionType.connectorConsumed) {
|
|
50
|
+
utils.StorageService.setItem(utils.PHANTOM_REDIRECT_CONNECTION_TYPE_KEY, undefined);
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
connectionType.connectorConsumed = true;
|
|
54
|
+
utils.StorageService.setItem(utils.PHANTOM_REDIRECT_CONNECTION_TYPE_KEY, connectionType);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
44
57
|
// Generate a new key pair
|
|
45
58
|
const keyPair = nacl__default["default"].box.keyPair();
|
|
46
59
|
storage.storage.encryptionPublicKey.set(keyPair.publicKey);
|
|
@@ -4,6 +4,7 @@ import { PublicKey, Transaction } from '@solana/web3.js';
|
|
|
4
4
|
import bs58 from 'bs58';
|
|
5
5
|
import nacl from 'tweetnacl';
|
|
6
6
|
import { SolanaWalletConnector } from '@dynamic-labs/solana-core';
|
|
7
|
+
import { StorageService, PHANTOM_REDIRECT_CONNECTION_TYPE_KEY } from '@dynamic-labs/utils';
|
|
7
8
|
import { buildUrl } from '../buildUrl/buildUrl.js';
|
|
8
9
|
import { decryptPayload } from '../decryptPayload/decryptPayload.js';
|
|
9
10
|
import { encryptPayload } from '../encryptPayload/encryptPayload.js';
|
|
@@ -32,6 +33,18 @@ class PhantomRedirect extends SolanaWalletConnector {
|
|
|
32
33
|
connect() {
|
|
33
34
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
35
|
var _a, _b;
|
|
36
|
+
// Consume the connection type
|
|
37
|
+
const connectionType = StorageService.getItem(PHANTOM_REDIRECT_CONNECTION_TYPE_KEY);
|
|
38
|
+
if (connectionType) {
|
|
39
|
+
// If this has already been consumed, then we must discard it
|
|
40
|
+
if (connectionType.connectorConsumed) {
|
|
41
|
+
StorageService.setItem(PHANTOM_REDIRECT_CONNECTION_TYPE_KEY, undefined);
|
|
42
|
+
}
|
|
43
|
+
else {
|
|
44
|
+
connectionType.connectorConsumed = true;
|
|
45
|
+
StorageService.setItem(PHANTOM_REDIRECT_CONNECTION_TYPE_KEY, connectionType);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
35
48
|
// Generate a new key pair
|
|
36
49
|
const keyPair = nacl.box.keyPair();
|
|
37
50
|
storage.encryptionPublicKey.set(keyPair.publicKey);
|