@dynamic-labs/ethereum 2.3.7 → 2.3.9

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,19 @@
1
1
 
2
+ ### [2.3.9](https://github.com/dynamic-labs/DynamicAuth/compare/v2.3.8...v2.3.9) (2024-08-13)
3
+
4
+
5
+ ### Bug Fixes
6
+
7
+ * hcaptcha for mobile login ([#6525](https://github.com/dynamic-labs/DynamicAuth/issues/6525)) ([#6539](https://github.com/dynamic-labs/DynamicAuth/issues/6539)) ([9b3676d](https://github.com/dynamic-labs/DynamicAuth/commit/9b3676dd27c65a7e678e720e5648a166b8d514a6))
8
+
9
+ ### [2.3.8](https://github.com/dynamic-labs/DynamicAuth/compare/v2.3.7...v2.3.8) (2024-08-02)
10
+
11
+
12
+ ### Bug Fixes
13
+
14
+ * fetch user on refresh from backend when cookie-enabled and user not in local storage ([#6472](https://github.com/dynamic-labs/DynamicAuth/issues/6472)) ([7300a21](https://github.com/dynamic-labs/DynamicAuth/commit/7300a21d81d51ef1fc93af12d1081b5c1d57b578))
15
+ * stop filtering wallet connect on keyword "wallet" ([#6476](https://github.com/dynamic-labs/DynamicAuth/issues/6476)) ([fc1be36](https://github.com/dynamic-labs/DynamicAuth/commit/fc1be36b0370f876dcfe4e84e25ee60cf9682306)), closes [#6475](https://github.com/dynamic-labs/DynamicAuth/issues/6475)
16
+
2
17
  ### [2.3.7](https://github.com/dynamic-labs/DynamicAuth/compare/v2.3.6...v2.3.7) (2024-07-26)
3
18
 
4
19
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamic-labs/ethereum",
3
- "version": "2.3.7",
3
+ "version": "2.3.9",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+https://github.com/dynamic-labs/dynamic-auth.git",
@@ -31,13 +31,13 @@
31
31
  "@walletconnect/ethereum-provider": "2.11.2",
32
32
  "eventemitter3": "5.0.1",
33
33
  "buffer": "6.0.3",
34
- "@dynamic-labs/rpc-provider-ethereum": "2.3.7",
35
- "@dynamic-labs/turnkey": "2.3.7",
36
- "@dynamic-labs/types": "2.3.7",
37
- "@dynamic-labs/utils": "2.3.7",
38
- "@dynamic-labs/viem-utils": "2.3.7",
39
- "@dynamic-labs/wallet-book": "2.3.7",
40
- "@dynamic-labs/wallet-connector-core": "2.3.7",
34
+ "@dynamic-labs/rpc-provider-ethereum": "2.3.9",
35
+ "@dynamic-labs/turnkey": "2.3.9",
36
+ "@dynamic-labs/types": "2.3.9",
37
+ "@dynamic-labs/utils": "2.3.9",
38
+ "@dynamic-labs/viem-utils": "2.3.9",
39
+ "@dynamic-labs/wallet-book": "2.3.9",
40
+ "@dynamic-labs/wallet-connector-core": "2.3.9",
41
41
  "stream": "0.0.2"
42
42
  },
43
43
  "peerDependencies": {
@@ -8,7 +8,6 @@ var viem = require('viem');
8
8
  var walletConnectorCore = require('@dynamic-labs/wallet-connector-core');
9
9
  var utils = require('@dynamic-labs/utils');
10
10
  var viemUtils = require('@dynamic-labs/viem-utils');
11
- var eip6963Provider = require('./eip6963Provider.cjs');
12
11
 
13
12
  class EthProviderHelper {
14
13
  constructor(wallet, connector) {
@@ -69,7 +68,7 @@ class EthProviderHelper {
69
68
  }
70
69
  eip6963ProviderLookup(rdns) {
71
70
  var _a;
72
- const { providers } = eip6963Provider.Eip6963ProviderSingleton.get();
71
+ const { providers } = utils.Eip6963ProviderSingleton.get();
73
72
  return (_a = providers.find((provider) => provider.info.rdns === rdns)) === null || _a === void 0 ? void 0 : _a.provider;
74
73
  }
75
74
  isInstalledHelper() {
@@ -2,9 +2,8 @@
2
2
  import { __awaiter } from '../_virtual/_tslib.js';
3
3
  import { createWalletClient, custom, getAddress } from 'viem';
4
4
  import { ProviderLookup, eventListenerHandlers, logger } from '@dynamic-labs/wallet-connector-core';
5
- import { getProvidersFromWindow } from '@dynamic-labs/utils';
5
+ import { getProvidersFromWindow, Eip6963ProviderSingleton } from '@dynamic-labs/utils';
6
6
  import { chainsMap } from '@dynamic-labs/viem-utils';
7
- import { Eip6963ProviderSingleton } from './eip6963Provider.js';
8
7
 
9
8
  class EthProviderHelper {
10
9
  constructor(wallet, connector) {
@@ -1,40 +0,0 @@
1
- 'use client'
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, '__esModule', { value: true });
5
-
6
- const isEip9693Event = (event) => event.type === 'eip6963:announceProvider' &&
7
- event.detail !== undefined;
8
- class Eip6963Provider {
9
- constructor() {
10
- this.providers = [];
11
- }
12
- registerProviders() {
13
- if (typeof window === 'undefined') {
14
- return;
15
- }
16
- window.addEventListener('eip6963:announceProvider', (event) => {
17
- if (!isEip9693Event(event)) {
18
- return;
19
- }
20
- this.providers.push(event.detail);
21
- });
22
- window.dispatchEvent(new Event('eip6963:requestProvider'));
23
- }
24
- }
25
- class Eip6963ProviderSingleton {
26
- constructor() {
27
- this.eip6963Provider = new Eip6963Provider();
28
- }
29
- static get() {
30
- var _a;
31
- if (!((_a = Eip6963ProviderSingleton.instance) === null || _a === void 0 ? void 0 : _a.eip6963Provider)) {
32
- Eip6963ProviderSingleton.instance = new Eip6963ProviderSingleton();
33
- Eip6963ProviderSingleton.instance.eip6963Provider.registerProviders();
34
- }
35
- return Eip6963ProviderSingleton.instance.eip6963Provider;
36
- }
37
- }
38
-
39
- exports.Eip6963Provider = Eip6963Provider;
40
- exports.Eip6963ProviderSingleton = Eip6963ProviderSingleton;
@@ -1,25 +0,0 @@
1
- import { IEthereum } from './types';
2
- /**
3
- * Represents the assets needed to display a wallet
4
- */
5
- type Eip6963ProviderInfo = {
6
- uuid: string;
7
- name: string;
8
- icon: string;
9
- rdns: string;
10
- };
11
- type Eip6963ProviderDetail = {
12
- info: Eip6963ProviderInfo;
13
- provider: IEthereum;
14
- };
15
- export declare class Eip6963Provider {
16
- providers: Eip6963ProviderDetail[];
17
- registerProviders(): void;
18
- }
19
- export declare class Eip6963ProviderSingleton {
20
- readonly eip6963Provider: Eip6963Provider;
21
- private constructor();
22
- private static instance;
23
- static get(): Eip6963Provider;
24
- }
25
- export {};
@@ -1,35 +0,0 @@
1
- 'use client'
2
- const isEip9693Event = (event) => event.type === 'eip6963:announceProvider' &&
3
- event.detail !== undefined;
4
- class Eip6963Provider {
5
- constructor() {
6
- this.providers = [];
7
- }
8
- registerProviders() {
9
- if (typeof window === 'undefined') {
10
- return;
11
- }
12
- window.addEventListener('eip6963:announceProvider', (event) => {
13
- if (!isEip9693Event(event)) {
14
- return;
15
- }
16
- this.providers.push(event.detail);
17
- });
18
- window.dispatchEvent(new Event('eip6963:requestProvider'));
19
- }
20
- }
21
- class Eip6963ProviderSingleton {
22
- constructor() {
23
- this.eip6963Provider = new Eip6963Provider();
24
- }
25
- static get() {
26
- var _a;
27
- if (!((_a = Eip6963ProviderSingleton.instance) === null || _a === void 0 ? void 0 : _a.eip6963Provider)) {
28
- Eip6963ProviderSingleton.instance = new Eip6963ProviderSingleton();
29
- Eip6963ProviderSingleton.instance.eip6963Provider.registerProviders();
30
- }
31
- return Eip6963ProviderSingleton.instance.eip6963Provider;
32
- }
33
- }
34
-
35
- export { Eip6963Provider, Eip6963ProviderSingleton };