From 4dbd53281b0c6ea78422a2050d46d05249b29a77 Mon Sep 17 00:00:00 2001 From: Tomas Martykan Date: Mon, 12 May 2025 08:17:59 +0200 Subject: [PATCH] fix(connect): add @trezor/type-utils to dependencies --- packages/blockchain-link-types/package.json | 2 +- packages/blockchain-link-types/tsconfig.json | 4 ++-- packages/blockchain-link-types/tsconfig.lib.json | 4 ++-- packages/coinjoin/package.json | 3 +++ packages/coinjoin/src/client/CoinjoinPrison.ts | 2 +- packages/coinjoin/src/client/Status.ts | 2 +- packages/coinjoin/tsconfig.json | 3 ++- packages/connect-popup/package.json | 1 + packages/connect-popup/src/index.tsx | 2 +- packages/connect-popup/src/log.tsx | 2 +- packages/connect-popup/tsconfig.json | 3 ++- packages/connect-web/package.json | 1 + packages/connect-web/src/popup/index.ts | 2 +- packages/connect-web/tsconfig.json | 3 ++- packages/connect-web/tsconfig.lib.json | 3 +++ packages/connect/package.json | 1 + packages/connect/src/backend/BackendManager.ts | 2 +- packages/connect/tsconfig.json | 1 + packages/connect/tsconfig.lib.json | 3 +++ yarn.lock | 4 ++++ 20 files changed, 34 insertions(+), 14 deletions(-) diff --git a/packages/blockchain-link-types/package.json b/packages/blockchain-link-types/package.json index 2b8489b441..7935f97808 100644 --- a/packages/blockchain-link-types/package.json +++ b/packages/blockchain-link-types/package.json @@ -19,10 +19,10 @@ "prepublish": "yarn tsx ../../scripts/prepublish.js" }, "dependencies": { - "@trezor/type-utils": "workspace:*", "@trezor/utxo-lib": "workspace:*" }, "devDependencies": { + "@trezor/type-utils": "workspace:*", "tsx": "^4.19.3" }, "peerDependencies": { diff --git a/packages/blockchain-link-types/tsconfig.json b/packages/blockchain-link-types/tsconfig.json index 7954b4991c..25c2097d8e 100644 --- a/packages/blockchain-link-types/tsconfig.json +++ b/packages/blockchain-link-types/tsconfig.json @@ -2,7 +2,7 @@ "extends": "../../tsconfig.base.json", "compilerOptions": { "outDir": "libDev" }, "references": [ - { "path": "../type-utils" }, - { "path": "../utxo-lib" } + { "path": "../utxo-lib" }, + { "path": "../type-utils" } ] } diff --git a/packages/blockchain-link-types/tsconfig.lib.json b/packages/blockchain-link-types/tsconfig.lib.json index 3f6aa579d1..372feaf9fa 100644 --- a/packages/blockchain-link-types/tsconfig.lib.json +++ b/packages/blockchain-link-types/tsconfig.lib.json @@ -6,10 +6,10 @@ "include": ["./src"], "references": [ { - "path": "../type-utils" + "path": "../utxo-lib" }, { - "path": "../utxo-lib" + "path": "../type-utils" } ] } diff --git a/packages/coinjoin/package.json b/packages/coinjoin/package.json index a6ca08ffb5..37975834c2 100644 --- a/packages/coinjoin/package.json +++ b/packages/coinjoin/package.json @@ -34,5 +34,8 @@ "cross-fetch": "^4.0.0", "golomb": "1.2.0", "n64": "^0.2.10" + }, + "devDependencies": { + "@trezor/type-utils": "workspace:*" } } diff --git a/packages/coinjoin/src/client/CoinjoinPrison.ts b/packages/coinjoin/src/client/CoinjoinPrison.ts index 7ce94544df..37f7e094f2 100644 --- a/packages/coinjoin/src/client/CoinjoinPrison.ts +++ b/packages/coinjoin/src/client/CoinjoinPrison.ts @@ -1,4 +1,4 @@ -import { ImmediateId, TimerId } from '@trezor/type-utils'; +import type { ImmediateId, TimerId } from '@trezor/type-utils'; import { TypedEmitter } from '@trezor/utils'; import { WabiSabiProtocolErrorCode } from '../enums'; diff --git a/packages/coinjoin/src/client/Status.ts b/packages/coinjoin/src/client/Status.ts index 3d583d721e..a3c2ce5f5b 100644 --- a/packages/coinjoin/src/client/Status.ts +++ b/packages/coinjoin/src/client/Status.ts @@ -1,4 +1,4 @@ -import { TimerId } from '@trezor/type-utils'; +import type { TimerId } from '@trezor/type-utils'; import { TypedEmitter } from '@trezor/utils'; import * as coordinator from './coordinator'; diff --git a/packages/coinjoin/tsconfig.json b/packages/coinjoin/tsconfig.json index 0dc96bcb84..3c25836f5e 100644 --- a/packages/coinjoin/tsconfig.json +++ b/packages/coinjoin/tsconfig.json @@ -10,6 +10,7 @@ { "path": "../blockchain-link-utils" }, { "path": "../eslint" }, { "path": "../utils" }, - { "path": "../utxo-lib" } + { "path": "../utxo-lib" }, + { "path": "../type-utils" } ] } diff --git a/packages/connect-popup/package.json b/packages/connect-popup/package.json index f1abf3afa7..ec097224df 100644 --- a/packages/connect-popup/package.json +++ b/packages/connect-popup/package.json @@ -40,6 +40,7 @@ "@trezor/eslint": "workspace:*", "@trezor/node-utils": "workspace:*", "@trezor/trezor-user-env-link": "workspace:*", + "@trezor/type-utils": "workspace:*", "@types/react": "18.2.55", "babel-loader": "^10.0.0", "copy-webpack-plugin": "^12.0.2", diff --git a/packages/connect-popup/src/index.tsx b/packages/connect-popup/src/index.tsx index 6479bb1010..ceea1e914e 100644 --- a/packages/connect-popup/src/index.tsx +++ b/packages/connect-popup/src/index.tsx @@ -29,7 +29,7 @@ import { parseConnectSettings } from '@trezor/connect-iframe/src/connectSettings import { initLogWriterWithSrcPath } from '@trezor/connect-iframe/src/sharedLoggerUtils'; import { reactEventBus } from '@trezor/connect-ui/src/utils/eventBus'; import { ErrorViewProps } from '@trezor/connect-ui/src/views/Error'; -import { TimerId } from '@trezor/type-utils'; +import type { TimerId } from '@trezor/type-utils'; import { isPhishingDomain } from './utils/isPhishingDomain'; import * as view from './view'; diff --git a/packages/connect-popup/src/log.tsx b/packages/connect-popup/src/log.tsx index 934d2c183a..b0a731ab6d 100644 --- a/packages/connect-popup/src/log.tsx +++ b/packages/connect-popup/src/log.tsx @@ -9,7 +9,7 @@ import { InfoPanel } from '@trezor/connect-ui/src/components/InfoPanel'; import { View } from '@trezor/connect-ui/src/components/View'; import { ErrorBoundary } from '@trezor/connect-ui/src/support/ErrorBoundary'; import { GlobalStyle } from '@trezor/connect-ui/src/support/GlobalStyle'; -import { TimerId } from '@trezor/type-utils'; +import type { TimerId } from '@trezor/type-utils'; interface ReactWrapperProps { children: React.ReactNode; diff --git a/packages/connect-popup/tsconfig.json b/packages/connect-popup/tsconfig.json index 705ffc7d0b..0df8f5aebf 100644 --- a/packages/connect-popup/tsconfig.json +++ b/packages/connect-popup/tsconfig.json @@ -19,6 +19,7 @@ { "path": "../utils" }, { "path": "../eslint" }, { "path": "../node-utils" }, - { "path": "../trezor-user-env-link" } + { "path": "../trezor-user-env-link" }, + { "path": "../type-utils" } ] } diff --git a/packages/connect-web/package.json b/packages/connect-web/package.json index 1454d1a8c2..34b3fb02d9 100644 --- a/packages/connect-web/package.json +++ b/packages/connect-web/package.json @@ -53,6 +53,7 @@ "@playwright/browser-webkit": "^1.51.0", "@playwright/test": "^1.51.0", "@trezor/eslint": "workspace:*", + "@trezor/type-utils": "workspace:*", "@types/chrome": "^0.0.299", "@types/w3c-web-usb": "^1.0.10", "babel-loader": "^10.0.0", diff --git a/packages/connect-web/src/popup/index.ts b/packages/connect-web/src/popup/index.ts index 9f1111c7cf..95dd1d73b0 100644 --- a/packages/connect-web/src/popup/index.ts +++ b/packages/connect-web/src/popup/index.ts @@ -18,7 +18,7 @@ import { AbstractMessageChannel, Message, } from '@trezor/connect-common/src/messageChannel/abstract'; -import { IntervalId, TimerId } from '@trezor/type-utils'; +import type { IntervalId, TimerId } from '@trezor/type-utils'; import { Deferred, createDeferred, scheduleAction } from '@trezor/utils'; import { showPopupRequest } from './showPopupRequest'; diff --git a/packages/connect-web/tsconfig.json b/packages/connect-web/tsconfig.json index 08f6f4a130..78d0f55279 100644 --- a/packages/connect-web/tsconfig.json +++ b/packages/connect-web/tsconfig.json @@ -25,6 +25,7 @@ { "path": "../connect" }, { "path": "../connect-common" }, { "path": "../utils" }, - { "path": "../eslint" } + { "path": "../eslint" }, + { "path": "../type-utils" } ] } diff --git a/packages/connect-web/tsconfig.lib.json b/packages/connect-web/tsconfig.lib.json index b8202759e0..1fd339ccb6 100644 --- a/packages/connect-web/tsconfig.lib.json +++ b/packages/connect-web/tsconfig.lib.json @@ -17,6 +17,9 @@ }, { "path": "../eslint" + }, + { + "path": "../type-utils" } ] } diff --git a/packages/connect/package.json b/packages/connect/package.json index d7f53ebb0f..2fa6576dcd 100644 --- a/packages/connect/package.json +++ b/packages/connect/package.json @@ -90,6 +90,7 @@ "@trezor/protocol": "workspace:*", "@trezor/schema-utils": "workspace:*", "@trezor/transport": "workspace:*", + "@trezor/type-utils": "workspace:*", "@trezor/utils": "workspace:*", "@trezor/utxo-lib": "workspace:*", "blakejs": "^1.2.1", diff --git a/packages/connect/src/backend/BackendManager.ts b/packages/connect/src/backend/BackendManager.ts index 8d1e083f56..8837b29295 100644 --- a/packages/connect/src/backend/BackendManager.ts +++ b/packages/connect/src/backend/BackendManager.ts @@ -1,4 +1,4 @@ -import { TimerId } from '@trezor/type-utils'; +import type { TimerId } from '@trezor/type-utils'; import { ERRORS } from '../constants'; import { Blockchain, BlockchainOptions } from './Blockchain'; diff --git a/packages/connect/tsconfig.json b/packages/connect/tsconfig.json index 71694dc949..818e637b56 100644 --- a/packages/connect/tsconfig.json +++ b/packages/connect/tsconfig.json @@ -13,6 +13,7 @@ { "path": "../protocol" }, { "path": "../schema-utils" }, { "path": "../transport" }, + { "path": "../type-utils" }, { "path": "../utils" }, { "path": "../utxo-lib" }, { "path": "../eslint" }, diff --git a/packages/connect/tsconfig.lib.json b/packages/connect/tsconfig.lib.json index 0952e87b92..4e92cc60a8 100644 --- a/packages/connect/tsconfig.lib.json +++ b/packages/connect/tsconfig.lib.json @@ -36,6 +36,9 @@ { "path": "../transport" }, + { + "path": "../type-utils" + }, { "path": "../utils" }, diff --git a/yarn.lock b/yarn.lock index 4aecf1afec..2d288dbf74 100644 --- a/yarn.lock +++ b/yarn.lock @@ -11496,6 +11496,7 @@ __metadata: "@trezor/blockchain-link-types": "workspace:*" "@trezor/blockchain-link-utils": "workspace:*" "@trezor/eslint": "workspace:*" + "@trezor/type-utils": "workspace:*" "@trezor/utils": "workspace:*" "@trezor/utxo-lib": "workspace:*" cross-fetch: "npm:^4.0.0" @@ -11763,6 +11764,7 @@ __metadata: "@trezor/node-utils": "workspace:*" "@trezor/transport": "workspace:*" "@trezor/trezor-user-env-link": "workspace:*" + "@trezor/type-utils": "workspace:*" "@trezor/urls": "workspace:*" "@trezor/utils": "workspace:*" "@types/react": "npm:18.2.55" @@ -11827,6 +11829,7 @@ __metadata: "@trezor/connect": "workspace:*" "@trezor/connect-common": "workspace:*" "@trezor/eslint": "workspace:*" + "@trezor/type-utils": "workspace:*" "@trezor/utils": "workspace:*" "@types/chrome": "npm:^0.0.299" "@types/w3c-web-usb": "npm:^1.0.10" @@ -11899,6 +11902,7 @@ __metadata: "@trezor/schema-utils": "workspace:*" "@trezor/transport": "workspace:*" "@trezor/trezor-user-env-link": "workspace:*" + "@trezor/type-utils": "workspace:*" "@trezor/utils": "workspace:*" "@trezor/utxo-lib": "workspace:*" "@types/karma": "npm:^6.3.9"