From 44c7a270535afd576352974430033d15ea8d9783 Mon Sep 17 00:00:00 2001 From: Eugene Panteleymonchuk Date: Mon, 12 Aug 2024 15:13:19 +0300 Subject: [PATCH] feat(wallet): improve imports. Signed-off-by: Eugene Panteleymonchuk --- .../account-sources/AccountSource.ts | 4 +-- .../account-sources/MnemonicAccountSource.ts | 13 ++++---- .../account-sources/SeedAccountSource.ts | 10 +++---- .../src/background/account-sources/index.ts | 4 +-- .../wallet/src/background/accounts/Account.ts | 6 ++-- .../background/accounts/MnemonicAccount.ts | 2 +- .../src/background/accounts/SeedAccount.ts | 2 +- apps/wallet/src/background/accounts/index.ts | 14 ++++----- .../connections/ContentScriptConnection.ts | 4 +-- .../background/connections/UiConnection.ts | 30 ++++++++----------- .../BackgroundServiceSigner.ts | 2 +- .../src/ui/app/background-client/index.ts | 8 ++--- .../src/ui/app/components/DAppInfoCard.tsx | 6 ++-- .../ui/app/components/DAppPermissionsList.tsx | 2 +- .../ui/app/components/HideShowDisplayBox.tsx | 6 ++-- .../src/ui/app/components/IconButton.tsx | 2 +- .../src/ui/app/components/SectionHeader.tsx | 2 +- .../src/ui/app/components/SummaryCard.tsx | 2 +- .../ui/app/components/WalletListSelect.tsx | 4 +-- .../app/components/WalletListSelectItem.tsx | 2 +- .../accounts/AccountBalanceItem.tsx | 4 +-- .../app/components/accounts/AccountItem.tsx | 10 +++---- .../components/accounts/AccountListItem.tsx | 2 +- .../app/components/accounts/AccountsList.tsx | 8 ++--- .../components/accounts/AutoLockSelector.tsx | 8 ++--- .../accounts/EditableAccountName.tsx | 4 +-- .../ui/app/components/accounts/FooterLink.tsx | 2 +- .../accounts/ImportPrivateKeyForm.tsx | 8 ++--- .../accounts/ImportRecoveryPhraseForm.tsx | 2 +- .../components/accounts/ImportSeedForm.tsx | 6 ++-- .../components/accounts/LockUnlockButton.tsx | 4 +-- .../components/accounts/NicknameDialog.tsx | 10 +++---- .../accounts/PasswordInputDialog.tsx | 12 ++++---- .../accounts/ProtectAccountForm.tsx | 10 +++---- .../accounts/RecoverAccountsGroup.tsx | 6 ++-- .../accounts/UnlockAccountButton.tsx | 2 +- .../accounts/UnlockAccountContext.tsx | 4 +-- .../accounts/UnlockAccountModal.tsx | 2 +- .../ui/app/components/explorer-link/index.tsx | 4 +-- .../ui/app/components/iota-apps/Banner.tsx | 2 +- .../iota-apps/ConnectedAppsCard.tsx | 6 ++-- .../components/iota-apps/DisconnectApp.tsx | 14 ++++----- .../src/ui/app/components/iota-apps/index.tsx | 2 +- .../components/ledger/ConnectLedgerModal.tsx | 2 +- .../menu/button/WalletSettingsButton.tsx | 2 +- .../menu/content/AutoLockAccounts.tsx | 6 ++-- .../content/VerifyLedgerConnectionStatus.tsx | 4 +-- .../menu/content/WalletSettingsMenuList.tsx | 2 +- .../ui/app/components/navigation/index.tsx | 2 +- .../ui/app/components/nft-display/Kiosk.tsx | 4 +-- .../ui/app/components/nft-display/index.tsx | 4 +-- .../src/ui/app/components/overlay/index.tsx | 6 ++-- .../components/receipt-card/StakeTxnCard.tsx | 2 +- .../receipt-card/UnstakeTxnCard.tsx | 2 +- .../ui/app/components/receipt-card/index.tsx | 8 ++--- .../components/transactions-card/TxnIcon.tsx | 2 +- .../user-approve-container/index.tsx | 8 ++--- .../src/ui/app/helpers/errorMessages.ts | 2 +- apps/wallet/src/ui/app/helpers/sentry.ts | 2 +- .../src/ui/app/hooks/useAccountGroups.ts | 2 +- apps/wallet/src/ui/app/hooks/useAccounts.ts | 2 +- .../src/ui/app/hooks/useAccountsFinder.ts | 4 +-- .../src/ui/app/hooks/useAutoLockMinutes.ts | 2 +- .../src/ui/app/hooks/useBackgroundClient.ts | 2 +- .../ui/app/hooks/useCreateAccountMutation.ts | 2 +- .../src/ui/app/hooks/useExplorerLink.ts | 4 +-- apps/wallet/src/ui/app/hooks/useGetNFTs.ts | 2 +- .../src/ui/app/hooks/useInitialPageView.ts | 2 +- .../ui/app/hooks/useRecoveryDataMutation.ts | 2 +- .../ui/app/hooks/useResetPasswordMutation.ts | 2 +- apps/wallet/src/ui/app/hooks/useSigner.ts | 8 ++--- .../src/ui/app/hooks/useUnlockMutation.ts | 2 +- .../src/ui/app/hooks/useUnlockedGuard.ts | 4 +-- .../src/ui/app/pages/StorageMigrationPage.tsx | 12 ++++---- .../ui/app/pages/accounts/AddAccountPage.tsx | 15 ++++------ .../app/pages/accounts/BackupMnemonicPage.tsx | 6 ++-- .../app/pages/accounts/ExportAccountPage.tsx | 12 ++++---- .../pages/accounts/ExportPassphrasePage.tsx | 10 +++---- .../ui/app/pages/accounts/ExportSeedPage.tsx | 10 +++---- .../accounts/ImportLedgerAccountsPage.tsx | 15 ++++------ .../pages/accounts/ImportPassphrasePage.tsx | 9 ++---- .../pages/accounts/ImportPrivateKeyPage.tsx | 9 ++---- .../ui/app/pages/accounts/ImportSeedPage.tsx | 9 ++---- .../app/pages/accounts/ProtectAccountPage.tsx | 20 ++++++------- .../src/ui/app/pages/accounts/WelcomePage.tsx | 2 +- .../ForgotPasswordIndexPage.tsx | 2 +- .../forgot-password/RecoverManyPage.tsx | 12 ++++---- .../accounts/forgot-password/RecoverPage.tsx | 6 ++-- .../forgot-password/ResetPasswordPage.tsx | 6 ++-- .../forgot-password/ResetWarningPage.tsx | 10 +++---- .../accounts/manage/ManageAccountsPage.tsx | 2 +- .../accounts-finder/AccountsFinderPage.tsx | 2 +- .../approval-request/SignMessageRequest.tsx | 16 +++++----- .../ui/app/pages/approval-request/index.tsx | 8 ++--- .../transaction-request/SummaryCard.tsx | 2 +- .../TransactionDetails/index.tsx | 2 +- .../transaction-request/index.tsx | 2 +- .../src/ui/app/pages/home/assets/index.tsx | 2 +- .../hidden-assets/HiddenAssetsProvider.tsx | 2 +- .../ui/app/pages/home/interstitial/index.tsx | 2 +- .../ui/app/pages/home/nfts/VisualAssets.tsx | 2 +- .../src/ui/app/pages/home/nfts/index.tsx | 2 +- .../app/pages/home/tokens/TokensDetails.tsx | 2 +- .../src/ui/app/pages/restricted/index.tsx | 4 +-- .../src/ui/app/pages/site-connect/index.tsx | 12 ++++---- .../src/ui/app/shared/InputWithAction.tsx | 2 +- .../src/ui/app/shared/dapp-status/index.tsx | 4 +-- .../ui/app/shared/faucet/useFaucetMutation.ts | 2 +- .../src/ui/app/shared/forms/FormField.tsx | 2 +- .../shared/forms/controls/PasswordInput.tsx | 2 +- .../src/ui/app/shared/header/Header.tsx | 2 +- .../page-main-layout/PageMainLayout.tsx | 12 ++++---- .../page-main-layout/PageMainLayoutTitle.tsx | 2 +- .../src/ui/app/shared/toaster/index.tsx | 2 +- .../transaction-summary/OwnerFooter.tsx | 2 +- .../cards/BalanceChanges.tsx | 4 +-- .../transaction-summary/cards/CoinStack.tsx | 2 +- .../cards/ExplorerLink.tsx | 4 +-- .../transaction-summary/cards/GasSummary.tsx | 2 +- .../cards/ObjectChanges.tsx | 6 ++-- .../transaction-summary/cards/SummaryCard.tsx | 2 +- .../transaction-summary/cards/TotalAmount.tsx | 2 +- .../objectSummary/ObjectChangeDisplay.tsx | 2 +- .../app/shared/transaction-summary/index.tsx | 4 +-- .../src/ui/app/shared/utils/ButtonOrLink.tsx | 4 +-- .../DelegationDetailCard.tsx | 8 ++--- .../app/staking/delegation-detail/index.tsx | 6 ++-- .../src/ui/app/staking/home/StakedCard.tsx | 2 +- apps/wallet/src/ui/app/staking/home/index.tsx | 8 ++--- .../src/ui/app/staking/stake/StakeForm.tsx | 2 +- .../src/ui/app/staking/stake/StakingCard.tsx | 12 ++++---- .../src/ui/app/staking/stake/UnstakeForm.tsx | 6 ++-- .../app/staking/stake/ValidatorFormDetail.tsx | 10 +++---- .../wallet/src/ui/app/staking/stake/index.tsx | 2 +- .../app/staking/validators/ValidatorsCard.tsx | 6 ++-- .../src/ui/app/staking/validators/index.tsx | 2 +- 136 files changed, 344 insertions(+), 366 deletions(-) diff --git a/apps/wallet/src/background/account-sources/AccountSource.ts b/apps/wallet/src/background/account-sources/AccountSource.ts index 6e1913f02ad..47cf674fcb1 100644 --- a/apps/wallet/src/background/account-sources/AccountSource.ts +++ b/apps/wallet/src/background/account-sources/AccountSource.ts @@ -4,12 +4,12 @@ import { type Serializable } from '_src/shared/cryptography/keystore'; -import { getDB } from '_src/background/db'; +import { getDB } from '../db'; import { clearEphemeralValue, getEphemeralValue, setEphemeralValue, -} from '_src/background/session-ephemeral-values'; +} from '../session-ephemeral-values'; export enum AccountSourceType { Mnemonic = 'mnemonic', diff --git a/apps/wallet/src/background/account-sources/MnemonicAccountSource.ts b/apps/wallet/src/background/account-sources/MnemonicAccountSource.ts index 8199372d066..ef25aaf851e 100644 --- a/apps/wallet/src/background/account-sources/MnemonicAccountSource.ts +++ b/apps/wallet/src/background/account-sources/MnemonicAccountSource.ts @@ -18,14 +18,11 @@ import { bytesToHex } from '@noble/hashes/utils'; import Dexie from 'dexie'; import { getAccountSources } from '.'; -import { getAllAccounts } from '_src/background/accounts'; -import { - MnemonicAccount, - type MnemonicSerializedAccount, -} from '_src/background/accounts/MnemonicAccount'; -import { setupAutoLockAlarm } from '_src/background/auto-lock-accounts'; -import { backupDB, getDB } from '_src/background/db'; -import { makeUniqueKey } from '_src/background/storage-utils'; +import { getAllAccounts } from '../accounts'; +import { MnemonicAccount, type MnemonicSerializedAccount } from '../accounts/MnemonicAccount'; +import { setupAutoLockAlarm } from '../auto-lock-accounts'; +import { backupDB, getDB } from '../db'; +import { makeUniqueKey } from '../storage-utils'; import { AccountSource, AccountSourceType, diff --git a/apps/wallet/src/background/account-sources/SeedAccountSource.ts b/apps/wallet/src/background/account-sources/SeedAccountSource.ts index 6262601167c..e74e71897e5 100644 --- a/apps/wallet/src/background/account-sources/SeedAccountSource.ts +++ b/apps/wallet/src/background/account-sources/SeedAccountSource.ts @@ -8,11 +8,11 @@ import { bytesToHex } from '@noble/hashes/utils'; import Dexie from 'dexie'; import { getAccountSources } from '.'; -import { getAllAccounts } from '_src/background/accounts'; -import { SeedAccount, type SeedSerializedAccount } from '_src/background/accounts/SeedAccount'; -import { setupAutoLockAlarm } from '_src/background/auto-lock-accounts'; -import { backupDB, getDB } from '_src/background/db'; -import { makeUniqueKey } from '_src/background/storage-utils'; +import { getAllAccounts } from '../accounts'; +import { SeedAccount, type SeedSerializedAccount } from '../accounts/SeedAccount'; +import { setupAutoLockAlarm } from '../auto-lock-accounts'; +import { backupDB, getDB } from '../db'; +import { makeUniqueKey } from '../storage-utils'; import { AccountSource, AccountSourceType, diff --git a/apps/wallet/src/background/account-sources/index.ts b/apps/wallet/src/background/account-sources/index.ts index bd383224de7..e22684b6a71 100644 --- a/apps/wallet/src/background/account-sources/index.ts +++ b/apps/wallet/src/background/account-sources/index.ts @@ -8,8 +8,8 @@ import { type MethodPayload, } from '_src/shared/messaging/messages/payloads/MethodPayload'; -import { type UiConnection } from '_src/background/connections/UiConnection'; -import { getDB } from '_src/background/db'; +import { type UiConnection } from '../connections/UiConnection'; +import { getDB } from '../db'; import { AccountSourceType, type AccountSourceSerialized } from './AccountSource'; import { MnemonicAccountSource } from './MnemonicAccountSource'; import { SeedAccountSource } from './SeedAccountSource'; diff --git a/apps/wallet/src/background/accounts/Account.ts b/apps/wallet/src/background/accounts/Account.ts index eef646d47c0..abbfbc8a5b3 100644 --- a/apps/wallet/src/background/accounts/Account.ts +++ b/apps/wallet/src/background/accounts/Account.ts @@ -10,13 +10,13 @@ import { } from '@iota/iota.js/cryptography'; import { blake2b } from '@noble/hashes/blake2b'; -import { setupAutoLockAlarm } from '_src/background/auto-lock-accounts'; -import { getDB } from '_src/background/db'; +import { setupAutoLockAlarm } from '../auto-lock-accounts'; +import { getDB } from '../db'; import { clearEphemeralValue, getEphemeralValue, setEphemeralValue, -} from '_src/background/session-ephemeral-values'; +} from '../session-ephemeral-values'; import { accountsEvents } from './events'; export enum AccountType { diff --git a/apps/wallet/src/background/accounts/MnemonicAccount.ts b/apps/wallet/src/background/accounts/MnemonicAccount.ts index 920e9d564a9..9bb5748743d 100644 --- a/apps/wallet/src/background/accounts/MnemonicAccount.ts +++ b/apps/wallet/src/background/accounts/MnemonicAccount.ts @@ -5,7 +5,7 @@ import { fromExportedKeypair } from '_src/shared/utils'; import { type Keypair } from '@iota/iota.js/cryptography'; -import { MnemonicAccountSource } from '_src/background/account-sources/MnemonicAccountSource'; +import { MnemonicAccountSource } from '../account-sources/MnemonicAccountSource'; import { Account, AccountType, diff --git a/apps/wallet/src/background/accounts/SeedAccount.ts b/apps/wallet/src/background/accounts/SeedAccount.ts index 50303a027ca..3171192cd68 100644 --- a/apps/wallet/src/background/accounts/SeedAccount.ts +++ b/apps/wallet/src/background/accounts/SeedAccount.ts @@ -4,7 +4,7 @@ import { fromExportedKeypair } from '_src/shared/utils'; import { type Keypair } from '@iota/iota.js/cryptography'; -import { SeedAccountSource } from '_src/background/account-sources/SeedAccountSource'; +import { SeedAccountSource } from '../account-sources/SeedAccountSource'; import { Account, AccountType, diff --git a/apps/wallet/src/background/accounts/index.ts b/apps/wallet/src/background/accounts/index.ts index 8085bdfdf99..880ef5dfef5 100644 --- a/apps/wallet/src/background/accounts/index.ts +++ b/apps/wallet/src/background/accounts/index.ts @@ -11,13 +11,13 @@ import { type WalletStatusChange } from '_src/shared/messaging/messages/payloads import { fromB64 } from '@iota/iota.js/utils'; import Dexie from 'dexie'; -import { getAccountSourceByID } from '_src/background/account-sources'; -import { accountSourcesEvents } from '_src/background/account-sources/events'; -import { MnemonicAccountSource } from '_src/background/account-sources/MnemonicAccountSource'; -import { SeedAccountSource } from '_src/background/account-sources/SeedAccountSource'; -import { type UiConnection } from '_src/background/connections/UiConnection'; -import { backupDB, getDB } from '_src/background/db'; -import { makeUniqueKey } from '_src/background/storage-utils'; +import { getAccountSourceByID } from '../account-sources'; +import { accountSourcesEvents } from '../account-sources/events'; +import { MnemonicAccountSource } from '../account-sources/MnemonicAccountSource'; +import { SeedAccountSource } from '../account-sources/SeedAccountSource'; +import { type UiConnection } from '../connections/UiConnection'; +import { backupDB, getDB } from '../db'; +import { makeUniqueKey } from '../storage-utils'; import { AccountType, isKeyPairExportableAccount, diff --git a/apps/wallet/src/background/connections/ContentScriptConnection.ts b/apps/wallet/src/background/connections/ContentScriptConnection.ts index 982645d95ad..6427bbe6f81 100644 --- a/apps/wallet/src/background/connections/ContentScriptConnection.ts +++ b/apps/wallet/src/background/connections/ContentScriptConnection.ts @@ -33,8 +33,8 @@ import { type SignedTransaction } from '_src/ui/app/WalletSigner'; import { type IotaTransactionBlockResponse } from '@iota/iota.js/client'; import type { Runtime } from 'webextension-polyfill'; -import { getAccountsStatusData } from '_src/background/accounts'; -import NetworkEnv from '_src/background/NetworkEnv'; +import { getAccountsStatusData } from '../accounts'; +import NetworkEnv from '../NetworkEnv'; import { Connection } from './Connection'; export class ContentScriptConnection extends Connection { diff --git a/apps/wallet/src/background/connections/UiConnection.ts b/apps/wallet/src/background/connections/UiConnection.ts index 35dae5ac16e..63cdbf79e19 100644 --- a/apps/wallet/src/background/connections/UiConnection.ts +++ b/apps/wallet/src/background/connections/UiConnection.ts @@ -35,30 +35,26 @@ import { accountSourcesHandleUIMessage, getAccountSourceByID, getAllSerializedUIAccountSources, -} from '_src/background/account-sources'; -import { accountSourcesEvents } from '_src/background/account-sources/events'; -import { MnemonicAccountSource } from '_src/background/account-sources/MnemonicAccountSource'; +} from '../account-sources'; +import { accountSourcesEvents } from '../account-sources/events'; +import { MnemonicAccountSource } from '../account-sources/MnemonicAccountSource'; import { accountsHandleUIMessage, addNewAccounts, getAccountsByAddress, getAllSerializedUIAccounts, -} from '_src/background/accounts'; -import { accountsEvents } from '_src/background/accounts/events'; -import { - getAutoLockMinutes, - notifyUserActive, - setAutoLockMinutes, -} from '_src/background/auto-lock-accounts'; -import { backupDB, getDB, SETTINGS_KEYS } from '_src/background/db'; -import { clearStatus, doMigration, getStatus } from '_src/background/storage-migration'; -import NetworkEnv from '_src/background/NetworkEnv'; +} from '../accounts'; +import { accountsEvents } from '../accounts/events'; +import { getAutoLockMinutes, notifyUserActive, setAutoLockMinutes } from '../auto-lock-accounts'; +import { backupDB, getDB, SETTINGS_KEYS } from '../db'; +import { clearStatus, doMigration, getStatus } from '../storage-migration'; +import NetworkEnv from '../NetworkEnv'; import { Connection } from './Connection'; -import { SeedAccountSource } from '_src/background/account-sources/SeedAccountSource'; -import { AccountSourceType } from '_src/background/account-sources/AccountSource'; +import { SeedAccountSource } from '../account-sources/SeedAccountSource'; +import { AccountSourceType } from '../account-sources/AccountSource'; import { isDeriveBipPathAccountsFinder, isPersistAccountsFinder } from '_payloads/accounts-finder'; -import type { SerializedAccount } from '_src/background/accounts/Account'; -import { LedgerAccount } from '_src/background/accounts/LedgerAccount'; +import type { SerializedAccount } from '../accounts/Account'; +import { LedgerAccount } from '../accounts/LedgerAccount'; export class UiConnection extends Connection { public static readonly CHANNEL: PortChannelName = 'iota_ui<->background'; diff --git a/apps/wallet/src/ui/app/background-client/BackgroundServiceSigner.ts b/apps/wallet/src/ui/app/background-client/BackgroundServiceSigner.ts index cc38616e17c..2b91458ac79 100644 --- a/apps/wallet/src/ui/app/background-client/BackgroundServiceSigner.ts +++ b/apps/wallet/src/ui/app/background-client/BackgroundServiceSigner.ts @@ -7,7 +7,7 @@ import { type IotaClient } from '@iota/iota.js/client'; import type { SerializedSignature } from '@iota/iota.js/cryptography'; import type { BackgroundClient } from '.'; -import { WalletSigner } from '../WalletSigner'; +import { WalletSigner } from '_app/WalletSigner'; export class BackgroundServiceSigner extends WalletSigner { readonly #account: SerializedUIAccount; diff --git a/apps/wallet/src/ui/app/background-client/index.ts b/apps/wallet/src/ui/app/background-client/index.ts index b6dcff12d7e..6a445810e70 100644 --- a/apps/wallet/src/ui/app/background-client/index.ts +++ b/apps/wallet/src/ui/app/background-client/index.ts @@ -34,10 +34,10 @@ import { toB64 } from '@iota/iota.js/utils'; import { type QueryKey } from '@tanstack/react-query'; import { lastValueFrom, map, take } from 'rxjs'; -import { growthbook } from '../experimentation/feature-gating'; -import { ACCOUNTS_QUERY_KEY } from '../helpers/query-client-keys'; -import { queryClient } from '../helpers/queryClient'; -import { ACCOUNT_SOURCES_QUERY_KEY } from '../hooks/useAccountSources'; +import { growthbook } from '_app/experimentation/feature-gating'; +import { ACCOUNTS_QUERY_KEY } from '_app/helpers/query-client-keys'; +import { queryClient } from '_app/helpers/queryClient'; +import { ACCOUNT_SOURCES_QUERY_KEY } from '_app/hooks/useAccountSources'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; import { type DeriveBipPathAccountsFinder, diff --git a/apps/wallet/src/ui/app/components/DAppInfoCard.tsx b/apps/wallet/src/ui/app/components/DAppInfoCard.tsx index aab81deed46..511df5b25cf 100644 --- a/apps/wallet/src/ui/app/components/DAppInfoCard.tsx +++ b/apps/wallet/src/ui/app/components/DAppInfoCard.tsx @@ -7,9 +7,9 @@ import { getValidDAppUrl } from '_src/shared/utils'; import { CheckFill16 } from '@iota/icons'; import cn from 'clsx'; -import { useAccountByAddress } from '../hooks/useAccountByAddress'; -import { Heading } from '../shared/heading'; -import { Link } from '../shared/Link'; +import { useAccountByAddress } from '_app/hooks/useAccountByAddress'; +import { Heading } from '_app/shared/heading'; +import { Link } from '_app/shared/Link'; import { AccountIcon } from './accounts/AccountIcon'; import { AccountItem } from './accounts/AccountItem'; import { LockUnlockButton } from './accounts/LockUnlockButton'; diff --git a/apps/wallet/src/ui/app/components/DAppPermissionsList.tsx b/apps/wallet/src/ui/app/components/DAppPermissionsList.tsx index df2a85aef4f..30325dcc1f3 100644 --- a/apps/wallet/src/ui/app/components/DAppPermissionsList.tsx +++ b/apps/wallet/src/ui/app/components/DAppPermissionsList.tsx @@ -5,7 +5,7 @@ import type { PermissionType } from '_messages/payloads/permissions'; import { CheckFill12 } from '@iota/icons'; -import { Text } from '../shared/text'; +import { Text } from '_app/shared/text'; export interface DAppPermissionsListProps { permissions: PermissionType[]; diff --git a/apps/wallet/src/ui/app/components/HideShowDisplayBox.tsx b/apps/wallet/src/ui/app/components/HideShowDisplayBox.tsx index eff9ace3fe7..7d172303a76 100644 --- a/apps/wallet/src/ui/app/components/HideShowDisplayBox.tsx +++ b/apps/wallet/src/ui/app/components/HideShowDisplayBox.tsx @@ -6,9 +6,9 @@ import { Copy16, EyeClose16, EyeOpen16 } from '@iota/icons'; import { cx } from 'class-variance-authority'; import { useEffect, useState } from 'react'; -import { useCopyToClipboard } from '../hooks/useCopyToClipboard'; -import { Link } from '../shared/Link'; -import { Text } from '../shared/text'; +import { useCopyToClipboard } from '_app/hooks/useCopyToClipboard'; +import { Link } from '_app/shared/Link'; +import { Text } from '_app/shared/text'; const AUTO_HIDE_INTERVAL = 3 * 60 * 1000; diff --git a/apps/wallet/src/ui/app/components/IconButton.tsx b/apps/wallet/src/ui/app/components/IconButton.tsx index a49f4014c53..8bc14925e3d 100644 --- a/apps/wallet/src/ui/app/components/IconButton.tsx +++ b/apps/wallet/src/ui/app/components/IconButton.tsx @@ -4,7 +4,7 @@ import { cva, type VariantProps } from 'class-variance-authority'; -import { ButtonOrLink, type ButtonOrLinkProps } from '../shared/utils/ButtonOrLink'; +import { ButtonOrLink, type ButtonOrLinkProps } from '_app/shared/utils/ButtonOrLink'; interface IconButtonProps extends ButtonOrLinkProps, VariantProps { icon: JSX.Element; diff --git a/apps/wallet/src/ui/app/components/SectionHeader.tsx b/apps/wallet/src/ui/app/components/SectionHeader.tsx index c36ebd91410..178c0464b93 100644 --- a/apps/wallet/src/ui/app/components/SectionHeader.tsx +++ b/apps/wallet/src/ui/app/components/SectionHeader.tsx @@ -2,7 +2,7 @@ // Modifications Copyright (c) 2024 IOTA Stiftung // SPDX-License-Identifier: Apache-2.0 -import { Text } from '../shared/text'; +import { Text } from '_app/shared/text'; interface SectionHeaderProps { title: string; diff --git a/apps/wallet/src/ui/app/components/SummaryCard.tsx b/apps/wallet/src/ui/app/components/SummaryCard.tsx index debc78d3724..b93dcfffe8f 100644 --- a/apps/wallet/src/ui/app/components/SummaryCard.tsx +++ b/apps/wallet/src/ui/app/components/SummaryCard.tsx @@ -5,7 +5,7 @@ import clsx from 'clsx'; import type { ReactNode } from 'react'; -import { Text } from '../shared/text'; +import { Text } from '_app/shared/text'; export interface SummaryCardProps { header?: string; diff --git a/apps/wallet/src/ui/app/components/WalletListSelect.tsx b/apps/wallet/src/ui/app/components/WalletListSelect.tsx index e3be7e2d962..d4763e91388 100644 --- a/apps/wallet/src/ui/app/components/WalletListSelect.tsx +++ b/apps/wallet/src/ui/app/components/WalletListSelect.tsx @@ -5,8 +5,8 @@ import { cx } from 'class-variance-authority'; import { useMemo } from 'react'; -import { useAccounts } from '../hooks/useAccounts'; -import { Link } from '../shared/Link'; +import { useAccounts } from '_app/hooks/useAccounts'; +import { Link } from '_app/shared/Link'; import { SummaryCard } from './SummaryCard'; import { WalletListSelectItem, type WalletListSelectItemProps } from './WalletListSelectItem'; diff --git a/apps/wallet/src/ui/app/components/WalletListSelectItem.tsx b/apps/wallet/src/ui/app/components/WalletListSelectItem.tsx index 0fcf45a9aa6..3d0e2bfc000 100644 --- a/apps/wallet/src/ui/app/components/WalletListSelectItem.tsx +++ b/apps/wallet/src/ui/app/components/WalletListSelectItem.tsx @@ -7,7 +7,7 @@ import { formatAddress } from '@iota/iota.js/utils'; import { cva, cx, type VariantProps } from 'class-variance-authority'; import { useEffect, useRef } from 'react'; -import { Text } from '../shared/text'; +import { Text } from '_app/shared/text'; const styles = cva('transition flex flex-row flex-nowrap items-center gap-3 py-2 cursor-pointer', { variants: { diff --git a/apps/wallet/src/ui/app/components/accounts/AccountBalanceItem.tsx b/apps/wallet/src/ui/app/components/accounts/AccountBalanceItem.tsx index 6ffc864ac6d..43459a1005d 100644 --- a/apps/wallet/src/ui/app/components/accounts/AccountBalanceItem.tsx +++ b/apps/wallet/src/ui/app/components/accounts/AccountBalanceItem.tsx @@ -4,8 +4,8 @@ import { Copy12 } from '@iota/icons'; import { Text } from '_src/ui/app/shared/text'; import { formatAddress } from '@iota/iota.js/utils'; -import { useCopyToClipboard } from '../../hooks/useCopyToClipboard'; -import { IconButton } from '../IconButton'; +import { useCopyToClipboard } from '_app/hooks/useCopyToClipboard'; +import { IconButton } from '_components/IconButton'; import { type SerializedUIAccount } from '_src/background/accounts/Account'; import { useBalance, useFormatCoin } from '@iota/core'; diff --git a/apps/wallet/src/ui/app/components/accounts/AccountItem.tsx b/apps/wallet/src/ui/app/components/accounts/AccountItem.tsx index 8ee227e3d37..70b219d7cc7 100644 --- a/apps/wallet/src/ui/app/components/accounts/AccountItem.tsx +++ b/apps/wallet/src/ui/app/components/accounts/AccountItem.tsx @@ -9,11 +9,11 @@ import { formatAddress } from '@iota/iota.js/utils'; import cn from 'clsx'; import { forwardRef, type ReactNode } from 'react'; -import { useAccounts } from '../../hooks/useAccounts'; -import { useCopyToClipboard } from '../../hooks/useCopyToClipboard'; -import { useExplorerLink } from '../../hooks/useExplorerLink'; -import { ExplorerLinkType } from '../explorer-link/ExplorerLinkType'; -import { IconButton } from '../IconButton'; +import { useAccounts } from '_app/hooks/useAccounts'; +import { useCopyToClipboard } from '_app/hooks/useCopyToClipboard'; +import { useExplorerLink } from '_app/hooks/useExplorerLink'; +import { ExplorerLinkType } from '_components/explorer-link/ExplorerLinkType'; +import { IconButton } from '_components/IconButton'; import { EditableAccountName } from './EditableAccountName'; interface AccountItemProps { diff --git a/apps/wallet/src/ui/app/components/accounts/AccountListItem.tsx b/apps/wallet/src/ui/app/components/accounts/AccountListItem.tsx index 0fb5d5796d2..081e52911f7 100644 --- a/apps/wallet/src/ui/app/components/accounts/AccountListItem.tsx +++ b/apps/wallet/src/ui/app/components/accounts/AccountListItem.tsx @@ -4,7 +4,7 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; -import { useActiveAccount } from '../../hooks/useActiveAccount'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; import { AccountIcon } from './AccountIcon'; import { AccountItem } from './AccountItem'; import { LockUnlockButton } from './LockUnlockButton'; diff --git a/apps/wallet/src/ui/app/components/accounts/AccountsList.tsx b/apps/wallet/src/ui/app/components/accounts/AccountsList.tsx index eb21c7fa001..5dd1cadda6d 100644 --- a/apps/wallet/src/ui/app/components/accounts/AccountsList.tsx +++ b/apps/wallet/src/ui/app/components/accounts/AccountsList.tsx @@ -8,10 +8,10 @@ import { Filter16, Plus12 } from '@iota/icons'; import * as ToggleGroup from '@radix-ui/react-toggle-group'; import { useMemo, useState } from 'react'; -import { useAccountGroups } from '../../hooks/useAccountGroups'; -import { useActiveAccount } from '../../hooks/useActiveAccount'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { Heading } from '../../shared/heading'; +import { useAccountGroups } from '_app/hooks/useAccountGroups'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { Heading } from '_app/shared/heading'; import { AccountListItem } from './AccountListItem'; import { FooterLink } from './FooterLink'; diff --git a/apps/wallet/src/ui/app/components/accounts/AutoLockSelector.tsx b/apps/wallet/src/ui/app/components/accounts/AutoLockSelector.tsx index d384b35fbeb..c7f5808f319 100644 --- a/apps/wallet/src/ui/app/components/accounts/AutoLockSelector.tsx +++ b/apps/wallet/src/ui/app/components/accounts/AutoLockSelector.tsx @@ -6,10 +6,10 @@ import { useEffect } from 'react'; import { useFormContext } from 'react-hook-form'; import { z } from 'zod'; -import { CheckboxField } from '../../shared/forms/CheckboxField'; -import { Input } from '../../shared/forms/controls/Input'; -import FormField from '../../shared/forms/FormField'; -import { SelectField } from '../../shared/forms/SelectField'; +import { CheckboxField } from '_app/shared/forms/CheckboxField'; +import { Input } from '_app/shared/forms/controls/Input'; +import FormField from '_app/shared/forms/FormField'; +import { SelectField } from '_app/shared/forms/SelectField'; const LOCK_INTERVALS = [ { id: 'day', label: 'Day' }, diff --git a/apps/wallet/src/ui/app/components/accounts/EditableAccountName.tsx b/apps/wallet/src/ui/app/components/accounts/EditableAccountName.tsx index c2be5bedfee..412d265eabe 100644 --- a/apps/wallet/src/ui/app/components/accounts/EditableAccountName.tsx +++ b/apps/wallet/src/ui/app/components/accounts/EditableAccountName.tsx @@ -7,8 +7,8 @@ import { forwardRef, useRef } from 'react'; import toast from 'react-hot-toast'; import { z } from 'zod'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { Form } from '../../shared/forms/Form'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { Form } from '_app/shared/forms/Form'; interface InputProps extends Omit, 'className'> {} diff --git a/apps/wallet/src/ui/app/components/accounts/FooterLink.tsx b/apps/wallet/src/ui/app/components/accounts/FooterLink.tsx index 495e1e31084..17d6946e352 100644 --- a/apps/wallet/src/ui/app/components/accounts/FooterLink.tsx +++ b/apps/wallet/src/ui/app/components/accounts/FooterLink.tsx @@ -4,7 +4,7 @@ import { forwardRef } from 'react'; -import { Link, type LinkProps } from '../../shared/Link'; +import { Link, type LinkProps } from '_app/shared/Link'; interface FooterLinkProps extends LinkProps { icon?: React.ReactNode; diff --git a/apps/wallet/src/ui/app/components/accounts/ImportPrivateKeyForm.tsx b/apps/wallet/src/ui/app/components/accounts/ImportPrivateKeyForm.tsx index 4fdee465cb5..c7c8d5f0cc7 100644 --- a/apps/wallet/src/ui/app/components/accounts/ImportPrivateKeyForm.tsx +++ b/apps/wallet/src/ui/app/components/accounts/ImportPrivateKeyForm.tsx @@ -8,10 +8,10 @@ import { type SubmitHandler } from 'react-hook-form'; import { useNavigate } from 'react-router-dom'; import { z } from 'zod'; -import { privateKeyValidation } from '../../helpers/validation/privateKeyValidation'; -import { Form } from '../../shared/forms/Form'; -import { TextAreaField } from '../../shared/forms/TextAreaField'; -import Alert from '../alert'; +import { privateKeyValidation } from '_app/helpers/validation/privateKeyValidation'; +import { Form } from '_app/shared/forms/Form'; +import { TextAreaField } from '_app/shared/forms/TextAreaField'; +import Alert from '_components/alert'; const formSchema = z.object({ privateKey: privateKeyValidation, diff --git a/apps/wallet/src/ui/app/components/accounts/ImportRecoveryPhraseForm.tsx b/apps/wallet/src/ui/app/components/accounts/ImportRecoveryPhraseForm.tsx index 388c8f83815..1a985eaaf5d 100644 --- a/apps/wallet/src/ui/app/components/accounts/ImportRecoveryPhraseForm.tsx +++ b/apps/wallet/src/ui/app/components/accounts/ImportRecoveryPhraseForm.tsx @@ -11,7 +11,7 @@ import { type SubmitHandler } from 'react-hook-form'; import { useNavigate } from 'react-router-dom'; import { z } from 'zod'; -import Alert from '../alert'; +import Alert from '_components/alert'; const RECOVERY_PHRASE_WORD_COUNT = 24; diff --git a/apps/wallet/src/ui/app/components/accounts/ImportSeedForm.tsx b/apps/wallet/src/ui/app/components/accounts/ImportSeedForm.tsx index 0660bf7e866..e25d6ccbb8c 100644 --- a/apps/wallet/src/ui/app/components/accounts/ImportSeedForm.tsx +++ b/apps/wallet/src/ui/app/components/accounts/ImportSeedForm.tsx @@ -7,9 +7,9 @@ import { type SubmitHandler } from 'react-hook-form'; import { useNavigate } from 'react-router-dom'; import { z } from 'zod'; -import { seedValidation } from '../../helpers/validation/seedValidation'; -import { Form } from '../../shared/forms/Form'; -import { TextAreaField } from '../../shared/forms/TextAreaField'; +import { seedValidation } from '_app/helpers/validation/seedValidation'; +import { Form } from '_app/shared/forms/Form'; +import { TextAreaField } from '_app/shared/forms/TextAreaField'; const formSchema = z.object({ seed: seedValidation, diff --git a/apps/wallet/src/ui/app/components/accounts/LockUnlockButton.tsx b/apps/wallet/src/ui/app/components/accounts/LockUnlockButton.tsx index 5e2b2295c95..3999cdf11cf 100644 --- a/apps/wallet/src/ui/app/components/accounts/LockUnlockButton.tsx +++ b/apps/wallet/src/ui/app/components/accounts/LockUnlockButton.tsx @@ -5,8 +5,8 @@ import { LockLocked16, LockUnlocked16 } from '@iota/icons'; import { type ComponentPropsWithoutRef } from 'react'; -import { Tooltip } from '../../shared/tooltip'; -import LoadingIndicator from '../loading/LoadingIndicator'; +import { Tooltip } from '_app/shared/tooltip'; +import LoadingIndicator from '_components/loading/LoadingIndicator'; interface LockUnlockButtonProps extends ComponentPropsWithoutRef<'button'> { isLocked: boolean; diff --git a/apps/wallet/src/ui/app/components/accounts/NicknameDialog.tsx b/apps/wallet/src/ui/app/components/accounts/NicknameDialog.tsx index 928c4f09838..fa82c79cffe 100644 --- a/apps/wallet/src/ui/app/components/accounts/NicknameDialog.tsx +++ b/apps/wallet/src/ui/app/components/accounts/NicknameDialog.tsx @@ -15,11 +15,11 @@ import { useState } from 'react'; import toast from 'react-hot-toast'; import { z } from 'zod'; -import { useAccounts } from '../../hooks/useAccounts'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { Button } from '../../shared/ButtonUI'; -import { Form } from '../../shared/forms/Form'; -import { TextField } from '../../shared/forms/TextField'; +import { useAccounts } from '_app/hooks/useAccounts'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { Button } from '_app/shared/ButtonUI'; +import { Form } from '_app/shared/forms/Form'; +import { TextField } from '_app/shared/forms/TextField'; const formSchema = z.object({ nickname: z.string().trim(), diff --git a/apps/wallet/src/ui/app/components/accounts/PasswordInputDialog.tsx b/apps/wallet/src/ui/app/components/accounts/PasswordInputDialog.tsx index 1994c30ebde..eb3429b58e7 100644 --- a/apps/wallet/src/ui/app/components/accounts/PasswordInputDialog.tsx +++ b/apps/wallet/src/ui/app/components/accounts/PasswordInputDialog.tsx @@ -17,12 +17,12 @@ import { toast } from 'react-hot-toast'; import { v4 as uuidV4 } from 'uuid'; import { z } from 'zod'; -import { useAccountSources } from '../../hooks/useAccountSources'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { PasswordInput } from '../../shared/forms/controls/PasswordInput'; -import { Form } from '../../shared/forms/Form'; -import FormField from '../../shared/forms/FormField'; -import { Link } from '../../shared/Link'; +import { useAccountSources } from '_app/hooks/useAccountSources'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { PasswordInput } from '_app/shared/forms/controls/PasswordInput'; +import { Form } from '_app/shared/forms/Form'; +import FormField from '_app/shared/forms/FormField'; +import { Link } from '_app/shared/Link'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; const formSchema = z.object({ diff --git a/apps/wallet/src/ui/app/components/accounts/ProtectAccountForm.tsx b/apps/wallet/src/ui/app/components/accounts/ProtectAccountForm.tsx index bbc2286a81d..1263ba54476 100644 --- a/apps/wallet/src/ui/app/components/accounts/ProtectAccountForm.tsx +++ b/apps/wallet/src/ui/app/components/accounts/ProtectAccountForm.tsx @@ -11,11 +11,11 @@ import { useNavigate } from 'react-router-dom'; import { z } from 'zod'; import zxcvbn from 'zxcvbn'; -import { parseAutoLock, useAutoLockMinutes } from '../../hooks/useAutoLockMinutes'; -import { CheckboxField } from '../../shared/forms/CheckboxField'; -import { Form } from '../../shared/forms/Form'; -import { TextField } from '../../shared/forms/TextField'; -import { Link } from '../../shared/Link'; +import { parseAutoLock, useAutoLockMinutes } from '_app/hooks/useAutoLockMinutes'; +import { CheckboxField } from '_app/shared/forms/CheckboxField'; +import { Form } from '_app/shared/forms/Form'; +import { TextField } from '_app/shared/forms/TextField'; +import { Link } from '_app/shared/Link'; import { AutoLockSelector, zodSchema } from './AutoLockSelector'; function addDot(str: string | undefined) { diff --git a/apps/wallet/src/ui/app/components/accounts/RecoverAccountsGroup.tsx b/apps/wallet/src/ui/app/components/accounts/RecoverAccountsGroup.tsx index bf30c098f6d..8c70ccb030a 100644 --- a/apps/wallet/src/ui/app/components/accounts/RecoverAccountsGroup.tsx +++ b/apps/wallet/src/ui/app/components/accounts/RecoverAccountsGroup.tsx @@ -5,9 +5,9 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; import { CheckFill16 } from '@iota/icons'; -import { Link } from '../../shared/Link'; -import { Text } from '../../shared/text'; -import { Tooltip } from '../../shared/tooltip'; +import { Link } from '_app/shared/Link'; +import { Text } from '_app/shared/text'; +import { Tooltip } from '_app/shared/tooltip'; import { AccountListItem } from './AccountListItem'; export interface RecoverAccountsGroupProps { diff --git a/apps/wallet/src/ui/app/components/accounts/UnlockAccountButton.tsx b/apps/wallet/src/ui/app/components/accounts/UnlockAccountButton.tsx index f18c319250c..648d3f7f350 100644 --- a/apps/wallet/src/ui/app/components/accounts/UnlockAccountButton.tsx +++ b/apps/wallet/src/ui/app/components/accounts/UnlockAccountButton.tsx @@ -4,7 +4,7 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; -import { Button } from '../../shared/ButtonUI'; +import { Button } from '_app/shared/ButtonUI'; import { useUnlockAccount } from './UnlockAccountContext'; export interface UnlockAccountButtonProps { diff --git a/apps/wallet/src/ui/app/components/accounts/UnlockAccountContext.tsx b/apps/wallet/src/ui/app/components/accounts/UnlockAccountContext.tsx index 58d6b818229..df7c8c8a92f 100644 --- a/apps/wallet/src/ui/app/components/accounts/UnlockAccountContext.tsx +++ b/apps/wallet/src/ui/app/components/accounts/UnlockAccountContext.tsx @@ -6,8 +6,8 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; import React, { createContext, useCallback, useContext, useState, type ReactNode } from 'react'; import { toast } from 'react-hot-toast'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { useUnlockMutation } from '../../hooks/useUnlockMutation'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { useUnlockMutation } from '_app/hooks/useUnlockMutation'; import { UnlockAccountModal } from './UnlockAccountModal'; interface UnlockAccountContextType { diff --git a/apps/wallet/src/ui/app/components/accounts/UnlockAccountModal.tsx b/apps/wallet/src/ui/app/components/accounts/UnlockAccountModal.tsx index 0682cae986e..86a47fb63a3 100644 --- a/apps/wallet/src/ui/app/components/accounts/UnlockAccountModal.tsx +++ b/apps/wallet/src/ui/app/components/accounts/UnlockAccountModal.tsx @@ -5,7 +5,7 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; import { toast } from 'react-hot-toast'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; import { PasswordModalDialog } from './PasswordInputDialog'; interface UnlockAccountModalProps { diff --git a/apps/wallet/src/ui/app/components/explorer-link/index.tsx b/apps/wallet/src/ui/app/components/explorer-link/index.tsx index b22e239d2da..e1e57663ae0 100644 --- a/apps/wallet/src/ui/app/components/explorer-link/index.tsx +++ b/apps/wallet/src/ui/app/components/explorer-link/index.tsx @@ -7,8 +7,8 @@ import { ArrowUpRight16 } from '@iota/icons'; import { formatAddress } from '@iota/iota.js/utils'; import type { ReactNode } from 'react'; -import { useExplorerLink, type ExplorerLinkConfig } from '../../hooks/useExplorerLink'; -import { Text } from '../../shared/text'; +import { useExplorerLink, type ExplorerLinkConfig } from '_app/hooks/useExplorerLink'; +import { Text } from '_app/shared/text'; import st from './ExplorerLink.module.scss'; import { ExplorerLinkType } from './ExplorerLinkType'; diff --git a/apps/wallet/src/ui/app/components/iota-apps/Banner.tsx b/apps/wallet/src/ui/app/components/iota-apps/Banner.tsx index e5211019d64..f63b5f7d7bc 100644 --- a/apps/wallet/src/ui/app/components/iota-apps/Banner.tsx +++ b/apps/wallet/src/ui/app/components/iota-apps/Banner.tsx @@ -6,7 +6,7 @@ import { ampli } from '_src/shared/analytics/ampli'; import { Feature } from '_src/shared/experimentation/features'; import { useFeature } from '@growthbook/growthbook-react'; -import ExternalLink from '../external-link'; +import ExternalLink from '_components/external-link'; export type BannerProps = { enabled: boolean; diff --git a/apps/wallet/src/ui/app/components/iota-apps/ConnectedAppsCard.tsx b/apps/wallet/src/ui/app/components/iota-apps/ConnectedAppsCard.tsx index a104209ebde..11037e78138 100644 --- a/apps/wallet/src/ui/app/components/iota-apps/ConnectedAppsCard.tsx +++ b/apps/wallet/src/ui/app/components/iota-apps/ConnectedAppsCard.tsx @@ -10,9 +10,9 @@ import { prepareLinkToCompare } from '_src/shared/utils'; import { useFeature } from '@growthbook/growthbook-react'; import { useEffect, useMemo } from 'react'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { permissionsSelectors } from '../../redux/slices/permissions'; -import Loading from '../loading'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { permissionsSelectors } from '_redux/slices/permissions'; +import Loading from '_components/loading'; import { IotaApp, type DAppEntry } from './IotaApp'; import { IotaAppEmpty } from './IotaAppEmpty'; diff --git a/apps/wallet/src/ui/app/components/iota-apps/DisconnectApp.tsx b/apps/wallet/src/ui/app/components/iota-apps/DisconnectApp.tsx index f138eaf24c0..e5336c1b1b0 100644 --- a/apps/wallet/src/ui/app/components/iota-apps/DisconnectApp.tsx +++ b/apps/wallet/src/ui/app/components/iota-apps/DisconnectApp.tsx @@ -11,13 +11,13 @@ import { useMutation } from '@tanstack/react-query'; import { useEffect, useMemo, useState } from 'react'; import { toast } from 'react-hot-toast'; -import { useBackgroundClient } from '../../hooks/useBackgroundClient'; -import { Button } from '../../shared/ButtonUI'; -import { Text } from '../../shared/text'; -import { DAppInfoCard } from '../DAppInfoCard'; -import { DAppPermissionsList } from '../DAppPermissionsList'; -import { SummaryCard } from '../SummaryCard'; -import { WalletListSelect } from '../WalletListSelect'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { Button } from '_app/shared/ButtonUI'; +import { Text } from '_app/shared/text'; +import { DAppInfoCard } from '_components/DAppInfoCard'; +import { DAppPermissionsList } from '_components/DAppPermissionsList'; +import { SummaryCard } from '_components/SummaryCard'; +import { WalletListSelect } from '_components/WalletListSelect'; import { type DAppEntry } from './IotaApp'; export interface DisconnectAppProps extends Omit { diff --git a/apps/wallet/src/ui/app/components/iota-apps/index.tsx b/apps/wallet/src/ui/app/components/iota-apps/index.tsx index e366710dcdb..0945ade7c72 100644 --- a/apps/wallet/src/ui/app/components/iota-apps/index.tsx +++ b/apps/wallet/src/ui/app/components/iota-apps/index.tsx @@ -11,7 +11,7 @@ import { useFeature } from '@growthbook/growthbook-react'; import { useMemo } from 'react'; import { useParams } from 'react-router-dom'; -import { permissionsSelectors } from '../../redux/slices/permissions'; +import { permissionsSelectors } from '_redux/slices/permissions'; import { AppsPageBanner } from './Banner'; import { IotaApp, type DAppEntry } from './IotaApp'; import { IotaAppEmpty } from './IotaAppEmpty'; diff --git a/apps/wallet/src/ui/app/components/ledger/ConnectLedgerModal.tsx b/apps/wallet/src/ui/app/components/ledger/ConnectLedgerModal.tsx index 2f2402eb445..3d36874ac97 100644 --- a/apps/wallet/src/ui/app/components/ledger/ConnectLedgerModal.tsx +++ b/apps/wallet/src/ui/app/components/ledger/ConnectLedgerModal.tsx @@ -15,7 +15,7 @@ import { import { Text } from '_src/ui/app/shared/text'; import { useState } from 'react'; -import { Link } from '../../shared/Link'; +import { Link } from '_app/shared/Link'; interface ConnectLedgerModalProps { onClose: () => void; diff --git a/apps/wallet/src/ui/app/components/menu/button/WalletSettingsButton.tsx b/apps/wallet/src/ui/app/components/menu/button/WalletSettingsButton.tsx index 6d1dcd65826..2fa3b9c3319 100644 --- a/apps/wallet/src/ui/app/components/menu/button/WalletSettingsButton.tsx +++ b/apps/wallet/src/ui/app/components/menu/button/WalletSettingsButton.tsx @@ -6,7 +6,7 @@ import { ButtonOrLink } from '_src/ui/app/shared/utils/ButtonOrLink'; import { HamburgerOpen24 as HamburgerOpenIcon, Settings24 as SettingsIcon } from '@iota/icons'; import { cx } from 'class-variance-authority'; -import { useMenuIsOpen, useNextMenuUrl } from '../hooks'; +import { useMenuIsOpen, useNextMenuUrl } from '_components/menu/hooks'; export function WalletSettingsButton() { const isOpen = useMenuIsOpen(); diff --git a/apps/wallet/src/ui/app/components/menu/content/AutoLockAccounts.tsx b/apps/wallet/src/ui/app/components/menu/content/AutoLockAccounts.tsx index 99d81a9f1f5..6258908658a 100644 --- a/apps/wallet/src/ui/app/components/menu/content/AutoLockAccounts.tsx +++ b/apps/wallet/src/ui/app/components/menu/content/AutoLockAccounts.tsx @@ -15,9 +15,9 @@ import { useZodForm } from '@iota/core'; import toast from 'react-hot-toast'; import { useNavigate } from 'react-router-dom'; -import { AutoLockSelector, zodSchema } from '../../accounts/AutoLockSelector'; -import Loading from '../../loading'; -import Overlay from '../../overlay'; +import { AutoLockSelector, zodSchema } from '_components/accounts/AutoLockSelector'; +import Loading from '_components/loading'; +import Overlay from '_components/overlay'; export function AutoLockAccounts() { const mainMenuUrl = useNextMenuUrl(true, '/'); diff --git a/apps/wallet/src/ui/app/components/menu/content/VerifyLedgerConnectionStatus.tsx b/apps/wallet/src/ui/app/components/menu/content/VerifyLedgerConnectionStatus.tsx index 22b182030e5..13d96889334 100644 --- a/apps/wallet/src/ui/app/components/menu/content/VerifyLedgerConnectionStatus.tsx +++ b/apps/wallet/src/ui/app/components/menu/content/VerifyLedgerConnectionStatus.tsx @@ -13,8 +13,8 @@ import { Ed25519PublicKey } from '@iota/iota.js/keypairs/ed25519'; import { useState } from 'react'; import toast from 'react-hot-toast'; -import { useIotaLedgerClient } from '../../ledger/IotaLedgerClientProvider'; -import LoadingIndicator from '../../loading/LoadingIndicator'; +import { useIotaLedgerClient } from '_components/ledger/IotaLedgerClientProvider'; +import LoadingIndicator from '_components/loading/LoadingIndicator'; export interface VerifyLedgerConnectionLinkProps { accountAddress: string; diff --git a/apps/wallet/src/ui/app/components/menu/content/WalletSettingsMenuList.tsx b/apps/wallet/src/ui/app/components/menu/content/WalletSettingsMenuList.tsx index 4a97a0621e4..8dce87985ca 100644 --- a/apps/wallet/src/ui/app/components/menu/content/WalletSettingsMenuList.tsx +++ b/apps/wallet/src/ui/app/components/menu/content/WalletSettingsMenuList.tsx @@ -14,7 +14,7 @@ import { ArrowUpRight12, Clipboard24, Domain24, LockLocked24, More24 } from '@io import { getNetwork, Network } from '@iota/iota.js/client'; import Browser from 'webextension-polyfill'; -import Loading from '../../loading'; +import Loading from '_components/loading'; import { MenuLayout } from './MenuLayout'; import MenuListItem from './MenuListItem'; diff --git a/apps/wallet/src/ui/app/components/navigation/index.tsx b/apps/wallet/src/ui/app/components/navigation/index.tsx index 8c3aa4ac026..7ffe03b4acf 100644 --- a/apps/wallet/src/ui/app/components/navigation/index.tsx +++ b/apps/wallet/src/ui/app/components/navigation/index.tsx @@ -8,7 +8,7 @@ import { Activity32, Apps32, Nft132, Tokens32 } from '@iota/icons'; import cl from 'clsx'; import { NavLink } from 'react-router-dom'; -import { useActiveAccount } from '../../hooks/useActiveAccount'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; import st from './Navigation.module.scss'; export function Navigation() { diff --git a/apps/wallet/src/ui/app/components/nft-display/Kiosk.tsx b/apps/wallet/src/ui/app/components/nft-display/Kiosk.tsx index a4bc69c4335..417d567b133 100644 --- a/apps/wallet/src/ui/app/components/nft-display/Kiosk.tsx +++ b/apps/wallet/src/ui/app/components/nft-display/Kiosk.tsx @@ -5,8 +5,8 @@ import { getKioskIdFromOwnerCap, hasDisplayData, useGetKioskContents } from '@io import { type IotaObjectResponse } from '@iota/iota.js/client'; import cl from 'clsx'; -import { useActiveAddress } from '../../hooks'; -import { Text } from '../../shared/text'; +import { useActiveAddress } from '_app/hooks'; +import { Text } from '_app/shared/text'; import { NftImage, type NftImageProps } from './NftImage'; interface KioskProps extends Partial { diff --git a/apps/wallet/src/ui/app/components/nft-display/index.tsx b/apps/wallet/src/ui/app/components/nft-display/index.tsx index 8149be5d80f..ab36a5b756a 100644 --- a/apps/wallet/src/ui/app/components/nft-display/index.tsx +++ b/apps/wallet/src/ui/app/components/nft-display/index.tsx @@ -11,8 +11,8 @@ import { formatAddress } from '@iota/iota.js/utils'; import { cva } from 'class-variance-authority'; import type { VariantProps } from 'class-variance-authority'; -import { useResolveVideo } from '../../hooks/useResolveVideo'; -import { Text } from '../../shared/text'; +import { useResolveVideo } from '_app/hooks/useResolveVideo'; +import { Text } from '_app/shared/text'; import { Kiosk } from './Kiosk'; const nftDisplayCardStyles = cva('flex flex-nowrap items-center h-full relative', { diff --git a/apps/wallet/src/ui/app/components/overlay/index.tsx b/apps/wallet/src/ui/app/components/overlay/index.tsx index 76e12dbaa99..14c6181f975 100644 --- a/apps/wallet/src/ui/app/components/overlay/index.tsx +++ b/apps/wallet/src/ui/app/components/overlay/index.tsx @@ -7,9 +7,9 @@ import cl from 'clsx'; import { useCallback } from 'react'; import type { ReactNode } from 'react'; -import useAppSelector from '../../hooks/useAppSelector'; -import { AppType } from '../../redux/slices/app/AppType'; -import { Portal } from '../../shared/Portal'; +import useAppSelector from '_app/hooks/useAppSelector'; +import { AppType } from '_redux/slices/app/AppType'; +import { Portal } from '_app/shared/Portal'; import st from './Overlay.module.scss'; interface OverlayProps { diff --git a/apps/wallet/src/ui/app/components/receipt-card/StakeTxnCard.tsx b/apps/wallet/src/ui/app/components/receipt-card/StakeTxnCard.tsx index a2b1d0abb09..c05b9bc243f 100644 --- a/apps/wallet/src/ui/app/components/receipt-card/StakeTxnCard.tsx +++ b/apps/wallet/src/ui/app/components/receipt-card/StakeTxnCard.tsx @@ -19,7 +19,7 @@ import { import type { IotaEvent } from '@iota/iota.js/client'; import { IOTA_TYPE_ARG } from '@iota/iota.js/utils'; -import { Card } from '../../shared/transaction-summary/Card'; +import { Card } from '_app/shared/transaction-summary/Card'; interface StakeTxnCardProps { event: IotaEvent; diff --git a/apps/wallet/src/ui/app/components/receipt-card/UnstakeTxnCard.tsx b/apps/wallet/src/ui/app/components/receipt-card/UnstakeTxnCard.tsx index fab2cd99396..68d481d3c3d 100644 --- a/apps/wallet/src/ui/app/components/receipt-card/UnstakeTxnCard.tsx +++ b/apps/wallet/src/ui/app/components/receipt-card/UnstakeTxnCard.tsx @@ -9,7 +9,7 @@ import { useFormatCoin } from '@iota/core'; import type { IotaEvent } from '@iota/iota.js/client'; import { IOTA_TYPE_ARG } from '@iota/iota.js/utils'; -import { Card } from '../../shared/transaction-summary/Card'; +import { Card } from '_app/shared/transaction-summary/Card'; interface UnStakeTxnCardProps { event: IotaEvent; diff --git a/apps/wallet/src/ui/app/components/receipt-card/index.tsx b/apps/wallet/src/ui/app/components/receipt-card/index.tsx index a5465c3d9cf..b7df4e51168 100644 --- a/apps/wallet/src/ui/app/components/receipt-card/index.tsx +++ b/apps/wallet/src/ui/app/components/receipt-card/index.tsx @@ -6,10 +6,10 @@ import { useRecognizedPackages } from '_src/ui/app/hooks/useRecognizedPackages'; import { useTransactionSummary, STAKING_REQUEST_EVENT, UNSTAKING_REQUEST_EVENT } from '@iota/core'; import { type IotaTransactionBlockResponse } from '@iota/iota.js/client'; -import { DateCard } from '../../shared/date-card'; -import { TransactionSummary } from '../../shared/transaction-summary'; -import { ExplorerLinkCard } from '../../shared/transaction-summary/cards/ExplorerLink'; -import { GasSummary } from '../../shared/transaction-summary/cards/GasSummary'; +import { DateCard } from '_app/shared/date-card'; +import { TransactionSummary } from '_app/shared/transaction-summary'; +import { ExplorerLinkCard } from '_app/shared/transaction-summary/cards/ExplorerLink'; +import { GasSummary } from '_app/shared/transaction-summary/cards/GasSummary'; import { StakeTxnCard } from './StakeTxnCard'; import { StatusIcon } from './StatusIcon'; import { UnStakeTxnCard } from './UnstakeTxnCard'; diff --git a/apps/wallet/src/ui/app/components/transactions-card/TxnIcon.tsx b/apps/wallet/src/ui/app/components/transactions-card/TxnIcon.tsx index 51a08fdf889..a57b501cf85 100644 --- a/apps/wallet/src/ui/app/components/transactions-card/TxnIcon.tsx +++ b/apps/wallet/src/ui/app/components/transactions-card/TxnIcon.tsx @@ -5,7 +5,7 @@ import { Account24, ArrowRight16, Info16, Iota, Unstaked, WalletActionStake24 } from '@iota/icons'; import cl from 'clsx'; -import LoadingIndicator from '../loading/LoadingIndicator'; +import LoadingIndicator from '_components/loading/LoadingIndicator'; const icons = { Send: ( diff --git a/apps/wallet/src/ui/app/components/user-approve-container/index.tsx b/apps/wallet/src/ui/app/components/user-approve-container/index.tsx index 550e31fcf21..0cd2970f668 100644 --- a/apps/wallet/src/ui/app/components/user-approve-container/index.tsx +++ b/apps/wallet/src/ui/app/components/user-approve-container/index.tsx @@ -7,10 +7,10 @@ import cn from 'clsx'; import { useCallback, useMemo, useState } from 'react'; import type { ReactNode } from 'react'; -import { useAccountByAddress } from '../../hooks/useAccountByAddress'; -import { Button } from '../../shared/ButtonUI'; -import { UnlockAccountButton } from '../accounts/UnlockAccountButton'; -import { DAppInfoCard } from '../DAppInfoCard'; +import { useAccountByAddress } from '_app/hooks/useAccountByAddress'; +import { Button } from '_app/shared/ButtonUI'; +import { UnlockAccountButton } from '_components/accounts/UnlockAccountButton'; +import { DAppInfoCard } from '_components/DAppInfoCard'; interface UserApproveContainerProps { children: ReactNode | ReactNode[]; diff --git a/apps/wallet/src/ui/app/helpers/errorMessages.ts b/apps/wallet/src/ui/app/helpers/errorMessages.ts index ca55e488fec..5cfc2f27264 100644 --- a/apps/wallet/src/ui/app/helpers/errorMessages.ts +++ b/apps/wallet/src/ui/app/helpers/errorMessages.ts @@ -9,7 +9,7 @@ import { LedgerConnectionFailedError, LedgerDeviceNotFoundError, LedgerNoTransportMechanismError, -} from '../components/ledger/ledgerErrors'; +} from '_components/ledger/ledgerErrors'; /** * Helper method for producing user-friendly error messages from Signer operations diff --git a/apps/wallet/src/ui/app/helpers/sentry.ts b/apps/wallet/src/ui/app/helpers/sentry.ts index d19055b0eea..7c87bf4b40b 100644 --- a/apps/wallet/src/ui/app/helpers/sentry.ts +++ b/apps/wallet/src/ui/app/helpers/sentry.ts @@ -5,7 +5,7 @@ import { growthbook } from '_src/ui/app/experimentation/feature-gating'; import * as Sentry from '@sentry/react'; -import { getSentryConfig } from '../../../shared/sentry-config'; +import { getSentryConfig } from '_shared/sentry-config'; export default function initSentry() { Sentry.init( diff --git a/apps/wallet/src/ui/app/hooks/useAccountGroups.ts b/apps/wallet/src/ui/app/hooks/useAccountGroups.ts index 708b4845eb9..54f1aadb3c0 100644 --- a/apps/wallet/src/ui/app/hooks/useAccountGroups.ts +++ b/apps/wallet/src/ui/app/hooks/useAccountGroups.ts @@ -4,7 +4,7 @@ import { useMemo } from 'react'; -import { DEFAULT_SORT_ORDER, groupByType } from '../helpers/accounts'; +import { DEFAULT_SORT_ORDER, groupByType } from '_app/helpers/accounts'; import { useAccounts } from './useAccounts'; export function useAccountGroups() { diff --git a/apps/wallet/src/ui/app/hooks/useAccounts.ts b/apps/wallet/src/ui/app/hooks/useAccounts.ts index a548c0fab97..999d4f84ff6 100644 --- a/apps/wallet/src/ui/app/hooks/useAccounts.ts +++ b/apps/wallet/src/ui/app/hooks/useAccounts.ts @@ -5,7 +5,7 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; import { useQuery } from '@tanstack/react-query'; -import { ACCOUNTS_QUERY_KEY } from '../helpers/query-client-keys'; +import { ACCOUNTS_QUERY_KEY } from '_app/helpers/query-client-keys'; import { useBackgroundClient } from './useBackgroundClient'; export function useAccounts() { diff --git a/apps/wallet/src/ui/app/hooks/useAccountsFinder.ts b/apps/wallet/src/ui/app/hooks/useAccountsFinder.ts index 9f6b4fef434..8bf3033dd6a 100644 --- a/apps/wallet/src/ui/app/hooks/useAccountsFinder.ts +++ b/apps/wallet/src/ui/app/hooks/useAccountsFinder.ts @@ -4,7 +4,7 @@ import { useBackgroundClient } from './useBackgroundClient'; import { AccountsFinder, type AllowedAccountSourceTypes } from '_src/ui/app/accounts-finder'; import { useIotaClient } from '@iota/dapp-kit'; -import { useIotaLedgerClient } from '../components/ledger/IotaLedgerClientProvider'; +import { useIotaLedgerClient } from '_components/ledger/IotaLedgerClientProvider'; import { useMemo } from 'react'; import type { SourceStrategyToFind, @@ -12,7 +12,7 @@ import type { } from '_src/shared/messaging/messages/payloads/accounts-finder'; import { makeDerivationPath } from '_src/background/account-sources/bip44Path'; import { Ed25519PublicKey } from '@iota/iota.js/keypairs/ed25519'; -import { IOTA_BIP44_COIN_TYPE } from '../redux/slices/iota-objects/Coin'; +import { IOTA_BIP44_COIN_TYPE } from '_redux/slices/iota-objects/Coin'; import { IOTA_TYPE_ARG } from '@iota/iota.js/utils'; export interface UseAccountFinderOptions { diff --git a/apps/wallet/src/ui/app/hooks/useAutoLockMinutes.ts b/apps/wallet/src/ui/app/hooks/useAutoLockMinutes.ts index d11f2f97523..9e3d74e1e87 100644 --- a/apps/wallet/src/ui/app/hooks/useAutoLockMinutes.ts +++ b/apps/wallet/src/ui/app/hooks/useAutoLockMinutes.ts @@ -5,7 +5,7 @@ import { useQuery } from '@tanstack/react-query'; import { type z } from 'zod'; -import { type zodSchema } from '../components/accounts/AutoLockSelector'; +import { type zodSchema } from '_components/accounts/AutoLockSelector'; import { useBackgroundClient } from './useBackgroundClient'; export type AutoLockInterval = z.infer['autoLock']['interval']; diff --git a/apps/wallet/src/ui/app/hooks/useBackgroundClient.ts b/apps/wallet/src/ui/app/hooks/useBackgroundClient.ts index ef19242b4d2..1a811d34b45 100644 --- a/apps/wallet/src/ui/app/hooks/useBackgroundClient.ts +++ b/apps/wallet/src/ui/app/hooks/useBackgroundClient.ts @@ -2,7 +2,7 @@ // Modifications Copyright (c) 2024 IOTA Stiftung // SPDX-License-Identifier: Apache-2.0 -import { thunkExtras } from '../redux/store/thunk-extras'; +import { thunkExtras } from '_redux/store/thunk-extras'; export function useBackgroundClient() { return thunkExtras.background; diff --git a/apps/wallet/src/ui/app/hooks/useCreateAccountMutation.ts b/apps/wallet/src/ui/app/hooks/useCreateAccountMutation.ts index 299051a6b05..02fe1c4c216 100644 --- a/apps/wallet/src/ui/app/hooks/useCreateAccountMutation.ts +++ b/apps/wallet/src/ui/app/hooks/useCreateAccountMutation.ts @@ -9,7 +9,7 @@ import { useAccountsFormContext, AccountsFormType, type AccountsFormValues, -} from '../components/accounts/AccountsFormContext'; +} from '_components/accounts/AccountsFormContext'; import { useBackgroundClient } from './useBackgroundClient'; import { AccountType } from '_src/background/accounts/Account'; diff --git a/apps/wallet/src/ui/app/hooks/useExplorerLink.ts b/apps/wallet/src/ui/app/hooks/useExplorerLink.ts index 25ca2bc81a8..6e5a3e7c336 100644 --- a/apps/wallet/src/ui/app/hooks/useExplorerLink.ts +++ b/apps/wallet/src/ui/app/hooks/useExplorerLink.ts @@ -11,8 +11,8 @@ import { getObjectUrl, getTransactionUrl, getValidatorUrl, -} from '../components/explorer-link//Explorer'; -import { ExplorerLinkType } from '../components/explorer-link/ExplorerLinkType'; +} from '_components/explorer-link//Explorer'; +import { ExplorerLinkType } from '_components/explorer-link/ExplorerLinkType'; import { useActiveAddress } from './useActiveAddress'; import useAppSelector from './useAppSelector'; diff --git a/apps/wallet/src/ui/app/hooks/useGetNFTs.ts b/apps/wallet/src/ui/app/hooks/useGetNFTs.ts index a75ee8e203e..6a4affe32bb 100644 --- a/apps/wallet/src/ui/app/hooks/useGetNFTs.ts +++ b/apps/wallet/src/ui/app/hooks/useGetNFTs.ts @@ -6,7 +6,7 @@ import { hasDisplayData, isKioskOwnerToken, useGetOwnedObjects, useKioskClient } import { type IotaObjectData } from '@iota/iota.js/client'; import { useMemo } from 'react'; -import { useHiddenAssets } from '../pages/home/hidden-assets/HiddenAssetsProvider'; +import { useHiddenAssets } from '_pages/home/hidden-assets/HiddenAssetsProvider'; type OwnedAssets = { visual: IotaObjectData[]; diff --git a/apps/wallet/src/ui/app/hooks/useInitialPageView.ts b/apps/wallet/src/ui/app/hooks/useInitialPageView.ts index b474adaac74..a55eb186a78 100644 --- a/apps/wallet/src/ui/app/hooks/useInitialPageView.ts +++ b/apps/wallet/src/ui/app/hooks/useInitialPageView.ts @@ -9,7 +9,7 @@ import { useEffect } from 'react'; import { useLocation } from 'react-router-dom'; import Browser from 'webextension-polyfill'; -import { AppType } from '../redux/slices/app/AppType'; +import { AppType } from '_redux/slices/app/AppType'; import { useActiveAccount } from './useActiveAccount'; import useAppSelector from './useAppSelector'; diff --git a/apps/wallet/src/ui/app/hooks/useRecoveryDataMutation.ts b/apps/wallet/src/ui/app/hooks/useRecoveryDataMutation.ts index 0567bef0896..f51a57844a4 100644 --- a/apps/wallet/src/ui/app/hooks/useRecoveryDataMutation.ts +++ b/apps/wallet/src/ui/app/hooks/useRecoveryDataMutation.ts @@ -5,7 +5,7 @@ import { type PasswordRecoveryData } from '_src/shared/messaging/messages/payloads/MethodPayload'; import { useMutation } from '@tanstack/react-query'; -import { useForgotPasswordContext } from '../pages/accounts/forgot-password/ForgotPasswordPage'; +import { useForgotPasswordContext } from '_pages/accounts/forgot-password/ForgotPasswordPage'; import { useBackgroundClient } from './useBackgroundClient'; export function useRecoveryDataMutation() { diff --git a/apps/wallet/src/ui/app/hooks/useResetPasswordMutation.ts b/apps/wallet/src/ui/app/hooks/useResetPasswordMutation.ts index cd3d32236ae..1f9200ed1bb 100644 --- a/apps/wallet/src/ui/app/hooks/useResetPasswordMutation.ts +++ b/apps/wallet/src/ui/app/hooks/useResetPasswordMutation.ts @@ -4,7 +4,7 @@ import { useMutation } from '@tanstack/react-query'; -import { type BackgroundClient } from '../background-client'; +import { type BackgroundClient } from '_app/background-client'; import { useBackgroundClient } from './useBackgroundClient'; export function useResetPasswordMutation() { diff --git a/apps/wallet/src/ui/app/hooks/useSigner.ts b/apps/wallet/src/ui/app/hooks/useSigner.ts index f3aa5003ae8..67d29824d8a 100644 --- a/apps/wallet/src/ui/app/hooks/useSigner.ts +++ b/apps/wallet/src/ui/app/hooks/useSigner.ts @@ -6,10 +6,10 @@ import { type SerializedUIAccount } from '_src/background/accounts/Account'; import { isLedgerAccountSerializedUI } from '_src/background/accounts/LedgerAccount'; import { useIotaClient } from '@iota/dapp-kit'; -import { walletApiProvider } from '../ApiProvider'; -import { useIotaLedgerClient } from '../components/ledger/IotaLedgerClientProvider'; -import { LedgerSigner } from '../LedgerSigner'; -import { type WalletSigner } from '../WalletSigner'; +import { walletApiProvider } from '_app/ApiProvider'; +import { useIotaLedgerClient } from '_components/ledger/IotaLedgerClientProvider'; +import { LedgerSigner } from '_app/LedgerSigner'; +import { type WalletSigner } from '_app/WalletSigner'; import { useBackgroundClient } from './useBackgroundClient'; export function useSigner(account: SerializedUIAccount | null): WalletSigner | null { diff --git a/apps/wallet/src/ui/app/hooks/useUnlockMutation.ts b/apps/wallet/src/ui/app/hooks/useUnlockMutation.ts index 8ff130de67d..eac835232a1 100644 --- a/apps/wallet/src/ui/app/hooks/useUnlockMutation.ts +++ b/apps/wallet/src/ui/app/hooks/useUnlockMutation.ts @@ -4,7 +4,7 @@ import { useMutation } from '@tanstack/react-query'; -import { type BackgroundClient } from '../background-client'; +import { type BackgroundClient } from '_app/background-client'; import { useBackgroundClient } from './useBackgroundClient'; export function useUnlockMutation() { diff --git a/apps/wallet/src/ui/app/hooks/useUnlockedGuard.ts b/apps/wallet/src/ui/app/hooks/useUnlockedGuard.ts index fb30507a6c3..53499e3d82f 100644 --- a/apps/wallet/src/ui/app/hooks/useUnlockedGuard.ts +++ b/apps/wallet/src/ui/app/hooks/useUnlockedGuard.ts @@ -5,8 +5,8 @@ import { useEffect } from 'react'; import { useNavigate } from 'react-router-dom'; -import { useAccounts } from '../hooks/useAccounts'; -import { useActiveAccount } from '../hooks/useActiveAccount'; +import { useAccounts } from '_app/hooks/useAccounts'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; export function useUnlockedGuard() { const navigate = useNavigate(); diff --git a/apps/wallet/src/ui/app/pages/StorageMigrationPage.tsx b/apps/wallet/src/ui/app/pages/StorageMigrationPage.tsx index bce643b83ee..1c884edcc84 100644 --- a/apps/wallet/src/ui/app/pages/StorageMigrationPage.tsx +++ b/apps/wallet/src/ui/app/pages/StorageMigrationPage.tsx @@ -5,12 +5,12 @@ import { useMutation } from '@tanstack/react-query'; import { toast } from 'react-hot-toast'; -import LoadingIndicator from '../components/loading/LoadingIndicator'; -import { PasswordInputDialog } from '../components/PasswordInputDialog'; -import { useBackgroundClient } from '../hooks/useBackgroundClient'; -import { useStorageMigrationStatus } from '../hooks/useStorageMigrationStatus'; -import { CardLayout } from '../shared/card-layout'; -import { Toaster } from '../shared/toaster'; +import LoadingIndicator from '_components/loading/LoadingIndicator'; +import { PasswordInputDialog } from '_components/PasswordInputDialog'; +import { useBackgroundClient } from '_app/hooks/useBackgroundClient'; +import { useStorageMigrationStatus } from '_app/hooks/useStorageMigrationStatus'; +import { CardLayout } from '_app/shared/card-layout'; +import { Toaster } from '_app/shared/toaster'; export function StorageMigrationPage() { const { data } = useStorageMigrationStatus(); diff --git a/apps/wallet/src/ui/app/pages/accounts/AddAccountPage.tsx b/apps/wallet/src/ui/app/pages/accounts/AddAccountPage.tsx index 4a3c1cb7199..e2227bdc6c6 100644 --- a/apps/wallet/src/ui/app/pages/accounts/AddAccountPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/AddAccountPage.tsx @@ -17,15 +17,12 @@ import { CardAction, ImageType, } from '@iota/apps-ui-kit'; -import { - AccountsFormType, - useAccountsFormContext, -} from '../../components/accounts/AccountsFormContext'; -import { ConnectLedgerModal } from '../../components/ledger/ConnectLedgerModal'; -import { getLedgerConnectionErrorMessage } from '../../helpers/errorMessages'; -import { useAppSelector } from '../../hooks'; -import { useCreateAccountsMutation } from '../../hooks/useCreateAccountMutation'; -import { AppType } from '../../redux/slices/app/AppType'; +import { AccountsFormType, useAccountsFormContext } from '_components/accounts/AccountsFormContext'; +import { ConnectLedgerModal } from '_components/ledger/ConnectLedgerModal'; +import { getLedgerConnectionErrorMessage } from '_app/helpers/errorMessages'; +import { useAppSelector } from '_hooks'; +import { useCreateAccountsMutation } from '_app/hooks/useCreateAccountMutation'; +import { AppType } from '_redux/slices/app/AppType'; import { Create, ImportPass, Key, Seed, Ledger } from '@iota/ui-icons'; async function openTabWithSearchParam(searchParam: string, searchParamValue: string) { diff --git a/apps/wallet/src/ui/app/pages/accounts/BackupMnemonicPage.tsx b/apps/wallet/src/ui/app/pages/accounts/BackupMnemonicPage.tsx index 50481fcefdb..be44539f0ed 100644 --- a/apps/wallet/src/ui/app/pages/accounts/BackupMnemonicPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/BackupMnemonicPage.tsx @@ -12,9 +12,9 @@ import { ArrowLeft16, Check12 } from '@iota/icons'; import { useEffect, useMemo, useState } from 'react'; import { Navigate, useLocation, useNavigate, useParams } from 'react-router-dom'; -import { VerifyPasswordModal } from '../../components/accounts/VerifyPasswordModal'; -import { useAccountSources } from '../../hooks/useAccountSources'; -import { useExportPassphraseMutation } from '../../hooks/useExportPassphraseMutation'; +import { VerifyPasswordModal } from '_components/accounts/VerifyPasswordModal'; +import { useAccountSources } from '_app/hooks/useAccountSources'; +import { useExportPassphraseMutation } from '_app/hooks/useExportPassphraseMutation'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; export function BackupMnemonicPage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/ExportAccountPage.tsx b/apps/wallet/src/ui/app/pages/accounts/ExportAccountPage.tsx index df9f24ba6e8..f191e86fbdc 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ExportAccountPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ExportAccountPage.tsx @@ -6,12 +6,12 @@ import { useBackgroundClient } from '_src/ui/app/hooks/useBackgroundClient'; import { useMutation } from '@tanstack/react-query'; import { Navigate, useNavigate, useParams } from 'react-router-dom'; -import { VerifyPasswordModal } from '../../components/accounts/VerifyPasswordModal'; -import Alert from '../../components/alert'; -import { HideShowDisplayBox } from '../../components/HideShowDisplayBox'; -import Loading from '../../components/loading'; -import Overlay from '../../components/overlay'; -import { useAccounts } from '../../hooks/useAccounts'; +import { VerifyPasswordModal } from '_components/accounts/VerifyPasswordModal'; +import Alert from '_components/alert'; +import { HideShowDisplayBox } from '_components/HideShowDisplayBox'; +import Loading from '_components/loading'; +import Overlay from '_components/overlay'; +import { useAccounts } from '_app/hooks/useAccounts'; export function ExportAccountPage() { const { accountID } = useParams(); diff --git a/apps/wallet/src/ui/app/pages/accounts/ExportPassphrasePage.tsx b/apps/wallet/src/ui/app/pages/accounts/ExportPassphrasePage.tsx index d22149f1fcb..0cdf0502159 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ExportPassphrasePage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ExportPassphrasePage.tsx @@ -6,11 +6,11 @@ import Alert from '_components/alert'; import { HideShowDisplayBox } from '_components/HideShowDisplayBox'; import { Navigate, useNavigate, useParams } from 'react-router-dom'; -import { VerifyPasswordModal } from '../../components/accounts/VerifyPasswordModal'; -import Loading from '../../components/loading'; -import Overlay from '../../components/overlay'; -import { useAccountSources } from '../../hooks/useAccountSources'; -import { useExportPassphraseMutation } from '../../hooks/useExportPassphraseMutation'; +import { VerifyPasswordModal } from '_components/accounts/VerifyPasswordModal'; +import Loading from '_components/loading'; +import Overlay from '_components/overlay'; +import { useAccountSources } from '_app/hooks/useAccountSources'; +import { useExportPassphraseMutation } from '_app/hooks/useExportPassphraseMutation'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; export function ExportPassphrasePage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/ExportSeedPage.tsx b/apps/wallet/src/ui/app/pages/accounts/ExportSeedPage.tsx index 9e7e770cdb3..9626d2aef8d 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ExportSeedPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ExportSeedPage.tsx @@ -5,11 +5,11 @@ import Alert from '_components/alert'; import { HideShowDisplayBox } from '_components/HideShowDisplayBox'; import { Navigate, useNavigate, useParams } from 'react-router-dom'; -import { VerifyPasswordModal } from '../../components/accounts/VerifyPasswordModal'; -import Loading from '../../components/loading'; -import Overlay from '../../components/overlay'; -import { useAccountSources } from '../../hooks/useAccountSources'; -import { useExportSeedMutation } from '../../hooks/useExportSeedMutation'; +import { VerifyPasswordModal } from '_components/accounts/VerifyPasswordModal'; +import Loading from '_components/loading'; +import Overlay from '_components/overlay'; +import { useAccountSources } from '_app/hooks/useAccountSources'; +import { useExportSeedMutation } from '_app/hooks/useExportSeedMutation'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; export function ExportSeedPage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/ImportLedgerAccountsPage.tsx b/apps/wallet/src/ui/app/pages/accounts/ImportLedgerAccountsPage.tsx index a7ea433b145..4afeaec6a0d 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ImportLedgerAccountsPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ImportLedgerAccountsPage.tsx @@ -14,21 +14,18 @@ import { useCallback, useEffect, useState } from 'react'; import toast from 'react-hot-toast'; import { useNavigate, useSearchParams } from 'react-router-dom'; -import { - AccountsFormType, - useAccountsFormContext, -} from '../../components/accounts/AccountsFormContext'; +import { AccountsFormType, useAccountsFormContext } from '_components/accounts/AccountsFormContext'; import { LedgerAccountList, type SelectableLedgerAccount, -} from '../../components/ledger/LedgerAccountList'; +} from '_components/ledger/LedgerAccountList'; import { useDeriveLedgerAccounts, type DerivedLedgerAccount, -} from '../../components/ledger/useDeriveLedgerAccounts'; -import Overlay from '../../components/overlay'; -import { getIotaApplicationErrorMessage } from '../../helpers/errorMessages'; -import { useAccounts } from '../../hooks/useAccounts'; +} from '_components/ledger/useDeriveLedgerAccounts'; +import Overlay from '_components/overlay'; +import { getIotaApplicationErrorMessage } from '_app/helpers/errorMessages'; +import { useAccounts } from '_app/hooks/useAccounts'; const NUM_LEDGER_ACCOUNTS_TO_DERIVE_BY_DEFAULT = 10; diff --git a/apps/wallet/src/ui/app/pages/accounts/ImportPassphrasePage.tsx b/apps/wallet/src/ui/app/pages/accounts/ImportPassphrasePage.tsx index 61f33d8b48b..98415ef6f7f 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ImportPassphrasePage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ImportPassphrasePage.tsx @@ -6,12 +6,9 @@ import { Text } from '_app/shared/text'; import { entropyToSerialized, mnemonicToEntropy } from '_src/shared/utils'; import { useNavigate } from 'react-router-dom'; -import { - AccountsFormType, - useAccountsFormContext, -} from '../../components/accounts/AccountsFormContext'; -import { ImportRecoveryPhraseForm } from '../../components/accounts/ImportRecoveryPhraseForm'; -import { Heading } from '../../shared/heading'; +import { AccountsFormType, useAccountsFormContext } from '_components/accounts/AccountsFormContext'; +import { ImportRecoveryPhraseForm } from '_components/accounts/ImportRecoveryPhraseForm'; +import { Heading } from '_app/shared/heading'; export function ImportPassphrasePage() { const navigate = useNavigate(); diff --git a/apps/wallet/src/ui/app/pages/accounts/ImportPrivateKeyPage.tsx b/apps/wallet/src/ui/app/pages/accounts/ImportPrivateKeyPage.tsx index 4139bc2e431..ef17ffbacb0 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ImportPrivateKeyPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ImportPrivateKeyPage.tsx @@ -5,12 +5,9 @@ import { Text } from '_app/shared/text'; import { useNavigate } from 'react-router-dom'; -import { - AccountsFormType, - useAccountsFormContext, -} from '../../components/accounts/AccountsFormContext'; -import { ImportPrivateKeyForm } from '../../components/accounts/ImportPrivateKeyForm'; -import { Heading } from '../../shared/heading'; +import { AccountsFormType, useAccountsFormContext } from '_components/accounts/AccountsFormContext'; +import { ImportPrivateKeyForm } from '_components/accounts/ImportPrivateKeyForm'; +import { Heading } from '_app/shared/heading'; export function ImportPrivateKeyPage() { const navigate = useNavigate(); diff --git a/apps/wallet/src/ui/app/pages/accounts/ImportSeedPage.tsx b/apps/wallet/src/ui/app/pages/accounts/ImportSeedPage.tsx index 3bb12e3270c..419e2ecc8f0 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ImportSeedPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ImportSeedPage.tsx @@ -4,12 +4,9 @@ import { Text } from '_app/shared/text'; import { useNavigate } from 'react-router-dom'; -import { - AccountsFormType, - useAccountsFormContext, -} from '../../components/accounts/AccountsFormContext'; -import { ImportSeedForm } from '../../components/accounts/ImportSeedForm'; -import { Heading } from '../../shared/heading'; +import { AccountsFormType, useAccountsFormContext } from '_components/accounts/AccountsFormContext'; +import { ImportSeedForm } from '_components/accounts/ImportSeedForm'; +import { Heading } from '_app/shared/heading'; export function ImportSeedPage() { const navigate = useNavigate(); diff --git a/apps/wallet/src/ui/app/pages/accounts/ProtectAccountPage.tsx b/apps/wallet/src/ui/app/pages/accounts/ProtectAccountPage.tsx index da9892ad5ec..f3bfbc8f0e1 100644 --- a/apps/wallet/src/ui/app/pages/accounts/ProtectAccountPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/ProtectAccountPage.tsx @@ -8,18 +8,18 @@ import { useCallback, useEffect, useMemo, useState } from 'react'; import { toast } from 'react-hot-toast'; import { Navigate, useNavigate, useSearchParams } from 'react-router-dom'; -import { ProtectAccountForm } from '../../components/accounts/ProtectAccountForm'; -import { VerifyPasswordModal } from '../../components/accounts/VerifyPasswordModal'; -import Loading from '../../components/loading'; -import { useAccounts } from '../../hooks/useAccounts'; -import { autoLockDataToMinutes } from '../../hooks/useAutoLockMinutes'; -import { useAutoLockMinutesMutation } from '../../hooks/useAutoLockMinutesMutation'; -import { useCreateAccountsMutation } from '../../hooks/useCreateAccountMutation'; -import { Heading } from '../../shared/heading'; -import { AccountsFormType } from '../../components/accounts/AccountsFormContext'; +import { ProtectAccountForm } from '_components/accounts/ProtectAccountForm'; +import { VerifyPasswordModal } from '_components/accounts/VerifyPasswordModal'; +import Loading from '_components/loading'; +import { useAccounts } from '_app/hooks/useAccounts'; +import { autoLockDataToMinutes } from '_app/hooks/useAutoLockMinutes'; +import { useAutoLockMinutesMutation } from '_app/hooks/useAutoLockMinutesMutation'; +import { useCreateAccountsMutation } from '_app/hooks/useCreateAccountMutation'; +import { Heading } from '_app/shared/heading'; +import { AccountsFormType } from '_components/accounts/AccountsFormContext'; import { isSeedSerializedUiAccount } from '_src/background/accounts/SeedAccount'; import { isLedgerAccountSerializedUI } from '_src/background/accounts/LedgerAccount'; -import { AllowedAccountSourceTypes } from '../../accounts-finder'; +import { AllowedAccountSourceTypes } from '_app/accounts-finder'; const ALLOWED_ACCOUNT_TYPES: AccountsFormType[] = [ AccountsFormType.NewMnemonic, diff --git a/apps/wallet/src/ui/app/pages/accounts/WelcomePage.tsx b/apps/wallet/src/ui/app/pages/accounts/WelcomePage.tsx index 92c9b19bc4c..d5a09f4ab2b 100644 --- a/apps/wallet/src/ui/app/pages/accounts/WelcomePage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/WelcomePage.tsx @@ -8,7 +8,7 @@ import { useFullscreenGuard, useInitializedGuard } from '_hooks'; import { Button, ButtonType } from '@iota/apps-ui-kit'; import { IotaLogoWeb } from '@iota/ui-icons'; -import { useCreateAccountsMutation } from '../../hooks/useCreateAccountMutation'; +import { useCreateAccountsMutation } from '_app/hooks/useCreateAccountMutation'; export function WelcomePage() { const createAccountsMutation = useCreateAccountsMutation(); diff --git a/apps/wallet/src/ui/app/pages/accounts/forgot-password/ForgotPasswordIndexPage.tsx b/apps/wallet/src/ui/app/pages/accounts/forgot-password/ForgotPasswordIndexPage.tsx index 5c994dd90c3..6bd9bac8b43 100644 --- a/apps/wallet/src/ui/app/pages/accounts/forgot-password/ForgotPasswordIndexPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/forgot-password/ForgotPasswordIndexPage.tsx @@ -5,7 +5,7 @@ import { useEffect } from 'react'; import { useNavigate } from 'react-router-dom'; -import { useAccountSources } from '../../../hooks/useAccountSources'; +import { useAccountSources } from '_app/hooks/useAccountSources'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; export function ForgotPasswordIndexPage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverManyPage.tsx b/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverManyPage.tsx index b3773b50194..e7a58743f2c 100644 --- a/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverManyPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverManyPage.tsx @@ -10,12 +10,12 @@ import { useEffect, useState } from 'react'; import toast from 'react-hot-toast'; import { useNavigate } from 'react-router-dom'; -import { RecoverAccountsGroup } from '../../../components/accounts/RecoverAccountsGroup'; -import { useAccountGroups } from '../../../hooks/useAccountGroups'; -import { useAccountSources } from '../../../hooks/useAccountSources'; -import { Button } from '../../../shared/ButtonUI'; -import { Heading } from '../../../shared/heading'; -import { Text } from '../../../shared/text'; +import { RecoverAccountsGroup } from '_components/accounts/RecoverAccountsGroup'; +import { useAccountGroups } from '_app/hooks/useAccountGroups'; +import { useAccountSources } from '_app/hooks/useAccountSources'; +import { Button } from '_app/shared/ButtonUI'; +import { Heading } from '_app/shared/heading'; +import { Text } from '_app/shared/text'; import { useForgotPasswordContext } from './ForgotPasswordPage'; import { ImportSeedForm } from '_src/ui/app/components/accounts/ImportSeedForm'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; diff --git a/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverPage.tsx b/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverPage.tsx index 7d7c3daede7..008d3674a3b 100644 --- a/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/forgot-password/RecoverPage.tsx @@ -9,9 +9,9 @@ import { useEffect } from 'react'; import toast from 'react-hot-toast'; import { useNavigate } from 'react-router-dom'; -import { useAccountSources } from '../../../hooks/useAccountSources'; -import { Heading } from '../../../shared/heading'; -import { Text } from '../../../shared/text'; +import { useAccountSources } from '_app/hooks/useAccountSources'; +import { Heading } from '_app/shared/heading'; +import { Text } from '_app/shared/text'; import { ImportSeedForm } from '_src/ui/app/components/accounts/ImportSeedForm'; import { AccountSourceType } from '_src/background/account-sources/AccountSource'; diff --git a/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetPasswordPage.tsx b/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetPasswordPage.tsx index 3fd59381197..524aa5b2583 100644 --- a/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetPasswordPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetPasswordPage.tsx @@ -7,9 +7,9 @@ import { useResetPasswordMutation } from '_src/ui/app/hooks/useResetPasswordMuta import { toast } from 'react-hot-toast'; import { Navigate, useNavigate } from 'react-router-dom'; -import { ProtectAccountForm } from '../../../components/accounts/ProtectAccountForm'; -import { autoLockDataToMinutes } from '../../../hooks/useAutoLockMinutes'; -import { Heading } from '../../../shared/heading'; +import { ProtectAccountForm } from '_components/accounts/ProtectAccountForm'; +import { autoLockDataToMinutes } from '_app/hooks/useAutoLockMinutes'; +import { Heading } from '_app/shared/heading'; import { useForgotPasswordContext } from './ForgotPasswordPage'; export function ResetPasswordPage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetWarningPage.tsx b/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetWarningPage.tsx index 81336c90734..11b970a4435 100644 --- a/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetWarningPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/forgot-password/ResetWarningPage.tsx @@ -6,11 +6,11 @@ import { Button } from '_app/shared/ButtonUI'; import { useAccounts } from '_src/ui/app/hooks/useAccounts'; import { Navigate, useNavigate } from 'react-router-dom'; -import { RecoverAccountsGroup } from '../../../components/accounts/RecoverAccountsGroup'; -import { useAccountGroups } from '../../../hooks/useAccountGroups'; -import { Heading } from '../../../shared/heading'; -import { Text } from '../../../shared/text'; -import { getGroupTitle } from '../manage/AccountGroup'; +import { RecoverAccountsGroup } from '_components/accounts/RecoverAccountsGroup'; +import { useAccountGroups } from '_app/hooks/useAccountGroups'; +import { Heading } from '_app/shared/heading'; +import { Text } from '_app/shared/text'; +import { getGroupTitle } from '_pages/accounts/manage/AccountGroup'; import { useForgotPasswordContext } from './ForgotPasswordPage'; export function ResetWarningPage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/manage/ManageAccountsPage.tsx b/apps/wallet/src/ui/app/pages/accounts/manage/ManageAccountsPage.tsx index a5f7c4ae39f..5b040069678 100644 --- a/apps/wallet/src/ui/app/pages/accounts/manage/ManageAccountsPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/manage/ManageAccountsPage.tsx @@ -6,7 +6,7 @@ import { useInitializedGuard } from '_src/ui/app/hooks'; import { useAccountGroups } from '_src/ui/app/hooks/useAccountGroups'; import { useNavigate } from 'react-router-dom'; -import Overlay from '../../../components/overlay'; +import Overlay from '_components/overlay'; import { AccountGroup } from './AccountGroup'; export function ManageAccountsPage() { diff --git a/apps/wallet/src/ui/app/pages/accounts/manage/accounts-finder/AccountsFinderPage.tsx b/apps/wallet/src/ui/app/pages/accounts/manage/accounts-finder/AccountsFinderPage.tsx index c9a9f486edd..a923477c3fd 100644 --- a/apps/wallet/src/ui/app/pages/accounts/manage/accounts-finder/AccountsFinderPage.tsx +++ b/apps/wallet/src/ui/app/pages/accounts/manage/accounts-finder/AccountsFinderPage.tsx @@ -3,7 +3,7 @@ import { useInitializedGuard } from '_src/ui/app/hooks'; import { useNavigate } from 'react-router-dom'; -import Overlay from '../../../../components/overlay'; +import Overlay from '_components/overlay'; import { AccountsFinderView } from './AccountsFinderView'; export function AccountsFinderPage() { diff --git a/apps/wallet/src/ui/app/pages/approval-request/SignMessageRequest.tsx b/apps/wallet/src/ui/app/pages/approval-request/SignMessageRequest.tsx index 1800b786d78..a66ff4e6753 100644 --- a/apps/wallet/src/ui/app/pages/approval-request/SignMessageRequest.tsx +++ b/apps/wallet/src/ui/app/pages/approval-request/SignMessageRequest.tsx @@ -6,14 +6,14 @@ import { type SignMessageApprovalRequest } from '_payloads/transactions/Approval import { toUtf8OrB64 } from '_src/shared/utils'; import { useMemo } from 'react'; -import { UserApproveContainer } from '../../components/user-approve-container'; -import { useAppDispatch } from '../../hooks'; -import { useAccountByAddress } from '../../hooks/useAccountByAddress'; -import { useSigner } from '../../hooks/useSigner'; -import { respondToTransactionRequest } from '../../redux/slices/transaction-requests'; -import { Heading } from '../../shared/heading'; -import { PageMainLayoutTitle } from '../../shared/page-main-layout/PageMainLayoutTitle'; -import { Text } from '../../shared/text'; +import { UserApproveContainer } from '_components/user-approve-container'; +import { useAppDispatch } from '_app/hooks'; +import { useAccountByAddress } from '_app/hooks/useAccountByAddress'; +import { useSigner } from '_app/hooks/useSigner'; +import { respondToTransactionRequest } from '_redux/slices/transaction-requests'; +import { Heading } from '_app/shared/heading'; +import { PageMainLayoutTitle } from '_app/shared/page-main-layout/PageMainLayoutTitle'; +import { Text } from '_app/shared/text'; export interface SignMessageRequestProps { request: SignMessageApprovalRequest; diff --git a/apps/wallet/src/ui/app/pages/approval-request/index.tsx b/apps/wallet/src/ui/app/pages/approval-request/index.tsx index 60201e562b4..840be7b7a16 100644 --- a/apps/wallet/src/ui/app/pages/approval-request/index.tsx +++ b/apps/wallet/src/ui/app/pages/approval-request/index.tsx @@ -9,10 +9,10 @@ import { import { useEffect, useMemo } from 'react'; import { useParams } from 'react-router-dom'; -import Loading from '../../components/loading'; -import { useAppSelector } from '../../hooks'; -import { type RootState } from '../../redux/RootReducer'; -import { txRequestsSelectors } from '../../redux/slices/transaction-requests'; +import Loading from '_components/loading'; +import { useAppSelector } from '_app/hooks'; +import { type RootState } from '_redux/RootReducer'; +import { txRequestsSelectors } from '_redux/slices/transaction-requests'; import { SignMessageRequest } from './SignMessageRequest'; import { TransactionRequest } from './transaction-request'; diff --git a/apps/wallet/src/ui/app/pages/approval-request/transaction-request/SummaryCard.tsx b/apps/wallet/src/ui/app/pages/approval-request/transaction-request/SummaryCard.tsx index 09ed7402b2c..b0d23e8dd74 100644 --- a/apps/wallet/src/ui/app/pages/approval-request/transaction-request/SummaryCard.tsx +++ b/apps/wallet/src/ui/app/pages/approval-request/transaction-request/SummaryCard.tsx @@ -6,7 +6,7 @@ import { ChevronDown16, ChevronRight16 } from '@iota/icons'; import clsx from 'clsx'; import { useState, type ReactNode } from 'react'; -import { Text } from '../../../shared/text'; +import { Text } from '_app/shared/text'; interface SummaryCardProps { header: ReactNode; diff --git a/apps/wallet/src/ui/app/pages/approval-request/transaction-request/TransactionDetails/index.tsx b/apps/wallet/src/ui/app/pages/approval-request/transaction-request/TransactionDetails/index.tsx index e22aecfee94..7936c63e498 100644 --- a/apps/wallet/src/ui/app/pages/approval-request/transaction-request/TransactionDetails/index.tsx +++ b/apps/wallet/src/ui/app/pages/approval-request/transaction-request/TransactionDetails/index.tsx @@ -6,7 +6,7 @@ import { useTransactionData } from '_src/ui/app/hooks'; import { Tab as HeadlessTab, type TabProps } from '@headlessui/react'; import { type TransactionBlock } from '@iota/iota.js/transactions'; -import { SummaryCard } from '../SummaryCard'; +import { SummaryCard } from '_pages/approval-request/transaction-request/SummaryCard'; import { Command } from './Command'; import { Input } from './Input'; diff --git a/apps/wallet/src/ui/app/pages/approval-request/transaction-request/index.tsx b/apps/wallet/src/ui/app/pages/approval-request/transaction-request/index.tsx index df9ac0f7499..7b96ba79207 100644 --- a/apps/wallet/src/ui/app/pages/approval-request/transaction-request/index.tsx +++ b/apps/wallet/src/ui/app/pages/approval-request/transaction-request/index.tsx @@ -17,7 +17,7 @@ import { useTransactionSummary } from '@iota/core'; import { TransactionBlock } from '@iota/iota.js/transactions'; import { useMemo, useState } from 'react'; -import { ConfirmationModal } from '../../../shared/ConfirmationModal'; +import { ConfirmationModal } from '_app/shared/ConfirmationModal'; import { GasFees } from './GasFees'; import { TransactionDetails } from './TransactionDetails'; diff --git a/apps/wallet/src/ui/app/pages/home/assets/index.tsx b/apps/wallet/src/ui/app/pages/home/assets/index.tsx index 54c64ef14b7..788f068978f 100644 --- a/apps/wallet/src/ui/app/pages/home/assets/index.tsx +++ b/apps/wallet/src/ui/app/pages/home/assets/index.tsx @@ -6,7 +6,7 @@ import { useUnlockedGuard } from '_src/ui/app/hooks/useUnlockedGuard'; import { Route, Routes } from 'react-router-dom'; import { HiddenAssetsPage, NftsPage } from '..'; -import { HiddenAssetsProvider } from '../hidden-assets/HiddenAssetsProvider'; +import { HiddenAssetsProvider } from '_pages/home/hidden-assets/HiddenAssetsProvider'; function AssetsPage() { if (useUnlockedGuard()) { diff --git a/apps/wallet/src/ui/app/pages/home/hidden-assets/HiddenAssetsProvider.tsx b/apps/wallet/src/ui/app/pages/home/hidden-assets/HiddenAssetsProvider.tsx index 393a9315795..0f326cccb50 100644 --- a/apps/wallet/src/ui/app/pages/home/hidden-assets/HiddenAssetsProvider.tsx +++ b/apps/wallet/src/ui/app/pages/home/hidden-assets/HiddenAssetsProvider.tsx @@ -8,7 +8,7 @@ import { get, set } from 'idb-keyval'; import { createContext, useCallback, useContext, useEffect, useState, type ReactNode } from 'react'; import { toast } from 'react-hot-toast'; -import { Link as InlineLink } from '../../../shared/Link'; +import { Link as InlineLink } from '_app/shared/Link'; const HIDDEN_ASSET_IDS = 'hidden-asset-ids'; diff --git a/apps/wallet/src/ui/app/pages/home/interstitial/index.tsx b/apps/wallet/src/ui/app/pages/home/interstitial/index.tsx index 95da37bf507..9a5b67a87dc 100644 --- a/apps/wallet/src/ui/app/pages/home/interstitial/index.tsx +++ b/apps/wallet/src/ui/app/pages/home/interstitial/index.tsx @@ -8,7 +8,7 @@ import { X32 } from '@iota/icons'; import { useEffect } from 'react'; import { useNavigate } from 'react-router-dom'; -import { Portal } from '../../../shared/Portal'; +import { Portal } from '_app/shared/Portal'; export type InterstitialConfig = { enabled: boolean; diff --git a/apps/wallet/src/ui/app/pages/home/nfts/VisualAssets.tsx b/apps/wallet/src/ui/app/pages/home/nfts/VisualAssets.tsx index 5d0d70a4641..e78315b7e88 100644 --- a/apps/wallet/src/ui/app/pages/home/nfts/VisualAssets.tsx +++ b/apps/wallet/src/ui/app/pages/home/nfts/VisualAssets.tsx @@ -10,7 +10,7 @@ import { EyeClose16 } from '@iota/icons'; import { type IotaObjectData } from '@iota/iota.js/client'; import { Link } from 'react-router-dom'; -import { useHiddenAssets } from '../hidden-assets/HiddenAssetsProvider'; +import { useHiddenAssets } from '_pages/home/hidden-assets/HiddenAssetsProvider'; import { getKioskIdFromOwnerCap, isKioskOwnerToken, useKioskClient } from '@iota/core'; interface VisualAssetsProps { diff --git a/apps/wallet/src/ui/app/pages/home/nfts/index.tsx b/apps/wallet/src/ui/app/pages/home/nfts/index.tsx index 19073f31b65..66bf6986b87 100644 --- a/apps/wallet/src/ui/app/pages/home/nfts/index.tsx +++ b/apps/wallet/src/ui/app/pages/home/nfts/index.tsx @@ -14,7 +14,7 @@ import { useOnScreen } from '@iota/core'; import { useEffect, useMemo, useRef } from 'react'; import { useParams } from 'react-router-dom'; -import { useHiddenAssets } from '../hidden-assets/HiddenAssetsProvider'; +import { useHiddenAssets } from '_pages/home/hidden-assets/HiddenAssetsProvider'; import AssetsOptionsMenu from './AssetsOptionsMenu'; import NonVisualAssets from './NonVisualAssets'; import VisualAssets from './VisualAssets'; diff --git a/apps/wallet/src/ui/app/pages/home/tokens/TokensDetails.tsx b/apps/wallet/src/ui/app/pages/home/tokens/TokensDetails.tsx index 9b757a5e151..c366246a013 100644 --- a/apps/wallet/src/ui/app/pages/home/tokens/TokensDetails.tsx +++ b/apps/wallet/src/ui/app/pages/home/tokens/TokensDetails.tsx @@ -40,7 +40,7 @@ import { useQuery } from '@tanstack/react-query'; import clsx from 'clsx'; import { useEffect, useState, type ReactNode } from 'react'; -import Interstitial, { type InterstitialConfig } from '../interstitial'; +import Interstitial, { type InterstitialConfig } from '_pages/home/interstitial'; import { CoinBalance } from './coin-balance'; import { PortfolioName } from './PortfolioName'; import { TokenIconLink } from './TokenIconLink'; diff --git a/apps/wallet/src/ui/app/pages/restricted/index.tsx b/apps/wallet/src/ui/app/pages/restricted/index.tsx index 4e053c3a2e6..e31400f3d16 100644 --- a/apps/wallet/src/ui/app/pages/restricted/index.tsx +++ b/apps/wallet/src/ui/app/pages/restricted/index.tsx @@ -2,8 +2,8 @@ // Modifications Copyright (c) 2024 IOTA Stiftung // SPDX-License-Identifier: Apache-2.0 -import { useInitializedGuard } from '../../hooks'; -import { Text } from '../../shared/text'; +import { useInitializedGuard } from '_app/hooks'; +import { Text } from '_app/shared/text'; import SadCapy from './SadCapy.svg'; export function RestrictedPage() { diff --git a/apps/wallet/src/ui/app/pages/site-connect/index.tsx b/apps/wallet/src/ui/app/pages/site-connect/index.tsx index 2a65672e989..924cef7f331 100644 --- a/apps/wallet/src/ui/app/pages/site-connect/index.tsx +++ b/apps/wallet/src/ui/app/pages/site-connect/index.tsx @@ -13,12 +13,12 @@ import { ampli } from '_src/shared/analytics/ampli'; import { useCallback, useEffect, useMemo, useState } from 'react'; import { useParams } from 'react-router-dom'; -import { AccountMultiSelectWithControls } from '../../components/accounts/AccountMultiSelect'; -import Alert from '../../components/alert'; -import { SectionHeader } from '../../components/SectionHeader'; -import { useAccountGroups } from '../../hooks/useAccountGroups'; -import { useActiveAccount } from '../../hooks/useActiveAccount'; -import { PageMainLayoutTitle } from '../../shared/page-main-layout/PageMainLayoutTitle'; +import { AccountMultiSelectWithControls } from '_components/accounts/AccountMultiSelect'; +import Alert from '_components/alert'; +import { SectionHeader } from '_components/SectionHeader'; +import { useAccountGroups } from '_app/hooks/useAccountGroups'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; +import { PageMainLayoutTitle } from '_app/shared/page-main-layout/PageMainLayoutTitle'; import st from './SiteConnectPage.module.scss'; function SiteConnectPage() { diff --git a/apps/wallet/src/ui/app/shared/InputWithAction.tsx b/apps/wallet/src/ui/app/shared/InputWithAction.tsx index dd09ab2051a..9f7e49ed6e7 100644 --- a/apps/wallet/src/ui/app/shared/InputWithAction.tsx +++ b/apps/wallet/src/ui/app/shared/InputWithAction.tsx @@ -11,7 +11,7 @@ import { useField, useFormikContext } from 'formik'; import type { ComponentProps, ReactNode } from 'react'; import { forwardRef } from 'react'; -import Alert from '../components/alert'; +import Alert from '_components/alert'; import { Pill, type PillProps } from './Pill'; const styles = cva( diff --git a/apps/wallet/src/ui/app/shared/dapp-status/index.tsx b/apps/wallet/src/ui/app/shared/dapp-status/index.tsx index 1b0a427cd22..66efa3e86f9 100644 --- a/apps/wallet/src/ui/app/shared/dapp-status/index.tsx +++ b/apps/wallet/src/ui/app/shared/dapp-status/index.tsx @@ -18,8 +18,8 @@ import { ChevronDown12, Dot12 } from '@iota/icons'; import { AnimatePresence, motion } from 'framer-motion'; import { memo, useCallback, useMemo, useRef, useState } from 'react'; -import { useActiveAddress } from '../../hooks/useActiveAddress'; -import { ButtonConnectedTo } from '../ButtonConnectedTo'; +import { useActiveAddress } from '_app/hooks/useActiveAddress'; +import { ButtonConnectedTo } from '_app/shared/ButtonConnectedTo'; import { appDisconnect } from './actions'; import st from './DappStatus.module.scss'; diff --git a/apps/wallet/src/ui/app/shared/faucet/useFaucetMutation.ts b/apps/wallet/src/ui/app/shared/faucet/useFaucetMutation.ts index 32da7ad44f8..fcde068b313 100644 --- a/apps/wallet/src/ui/app/shared/faucet/useFaucetMutation.ts +++ b/apps/wallet/src/ui/app/shared/faucet/useFaucetMutation.ts @@ -5,7 +5,7 @@ import { getFaucetRequestStatus, requestIotaFromFaucetV1 } from '@iota/iota.js/faucet'; import { useIsMutating, useMutation, type UseMutationOptions } from '@tanstack/react-query'; -import { useActiveAccount } from '../../hooks/useActiveAccount'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; type UseFaucetMutationOptions = Pick & { host?: string; diff --git a/apps/wallet/src/ui/app/shared/forms/FormField.tsx b/apps/wallet/src/ui/app/shared/forms/FormField.tsx index cf1a90ec165..a9fadc4746d 100644 --- a/apps/wallet/src/ui/app/shared/forms/FormField.tsx +++ b/apps/wallet/src/ui/app/shared/forms/FormField.tsx @@ -5,7 +5,7 @@ import { type ReactNode } from 'react'; import { useFormContext } from 'react-hook-form'; -import Alert from '../../components/alert'; +import Alert from '_app/components/alert'; import { FormLabel } from './FormLabel'; interface FormFieldProps { diff --git a/apps/wallet/src/ui/app/shared/forms/controls/PasswordInput.tsx b/apps/wallet/src/ui/app/shared/forms/controls/PasswordInput.tsx index 5b566db10f0..87107582308 100644 --- a/apps/wallet/src/ui/app/shared/forms/controls/PasswordInput.tsx +++ b/apps/wallet/src/ui/app/shared/forms/controls/PasswordInput.tsx @@ -5,7 +5,7 @@ import { EyeClose16, EyeOpen16 } from '@iota/icons'; import { forwardRef, useState, type ComponentProps } from 'react'; -import { ButtonOrLink } from '../../utils/ButtonOrLink'; +import { ButtonOrLink } from '_app/shared/utils/ButtonOrLink'; import { Input } from './Input'; type PasswordInputProps = { diff --git a/apps/wallet/src/ui/app/shared/header/Header.tsx b/apps/wallet/src/ui/app/shared/header/Header.tsx index dd12650769e..918306a1883 100644 --- a/apps/wallet/src/ui/app/shared/header/Header.tsx +++ b/apps/wallet/src/ui/app/shared/header/Header.tsx @@ -6,7 +6,7 @@ import { type Network } from '@iota/iota.js/client'; import { type ReactNode } from 'react'; import { Link } from 'react-router-dom'; -import Logo from '../../components/logo'; +import Logo from '_components/logo'; interface HeaderProps { network: Network; diff --git a/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayout.tsx b/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayout.tsx index a4131572daa..157246c5e42 100644 --- a/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayout.tsx +++ b/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayout.tsx @@ -8,12 +8,12 @@ import { Navigation } from '_components/navigation'; import cn from 'clsx'; import { createContext, useState, type ReactNode } from 'react'; -import { WalletSettingsButton } from '../../components/menu/button/WalletSettingsButton'; -import { useAppSelector } from '../../hooks'; -import { AppType } from '../../redux/slices/app/AppType'; -import DappStatus from '../dapp-status'; -import { Header } from '../header/Header'; -import { Toaster } from '../toaster'; +import { WalletSettingsButton } from '_components/menu/button/WalletSettingsButton'; +import { useAppSelector } from '_app/hooks'; +import { AppType } from '_redux/slices/app/AppType'; +import DappStatus from '_app/shared/dapp-status'; +import { Header } from '_app/shared/header/Header'; +import { Toaster } from '_app/shared/toaster'; export const PageMainLayoutContext = createContext(null); diff --git a/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayoutTitle.tsx b/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayoutTitle.tsx index 10cec781cc9..b02095a5cc1 100644 --- a/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayoutTitle.tsx +++ b/apps/wallet/src/ui/app/shared/page-main-layout/PageMainLayoutTitle.tsx @@ -5,7 +5,7 @@ import { useContext } from 'react'; import { createPortal } from 'react-dom'; -import { Heading } from '../heading'; +import { Heading } from '_app/shared/heading'; import { PageMainLayoutContext } from './PageMainLayout'; export type PageMainLayoutTitleProps = { diff --git a/apps/wallet/src/ui/app/shared/toaster/index.tsx b/apps/wallet/src/ui/app/shared/toaster/index.tsx index b7989433493..4f7e433fd70 100644 --- a/apps/wallet/src/ui/app/shared/toaster/index.tsx +++ b/apps/wallet/src/ui/app/shared/toaster/index.tsx @@ -9,7 +9,7 @@ import cl from 'clsx'; import { Toaster as ToasterLib } from 'react-hot-toast'; import { useLocation } from 'react-router-dom'; -import { Portal } from '../Portal'; +import { Portal } from '_app/shared/Portal'; export type ToasterProps = { bottomNavEnabled?: boolean; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/OwnerFooter.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/OwnerFooter.tsx index 4b07aee5ff1..ba38e78b207 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/OwnerFooter.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/OwnerFooter.tsx @@ -7,7 +7,7 @@ import { ExplorerLinkType } from '_src/ui/app/components/explorer-link/ExplorerL import { useActiveAddress } from '_src/ui/app/hooks'; import { getOwnerDisplay } from '@iota/core'; -import { Text } from '../text'; +import { Text } from '_app/shared/text'; import { SummaryCardFooter } from './Card'; export function OwnerFooter({ owner, ownerType }: { owner?: string; ownerType?: string }) { diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/BalanceChanges.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/BalanceChanges.tsx index e6c30fae3a9..ca9c4d8c4de 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/BalanceChanges.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/BalanceChanges.tsx @@ -15,8 +15,8 @@ import { import classNames from 'clsx'; import { useMemo } from 'react'; -import { Card } from '../Card'; -import { OwnerFooter } from '../OwnerFooter'; +import { Card } from '_app/shared/transaction-summary/Card'; +import { OwnerFooter } from '_app/shared/transaction-summary/OwnerFooter'; interface BalanceChangesProps { changes?: BalanceChangeSummary; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/CoinStack.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/CoinStack.tsx index 61db485486f..5e3ac40f505 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/CoinStack.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/CoinStack.tsx @@ -4,7 +4,7 @@ import { CoinIcon } from '_src/ui/app/components/coin-icon'; -import { Text } from '../../text'; +import { Text } from '_app/shared/text'; export interface CoinsStackProps { coinTypes: string[]; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/ExplorerLink.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/ExplorerLink.tsx index 3fb39e1d256..dfe89d053b5 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/ExplorerLink.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/ExplorerLink.tsx @@ -6,8 +6,8 @@ import { useExplorerLink } from '_src/ui/app/hooks/useExplorerLink'; import { ArrowUpRight12 } from '@iota/icons'; import { useEffect, useState } from 'react'; -import { Text } from '../../text'; -import { Card } from '../Card'; +import { Text } from '_app/shared/text'; +import { Card } from '_app/shared/transaction-summary/Card'; const TIME_TO_WAIT_FOR_EXPLORER = 60 * 1000; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/GasSummary.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/GasSummary.tsx index e33fcafcce0..36d2164a643 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/GasSummary.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/GasSummary.tsx @@ -7,7 +7,7 @@ import { useActiveAddress } from '_src/ui/app/hooks'; import { useFormatCoin, type GasSummaryType } from '@iota/core'; import { formatAddress, IOTA_TYPE_ARG } from '@iota/iota.js/utils'; -import { Text } from '../../text'; +import { Text } from '_app/shared/text'; interface GasSummaryProps { gasSummary?: GasSummaryType; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/ObjectChanges.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/ObjectChanges.tsx index 78beadc60d3..19f83fb12f8 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/ObjectChanges.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/ObjectChanges.tsx @@ -16,9 +16,9 @@ import { ChevronDown12, ChevronRight12 } from '@iota/icons'; import { formatAddress } from '@iota/iota.js/utils'; import cx from 'clsx'; -import { ExpandableList } from '../../ExpandableList'; -import { Card } from '../Card'; -import { OwnerFooter } from '../OwnerFooter'; +import { ExpandableList } from '_app/shared/ExpandableList'; +import { Card } from '_app/shared/transaction-summary/Card'; +import { OwnerFooter } from '_app/shared/transaction-summary/OwnerFooter'; import { ObjectChangeDisplay } from './objectSummary/ObjectChangeDisplay'; interface ChevronDownProps { diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/SummaryCard.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/SummaryCard.tsx index 29309677f6b..9255ca27f18 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/SummaryCard.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/SummaryCard.tsx @@ -5,7 +5,7 @@ import { ChevronDown16, ChevronRight16 } from '@iota/icons'; import clsx from 'clsx'; import { useState, type ReactNode } from 'react'; -import { Text } from '../../../shared/text'; +import { Text } from '_app/shared/text'; interface SummaryCardProps { header: ReactNode; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/TotalAmount.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/TotalAmount.tsx index f5a3be5cc29..46a149047d6 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/TotalAmount.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/TotalAmount.tsx @@ -5,7 +5,7 @@ import { Heading } from '_src/ui/app/shared/heading'; import { Text } from '_src/ui/app/shared/text'; import { useFormatCoin } from '@iota/core'; -import { Card } from '../Card'; +import { Card } from '_app/shared/transaction-summary/Card'; interface TotalAmountProps { amount?: string; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/cards/objectSummary/ObjectChangeDisplay.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/cards/objectSummary/ObjectChangeDisplay.tsx index 38cc0b9f66c..a9de5be158e 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/cards/objectSummary/ObjectChangeDisplay.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/cards/objectSummary/ObjectChangeDisplay.tsx @@ -8,7 +8,7 @@ import { NftImage } from '_src/ui/app/components/nft-display/NftImage'; import { type IotaObjectChangeWithDisplay } from '@iota/core'; import { formatAddress } from '@iota/iota.js/utils'; -import { Text } from '../../../text'; +import { Text } from '_app/shared/text'; export function ObjectChangeDisplay({ change }: { change: IotaObjectChangeWithDisplay }) { const display = change?.display?.data; diff --git a/apps/wallet/src/ui/app/shared/transaction-summary/index.tsx b/apps/wallet/src/ui/app/shared/transaction-summary/index.tsx index ea25e3a663d..1fa57dcce2c 100644 --- a/apps/wallet/src/ui/app/shared/transaction-summary/index.tsx +++ b/apps/wallet/src/ui/app/shared/transaction-summary/index.tsx @@ -4,8 +4,8 @@ import { type TransactionSummary as TransactionSummaryType } from '@iota/core'; import clsx from 'clsx'; -import LoadingIndicator from '../../components/loading/LoadingIndicator'; -import { Heading } from '../heading'; +import LoadingIndicator from '_components/loading/LoadingIndicator'; +import { Heading } from '_app/shared/heading'; import { BalanceChanges } from './cards/BalanceChanges'; import { ExplorerLinkCard } from './cards/ExplorerLink'; import { GasSummary } from './cards/GasSummary'; diff --git a/apps/wallet/src/ui/app/shared/utils/ButtonOrLink.tsx b/apps/wallet/src/ui/app/shared/utils/ButtonOrLink.tsx index 31684976ce6..07a18e88051 100644 --- a/apps/wallet/src/ui/app/shared/utils/ButtonOrLink.tsx +++ b/apps/wallet/src/ui/app/shared/utils/ButtonOrLink.tsx @@ -6,8 +6,8 @@ import clsx from 'clsx'; import { forwardRef, type ComponentProps, type ReactNode, type Ref } from 'react'; import { Link, type LinkProps } from 'react-router-dom'; -import LoadingIndicator from '../../components/loading/LoadingIndicator'; -import { Tooltip } from '../tooltip'; +import LoadingIndicator from '_components/loading/LoadingIndicator'; +import { Tooltip } from '_app/shared/tooltip'; interface WithTooltipProps { title?: ReactNode; diff --git a/apps/wallet/src/ui/app/staking/delegation-detail/DelegationDetailCard.tsx b/apps/wallet/src/ui/app/staking/delegation-detail/DelegationDetailCard.tsx index 1b1f25d6216..74dd4d39f45 100644 --- a/apps/wallet/src/ui/app/staking/delegation-detail/DelegationDetailCard.tsx +++ b/apps/wallet/src/ui/app/staking/delegation-detail/DelegationDetailCard.tsx @@ -29,10 +29,10 @@ import { MICROS_PER_IOTA, IOTA_TYPE_ARG } from '@iota/iota.js/utils'; import BigNumber from 'bignumber.js'; import { useMemo } from 'react'; -import { useActiveAddress } from '../../hooks/useActiveAddress'; -import { Heading } from '../../shared/heading'; -import { getDelegationDataByStakeId } from '../getDelegationByStakeId'; -import { StakeAmount } from '../home/StakeAmount'; +import { useActiveAddress } from '_app/hooks/useActiveAddress'; +import { Heading } from '_app/shared/heading'; +import { getDelegationDataByStakeId } from '_app/staking/getDelegationByStakeId'; +import { StakeAmount } from '_app/staking/home/StakeAmount'; interface DelegationDetailCardProps { validatorAddress: string; diff --git a/apps/wallet/src/ui/app/staking/delegation-detail/index.tsx b/apps/wallet/src/ui/app/staking/delegation-detail/index.tsx index b9bf5f948ca..0e9e5dd030b 100644 --- a/apps/wallet/src/ui/app/staking/delegation-detail/index.tsx +++ b/apps/wallet/src/ui/app/staking/delegation-detail/index.tsx @@ -7,9 +7,9 @@ import Overlay from '_components/overlay'; import { useGetDelegatedStake } from '@iota/core'; import { Navigate, useNavigate, useSearchParams } from 'react-router-dom'; -import { useActiveAddress } from '../../hooks/useActiveAddress'; -import { getDelegationDataByStakeId } from '../getDelegationByStakeId'; -import { ValidatorLogo } from '../validators/ValidatorLogo'; +import { useActiveAddress } from '_app/hooks/useActiveAddress'; +import { getDelegationDataByStakeId } from '_app/staking/getDelegationByStakeId'; +import { ValidatorLogo } from '_app/staking/validators/ValidatorLogo'; import { DelegationDetailCard } from './DelegationDetailCard'; export function DelegationDetail() { diff --git a/apps/wallet/src/ui/app/staking/home/StakedCard.tsx b/apps/wallet/src/ui/app/staking/home/StakedCard.tsx index 64de3508493..7dae44e5ae7 100644 --- a/apps/wallet/src/ui/app/staking/home/StakedCard.tsx +++ b/apps/wallet/src/ui/app/staking/home/StakedCard.tsx @@ -16,7 +16,7 @@ import { cva, cx, type VariantProps } from 'class-variance-authority'; import type { ReactNode } from 'react'; import { Link } from 'react-router-dom'; -import { ValidatorLogo } from '../validators/ValidatorLogo'; +import { ValidatorLogo } from '_app/staking/validators/ValidatorLogo'; export enum StakeState { WarmUp = 'WARM_UP', diff --git a/apps/wallet/src/ui/app/staking/home/index.tsx b/apps/wallet/src/ui/app/staking/home/index.tsx index 28e7d990c47..9e80e94615e 100644 --- a/apps/wallet/src/ui/app/staking/home/index.tsx +++ b/apps/wallet/src/ui/app/staking/home/index.tsx @@ -4,10 +4,10 @@ import { Route, Routes } from 'react-router-dom'; -import { useUnlockedGuard } from '../../hooks/useUnlockedGuard'; -import { DelegationDetail } from '../delegation-detail'; -import StakePage from '../stake'; -import { Validators } from '../validators'; +import { useUnlockedGuard } from '_app/hooks/useUnlockedGuard'; +import { DelegationDetail } from '_app/staking/delegation-detail'; +import StakePage from '_app/staking/stake'; +import { Validators } from '_app/staking/validators'; export function Staking() { if (useUnlockedGuard()) { diff --git a/apps/wallet/src/ui/app/staking/stake/StakeForm.tsx b/apps/wallet/src/ui/app/staking/stake/StakeForm.tsx index 7209cee86bb..ed7264e634e 100644 --- a/apps/wallet/src/ui/app/staking/stake/StakeForm.tsx +++ b/apps/wallet/src/ui/app/staking/stake/StakeForm.tsx @@ -20,7 +20,7 @@ import { import { Field, Form, useFormikContext } from 'formik'; import { memo, useCallback, useMemo } from 'react'; -import { useActiveAddress, useTransactionGasBudget } from '../../hooks'; +import { useActiveAddress, useTransactionGasBudget } from '_app/hooks'; import { type FormValues } from './StakingCard'; const HIDE_MAX = true; diff --git a/apps/wallet/src/ui/app/staking/stake/StakingCard.tsx b/apps/wallet/src/ui/app/staking/stake/StakingCard.tsx index b27cca25f42..dfb67368d33 100644 --- a/apps/wallet/src/ui/app/staking/stake/StakingCard.tsx +++ b/apps/wallet/src/ui/app/staking/stake/StakingCard.tsx @@ -34,12 +34,12 @@ import { useCallback, useMemo } from 'react'; import { toast } from 'react-hot-toast'; import { Navigate, useNavigate, useSearchParams } from 'react-router-dom'; -import Alert from '../../components/alert'; -import { getSignerOperationErrorMessage } from '../../helpers/errorMessages'; -import { useActiveAccount } from '../../hooks/useActiveAccount'; -import { useSigner } from '../../hooks/useSigner'; -import { getDelegationDataByStakeId } from '../getDelegationByStakeId'; -import { getStakeIotaByIotaId } from '../getStakeIotaByIotaId'; +import Alert from '_components/alert'; +import { getSignerOperationErrorMessage } from '_app/helpers/errorMessages'; +import { useActiveAccount } from '_app/hooks/useActiveAccount'; +import { useSigner } from '_app/hooks/useSigner'; +import { getDelegationDataByStakeId } from '_app/staking/getDelegationByStakeId'; +import { getStakeIotaByIotaId } from '_app/staking/getStakeIotaByIotaId'; import StakeForm from './StakeForm'; import { UnStakeForm } from './UnstakeForm'; import { createValidationSchema } from './utils/validation'; diff --git a/apps/wallet/src/ui/app/staking/stake/UnstakeForm.tsx b/apps/wallet/src/ui/app/staking/stake/UnstakeForm.tsx index e99c723689f..98810d00835 100644 --- a/apps/wallet/src/ui/app/staking/stake/UnstakeForm.tsx +++ b/apps/wallet/src/ui/app/staking/stake/UnstakeForm.tsx @@ -10,9 +10,9 @@ import { IOTA_TYPE_ARG } from '@iota/iota.js/utils'; import { Form } from 'formik'; import { useMemo } from 'react'; -import { useActiveAddress, useTransactionGasBudget } from '../../hooks'; -import { GAS_SYMBOL } from '../../redux/slices/iota-objects/Coin'; -import { Heading } from '../../shared/heading'; +import { useActiveAddress, useTransactionGasBudget } from '_app/hooks'; +import { GAS_SYMBOL } from '_redux/slices/iota-objects/Coin'; +import { Heading } from '_app/shared/heading'; export interface StakeFromProps { stakedIotaId: string; diff --git a/apps/wallet/src/ui/app/staking/stake/ValidatorFormDetail.tsx b/apps/wallet/src/ui/app/staking/stake/ValidatorFormDetail.tsx index 33b45d6adf4..31f34ac8b3d 100644 --- a/apps/wallet/src/ui/app/staking/stake/ValidatorFormDetail.tsx +++ b/apps/wallet/src/ui/app/staking/stake/ValidatorFormDetail.tsx @@ -19,11 +19,11 @@ import { useIotaClientQuery } from '@iota/dapp-kit'; import { useMemo } from 'react'; import { useSearchParams } from 'react-router-dom'; -import { useActiveAddress } from '../../hooks/useActiveAddress'; -import { getStakeIotaByIotaId } from '../getStakeIotaByIotaId'; -import { getTokenStakeIotaForValidator } from '../getTokenStakeIotaForValidator'; -import { StakeAmount } from '../home/StakeAmount'; -import { ValidatorLogo } from '../validators/ValidatorLogo'; +import { useActiveAddress } from '_app/hooks/useActiveAddress'; +import { getStakeIotaByIotaId } from '_app/staking/getStakeIotaByIotaId'; +import { getTokenStakeIotaForValidator } from '_app/staking/getTokenStakeIotaForValidator'; +import { StakeAmount } from '_app/staking/home/StakeAmount'; +import { ValidatorLogo } from '_app/staking/validators/ValidatorLogo'; interface ValidatorFormDetailProps { validatorAddress: string; diff --git a/apps/wallet/src/ui/app/staking/stake/index.tsx b/apps/wallet/src/ui/app/staking/stake/index.tsx index 286d5da65d2..1b820e0e463 100644 --- a/apps/wallet/src/ui/app/staking/stake/index.tsx +++ b/apps/wallet/src/ui/app/staking/stake/index.tsx @@ -5,7 +5,7 @@ import Overlay from '_components/overlay'; import { useNavigate, useSearchParams } from 'react-router-dom'; -import { SelectValidatorCard } from '../validators/SelectValidatorCard'; +import { SelectValidatorCard } from '_app/staking/validators/SelectValidatorCard'; import StakingCard from './StakingCard'; function StakePage() { diff --git a/apps/wallet/src/ui/app/staking/validators/ValidatorsCard.tsx b/apps/wallet/src/ui/app/staking/validators/ValidatorsCard.tsx index dbaf7405860..528fd076b1a 100644 --- a/apps/wallet/src/ui/app/staking/validators/ValidatorsCard.tsx +++ b/apps/wallet/src/ui/app/staking/validators/ValidatorsCard.tsx @@ -21,9 +21,9 @@ import { useIotaClientQuery } from '@iota/dapp-kit'; import { Plus12 } from '@iota/icons'; import { useMemo } from 'react'; -import { useActiveAddress } from '../../hooks/useActiveAddress'; -import { StakeAmount } from '../home/StakeAmount'; -import { StakeCard } from '../home/StakedCard'; +import { useActiveAddress } from '_app/hooks/useActiveAddress'; +import { StakeAmount } from '_app/staking/home/StakeAmount'; +import { StakeCard } from '_app/staking/home/StakedCard'; export function ValidatorsCard() { const accountAddress = useActiveAddress(); diff --git a/apps/wallet/src/ui/app/staking/validators/index.tsx b/apps/wallet/src/ui/app/staking/validators/index.tsx index 3f4ba42b551..abbb2749cc8 100644 --- a/apps/wallet/src/ui/app/staking/validators/index.tsx +++ b/apps/wallet/src/ui/app/staking/validators/index.tsx @@ -12,7 +12,7 @@ import { } from '@iota/core'; import { useNavigate } from 'react-router-dom'; -import { useActiveAddress } from '../../hooks/useActiveAddress'; +import { useActiveAddress } from '_app/hooks/useActiveAddress'; import { SelectValidatorCard } from './SelectValidatorCard'; import { ValidatorsCard } from './ValidatorsCard';