@ledgerhq/connect-kit 1.0.3 → 1.0.4
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 +13 -1
- package/dist/umd/components/ConnectWithLedgerLiveModal/ConnectWithLedgerLiveModal.d.ts +2 -2
- package/dist/umd/index.d.ts +2 -4
- package/dist/umd/index.js +14 -14
- package/dist/umd/index.js.map +1 -1
- package/dist/umd/lib/provider.d.ts +1 -2
- package/dist/umd/providers/Ethereum.d.ts +2 -3
- package/dist/umd/providers/WalletConnect.d.ts +2 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
@@ -7,11 +7,23 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
7
7
|
|
8
8
|
## Unreleased
|
9
9
|
|
10
|
+
## 1.0.4 - 2022-12-06
|
11
|
+
### Changed
|
12
|
+
- Create a new WalletConnect session each time `eth_requestAccounts` is called
|
13
|
+
(and hence each time the "Use Ledger Live" modal is shown) to avoid reusing
|
14
|
+
the same WalletConnect URI.
|
15
|
+
- The "Use Ledger Live" modal is now closed when pressing the "Use Ledger
|
16
|
+
Live" button to avoid the same WalletConnect URI being reused (e.g. if the
|
17
|
+
user clicks "Decline" in Ledger Live and clicks "Use Ledger Live" again.
|
18
|
+
- No longer reuse the provider instance in the Provider module as it
|
19
|
+
interferes with refreshing the WalletConnect URI.
|
20
|
+
- No longer reuse the provider instance in the WalletConnect module.
|
21
|
+
|
10
22
|
## 1.0.3 - 2022-12-06
|
11
23
|
|
12
24
|
## 1.0.2 - 2022-12-02
|
13
25
|
### Changed
|
14
|
-
- Use the ledgerlive: deeplink for
|
26
|
+
- Use the ledgerlive: deeplink for the QR code instead of the WalletConnect
|
15
27
|
URI; this allows scanning the QR code with the native camera app.
|
16
28
|
|
17
29
|
## 1.0.1 - 2022-12-02
|
@@ -1,8 +1,8 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
-
export declare let setWalletConnectUri: (uri: string) => void;
|
3
2
|
export type ConnectWithLedgerLiveModalProps = {
|
4
3
|
withQrCode?: boolean;
|
4
|
+
uri?: string;
|
5
5
|
onClose?: () => void;
|
6
6
|
};
|
7
|
-
declare const ConnectWithLedgerLiveModal: ({ withQrCode, onClose, }: ConnectWithLedgerLiveModalProps) => JSX.Element;
|
7
|
+
declare const ConnectWithLedgerLiveModal: ({ withQrCode, uri, onClose, }: ConnectWithLedgerLiveModalProps) => JSX.Element;
|
8
8
|
export default ConnectWithLedgerLiveModal;
|
package/dist/umd/index.d.ts
CHANGED
@@ -1,12 +1,10 @@
|
|
1
|
-
import WalletConnectProvider from '@walletconnect/ethereum-provider/dist/esm';
|
2
|
-
|
3
1
|
type EthereumRequestPayload = {
|
4
2
|
method: string;
|
5
3
|
params?: unknown[] | object;
|
6
4
|
};
|
7
5
|
interface EthereumProvider {
|
8
6
|
providers?: EthereumProvider[];
|
9
|
-
request(
|
7
|
+
request<T = unknown>(args: EthereumRequestPayload): Promise<T>;
|
10
8
|
disconnect?: {
|
11
9
|
(): Promise<void>;
|
12
10
|
};
|
@@ -33,7 +31,7 @@ declare enum SupportedProviderImplementations {
|
|
33
31
|
LedgerConnect = "LedgerConnect",
|
34
32
|
WalletConnect = "WalletConnect"
|
35
33
|
}
|
36
|
-
type ProviderResult = EthereumProvider | SolanaProvider
|
34
|
+
type ProviderResult = EthereumProvider | SolanaProvider;
|
37
35
|
declare function getProvider(): Promise<ProviderResult>;
|
38
36
|
|
39
37
|
type CheckSupportOptions = {
|