@trezor/connect 9.0.3 → 9.0.5
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 +67 -0
- package/README.md +1 -1
- package/lib/api/authorizeCoinJoin.js +6 -2
- package/lib/api/binanceGetAddress.d.ts +1 -1
- package/lib/api/binanceSignTransaction.d.ts +1 -1
- package/lib/api/bitcoin/Fees.d.ts +1 -1
- package/lib/api/bitcoin/TransactionComposer.d.ts +1 -1
- package/lib/api/bitcoin/enhanceSignTx.js +1 -1
- package/lib/api/bitcoin/inputs.js +3 -2
- package/lib/api/bitcoin/refTx.js +3 -3
- package/lib/api/bitcoin/signtxVerify.d.ts +1 -1
- package/lib/api/blockchainDisconnect.d.ts +1 -1
- package/lib/api/blockchainDisconnect.js +1 -1
- package/lib/api/blockchainEstimateFee.d.ts +1 -1
- package/lib/api/blockchainGetAccountBalanceHistory.d.ts +1 -1
- package/lib/api/blockchainGetCurrentFiatRates.d.ts +1 -1
- package/lib/api/blockchainGetFiatRatesForTimestamps.d.ts +1 -1
- package/lib/api/blockchainGetTransactions.d.ts +1 -1
- package/lib/api/blockchainSetCustomBackend.d.ts +1 -1
- package/lib/api/blockchainSetCustomBackend.js +1 -1
- package/lib/api/blockchainSubscribe.d.ts +1 -1
- package/lib/api/blockchainSubscribeFiatRates.d.ts +1 -1
- package/lib/api/blockchainUnsubscribe.d.ts +1 -1
- package/lib/api/blockchainUnsubscribeFiatRates.d.ts +1 -1
- package/lib/api/cardano/cardanoAuxiliaryData.d.ts +1 -1
- package/lib/api/cardano/cardanoAuxiliaryData.js +38 -16
- package/lib/api/cardano/cardanoCertificate.d.ts +2 -2
- package/lib/api/cardano/cardanoInputs.d.ts +3 -3
- package/lib/api/cardano/cardanoOutputs.d.ts +1 -1
- package/lib/api/cardano/cardanoTokenBundle.d.ts +1 -1
- package/lib/api/cardanoGetAddress.d.ts +1 -1
- package/lib/api/cardanoSignTransaction.d.ts +2 -1
- package/lib/api/cardanoSignTransaction.js +23 -3
- package/lib/api/common/Discovery.d.ts +2 -2
- package/lib/api/common/paramsValidator.d.ts +2 -2
- package/lib/api/composeTransaction.d.ts +1 -1
- package/lib/api/eos/eosSignTx.js +1 -1
- package/lib/api/eosSignTransaction.d.ts +1 -1
- package/lib/api/ethereumGetAddress.d.ts +1 -1
- package/lib/api/ethereumGetPublicKey.d.ts +1 -1
- package/lib/api/ethereumSignTransaction.d.ts +1 -1
- package/lib/api/ethereumSignTypedData.d.ts +1 -1
- package/lib/api/firmware/uploadFirmware.d.ts +2 -2
- package/lib/api/firmwareUpdate.d.ts +1 -1
- package/lib/api/firmwareUpdate.js +1 -1
- package/lib/api/getAccountInfo.d.ts +1 -1
- package/lib/api/getAddress.d.ts +1 -1
- package/lib/api/getCoinInfo.d.ts +2 -2
- package/lib/api/getOwnershipProof.d.ts +1 -5
- package/lib/api/getOwnershipProof.js +5 -3
- package/lib/api/getPublicKey.d.ts +1 -1
- package/lib/api/index.d.ts +1 -0
- package/lib/api/index.js +3 -1
- package/lib/api/nemGetAddress.d.ts +1 -1
- package/lib/api/pushTransaction.d.ts +1 -1
- package/lib/api/rippleGetAddress.d.ts +1 -1
- package/lib/api/setBusy.d.ts +7 -0
- package/lib/api/setBusy.js +31 -0
- package/lib/api/setProxy.js +3 -4
- package/lib/api/signTransaction.d.ts +2 -2
- package/lib/api/signTransaction.js +10 -3
- package/lib/api/stellarGetAddress.d.ts +1 -1
- package/lib/api/stellarSignTransaction.d.ts +1 -1
- package/lib/api/tezosGetAddress.d.ts +1 -1
- package/lib/backend/BackendManager.d.ts +21 -0
- package/lib/backend/BackendManager.js +87 -0
- package/lib/backend/Blockchain.d.ts +66 -0
- package/lib/backend/Blockchain.js +189 -0
- package/lib/backend/BlockchainLink.d.ts +6 -71
- package/lib/backend/BlockchainLink.js +12 -288
- package/lib/constants/cardano.d.ts +3 -1
- package/lib/constants/cardano.js +3 -1
- package/lib/constants/network.d.ts +1 -1
- package/lib/core/AbstractMethod.d.ts +5 -4
- package/lib/core/AbstractMethod.js +7 -5
- package/lib/core/index.d.ts +1 -1
- package/lib/core/index.js +3 -1
- package/lib/core/method.d.ts +1 -1
- package/lib/data/DataManager.d.ts +1 -1
- package/lib/data/analyticsInfo.d.ts +6 -0
- package/lib/data/analyticsInfo.js +37 -0
- package/lib/data/config.js +1 -1
- package/lib/data/version.d.ts +1 -1
- package/lib/data/version.js +1 -1
- package/lib/device/AbortController.d.ts +1 -1
- package/lib/device/DescriptorStream.d.ts +1 -1
- package/lib/device/Device.d.ts +2 -2
- package/lib/device/Device.js +11 -2
- package/lib/device/DeviceCommands.d.ts +8 -7
- package/lib/device/DeviceCommands.js +14 -1
- package/lib/device/DeviceList.d.ts +1 -1
- package/lib/events/blockchain.d.ts +4 -5
- package/lib/events/call.d.ts +10 -10
- package/lib/events/core.d.ts +3 -2
- package/lib/events/device.d.ts +3 -3
- package/lib/events/iframe.d.ts +2 -2
- package/lib/events/popup.d.ts +2 -2
- package/lib/events/transport.d.ts +3 -3
- package/lib/events/ui-promise.d.ts +2 -2
- package/lib/events/ui-request.d.ts +8 -6
- package/lib/events/ui-response.d.ts +2 -2
- package/lib/factory.js +1 -0
- package/lib/types/account.d.ts +2 -2
- package/lib/types/api/authorizeCoinJoin.d.ts +1 -0
- package/lib/types/api/binance/index.d.ts +1 -1
- package/lib/types/api/bitcoin/index.d.ts +6 -2
- package/lib/types/api/blockchainGetTransactions.d.ts +1 -1
- package/lib/types/api/blockchainSetCustomBackend.d.ts +1 -1
- package/lib/types/api/blockchainSubscribe.d.ts +1 -1
- package/lib/types/api/blockchainSubscribeFiatRates.d.ts +1 -1
- package/lib/types/api/cardano/index.d.ts +12 -5
- package/lib/types/api/composeTransaction.d.ts +3 -3
- package/lib/types/api/eos/index.d.ts +1 -1
- package/lib/types/api/getAddress.d.ts +1 -1
- package/lib/types/api/index.d.ts +2 -0
- package/lib/types/api/nem/index.d.ts +9 -9
- package/lib/types/api/off.d.ts +2 -2
- package/lib/types/api/on.d.ts +2 -2
- package/lib/types/api/pushTransaction.d.ts +1 -1
- package/lib/types/api/setBusy.d.ts +4 -0
- package/lib/types/api/setBusy.js +3 -0
- package/lib/types/api/setProxy.d.ts +1 -2
- package/lib/types/api/stellar/index.d.ts +2 -2
- package/lib/types/coinInfo.d.ts +3 -3
- package/lib/types/device.d.ts +13 -13
- package/lib/types/firmware.d.ts +3 -3
- package/lib/types/params.d.ts +3 -3
- package/lib/types/settings.d.ts +1 -2
- package/lib/types/utils.d.ts +2 -2
- package/lib/utils/accountUtils.d.ts +1 -1
- package/lib/utils/browserUtils.d.ts +2 -2
- package/lib/utils/debug.d.ts +1 -1
- package/lib/utils/deferred.d.ts +2 -2
- package/lib/utils/interactionTimeout.d.ts +1 -1
- package/lib/workers/RNUsbPlugin.d.ts +1 -1
- package/lib/workers/workers.d.ts +1 -1
- package/package.json +83 -78
- package/lib/utils/bufferUtils.d.ts +0 -3
- package/lib/utils/bufferUtils.js +0 -11
package/package.json
CHANGED
|
@@ -1,79 +1,84 @@
|
|
|
1
1
|
{
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
},
|
|
48
|
-
"
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
"
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
2
|
+
"name": "@trezor/connect",
|
|
3
|
+
"version": "9.0.5",
|
|
4
|
+
"author": "Trezor <info@trezor.io>",
|
|
5
|
+
"homepage": "https://github.com/trezor/trezor-suite/tree/develop/packages/connect",
|
|
6
|
+
"description": "High-level javascript interface for Trezor hardware wallet.",
|
|
7
|
+
"npmPublishAccess": "public",
|
|
8
|
+
"license": "SEE LICENSE IN LICENSE.md",
|
|
9
|
+
"repository": {
|
|
10
|
+
"type": "git",
|
|
11
|
+
"url": "git://github.com/trezor/trezor-suite.git"
|
|
12
|
+
},
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://github.com/trezor/trezor-suite/issues"
|
|
15
|
+
},
|
|
16
|
+
"keywords": [
|
|
17
|
+
"Trezor",
|
|
18
|
+
"trezor-connect",
|
|
19
|
+
"javascript"
|
|
20
|
+
],
|
|
21
|
+
"sideEffects": false,
|
|
22
|
+
"main": "lib/index",
|
|
23
|
+
"browser": {
|
|
24
|
+
"./lib/index": "./lib/index-browser",
|
|
25
|
+
"./lib/utils/assets": "./lib/utils/assets-browser",
|
|
26
|
+
"./lib/workers/workers": "./lib/workers/workers-browser"
|
|
27
|
+
},
|
|
28
|
+
"react-native": {
|
|
29
|
+
"./lib/index": "./lib/index",
|
|
30
|
+
"./lib/workers/workers": "./lib/workers/workers-react-native",
|
|
31
|
+
"./lib/utils/assets": "./lib/utils/assets-native"
|
|
32
|
+
},
|
|
33
|
+
"files": [
|
|
34
|
+
"lib/",
|
|
35
|
+
"!**/*.map"
|
|
36
|
+
],
|
|
37
|
+
"scripts": {
|
|
38
|
+
"lint:js": "yarn g:eslint '**/*.{ts,tsx,js}'",
|
|
39
|
+
"test:unit": "jest",
|
|
40
|
+
"type-check": "tsc --build",
|
|
41
|
+
"build:lib": "rimraf ./lib && yarn tsc --build tsconfig.lib.json",
|
|
42
|
+
"version:beta": "tsx scripts/bump-version.ts prerelease",
|
|
43
|
+
"version:patch": "tsx scripts/bump-version.ts patch",
|
|
44
|
+
"version:minor": "tsx scripts/bump-version.ts minor",
|
|
45
|
+
"version:major": "tsx scripts/bump-version.ts major",
|
|
46
|
+
"test:e2e:web": "ts-node -O '{\"module\": \"commonjs\"}' ./e2e/run.ts web",
|
|
47
|
+
"test:e2e:node": "ts-node -O '{\"module\": \"commonjs\"}' ./e2e/run.ts node",
|
|
48
|
+
"prepublishOnly": "yarn tsx ../../scripts/prepublishNPM.js",
|
|
49
|
+
"prepublish": "yarn tsx ../../scripts/prepublish.js"
|
|
50
|
+
},
|
|
51
|
+
"dependencies": {
|
|
52
|
+
"@trezor/blockchain-link": "^2.1.6",
|
|
53
|
+
"@trezor/connect-common": "0.0.11",
|
|
54
|
+
"@trezor/transport": "^1.1.6",
|
|
55
|
+
"@trezor/utils": "^9.0.4",
|
|
56
|
+
"@trezor/utxo-lib": "^1.0.2",
|
|
57
|
+
"bignumber.js": "^9.1.0",
|
|
58
|
+
"blakejs": "^1.2.1",
|
|
59
|
+
"bowser": "^2.11.0",
|
|
60
|
+
"cross-fetch": "^3.1.5",
|
|
61
|
+
"events": "^3.3.0",
|
|
62
|
+
"parse-uri": "1.0.7",
|
|
63
|
+
"randombytes": "2.1.0"
|
|
64
|
+
},
|
|
65
|
+
"devDependencies": {
|
|
66
|
+
"@trezor/connect-analytics": "1.0.0",
|
|
67
|
+
"@trezor/trezor-user-env-link": "1.0.0",
|
|
68
|
+
"@types/karma": "^6.3.3",
|
|
69
|
+
"@types/parse-uri": "^1.0.0",
|
|
70
|
+
"@types/randombytes": "^2.0.0",
|
|
71
|
+
"jest": "^26.6.3",
|
|
72
|
+
"karma": "^6.4.1",
|
|
73
|
+
"karma-babel-preprocessor": "^8.0.2",
|
|
74
|
+
"karma-chrome-launcher": "^3.1.1",
|
|
75
|
+
"karma-jasmine": "^5.1.0",
|
|
76
|
+
"karma-jasmine-async": "^0.0.1",
|
|
77
|
+
"karma-sourcemap-loader": "^0.3.8",
|
|
78
|
+
"karma-webpack": "^5.0.0",
|
|
79
|
+
"rimraf": "^3.0.2",
|
|
80
|
+
"ts-node": "^10.9.1",
|
|
81
|
+
"tsx": "^3.8.2",
|
|
82
|
+
"typescript": "4.9.3"
|
|
83
|
+
}
|
|
84
|
+
}
|
package/lib/utils/bufferUtils.js
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.reverseBuffer = void 0;
|
|
4
|
-
const reverseBuffer = (buf) => {
|
|
5
|
-
const copy = Buffer.alloc(buf.length);
|
|
6
|
-
buf.copy(copy);
|
|
7
|
-
[].reverse.call(copy);
|
|
8
|
-
return copy;
|
|
9
|
-
};
|
|
10
|
-
exports.reverseBuffer = reverseBuffer;
|
|
11
|
-
//# sourceMappingURL=bufferUtils.js.map
|