@subwallet/extension-base 0.3.6-3 → 0.4.2-1
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/LICENSE +201 -201
- package/README.md +10 -10
- package/background/KoniTypes.d.ts +590 -462
- package/background/KoniTypes.js +1 -0
- package/background/RequestBytesSign.d.ts +12 -12
- package/background/RequestExtrinsicSign.d.ts +12 -12
- package/background/handlers/Extension.d.ts +49 -49
- package/background/handlers/Extension.js +2 -2
- package/background/handlers/State.d.ts +87 -87
- package/background/handlers/Tabs.d.ts +24 -24
- package/background/handlers/helpers.d.ts +1 -1
- package/background/handlers/index.d.ts +3 -3
- package/background/handlers/subscriptions.d.ts +5 -4
- package/background/handlers/subscriptions.js +3 -0
- package/background/types.d.ts +345 -345
- package/bundle.d.ts +1 -1
- package/cjs/background/KoniTypes.js +1 -0
- package/cjs/background/handlers/Extension.js +4 -4
- package/cjs/background/handlers/subscriptions.js +5 -0
- package/cjs/packageInfo.js +1 -1
- package/cjs/page/PostMessageProvider.js +27 -27
- package/defaults.d.ts +10 -10
- package/detectOther.d.ts +7 -7
- package/detectPackage.d.ts +1 -1
- package/index.d.ts +1 -1
- package/package.json +4 -4
- package/packageInfo.d.ts +6 -6
- package/packageInfo.js +1 -1
- package/page/Accounts.d.ts +7 -7
- package/page/Injected.d.ts +13 -13
- package/page/Metadata.d.ts +7 -7
- package/page/PostMessageProvider.d.ts +62 -62
- package/page/PostMessageProvider.js +27 -27
- package/page/Signer.d.ts +8 -8
- package/page/index.d.ts +16 -16
- package/page/types.d.ts +6 -6
- package/stores/Accounts.d.ts +6 -6
- package/stores/Base.d.ts +10 -10
- package/stores/Metadata.d.ts +5 -5
- package/stores/index.d.ts +2 -2
- package/types.d.ts +9 -9
- package/utils/canDerive.d.ts +2 -2
- package/utils/getId.d.ts +1 -1
- package/utils/index.d.ts +1 -1
package/stores/Accounts.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import type { KeyringJson, KeyringStore } from '@polkadot/ui-keyring/types';
|
|
2
|
-
import BaseStore from './Base';
|
|
3
|
-
export default class AccountsStore extends BaseStore<KeyringJson> implements KeyringStore {
|
|
4
|
-
constructor();
|
|
5
|
-
set(key: string, value: KeyringJson, update?: () => void): void;
|
|
6
|
-
}
|
|
1
|
+
import type { KeyringJson, KeyringStore } from '@polkadot/ui-keyring/types';
|
|
2
|
+
import BaseStore from './Base';
|
|
3
|
+
export default class AccountsStore extends BaseStore<KeyringJson> implements KeyringStore {
|
|
4
|
+
constructor();
|
|
5
|
+
set(key: string, value: KeyringJson, update?: () => void): void;
|
|
6
|
+
}
|
package/stores/Base.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
export default abstract class BaseStore<T> {
|
|
2
|
-
#private;
|
|
3
|
-
constructor(prefix: string | null);
|
|
4
|
-
getPrefix(): string;
|
|
5
|
-
all(update: (key: string, value: T) => void): void;
|
|
6
|
-
allMap(update: (value: Record<string, T>) => void): void;
|
|
7
|
-
get(_key: string, update: (value: T) => void): void;
|
|
8
|
-
remove(_key: string, update?: () => void): void;
|
|
9
|
-
set(_key: string, value: T, update?: () => void): void;
|
|
10
|
-
}
|
|
1
|
+
export default abstract class BaseStore<T> {
|
|
2
|
+
#private;
|
|
3
|
+
constructor(prefix: string | null);
|
|
4
|
+
getPrefix(): string;
|
|
5
|
+
all(update: (key: string, value: T) => void): void;
|
|
6
|
+
allMap(update: (value: Record<string, T>) => void): void;
|
|
7
|
+
get(_key: string, update: (value: T) => void): void;
|
|
8
|
+
remove(_key: string, update?: () => void): void;
|
|
9
|
+
set(_key: string, value: T, update?: () => void): void;
|
|
10
|
+
}
|
package/stores/Metadata.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { MetadataDef } from '@subwallet/extension-inject/types';
|
|
2
|
-
import BaseStore from './Base';
|
|
3
|
-
export default class MetadataStore extends BaseStore<MetadataDef> {
|
|
4
|
-
constructor();
|
|
5
|
-
}
|
|
1
|
+
import type { MetadataDef } from '@subwallet/extension-inject/types';
|
|
2
|
+
import BaseStore from './Base';
|
|
3
|
+
export default class MetadataStore extends BaseStore<MetadataDef> {
|
|
4
|
+
constructor();
|
|
5
|
+
}
|
package/stores/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { default as AccountsStore } from './Accounts';
|
|
2
|
-
export { default as MetadataStore } from './Metadata';
|
|
1
|
+
export { default as AccountsStore } from './Accounts';
|
|
2
|
+
export { default as MetadataStore } from './Metadata';
|
package/types.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export interface Message extends MessageEvent {
|
|
2
|
-
data: {
|
|
3
|
-
error?: string;
|
|
4
|
-
id: string;
|
|
5
|
-
origin: string;
|
|
6
|
-
response?: string;
|
|
7
|
-
subscription?: string;
|
|
8
|
-
};
|
|
9
|
-
}
|
|
1
|
+
export interface Message extends MessageEvent {
|
|
2
|
+
data: {
|
|
3
|
+
error?: string;
|
|
4
|
+
id: string;
|
|
5
|
+
origin: string;
|
|
6
|
+
response?: string;
|
|
7
|
+
subscription?: string;
|
|
8
|
+
};
|
|
9
|
+
}
|
package/utils/canDerive.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import type { KeypairType } from '@polkadot/util-crypto/types';
|
|
2
|
-
export declare function canDerive(type?: KeypairType): boolean;
|
|
1
|
+
import type { KeypairType } from '@polkadot/util-crypto/types';
|
|
2
|
+
export declare function canDerive(type?: KeypairType): boolean;
|
package/utils/getId.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function getId(): string;
|
|
1
|
+
export declare function getId(): string;
|
package/utils/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { canDerive } from './canDerive';
|
|
1
|
+
export { canDerive } from './canDerive';
|