@dynamic-labs/wallet-connector-core 4.49.0 → 4.50.2
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 +24 -0
- package/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +7 -7
- package/src/interfaces/IPhantomRedirectConnector.d.ts +13 -21
- package/src/utils/walletConnectDeepLinks/performPlatformSpecificConnectionMethod.cjs +6 -3
- package/src/utils/walletConnectDeepLinks/performPlatformSpecificConnectionMethod.d.ts +1 -1
- package/src/utils/walletConnectDeepLinks/performPlatformSpecificConnectionMethod.js +6 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,28 @@
|
|
|
1
1
|
|
|
2
|
+
### [4.50.2](https://github.com/dynamic-labs/dynamic-auth/compare/v4.50.1...v4.50.2) (2025-12-12)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Bug Fixes
|
|
6
|
+
|
|
7
|
+
* **flutter:** flutter should not require redirectUrl ([#10094](https://github.com/dynamic-labs/dynamic-auth/issues/10094)) ([7a14d7f](https://github.com/dynamic-labs/dynamic-auth/commit/7a14d7f235eaa308b2dfa42954fc38d484f9d3d3))
|
|
8
|
+
* properly handle signAllTransactions when using Solana Wallet Standard wallets ([#10084](https://github.com/dynamic-labs/dynamic-auth/issues/10084)) ([e3b2872](https://github.com/dynamic-labs/dynamic-auth/commit/e3b287252460150661df4f09a4eb9ddf2d23cb64))
|
|
9
|
+
* set authMode in configWaasWalletConnector in useSetWalletConnectorFetchers ([#10087](https://github.com/dynamic-labs/dynamic-auth/issues/10087)) ([c5f95de](https://github.com/dynamic-labs/dynamic-auth/commit/c5f95dec76c14e5bdd41b6ba88a3d8c45e616fc6))
|
|
10
|
+
|
|
11
|
+
## [4.50.0](https://github.com/dynamic-labs/dynamic-auth/compare/v4.49.0...v4.50.0) (2025-12-09)
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
### Features
|
|
15
|
+
|
|
16
|
+
* add usePhantomRedirectEvents hook ([#10030](https://github.com/dynamic-labs/dynamic-auth/issues/10030)) ([fb8585e](https://github.com/dynamic-labs/dynamic-auth/commit/fb8585eec9847cd350be71d28291e9831a3f31b1))
|
|
17
|
+
* introduce embedded wallet reveal complete events ([#10068](https://github.com/dynamic-labs/dynamic-auth/issues/10068)) ([8ea79ce](https://github.com/dynamic-labs/dynamic-auth/commit/8ea79ceaba36745d46759c8e8c6681895b092096))
|
|
18
|
+
* **react-native:** add download file ([#9954](https://github.com/dynamic-labs/dynamic-auth/issues/9954)) ([408b00f](https://github.com/dynamic-labs/dynamic-auth/commit/408b00fabd2afbd87d12efb51e78ecbd89a323d3))
|
|
19
|
+
* **react-native:** add solana Phantom support with client module for listening to events ([#10033](https://github.com/dynamic-labs/dynamic-auth/issues/10033)) ([a5a2d11](https://github.com/dynamic-labs/dynamic-auth/commit/a5a2d11ccd3c102e22dece808a0ba4116155a582))
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
### Bug Fixes
|
|
23
|
+
|
|
24
|
+
* remove overflow from token balance dropdown ([#10044](https://github.com/dynamic-labs/dynamic-auth/issues/10044)) ([b37c5bb](https://github.com/dynamic-labs/dynamic-auth/commit/b37c5bb8e8c916b8d685b495555a3a3481cd5f0d))
|
|
25
|
+
|
|
2
26
|
## [4.49.0](https://github.com/dynamic-labs/dynamic-auth/compare/v4.48.2...v4.49.0) (2025-12-05)
|
|
3
27
|
|
|
4
28
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/wallet-connector-core",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.50.2",
|
|
4
4
|
"description": "Core package for utilities and types for handling multiple wallet/chain support Dynamic SDK",
|
|
5
5
|
"author": "Dynamic Labs, Inc.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -19,12 +19,12 @@
|
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@dynamic-labs/sdk-api-core": "0.0.831",
|
|
22
|
-
"@dynamic-labs/assert-package-version": "4.
|
|
23
|
-
"@dynamic-labs/logger": "4.
|
|
24
|
-
"@dynamic-labs/rpc-providers": "4.
|
|
25
|
-
"@dynamic-labs/types": "4.
|
|
26
|
-
"@dynamic-labs/utils": "4.
|
|
27
|
-
"@dynamic-labs/wallet-book": "4.
|
|
22
|
+
"@dynamic-labs/assert-package-version": "4.50.2",
|
|
23
|
+
"@dynamic-labs/logger": "4.50.2",
|
|
24
|
+
"@dynamic-labs/rpc-providers": "4.50.2",
|
|
25
|
+
"@dynamic-labs/types": "4.50.2",
|
|
26
|
+
"@dynamic-labs/utils": "4.50.2",
|
|
27
|
+
"@dynamic-labs/wallet-book": "4.50.2",
|
|
28
28
|
"eventemitter3": "5.0.1"
|
|
29
29
|
},
|
|
30
30
|
"peerDependencies": {}
|
|
@@ -1,30 +1,15 @@
|
|
|
1
1
|
import EventEmitter from 'eventemitter3';
|
|
2
|
+
import { PhantomSignAllTransactionsPayload, PhantomSignAndSendTransactionPayload, PhantomSignMessagePayload, PhantomSignTransactionPayload } from '@dynamic-labs/types';
|
|
2
3
|
import { WalletConnectorBase } from '..';
|
|
3
|
-
export type SignAndSendTransactionListener = (response:
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
}) => void;
|
|
8
|
-
export type SignAllTransactionsListener = (response: {
|
|
9
|
-
transactions?: string[];
|
|
10
|
-
errorCode?: string;
|
|
11
|
-
errorMessage?: string;
|
|
12
|
-
}) => void;
|
|
13
|
-
export type SignTransactionListener = (response: {
|
|
14
|
-
transaction?: string;
|
|
15
|
-
errorCode?: string;
|
|
16
|
-
errorMessage?: string;
|
|
17
|
-
}) => void;
|
|
18
|
-
export type SignMessageListener = (response: {
|
|
19
|
-
signature?: string;
|
|
20
|
-
errorCode?: string;
|
|
21
|
-
errorMessage?: string;
|
|
22
|
-
}) => void;
|
|
4
|
+
export type SignAndSendTransactionListener = (response: PhantomSignAndSendTransactionPayload) => void;
|
|
5
|
+
export type SignAllTransactionsListener = (response: PhantomSignAllTransactionsPayload) => void;
|
|
6
|
+
export type SignTransactionListener = (response: PhantomSignTransactionPayload) => void;
|
|
7
|
+
export type SignMessageListener = (response: PhantomSignMessagePayload) => void;
|
|
23
8
|
type Events = {
|
|
24
9
|
signAndSendTransaction: SignAndSendTransactionListener;
|
|
25
10
|
signAllTransactions: SignAllTransactionsListener;
|
|
26
|
-
signTransaction: SignTransactionListener;
|
|
27
11
|
signMessage: SignMessageListener;
|
|
12
|
+
signTransaction: SignTransactionListener;
|
|
28
13
|
};
|
|
29
14
|
export interface IPhantomRedirectConnector extends WalletConnectorBase {
|
|
30
15
|
extractSignature(): {
|
|
@@ -33,7 +18,14 @@ export interface IPhantomRedirectConnector extends WalletConnectorBase {
|
|
|
33
18
|
};
|
|
34
19
|
extractTransactions(): any[];
|
|
35
20
|
extractTransaction(): any;
|
|
21
|
+
/**
|
|
22
|
+
* Extracts the signed transaction and sends it to the network.
|
|
23
|
+
* Used for signAndSendTransaction since Phantom redirect doesn't support it natively.
|
|
24
|
+
* @returns The transaction signature
|
|
25
|
+
*/
|
|
26
|
+
extractAndSendTransaction(): Promise<string>;
|
|
36
27
|
consumeMethod(): keyof Events | undefined;
|
|
28
|
+
consumeRequestId?(): string | undefined;
|
|
37
29
|
}
|
|
38
30
|
export type IPhantomRedirectConnectorWithEvents = IPhantomRedirectConnector & EventEmitter<Events>;
|
|
39
31
|
export {};
|
|
@@ -3,10 +3,11 @@
|
|
|
3
3
|
|
|
4
4
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
5
|
|
|
6
|
+
var _tslib = require('../../../_virtual/_tslib.cjs');
|
|
6
7
|
var utils = require('@dynamic-labs/utils');
|
|
7
8
|
var walletConnectDeepLinks = require('./walletConnectDeepLinks.cjs');
|
|
8
9
|
|
|
9
|
-
const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preference) => {
|
|
10
|
+
const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preference) => _tslib.__awaiter(void 0, void 0, void 0, function* () {
|
|
10
11
|
var _a, _b, _c;
|
|
11
12
|
const deepLink = walletConnectDeepLinks.getDeepLink({
|
|
12
13
|
deepLinks,
|
|
@@ -16,7 +17,9 @@ const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preferenc
|
|
|
16
17
|
});
|
|
17
18
|
// Deeplink performed here
|
|
18
19
|
if (utils.isMobile()) {
|
|
19
|
-
|
|
20
|
+
// Await the openURL call so errors propagate to the caller
|
|
21
|
+
// This ensures that if opening the URL fails, the connection promise rejects
|
|
22
|
+
yield utils.PlatformService.openURL(deepLink);
|
|
20
23
|
}
|
|
21
24
|
else {
|
|
22
25
|
if ((_a = deepLinks === null || deepLinks === void 0 ? void 0 : deepLinks.desktop) === null || _a === void 0 ? void 0 : _a.native) {
|
|
@@ -24,6 +27,6 @@ const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preferenc
|
|
|
24
27
|
}
|
|
25
28
|
(_c = opts.onDisplayUri) === null || _c === void 0 ? void 0 : _c.call(opts, uri);
|
|
26
29
|
}
|
|
27
|
-
};
|
|
30
|
+
});
|
|
28
31
|
|
|
29
32
|
exports.performPlatformSpecificConnectionMethod = performPlatformSpecificConnectionMethod;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import type { GetAddressOpts } from '../../WalletConnectorBase/types';
|
|
2
2
|
import type { WalletDeepLinks } from '../../types';
|
|
3
3
|
import { DeepLinkVariant } from './walletConnectDeepLinks';
|
|
4
|
-
export declare const performPlatformSpecificConnectionMethod: (uri: string, deepLinks: WalletDeepLinks | undefined, opts: Pick<GetAddressOpts, 'onDesktopUri' | 'onDisplayUri'>, preference: DeepLinkVariant) => void
|
|
4
|
+
export declare const performPlatformSpecificConnectionMethod: (uri: string, deepLinks: WalletDeepLinks | undefined, opts: Pick<GetAddressOpts, 'onDesktopUri' | 'onDisplayUri'>, preference: DeepLinkVariant) => Promise<void>;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
'use client'
|
|
2
|
+
import { __awaiter } from '../../../_virtual/_tslib.js';
|
|
2
3
|
import { isMobile, PlatformService } from '@dynamic-labs/utils';
|
|
3
4
|
import { getDeepLink } from './walletConnectDeepLinks.js';
|
|
4
5
|
|
|
5
|
-
const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preference) => {
|
|
6
|
+
const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preference) => __awaiter(void 0, void 0, void 0, function* () {
|
|
6
7
|
var _a, _b, _c;
|
|
7
8
|
const deepLink = getDeepLink({
|
|
8
9
|
deepLinks,
|
|
@@ -12,7 +13,9 @@ const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preferenc
|
|
|
12
13
|
});
|
|
13
14
|
// Deeplink performed here
|
|
14
15
|
if (isMobile()) {
|
|
15
|
-
|
|
16
|
+
// Await the openURL call so errors propagate to the caller
|
|
17
|
+
// This ensures that if opening the URL fails, the connection promise rejects
|
|
18
|
+
yield PlatformService.openURL(deepLink);
|
|
16
19
|
}
|
|
17
20
|
else {
|
|
18
21
|
if ((_a = deepLinks === null || deepLinks === void 0 ? void 0 : deepLinks.desktop) === null || _a === void 0 ? void 0 : _a.native) {
|
|
@@ -20,6 +23,6 @@ const performPlatformSpecificConnectionMethod = (uri, deepLinks, opts, preferenc
|
|
|
20
23
|
}
|
|
21
24
|
(_c = opts.onDisplayUri) === null || _c === void 0 ? void 0 : _c.call(opts, uri);
|
|
22
25
|
}
|
|
23
|
-
};
|
|
26
|
+
});
|
|
24
27
|
|
|
25
28
|
export { performPlatformSpecificConnectionMethod };
|