@ledgerhq/connect-kit 1.1.0-beta.3 → 1.1.1-beta.0

Sign up to get free protection for your applications and to get access to all the features.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,22 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## Unreleased
9
9
 
10
+ ## 1.1.1-beta.0 - 2023-08-01
11
+ ### Changed
12
+ - Use WalletConnect's default list of optional methods and events.
13
+ - Add analytics support so that we can better understand usage.
14
+ - Handle display_uri event only once when calling eth_requestAccounts.
15
+ - Update WalletConnect package versions.
16
+ - Switch to the correct chain when connecting with the Extension.
17
+ - Expose provider.chainId.
18
+ - Remove unfinished Solana support.
19
+
20
+ ## 1.1.0 - 2023-06-22
21
+ Connect Kit now supports WalletConnect v2.
22
+
23
+ Have a look at the Connect Kit loader documentation for
24
+ more details.
25
+
10
26
  ## 1.1.0-beta.3 - 2023-06-21
11
27
  ### Changed
12
28
  - Rename the version parameter to walletConnectVersion.
@@ -0,0 +1,11 @@
1
+ import { Plugin } from "@segment/analytics-next";
2
+ type UseAnalyticsReturn = {
3
+ track: (eventName: string, eventProperties?: Record<string, unknown>) => Promise<void>;
4
+ page: (pageName: string, eventProperties?: Record<string, unknown>) => Promise<void>;
5
+ init: (globalProperties?: Record<string, unknown>, globalOptions?: Record<string, unknown>) => Promise<void>;
6
+ addStepToFlow: (step: string) => void;
7
+ sendUserFlow: () => void;
8
+ };
9
+ export declare const debug: Plugin;
10
+ export declare function useAnalytics(): UseAnalyticsReturn;
11
+ export {};
@@ -9,6 +9,7 @@ interface EthereumProvider {
9
9
  providers?: EthereumProvider[];
10
10
  connector?: unknown;
11
11
  session?: unknown;
12
+ chainId: string | number;
12
13
  request<T = unknown>(args: EthereumRequestPayload): Promise<T>;
13
14
  disconnect?: {
14
15
  (): Promise<void>;
@@ -17,16 +18,6 @@ interface EthereumProvider {
17
18
  removeListener(event: string, listener: any): void;
18
19
  }
19
20
 
20
- declare const EXTENSION_SOLANA_PROP = "isLedgerConnect";
21
- interface SolanaProvider {
22
- [EXTENSION_SOLANA_PROP]: boolean;
23
- signTransaction(...args: unknown[]): Promise<unknown>;
24
- signAllTransactions(...args: unknown[]): Promise<unknown>;
25
- signAndSendTransaction(...args: unknown[]): Promise<unknown>;
26
- connect(): Promise<void>;
27
- disconnect(): Promise<void>;
28
- }
29
-
30
21
  declare enum SupportedProviders {
31
22
  Ethereum = "Ethereum",
32
23
  Solana = "Solana"
@@ -35,7 +26,7 @@ declare enum SupportedProviderImplementations {
35
26
  LedgerConnect = "LedgerConnect",
36
27
  WalletConnect = "WalletConnect"
37
28
  }
38
- type ProviderResult = EthereumProvider | SolanaProvider;
29
+ type ProviderResult = EthereumProvider;
39
30
  /**
40
31
  * Gets a provider instance based on the implementation set earlier.
41
32
  */
@@ -56,6 +47,7 @@ type CheckSupportWalletConnectProviderOptions = {
56
47
  rpcMap?: {
57
48
  [chainId: string]: string;
58
49
  };
50
+ relayUrl?: string;
59
51
  };
60
52
  type CheckSupportWalletConnectLegacyProviderOptions = {
61
53
  chainId?: number;