@metamask-previews/keyring-controller 23.0.0-preview-9a5f096 → 23.0.0-preview-f3f2e8c8
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 +0 -12
- package/dist/KeyringController.cjs +7 -31
- package/dist/KeyringController.cjs.map +1 -1
- package/dist/KeyringController.d.cts +2 -5
- package/dist/KeyringController.d.cts.map +1 -1
- package/dist/KeyringController.d.mts +2 -5
- package/dist/KeyringController.d.mts.map +1 -1
- package/dist/KeyringController.mjs +7 -31
- package/dist/KeyringController.mjs.map +1 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -7,18 +7,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
-
### Added
|
|
11
|
-
|
|
12
|
-
- Add `KeyringController:addNewKeyring` action ([#6439](https://github.com/MetaMask/core/pull/6439))
|
|
13
|
-
- Add two new controller state metadata properties: `includeInStateLogs` and `usedInUi` ([#6525](https://github.com/MetaMask/core/pull/6525))
|
|
14
|
-
|
|
15
|
-
### Changed
|
|
16
|
-
|
|
17
|
-
- Bump `@metamask/base-controller` from `^8.1.0` to `^8.3.0` ([#6355](https://github.com/MetaMask/core/pull/6355), [#6465](https://github.com/MetaMask/core/pull/6465))
|
|
18
|
-
- Bump `@metamask/keyring-api` from `^20.1.0` to `^21.0.0` ([#6560](https://github.com/MetaMask/core/pull/6560))
|
|
19
|
-
- Bump `@metamask/keyring-internal-api` from `^8.1.0` to `^9.0.0` ([#6560](https://github.com/MetaMask/core/pull/6560))
|
|
20
|
-
- Bump `@metamask/eth-hd-keyring` from `^12.0.0` to `13.0.0` ([#6566](https://github.com/MetaMask/core/pull/6566))
|
|
21
|
-
|
|
22
10
|
## [23.0.0]
|
|
23
11
|
|
|
24
12
|
### Changed
|
|
@@ -65,6 +65,7 @@ var KeyringTypes;
|
|
|
65
65
|
KeyringTypes["oneKey"] = "OneKey Hardware";
|
|
66
66
|
KeyringTypes["ledger"] = "Ledger Hardware";
|
|
67
67
|
KeyringTypes["lattice"] = "Lattice Hardware";
|
|
68
|
+
KeyringTypes["keystone"] = "Keystone Hardware";
|
|
68
69
|
KeyringTypes["snap"] = "Snap Keyring";
|
|
69
70
|
})(KeyringTypes || (exports.KeyringTypes = KeyringTypes = {}));
|
|
70
71
|
/**
|
|
@@ -115,6 +116,7 @@ const defaultKeyringBuilders = [
|
|
|
115
116
|
// todo: keyring types are mismatched, this should be fixed in they keyrings themselves
|
|
116
117
|
// @ts-expect-error keyring types are mismatched
|
|
117
118
|
keyringBuilderFactory(eth_simple_keyring_1.default),
|
|
119
|
+
// @ts-expect-error keyring types are mismatched
|
|
118
120
|
keyringBuilderFactory(eth_hd_keyring_1.HdKeyring),
|
|
119
121
|
];
|
|
120
122
|
const getDefaultKeyringState = () => {
|
|
@@ -263,36 +265,11 @@ class KeyringController extends base_controller_1.BaseController {
|
|
|
263
265
|
super({
|
|
264
266
|
name,
|
|
265
267
|
metadata: {
|
|
266
|
-
vault: {
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
},
|
|
272
|
-
isUnlocked: {
|
|
273
|
-
includeInStateLogs: true,
|
|
274
|
-
persist: false,
|
|
275
|
-
anonymous: true,
|
|
276
|
-
usedInUi: true,
|
|
277
|
-
},
|
|
278
|
-
keyrings: {
|
|
279
|
-
includeInStateLogs: true,
|
|
280
|
-
persist: false,
|
|
281
|
-
anonymous: false,
|
|
282
|
-
usedInUi: true,
|
|
283
|
-
},
|
|
284
|
-
encryptionKey: {
|
|
285
|
-
includeInStateLogs: false,
|
|
286
|
-
persist: false,
|
|
287
|
-
anonymous: false,
|
|
288
|
-
usedInUi: false,
|
|
289
|
-
},
|
|
290
|
-
encryptionSalt: {
|
|
291
|
-
includeInStateLogs: false,
|
|
292
|
-
persist: false,
|
|
293
|
-
anonymous: false,
|
|
294
|
-
usedInUi: false,
|
|
295
|
-
},
|
|
268
|
+
vault: { persist: true, anonymous: false },
|
|
269
|
+
isUnlocked: { persist: false, anonymous: true },
|
|
270
|
+
keyrings: { persist: false, anonymous: false },
|
|
271
|
+
encryptionKey: { persist: false, anonymous: false },
|
|
272
|
+
encryptionSalt: { persist: false, anonymous: false },
|
|
296
273
|
},
|
|
297
274
|
messenger,
|
|
298
275
|
state: {
|
|
@@ -1031,7 +1008,6 @@ _KeyringController_controllerOperationMutex = new WeakMap(), _KeyringController_
|
|
|
1031
1008
|
this.messagingSystem.registerActionHandler(`${name}:signUserOperation`, this.signUserOperation.bind(this));
|
|
1032
1009
|
this.messagingSystem.registerActionHandler(`${name}:addNewAccount`, this.addNewAccount.bind(this));
|
|
1033
1010
|
this.messagingSystem.registerActionHandler(`${name}:withKeyring`, this.withKeyring.bind(this));
|
|
1034
|
-
this.messagingSystem.registerActionHandler(`${name}:addNewKeyring`, this.addNewKeyring.bind(this));
|
|
1035
1011
|
}, _KeyringController_getKeyringById = function _KeyringController_getKeyringById(keyringId) {
|
|
1036
1012
|
return __classPrivateFieldGet(this, _KeyringController_keyrings, "f").find(({ metadata }) => metadata.id === keyringId)
|
|
1037
1013
|
?.keyring;
|