@dynamic-labs/eclipse 4.2.2 → 4.3.0
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 +19 -0
- package/package.cjs +1 -1
- package/package.js +1 -1
- package/package.json +10 -9
- package/src/connectors/EclipseWalletConnectors.cjs +2 -1
- package/src/connectors/EclipseWalletConnectors.js +2 -1
- package/src/connectors/injected/InjectedWalletBase/InjectedWalletBase.cjs +0 -2
- package/src/connectors/injected/InjectedWalletBase/InjectedWalletBase.d.ts +1 -4
- package/src/connectors/injected/InjectedWalletBase/InjectedWalletBase.js +0 -2
- package/src/connectors/injected/Nightly/Nightly.cjs +34 -0
- package/src/connectors/injected/Nightly/Nightly.d.ts +11 -0
- package/src/connectors/injected/Nightly/Nightly.js +30 -0
- package/src/connectors/injected/Nightly/index.d.ts +1 -0
- package/src/connectors/injected/index.d.ts +1 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,4 +1,23 @@
|
|
|
1
1
|
|
|
2
|
+
## [4.3.0](https://github.com/dynamic-labs/dynamic-auth/compare/v4.2.3...v4.3.0) (2025-01-21)
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
### Features
|
|
6
|
+
|
|
7
|
+
* add support for Nightly wallet on Eclipse ([#7848](https://github.com/dynamic-labs/dynamic-auth/issues/7848)) ([dd6e8d4](https://github.com/dynamic-labs/dynamic-auth/commit/dd6e8d41daf632a1b55137f903b6fc99a148c071))
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Bug Fixes
|
|
11
|
+
|
|
12
|
+
* fix storage sync issues when upgrade to sdk v4 while user is logged in ([#7835](https://github.com/dynamic-labs/dynamic-auth/issues/7835)) ([528b6f9](https://github.com/dynamic-labs/dynamic-auth/commit/528b6f9ce5d0e77d518dcfb7021fc711d2a9e503))
|
|
13
|
+
|
|
14
|
+
### [4.2.3](https://github.com/dynamic-labs/dynamic-auth/compare/v4.2.2...v4.2.3) (2025-01-16)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
### Bug Fixes
|
|
18
|
+
|
|
19
|
+
* properly raise userUpdated event when updating email and phone ([#7817](https://github.com/dynamic-labs/dynamic-auth/issues/7817)) ([f129aa1](https://github.com/dynamic-labs/dynamic-auth/commit/f129aa1cd0360394ea3b500a829e378bdf5b7c64))
|
|
20
|
+
|
|
2
21
|
### [4.2.2](https://github.com/dynamic-labs/dynamic-auth/compare/v4.2.1...v4.2.2) (2025-01-15)
|
|
3
22
|
|
|
4
23
|
|
package/package.cjs
CHANGED
package/package.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynamic-labs/eclipse",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.3.0",
|
|
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",
|
|
@@ -19,15 +19,16 @@
|
|
|
19
19
|
"homepage": "https://www.dynamic.xyz/",
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@solana/web3.js": "1.92.1",
|
|
22
|
-
"@
|
|
23
|
-
"@dynamic-labs/
|
|
22
|
+
"@wallet-standard/base": "1.0.1",
|
|
23
|
+
"@dynamic-labs/assert-package-version": "4.3.0",
|
|
24
|
+
"@dynamic-labs/rpc-providers": "4.3.0",
|
|
24
25
|
"@dynamic-labs/sdk-api-core": "0.0.586",
|
|
25
|
-
"@dynamic-labs/solana": "4.
|
|
26
|
-
"@dynamic-labs/solana-core": "4.
|
|
27
|
-
"@dynamic-labs/types": "4.
|
|
28
|
-
"@dynamic-labs/utils": "4.
|
|
29
|
-
"@dynamic-labs/wallet-book": "4.
|
|
30
|
-
"@dynamic-labs/wallet-connector-core": "4.
|
|
26
|
+
"@dynamic-labs/solana": "4.3.0",
|
|
27
|
+
"@dynamic-labs/solana-core": "4.3.0",
|
|
28
|
+
"@dynamic-labs/types": "4.3.0",
|
|
29
|
+
"@dynamic-labs/utils": "4.3.0",
|
|
30
|
+
"@dynamic-labs/wallet-book": "4.3.0",
|
|
31
|
+
"@dynamic-labs/wallet-connector-core": "4.3.0"
|
|
31
32
|
},
|
|
32
33
|
"peerDependencies": {}
|
|
33
34
|
}
|
|
@@ -10,7 +10,8 @@ require('@dynamic-labs/solana-core');
|
|
|
10
10
|
require('@dynamic-labs/utils');
|
|
11
11
|
var Backpack = require('./injected/Backpack/Backpack.cjs');
|
|
12
12
|
var OKX = require('./injected/OKX/OKX.cjs');
|
|
13
|
+
var Nightly = require('./injected/Nightly/Nightly.cjs');
|
|
13
14
|
|
|
14
|
-
const EclipseWalletConnectors = () => [Backpack.Backpack, OKX.OKX];
|
|
15
|
+
const EclipseWalletConnectors = () => [Backpack.Backpack, OKX.OKX, Nightly.Nightly];
|
|
15
16
|
|
|
16
17
|
exports.EclipseWalletConnectors = EclipseWalletConnectors;
|
|
@@ -6,7 +6,8 @@ import '@dynamic-labs/solana-core';
|
|
|
6
6
|
import '@dynamic-labs/utils';
|
|
7
7
|
import { Backpack } from './injected/Backpack/Backpack.js';
|
|
8
8
|
import { OKX } from './injected/OKX/OKX.js';
|
|
9
|
+
import { Nightly } from './injected/Nightly/Nightly.js';
|
|
9
10
|
|
|
10
|
-
const EclipseWalletConnectors = () => [Backpack, OKX];
|
|
11
|
+
const EclipseWalletConnectors = () => [Backpack, OKX, Nightly];
|
|
11
12
|
|
|
12
13
|
export { EclipseWalletConnectors };
|
|
@@ -16,8 +16,6 @@ class InjectedWalletBase extends solana.SolanaInjectedConnector {
|
|
|
16
16
|
super(opts);
|
|
17
17
|
this.connectedChain = 'ECLIPSE';
|
|
18
18
|
this.supportedChains = ['ECLIPSE'];
|
|
19
|
-
this.name = 'Backpack';
|
|
20
|
-
this.overrideKey = 'backpackeclipse';
|
|
21
19
|
this.eclipseNetworks = opts.eclipseNetworks;
|
|
22
20
|
this.chainRpcProviders = opts.chainRpcProviders;
|
|
23
21
|
(_a = this.chainRpcProviders) === null || _a === void 0 ? void 0 : _a.registerEclipseProviders();
|
|
@@ -3,18 +3,15 @@ import { SolanaInjectedConnector } from '@dynamic-labs/solana';
|
|
|
3
3
|
import { Chain } from '@dynamic-labs/wallet-connector-core';
|
|
4
4
|
import { SolanaWalletConnectorOpts } from '@dynamic-labs/solana-core';
|
|
5
5
|
import { GenericNetwork } from '@dynamic-labs/types';
|
|
6
|
-
type EclipseInjectedConnectorOpts = {
|
|
6
|
+
export type EclipseInjectedConnectorOpts = {
|
|
7
7
|
eclipseNetworks: GenericNetwork[];
|
|
8
8
|
} & SolanaWalletConnectorOpts;
|
|
9
9
|
export declare abstract class InjectedWalletBase extends SolanaInjectedConnector {
|
|
10
10
|
connectedChain: Chain;
|
|
11
11
|
supportedChains: Chain[];
|
|
12
|
-
name: string;
|
|
13
|
-
overrideKey: string;
|
|
14
12
|
eclipseNetworks: GenericNetwork[];
|
|
15
13
|
constructor(opts: EclipseInjectedConnectorOpts);
|
|
16
14
|
getPublicClient(): Promise<Connection | undefined>;
|
|
17
15
|
getWalletClient(): Connection;
|
|
18
16
|
getNetwork(): Promise<string>;
|
|
19
17
|
}
|
|
20
|
-
export {};
|
|
@@ -12,8 +12,6 @@ class InjectedWalletBase extends SolanaInjectedConnector {
|
|
|
12
12
|
super(opts);
|
|
13
13
|
this.connectedChain = 'ECLIPSE';
|
|
14
14
|
this.supportedChains = ['ECLIPSE'];
|
|
15
|
-
this.name = 'Backpack';
|
|
16
|
-
this.overrideKey = 'backpackeclipse';
|
|
17
15
|
this.eclipseNetworks = opts.eclipseNetworks;
|
|
18
16
|
this.chainRpcProviders = opts.chainRpcProviders;
|
|
19
17
|
(_a = this.chainRpcProviders) === null || _a === void 0 ? void 0 : _a.registerEclipseProviders();
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
'use client'
|
|
2
|
+
'use strict';
|
|
3
|
+
|
|
4
|
+
Object.defineProperty(exports, '__esModule', { value: true });
|
|
5
|
+
|
|
6
|
+
var solana = require('@dynamic-labs/solana');
|
|
7
|
+
var InjectedWalletBase = require('../InjectedWalletBase/InjectedWalletBase.cjs');
|
|
8
|
+
var constants = require('../../constants.cjs');
|
|
9
|
+
|
|
10
|
+
const getNightlyWallet = () => solana.getWalletStandardWallets().find((wallet) => wallet.name === 'Nightly' && solana.hasAllWalletStandardRequiredFeatures(wallet));
|
|
11
|
+
class Nightly extends InjectedWalletBase.InjectedWalletBase {
|
|
12
|
+
constructor(opts) {
|
|
13
|
+
super(opts);
|
|
14
|
+
this.name = 'Nightly';
|
|
15
|
+
this.overrideKey = 'nightlyeclipse';
|
|
16
|
+
this._wallet = getNightlyWallet();
|
|
17
|
+
if (this._wallet) {
|
|
18
|
+
this._provider = solana.createSolanaSignerFromWalletStandard({
|
|
19
|
+
genesisHashesMap: {
|
|
20
|
+
[constants.eclipseMainnetHash]: 'mainnet',
|
|
21
|
+
[constants.eclipseTestnetHash]: 'testnet',
|
|
22
|
+
},
|
|
23
|
+
network: this.eclipseNetworks[0],
|
|
24
|
+
wallet: this._wallet,
|
|
25
|
+
walletConnector: this,
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
findProvider() {
|
|
30
|
+
return this._provider;
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
exports.Nightly = Nightly;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Wallet } from '@wallet-standard/base';
|
|
2
|
+
import { ISolana } from '@dynamic-labs/solana-core';
|
|
3
|
+
import { EclipseInjectedConnectorOpts, InjectedWalletBase } from '../InjectedWalletBase';
|
|
4
|
+
export declare class Nightly extends InjectedWalletBase {
|
|
5
|
+
name: string;
|
|
6
|
+
overrideKey: string;
|
|
7
|
+
_wallet: Wallet | undefined;
|
|
8
|
+
private _provider;
|
|
9
|
+
constructor(opts: EclipseInjectedConnectorOpts);
|
|
10
|
+
findProvider(): ISolana | undefined;
|
|
11
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
'use client'
|
|
2
|
+
import { createSolanaSignerFromWalletStandard, getWalletStandardWallets, hasAllWalletStandardRequiredFeatures } from '@dynamic-labs/solana';
|
|
3
|
+
import { InjectedWalletBase } from '../InjectedWalletBase/InjectedWalletBase.js';
|
|
4
|
+
import { eclipseMainnetHash, eclipseTestnetHash } from '../../constants.js';
|
|
5
|
+
|
|
6
|
+
const getNightlyWallet = () => getWalletStandardWallets().find((wallet) => wallet.name === 'Nightly' && hasAllWalletStandardRequiredFeatures(wallet));
|
|
7
|
+
class Nightly extends InjectedWalletBase {
|
|
8
|
+
constructor(opts) {
|
|
9
|
+
super(opts);
|
|
10
|
+
this.name = 'Nightly';
|
|
11
|
+
this.overrideKey = 'nightlyeclipse';
|
|
12
|
+
this._wallet = getNightlyWallet();
|
|
13
|
+
if (this._wallet) {
|
|
14
|
+
this._provider = createSolanaSignerFromWalletStandard({
|
|
15
|
+
genesisHashesMap: {
|
|
16
|
+
[eclipseMainnetHash]: 'mainnet',
|
|
17
|
+
[eclipseTestnetHash]: 'testnet',
|
|
18
|
+
},
|
|
19
|
+
network: this.eclipseNetworks[0],
|
|
20
|
+
wallet: this._wallet,
|
|
21
|
+
walletConnector: this,
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
findProvider() {
|
|
26
|
+
return this._provider;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
export { Nightly };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './Nightly';
|