@trezor/connect 9.4.1 → 9.4.2-beta.2
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 +54 -9
- package/README.md +1 -1
- package/lib/api/bitcoin/inputs.js +1 -1
- package/lib/api/cardano/cardanoInputs.d.ts +7 -7
- package/lib/api/cardano/cardanoOutputs.d.ts +22 -22
- package/lib/api/cardano/cardanoTokenBundle.d.ts +5 -5
- package/lib/api/ethereum/api/ethereumSignTypedData.d.ts +56 -56
- package/lib/api/ethereum/ethereumDefinitions.d.ts +20 -20
- package/lib/backend/Blockchain.js +10 -3
- package/lib/constants/nem.d.ts +3 -3
- package/lib/core/index.js +25 -14
- package/lib/data/connectSettings.js +3 -0
- package/lib/data/deviceAuthenticityConfigTypes.d.ts +23 -23
- package/lib/data/version.d.ts +1 -1
- package/lib/data/version.js +1 -1
- package/lib/device/Device.d.ts +17 -13
- package/lib/device/Device.js +22 -16
- package/lib/device/DeviceCommands.d.ts +40 -10
- package/lib/device/DeviceCommands.js +25 -90
- package/lib/device/DeviceList.d.ts +5 -2
- package/lib/device/DeviceList.js +35 -11
- package/lib/device/prompts.d.ts +15 -0
- package/lib/device/prompts.js +63 -0
- package/lib/events/call.d.ts +4 -2
- package/lib/events/call.js +8 -1
- package/lib/events/core.js +1 -0
- package/lib/events/ui-response.d.ts +3 -3
- package/lib/index.js +2 -2
- package/lib/types/api/applySettings.d.ts +13 -13
- package/lib/types/api/authenticateDevice.d.ts +24 -24
- package/lib/types/api/authorizeCoinjoin.d.ts +9 -9
- package/lib/types/api/binance/index.d.ts +142 -142
- package/lib/types/api/bitcoin/index.d.ts +10 -10
- package/lib/types/api/cancelCoinjoinAuthorization.d.ts +1 -1
- package/lib/types/api/cardano/index.d.ts +507 -507
- package/lib/types/api/changeLanguage.d.ts +6 -6
- package/lib/types/api/cipherKeyValue.d.ts +7 -7
- package/lib/types/api/eos/index.d.ts +525 -525
- package/lib/types/api/ethereum/index.d.ts +100 -100
- package/lib/types/api/firmwareUpdate.d.ts +5 -5
- package/lib/types/api/getAccountDescriptor.d.ts +4 -4
- package/lib/types/api/getAddress.d.ts +32 -32
- package/lib/types/api/getOwnershipId.d.ts +24 -24
- package/lib/types/api/getOwnershipProof.d.ts +28 -28
- package/lib/types/api/getPublicKey.d.ts +23 -23
- package/lib/types/api/nem/index.d.ts +611 -611
- package/lib/types/api/nemGetAddress.d.ts +6 -6
- package/lib/types/api/pushTransaction.d.ts +3 -3
- package/lib/types/api/recoveryDevice.d.ts +9 -9
- package/lib/types/api/requestLogin.d.ts +25 -25
- package/lib/types/api/ripple/index.d.ts +21 -21
- package/lib/types/api/solana/index.d.ts +23 -23
- package/lib/types/api/stellar/index.d.ts +581 -581
- package/lib/types/api/tezos/index.d.ts +120 -120
- package/lib/types/api/unlockPath.d.ts +2 -2
- package/lib/types/coinInfo.d.ts +224 -224
- package/lib/types/fees.d.ts +19 -19
- package/lib/types/firmware.d.ts +1 -1
- package/lib/types/params.d.ts +24 -20
- package/lib/types/settings.d.ts +4 -0
- package/package.json +4 -4
package/lib/types/fees.d.ts
CHANGED
|
@@ -1,30 +1,30 @@
|
|
|
1
1
|
import { Static } from '@trezor/schema-utils';
|
|
2
2
|
export type FeeInfo = Static<typeof FeeInfo>;
|
|
3
3
|
export declare const FeeInfo: import("@trezor/schema-utils").TObject<{
|
|
4
|
-
blockTime: import("@sinclair/typebox
|
|
5
|
-
minFee: import("@sinclair/typebox
|
|
6
|
-
maxFee: import("@sinclair/typebox
|
|
7
|
-
dustLimit: import("@sinclair/typebox
|
|
4
|
+
blockTime: import("@sinclair/typebox").TNumber;
|
|
5
|
+
minFee: import("@sinclair/typebox").TNumber;
|
|
6
|
+
maxFee: import("@sinclair/typebox").TNumber;
|
|
7
|
+
dustLimit: import("@sinclair/typebox").TNumber;
|
|
8
8
|
}>;
|
|
9
9
|
export type FeeLevel = Static<typeof FeeLevel>;
|
|
10
10
|
export declare const FeeLevel: import("@trezor/schema-utils").TObject<{
|
|
11
|
-
label: import("@sinclair/typebox
|
|
12
|
-
feePerUnit: import("@sinclair/typebox
|
|
13
|
-
blocks: import("@sinclair/typebox
|
|
14
|
-
feeLimit: import("@sinclair/typebox
|
|
15
|
-
feePerTx: import("@sinclair/typebox
|
|
11
|
+
label: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<"high">, import("@sinclair/typebox").TLiteral<"normal">, import("@sinclair/typebox").TLiteral<"economy">, import("@sinclair/typebox").TLiteral<"low">, import("@sinclair/typebox").TLiteral<"custom">]>;
|
|
12
|
+
feePerUnit: import("@sinclair/typebox").TString;
|
|
13
|
+
blocks: import("@sinclair/typebox").TNumber;
|
|
14
|
+
feeLimit: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
15
|
+
feePerTx: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
16
16
|
}>;
|
|
17
17
|
export type SelectFeeLevel = Static<typeof SelectFeeLevel>;
|
|
18
|
-
export declare const SelectFeeLevel: import("@sinclair/typebox
|
|
19
|
-
name: import("@sinclair/typebox
|
|
20
|
-
fee: import("@sinclair/typebox
|
|
21
|
-
feePerByte: import("@sinclair/typebox
|
|
22
|
-
disabled: import("@sinclair/typebox
|
|
18
|
+
export declare const SelectFeeLevel: import("@sinclair/typebox").TUnion<[import("@trezor/schema-utils").TObject<{
|
|
19
|
+
name: import("@sinclair/typebox").TString;
|
|
20
|
+
fee: import("@sinclair/typebox").TLiteral<"0">;
|
|
21
|
+
feePerByte: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TUndefined>;
|
|
22
|
+
disabled: import("@sinclair/typebox").TLiteral<true>;
|
|
23
23
|
}>, import("@trezor/schema-utils").TObject<{
|
|
24
|
-
name: import("@sinclair/typebox
|
|
25
|
-
fee: import("@sinclair/typebox
|
|
26
|
-
feePerByte: import("@sinclair/typebox
|
|
27
|
-
minutes: import("@sinclair/typebox
|
|
28
|
-
total: import("@sinclair/typebox
|
|
24
|
+
name: import("@sinclair/typebox").TString;
|
|
25
|
+
fee: import("@sinclair/typebox").TString;
|
|
26
|
+
feePerByte: import("@sinclair/typebox").TString;
|
|
27
|
+
minutes: import("@sinclair/typebox").TNumber;
|
|
28
|
+
total: import("@sinclair/typebox").TString;
|
|
29
29
|
}>]>;
|
|
30
30
|
//# sourceMappingURL=fees.d.ts.map
|
package/lib/types/firmware.d.ts
CHANGED
|
@@ -21,7 +21,7 @@ export type FirmwareRelease = {
|
|
|
21
21
|
translations?: string[];
|
|
22
22
|
};
|
|
23
23
|
export type IntermediaryVersion = 1 | 2 | 3;
|
|
24
|
-
export declare const IntermediaryVersion: import("@sinclair/typebox
|
|
24
|
+
export declare const IntermediaryVersion: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TLiteral<1>, import("@sinclair/typebox").TLiteral<2>, import("@sinclair/typebox").TLiteral<3>]>;
|
|
25
25
|
export type ReleaseInfo = {
|
|
26
26
|
changelog: FirmwareRelease[] | null;
|
|
27
27
|
release: FirmwareRelease;
|
package/lib/types/params.d.ts
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { TSchema, Static } from '@trezor/schema-utils';
|
|
2
2
|
import { DeviceState } from './device';
|
|
3
|
+
export interface DeviceIdentity {
|
|
4
|
+
path?: string;
|
|
5
|
+
state?: string | DeviceState;
|
|
6
|
+
instance?: number;
|
|
7
|
+
}
|
|
3
8
|
export interface CommonParams {
|
|
4
|
-
device?:
|
|
5
|
-
path?: string;
|
|
6
|
-
state?: string | DeviceState;
|
|
7
|
-
instance?: number;
|
|
8
|
-
};
|
|
9
|
+
device?: DeviceIdentity;
|
|
9
10
|
useEmptyPassphrase?: boolean;
|
|
10
11
|
useEventListener?: boolean;
|
|
11
12
|
allowSeedlessDevice?: boolean;
|
|
@@ -22,7 +23,7 @@ interface Bundle<T> {
|
|
|
22
23
|
bundle: T[];
|
|
23
24
|
}
|
|
24
25
|
export declare const Bundle: <T extends TSchema>(type: T) => import("@trezor/schema-utils").TObject<{
|
|
25
|
-
bundle: import("@sinclair/typebox
|
|
26
|
+
bundle: import("@sinclair/typebox").TArray<T>;
|
|
26
27
|
}>;
|
|
27
28
|
export type BundledParams<T> = CommonParams & Bundle<T>;
|
|
28
29
|
export interface CommonParamsWithCoin extends CommonParams {
|
|
@@ -40,9 +41,12 @@ export interface Success<T> {
|
|
|
40
41
|
success: true;
|
|
41
42
|
payload: T;
|
|
42
43
|
}
|
|
43
|
-
export
|
|
44
|
+
export interface SuccessWithDevice<T> extends Success<T> {
|
|
45
|
+
device?: DeviceIdentity;
|
|
46
|
+
}
|
|
47
|
+
export type Response<T> = Promise<SuccessWithDevice<T> | Unsuccessful>;
|
|
44
48
|
export type DerivationPath = string | number[];
|
|
45
|
-
export declare const DerivationPath: import("@sinclair/typebox
|
|
49
|
+
export declare const DerivationPath: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TArray<import("@sinclair/typebox").TNumber>]>;
|
|
46
50
|
type ProtoWithExtendedAddressN<T, A, R> = Omit<Extract<T, {
|
|
47
51
|
address_n: A;
|
|
48
52
|
}>, 'address_n'> & {
|
|
@@ -55,11 +59,11 @@ export type ProtoWithDerivationPath<T> = ProtoWithoutAddressN<T, number[]> | Pro
|
|
|
55
59
|
export type ProtoWithAddressN<P extends ProtoWithDerivationPath<any>> = P extends ProtoWithDerivationPath<infer T> ? T : unknown;
|
|
56
60
|
export type GetAddress = Static<typeof GetAddress>;
|
|
57
61
|
export declare const GetAddress: import("@trezor/schema-utils").TObject<{
|
|
58
|
-
path: import("@sinclair/typebox
|
|
59
|
-
address: import("@sinclair/typebox
|
|
60
|
-
showOnTrezor: import("@sinclair/typebox
|
|
61
|
-
chunkify: import("@sinclair/typebox
|
|
62
|
-
useEventListener: import("@sinclair/typebox
|
|
62
|
+
path: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TArray<import("@sinclair/typebox").TNumber>]>;
|
|
63
|
+
address: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TString>;
|
|
64
|
+
showOnTrezor: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
|
|
65
|
+
chunkify: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
|
|
66
|
+
useEventListener: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
|
|
63
67
|
}>;
|
|
64
68
|
export interface Address {
|
|
65
69
|
address: string;
|
|
@@ -68,16 +72,16 @@ export interface Address {
|
|
|
68
72
|
}
|
|
69
73
|
export type GetPublicKey = Static<typeof GetPublicKey>;
|
|
70
74
|
export declare const GetPublicKey: import("@trezor/schema-utils").TObject<{
|
|
71
|
-
path: import("@sinclair/typebox
|
|
72
|
-
showOnTrezor: import("@sinclair/typebox
|
|
73
|
-
suppressBackupWarning: import("@sinclair/typebox
|
|
74
|
-
chunkify: import("@sinclair/typebox
|
|
75
|
+
path: import("@sinclair/typebox").TUnion<[import("@sinclair/typebox").TString, import("@sinclair/typebox").TArray<import("@sinclair/typebox").TNumber>]>;
|
|
76
|
+
showOnTrezor: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
|
|
77
|
+
suppressBackupWarning: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
|
|
78
|
+
chunkify: import("@sinclair/typebox").TOptional<import("@sinclair/typebox").TBoolean>;
|
|
75
79
|
}>;
|
|
76
80
|
export type PublicKey = Static<typeof PublicKey>;
|
|
77
81
|
export declare const PublicKey: import("@trezor/schema-utils").TObject<{
|
|
78
|
-
publicKey: import("@sinclair/typebox
|
|
79
|
-
path: import("@sinclair/typebox
|
|
80
|
-
serializedPath: import("@sinclair/typebox
|
|
82
|
+
publicKey: import("@sinclair/typebox").TString;
|
|
83
|
+
path: import("@sinclair/typebox").TArray<import("@sinclair/typebox").TNumber>;
|
|
84
|
+
serializedPath: import("@sinclair/typebox").TString;
|
|
81
85
|
}>;
|
|
82
86
|
export {};
|
|
83
87
|
//# sourceMappingURL=params.d.ts.map
|
package/lib/types/settings.d.ts
CHANGED
|
@@ -22,6 +22,10 @@ export interface ConnectSettingsPublic {
|
|
|
22
22
|
trustedHost: boolean;
|
|
23
23
|
coreMode?: 'auto' | 'popup' | 'iframe';
|
|
24
24
|
_extendWebextensionLifetime?: boolean;
|
|
25
|
+
_sessionsBackgroundUrl?: string;
|
|
26
|
+
deeplinkOpen?: (url: string) => void;
|
|
27
|
+
deeplinkCallbackUrl?: string;
|
|
28
|
+
deeplinkUrl?: string;
|
|
25
29
|
}
|
|
26
30
|
export interface ConnectSettingsInternal {
|
|
27
31
|
origin?: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@trezor/connect",
|
|
3
|
-
"version": "9.4.
|
|
3
|
+
"version": "9.4.2-beta.2",
|
|
4
4
|
"author": "Trezor <info@trezor.io>",
|
|
5
5
|
"homepage": "https://github.com/trezor/trezor-suite/tree/develop/packages/connect",
|
|
6
6
|
"description": "High-level javascript interface for Trezor hardware wallet.",
|
|
@@ -76,11 +76,11 @@
|
|
|
76
76
|
"@trezor/blockchain-link": "2.3.1",
|
|
77
77
|
"@trezor/blockchain-link-types": "1.2.1",
|
|
78
78
|
"@trezor/connect-analytics": "1.2.1",
|
|
79
|
-
"@trezor/connect-common": "0.2.1",
|
|
80
|
-
"@trezor/protobuf": "1.2.1",
|
|
79
|
+
"@trezor/connect-common": "0.2.2-beta.1",
|
|
80
|
+
"@trezor/protobuf": "1.2.2-beta.1",
|
|
81
81
|
"@trezor/protocol": "1.2.1",
|
|
82
82
|
"@trezor/schema-utils": "1.2.1",
|
|
83
|
-
"@trezor/transport": "1.3.1",
|
|
83
|
+
"@trezor/transport": "1.3.2-beta.1",
|
|
84
84
|
"@trezor/utils": "9.2.1",
|
|
85
85
|
"@trezor/utxo-lib": "2.2.1",
|
|
86
86
|
"blakejs": "^1.2.1",
|