diff --git a/apps/wallet-mobile/.storybook/storybook.requires.js b/apps/wallet-mobile/.storybook/storybook.requires.js
index 8d43d52f4b..f3a090b1da 100644
--- a/apps/wallet-mobile/.storybook/storybook.requires.js
+++ b/apps/wallet-mobile/.storybook/storybook.requires.js
@@ -254,7 +254,9 @@ const getStories = () => {
"./src/Nfts/Nfts.stories.tsx": require("../src/Nfts/Nfts.stories.tsx"),
"./src/Nfts/NoNftsScreen.stories.tsx": require("../src/Nfts/NoNftsScreen.stories.tsx"),
"./src/Staking/DelegationConfirmation/DelegationConfirmation.stories.tsx": require("../src/Staking/DelegationConfirmation/DelegationConfirmation.stories.tsx"),
+ "./src/Staking/FailedTx/FailedTxScreen.stories.tsx": require("../src/Staking/FailedTx/FailedTxScreen.stories.tsx"),
"./src/Staking/PoolDetails/PoolDetailScreen.stories.tsx": require("../src/Staking/PoolDetails/PoolDetailScreen.stories.tsx"),
+ "./src/Staking/PoolTransition/PoolTransitionModal.stories.tsx": require("../src/Staking/PoolTransition/PoolTransitionModal.stories.tsx"),
"./src/Staking/PoolWarningModal/PoolWarningModal.stories.tsx": require("../src/Staking/PoolWarningModal/PoolWarningModal.stories.tsx"),
"./src/Staking/StakingCenter/StakingCenter.stories.tsx": require("../src/Staking/StakingCenter/StakingCenter.stories.tsx"),
"./src/TxHistory/AssetList/ActionsBanner.stories.tsx": require("../src/TxHistory/AssetList/ActionsBanner.stories.tsx"),
diff --git a/apps/wallet-mobile/ios/Podfile.lock b/apps/wallet-mobile/ios/Podfile.lock
index dc43a58c8a..a4779cbf97 100644
--- a/apps/wallet-mobile/ios/Podfile.lock
+++ b/apps/wallet-mobile/ios/Podfile.lock
@@ -325,7 +325,7 @@ PODS:
- react-native-config/App (= 1.5.1)
- react-native-config/App (1.5.1):
- React-Core
- - react-native-haskell-shelley (6.0.0-alpha.4):
+ - react-native-haskell-shelley (6.0.0-alpha.9):
- React
- react-native-mmkv (2.11.0):
- MMKV (>= 1.2.13)
@@ -816,7 +816,7 @@ SPEC CHECKSUMS:
react-native-background-timer: 17ea5e06803401a379ebf1f20505b793ac44d0fe
react-native-ble-plx: f10240444452dfb2d2a13a0e4f58d7783e92d76e
react-native-config: 86038147314e2e6d10ea9972022aa171e6b1d4d8
- react-native-haskell-shelley: 46f5fa9068996637c969e9526c22bd3867c27810
+ react-native-haskell-shelley: 4015aef14eca3ecf5e8d8718e8d1b47cdcf60f84
react-native-mmkv: e97c0c79403fb94577e5d902ab1ebd42b0715b43
react-native-pager-view: 0ccb8bf60e2ebd38b1f3669fa3650ecce81db2df
react-native-quick-base64: 62290829c619fbabca4c41cfec75ae759d08fc1c
diff --git a/apps/wallet-mobile/package.json b/apps/wallet-mobile/package.json
index c19605b760..2cfd62051c 100644
--- a/apps/wallet-mobile/package.json
+++ b/apps/wallet-mobile/package.json
@@ -1,6 +1,6 @@
{
"name": "@yoroi/wallet-mobile",
- "version": "4.27.0",
+ "version": "4.27.1",
"private": true,
"scripts": {
"android-bundle": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res",
@@ -90,16 +90,16 @@
]
},
"dependencies": {
- "@amplitude/analytics-react-native": "^1.3.1",
+ "@amplitude/analytics-react-native": "1.3.1",
"@cardano-foundation/ledgerjs-hw-app-cardano": "^6.0.0",
"@emurgo/cip14-js": "^3.0.1",
"@emurgo/cip4-js": "1.0.7",
- "@emurgo/cross-csl-core": "^4.2.0",
- "@emurgo/cross-csl-mobile": "^4.2.0",
- "@emurgo/csl-mobile-bridge": "6.0.0-alpha.4",
+ "@emurgo/cross-csl-core": "4.4.0",
+ "@emurgo/cross-csl-mobile": "4.4.0",
+ "@emurgo/csl-mobile-bridge": "6.0.0-alpha.9",
"@emurgo/react-native-blockies-svg": "^0.0.2",
"@emurgo/react-native-hid": "^5.15.6",
- "@emurgo/yoroi-lib": "0.15.1",
+ "@emurgo/yoroi-lib": "0.15.5-alpha.8",
"@formatjs/intl-datetimeformat": "^6.7.0",
"@formatjs/intl-getcanonicallocales": "^2.1.0",
"@formatjs/intl-locale": "^3.2.1",
@@ -127,11 +127,11 @@
"@yoroi/exchange": "2.0.1",
"@yoroi/links": "1.5.4",
"@yoroi/resolver": "2.0.5",
+ "@yoroi/setup-wallet": "1.0.0",
"@yoroi/staking": "1.5.1",
"@yoroi/swap": "1.5.2",
"@yoroi/theme": "^1.0.0",
"@yoroi/transfer": "1.0.0",
- "@yoroi/setup-wallet": "1.0.0",
"add": "2.0.6",
"assert": "^2.0.0",
"axios": "^1.5.0",
@@ -213,8 +213,8 @@
"@babel/preset-env": "^7.20.0",
"@babel/preset-react": "^7.16.7",
"@babel/runtime": "^7.20.0",
- "@emurgo/cardano-serialization-lib-nodejs": "^9.1.4",
- "@emurgo/cross-csl-nodejs": "^4.2.0",
+ "@emurgo/cardano-serialization-lib-nodejs": "12.0.0-alpha.28",
+ "@emurgo/cross-csl-nodejs": "4.4.0",
"@formatjs/cli": "^6.1.0",
"@formatjs/ts-transformer": "^3.13.0",
"@react-navigation/devtools": "^6.0.13",
diff --git a/apps/wallet-mobile/src/Dashboard/Dashboard.tsx b/apps/wallet-mobile/src/Dashboard/Dashboard.tsx
index 1c869f96ba..46ba5036a4 100644
--- a/apps/wallet-mobile/src/Dashboard/Dashboard.tsx
+++ b/apps/wallet-mobile/src/Dashboard/Dashboard.tsx
@@ -1,5 +1,6 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
import {useNavigation} from '@react-navigation/native'
+import {useTheme} from '@yoroi/theme'
import BigNumber from 'bignumber.js'
import React from 'react'
import {defineMessages, useIntl} from 'react-intl'
@@ -16,6 +17,8 @@ import {useSelectedWallet} from '../features/WalletManager/Context/SelectedWalle
import globalMessages from '../i18n/global-messages'
import {Modal} from '../legacy/Modal'
import {useWalletNavigation} from '../navigation'
+import {PoolTransitionNotice} from '../Staking/PoolTransition/PoolTransitionNotice'
+import {usePoolTransition} from '../Staking/PoolTransition/usePoolTransition'
import {isEmptyString} from '../utils/utils'
import {getCardanoNetworkConfigById} from '../yoroi-wallets/cardano/networks'
import {getCardanoBaseConfig} from '../yoroi-wallets/cardano/utils'
@@ -34,9 +37,11 @@ import {UserSummary} from './UserSummary'
import {WithdrawStakingRewards} from './WithdrawStakingRewards'
export const Dashboard = () => {
+ const {styles} = useStyles()
const intl = useIntl()
const navigateTo = useNavigateTo()
const governanceStrings = useGovernanceStrings()
+ const {isPoolRetiring} = usePoolTransition()
const wallet = useSelectedWallet()
const {isLoading: isSyncing, sync} = useSync(wallet)
@@ -90,6 +95,12 @@ export const Dashboard = () => {
>
{stakingInfo?.status !== 'staked' && }
+ {isPoolRetiring && (
+
+
+
+ )}
+
@@ -169,8 +180,6 @@ const useNavigateTo = () => {
}
}
-const Row = ({style, ...props}: ViewProps) =>
-
const SyncErrorBanner = ({showRefresh}: {showRefresh: boolean}) => {
const intl = useIntl()
@@ -239,8 +248,6 @@ const EpochInfo = () => {
)
}
-const Actions = (props: ViewProps) =>
-
const messages = defineMessages({
stakingCenterButton: {
id: 'components.delegation.delegationnavigationbuttons.stakingCenterButton',
@@ -248,36 +255,53 @@ const messages = defineMessages({
},
})
-const styles = StyleSheet.create({
- root: {
- flex: 1,
- },
- container: {
- flexDirection: 'column',
- flex: 1,
- },
- scrollView: {
- flex: 1,
- backgroundColor: '#fff',
- },
- contentContainer: {
- paddingTop: 16,
- paddingHorizontal: 16,
- },
- row: {
- flex: 1,
- paddingVertical: 12,
- },
- actions: {
- flexDirection: 'row',
- backgroundColor: '#fff',
- padding: 16,
- borderTopLeftRadius: 8,
- borderTopRightRadius: 8,
- elevation: 1,
- shadowOpacity: 0.06,
- shadowColor: 'black',
- shadowRadius: 6,
- shadowOffset: {width: 0, height: -8},
- },
-})
+const useStyles = () => {
+ const {theme} = useTheme()
+ const {color} = theme
+
+ const styles = StyleSheet.create({
+ root: {
+ flex: 1,
+ },
+ container: {
+ flexDirection: 'column',
+ flex: 1,
+ },
+ scrollView: {
+ flex: 1,
+ backgroundColor: color.gray.min,
+ },
+ contentContainer: {
+ paddingTop: 16,
+ paddingHorizontal: 16,
+ },
+ row: {
+ flex: 1,
+ paddingVertical: 12,
+ },
+ actions: {
+ flexDirection: 'row',
+ backgroundColor: color.gray.min,
+ padding: 16,
+ borderTopLeftRadius: 8,
+ borderTopRightRadius: 8,
+ elevation: 1,
+ shadowOpacity: 0.06,
+ shadowColor: color['black-static'],
+ shadowRadius: 6,
+ shadowOffset: {width: 0, height: -8},
+ },
+ })
+
+ return {styles}
+}
+
+const Actions = (props: ViewProps) => {
+ const {styles} = useStyles()
+ return
+}
+
+const Row = (props: ViewProps) => {
+ const {styles} = useStyles()
+ return
+}
diff --git a/apps/wallet-mobile/src/Dashboard/DashboardNavigator.tsx b/apps/wallet-mobile/src/Dashboard/DashboardNavigator.tsx
index 06c599f736..d7ecc0ae43 100644
--- a/apps/wallet-mobile/src/Dashboard/DashboardNavigator.tsx
+++ b/apps/wallet-mobile/src/Dashboard/DashboardNavigator.tsx
@@ -9,7 +9,7 @@ import {SettingsButton} from '../components/Button'
import {useGovernanceManagerMaker} from '../features/Staking/Governance'
import {useSelectedWallet} from '../features/WalletManager/Context/SelectedWalletContext'
import {DashboardRoutes, defaultStackNavigationOptions, useWalletNavigation} from '../navigation'
-import {DelegationConfirmation} from '../Staking'
+import {DelegationConfirmation, FailedTxScreen} from '../Staking'
import {StakingCenter} from '../Staking/StakingCenter'
import {useWalletName} from '../yoroi-wallets/hooks'
import {Dashboard} from './Dashboard'
@@ -46,6 +46,8 @@ export const DashboardNavigator = () => {
component={DelegationConfirmation}
options={{title: strings.title}}
/>
+
+
)
diff --git a/apps/wallet-mobile/src/Staking/FailedTx/FailedTxImage.tsx b/apps/wallet-mobile/src/Staking/FailedTx/FailedTxImage.tsx
new file mode 100644
index 0000000000..b63d5b8dd2
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/FailedTx/FailedTxImage.tsx
@@ -0,0 +1,47 @@
+import * as React from 'react'
+import Svg, {Defs, LinearGradient, Path, Stop, SvgProps} from 'react-native-svg'
+
+export const FailedTxImage = (props: SvgProps) => {
+ return (
+
+ )
+}
diff --git a/apps/wallet-mobile/src/Staking/FailedTx/FailedTxScreen.stories.tsx b/apps/wallet-mobile/src/Staking/FailedTx/FailedTxScreen.stories.tsx
new file mode 100644
index 0000000000..21536f6847
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/FailedTx/FailedTxScreen.stories.tsx
@@ -0,0 +1,8 @@
+import {storiesOf} from '@storybook/react-native'
+import React from 'react'
+
+import {FailedTxScreen} from './FailedTxScreen'
+
+storiesOf('Staking/Failed Tx Screen', module).add('initial', () => {
+ return
+})
diff --git a/apps/wallet-mobile/src/Staking/FailedTx/FailedTxScreen.tsx b/apps/wallet-mobile/src/Staking/FailedTx/FailedTxScreen.tsx
new file mode 100644
index 0000000000..5271bf4187
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/FailedTx/FailedTxScreen.tsx
@@ -0,0 +1,121 @@
+import {useNavigation} from '@react-navigation/native'
+import {useTheme} from '@yoroi/theme'
+import React from 'react'
+import {defineMessages, useIntl} from 'react-intl'
+import {StyleSheet, View} from 'react-native'
+
+import {Button, Spacer, Text} from '../../components'
+import {Space} from '../../components/Space/Space'
+import {FailedTxImage} from './FailedTxImage'
+
+export const FailedTxScreen = () => {
+ const strings = useStrings()
+ const styles = useStyles()
+ const navigateTo = useNavigateTo()
+
+ return (
+
+
+
+
+
+ {strings.notEnoughFunds}
+
+ {strings.noFundsToProcess}
+
+
+
+
+
+
+
+
+
+ )
+}
+
+const useNavigateTo = () => {
+ const navigation = useNavigation()
+
+ return {
+ buyAda: () =>
+ navigation.navigate('manage-wallets', {
+ screen: 'main-wallet-routes',
+ params: {
+ screen: 'history',
+ params: {
+ screen: 'exchange-create-order',
+ },
+ },
+ }),
+ main: () =>
+ navigation.navigate('manage-wallets', {
+ screen: 'main-wallet-routes',
+ params: {
+ screen: 'history',
+ params: {
+ screen: 'history-list',
+ },
+ },
+ }),
+ }
+}
+
+const useStyles = () => {
+ const {theme} = useTheme()
+ const {color, typography, padding} = theme
+ const styles = StyleSheet.create({
+ container: {
+ flex: 1,
+ alignItems: 'center',
+ justifyContent: 'center',
+ ...padding['l'],
+ },
+ title: {
+ color: color.gray.max,
+ ...typography['heading-3-medium'],
+ ...padding['x-s'],
+ textAlign: 'center',
+ },
+ text: {
+ color: color.gray[600],
+ ...typography['body-2-m-regular'],
+ textAlign: 'center',
+ maxWidth: 330,
+ },
+ outlineText: {
+ color: theme.color.primary[500],
+ },
+ })
+ return styles
+}
+
+const useStrings = () => {
+ const intl = useIntl()
+
+ return {
+ notEnoughFunds: intl.formatMessage(messages.notEnoughFunds),
+ noFundsToProcess: intl.formatMessage(messages.noFundsToProcess),
+ buyAda: intl.formatMessage(messages.buyAda),
+ goToMain: intl.formatMessage(messages.goToMain),
+ }
+}
+
+const messages = defineMessages({
+ notEnoughFunds: {
+ id: 'components.stakingcenter.failedDelegation.notEnoughFunds',
+ defaultMessage: '!!!Not enough funds',
+ },
+ noFundsToProcess: {
+ id: 'components.stakingcenter.failedDelegation.noFundsToProcess',
+ defaultMessage: '!!!Your transaction cannot be processed due to lack of funds on your wallet balance',
+ },
+ buyAda: {
+ id: 'components.stakingcenter.failedDelegation.buyAda',
+ defaultMessage: '!!!Buy ada',
+ },
+ goToMain: {
+ id: 'components.stakingcenter.failedDelegation.goToMain',
+ defaultMessage: '!!!Go to main wallet page',
+ },
+})
diff --git a/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionModal.stories.tsx b/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionModal.stories.tsx
new file mode 100644
index 0000000000..dfd2f04ff3
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionModal.stories.tsx
@@ -0,0 +1,53 @@
+import {PoolTransition} from '@emurgo/yoroi-lib'
+import {action} from '@storybook/addon-actions'
+import {storiesOf} from '@storybook/react-native'
+import * as React from 'react'
+import {View} from 'react-native'
+
+import {PoolTransitionModal} from './PoolTransitionModal'
+
+const mock: PoolTransition = {
+ current: {
+ id: '',
+ hash: '',
+ saturation: '',
+ taxFix: '',
+ stake: '',
+ share: '',
+ pic: 'https://img.cexplorer.io/a/5/5/f/2/pool12eht6dqxpzqj87xuextrpufz2gxmt4reuesuw26r2utzw0kw906.png',
+ ticker: 'EMRG',
+ name: 'emurgo old',
+ roa: '0',
+ taxRatio: '0.05',
+ },
+ suggested: {
+ hash: '',
+ saturation: '',
+ taxFix: '',
+ stake: '',
+ share: '',
+ pic: 'https://img.cexplorer.io/e/c/2/3/1/pool1dkww2vlysa8lsnuf5rca979zdsyr3zvt59hu7e420yxfunkka2z.png',
+ id: 'df1750df9b2df285fcfb50f4740657a18ee3af42727d410c37b86207',
+ name: 'emurgo new',
+ roa: '5.1',
+ ticker: 'EMRG',
+ taxRatio: '0.02',
+ },
+ deadlineMilliseconds: Date.now() + 2999777000,
+}
+
+storiesOf('PoolTransitionModal', module)
+ .add('Future deadline', () => (
+
+
+
+
+
+ ))
+ .add('Past deadline', () => (
+
+
+
+
+
+ ))
diff --git a/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionModal.tsx b/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionModal.tsx
new file mode 100644
index 0000000000..183973402f
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionModal.tsx
@@ -0,0 +1,240 @@
+import {PoolTransition} from '@emurgo/yoroi-lib'
+import {useTheme} from '@yoroi/theme'
+import * as React from 'react'
+import {Image, StyleSheet, Text, View, ViewProps} from 'react-native'
+import LinearGradient from 'react-native-linear-gradient'
+
+import {Button, Icon, useModal} from '../../components'
+import {Space} from '../../components/Space/Space'
+import {formatTimeSpan} from '../../yoroi-wallets/utils'
+import {useStrings} from './usePoolTransition'
+
+export const PoolTransitionModal = ({
+ poolTransition,
+ onContinue,
+}: {
+ poolTransition: PoolTransition
+ onContinue: () => void
+}) => {
+ const {styles, colors} = useStyles()
+ const strings = useStrings()
+
+ const {closeModal} = useModal()
+
+ const handleOnSkip = () => {
+ closeModal()
+ }
+
+ const handleOnUpdate = () => {
+ closeModal()
+ onContinue()
+ }
+
+ const timeSpan = poolTransition.deadlineMilliseconds - Date.now()
+ const isActive = timeSpan > 0
+
+ return (
+
+ {isActive ? strings.warning : strings.finalWarning}
+
+
+
+
+
+ {strings.currentPool}
+
+
+ {poolTransition.current.pic != null && (
+
+ )}
+
+ {`[${poolTransition.current.ticker}] ${poolTransition.current.name}`}
+
+
+
+
+ {strings.estimatedRoa}
+
+ {poolTransition.current.roa} %
+
+
+
+ {strings.fee}
+
+ {formatFee(poolTransition.current.taxRatio)} %
+
+
+
+ {isActive ? strings.poolWillStopRewards : strings.poolNoRewards}
+
+ {isActive && (
+
+ {'\n'}
+
+ {formatTimeSpan(timeSpan)}
+
+ )}
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {strings.newPool}
+
+
+ {poolTransition.suggested.pic != null && (
+
+ )}
+
+ {`[${poolTransition.suggested.ticker}] ${poolTransition.suggested.name}`}
+
+
+
+
+ {strings.estimatedRoa}
+
+ {poolTransition.suggested.roa} %
+
+
+
+ {strings.fee}
+
+ {formatFee(poolTransition.suggested.taxRatio)} %
+
+
+ {strings.poolGeneratesRewards}
+
+
+
+
+
+
+
+
+
+
+
+
+ )
+}
+
+const useStyles = () => {
+ const {theme} = useTheme()
+
+ const styles = StyleSheet.create({
+ modal: {
+ alignItems: 'center',
+ flex: 1,
+ justifyContent: 'flex-end',
+ },
+ card: {
+ borderRadius: 8,
+ gap: 8,
+ ...theme.padding.l,
+ width: '100%',
+ overflow: 'hidden',
+ },
+ border: {
+ borderWidth: 1,
+ borderColor: theme.color.gray['300'],
+ },
+ warningBorder: {
+ borderWidth: 1,
+ borderColor: theme.color.magenta['500'],
+ },
+ poolTicker: {
+ alignItems: 'center',
+ flexDirection: 'row',
+ gap: 8,
+ },
+ poolTickerText: {
+ ...theme.typography['body-1-l-regular'],
+ color: theme.color.primary[600],
+ },
+ pic: {
+ width: 24,
+ height: 24,
+ borderRadius: 100,
+ },
+ label: {
+ ...theme.typography['body-1-l-regular'],
+ color: theme.color.gray['600'],
+ },
+ currentValue: {
+ ...theme.typography['body-1-l-regular'],
+ color: theme.color.gray['max'],
+ },
+ suggestedValue: {
+ ...theme.typography['body-1-l-medium'],
+ color: theme.color.gray['max'],
+ },
+ warning: {
+ color: theme.color.magenta['500'],
+ },
+ warningText: {
+ ...theme.typography['body-1-l-regular'],
+ },
+ warningTimer: {
+ ...theme.typography['body-1-l-medium'],
+ },
+ row: {
+ width: '100%',
+ flexDirection: 'row',
+ justifyContent: 'space-between',
+ height: 24,
+ alignItems: 'center',
+ },
+ actions: {
+ alignSelf: 'stretch',
+ backgroundColor: theme.color.gray.min,
+ gap: 4,
+ },
+ details: {
+ ...theme.typography['body-1-l-regular'],
+ color: theme.color.gray['900'],
+ width: '100%',
+ },
+ outlineButton: {
+ color: theme.color.gray[900],
+ ...theme.typography['button-2-m'],
+ },
+ button: {
+ ...theme.typography['button-1-l'],
+ },
+ })
+
+ const colors = {
+ backgroundGradientCard: theme.color.gradients['blue-green'],
+ }
+
+ return {styles, colors} as const
+}
+
+const Actions = (props: ViewProps) => {
+ const {styles} = useStyles()
+ return
+}
+
+const Row = (props: ViewProps) => {
+ const {styles} = useStyles()
+ return
+}
+
+const formatFee = (fee: string) => Number((Number(fee) * 100).toFixed(2))
diff --git a/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionNotice.tsx b/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionNotice.tsx
new file mode 100644
index 0000000000..5044eeb734
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/PoolTransition/PoolTransitionNotice.tsx
@@ -0,0 +1,90 @@
+import {useTheme} from '@yoroi/theme'
+import * as React from 'react'
+import {StyleSheet, Text, View, ViewProps} from 'react-native'
+
+import {Button, Icon} from '../../components'
+import {Space} from '../../components/Space/Space'
+import {formatTimeSpan} from '../../yoroi-wallets/utils'
+import {usePoolTransition, useStrings} from './usePoolTransition'
+
+export const PoolTransitionNotice = () => {
+ const {styles, color} = useStyles()
+ const strings = useStrings()
+ const {poolTransition, navigateToUpdate} = usePoolTransition()
+ if (poolTransition === null) return null
+
+ const timeSpan = poolTransition.deadlineMilliseconds - Date.now()
+ const isActive = timeSpan > 0
+
+ return (
+
+
+
+
+
+
+ {isActive ? strings.poolWillStopRewards : strings.poolNoRewards}
+
+ {isActive && (
+
+ {'\n'}
+
+ {formatTimeSpan(timeSpan)}
+
+ )}
+
+
+
+
+
+
+
+
+ )
+}
+
+const useStyles = () => {
+ const {theme} = useTheme()
+ const {color, typography} = theme
+
+ const styles = StyleSheet.create({
+ notice: {
+ flex: 1,
+ padding: 16,
+ gap: 12,
+ backgroundColor: color.magenta[100],
+ borderRadius: 8,
+ },
+ text: {
+ color: color.gray.max,
+ ...typography['body-2-m-regular'],
+ },
+ bold: {
+ ...typography['body-2-m-medium'],
+ },
+ noticeButton: {
+ flexGrow: 0,
+ backgroundColor: color.magenta[500],
+ ...typography['button-2-m'],
+ },
+ actions: {
+ flexDirection: 'row',
+ },
+ row: {
+ flexDirection: 'row',
+ gap: 4,
+ },
+ })
+
+ return {styles, color}
+}
+
+const Actions = (props: ViewProps) => {
+ const {styles} = useStyles()
+ return
+}
+
+const Row = (props: ViewProps) => {
+ const {styles} = useStyles()
+ return
+}
diff --git a/apps/wallet-mobile/src/Staking/PoolTransition/usePoolTransition.tsx b/apps/wallet-mobile/src/Staking/PoolTransition/usePoolTransition.tsx
new file mode 100644
index 0000000000..43c4655ca1
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/PoolTransition/usePoolTransition.tsx
@@ -0,0 +1,168 @@
+import {init} from '@emurgo/cross-csl-mobile'
+import {PoolInfoApi} from '@emurgo/yoroi-lib'
+import {useNavigation} from '@react-navigation/native'
+import BigNumber from 'bignumber.js'
+import * as React from 'react'
+import {defineMessages, useIntl} from 'react-intl'
+import {useQuery} from 'react-query'
+
+import {useStakingInfo} from '../../Dashboard/StakePoolInfos'
+import {features} from '../../features'
+import {useSelectedWallet} from '../../features/WalletManager/Context/SelectedWalletContext'
+import {getCardanoNetworkConfigById} from '../../yoroi-wallets/cardano/networks'
+import {YoroiWallet} from '../../yoroi-wallets/cardano/types'
+import {asQuantity, Quantities} from '../../yoroi-wallets/utils'
+
+const createDelegationTx = async (wallet: YoroiWallet, poolId: string) => {
+ const accountStates = await wallet.fetchAccountState()
+ const accountState = accountStates[wallet.rewardAddressHex]
+ if (!accountState) throw new Error('Account state not found')
+
+ const stakingUtxos = await wallet.getAllUtxosForKey()
+ const amountToDelegate = Quantities.sum([
+ ...stakingUtxos.map((utxo) => asQuantity(utxo.amount)),
+ asQuantity(accountState.remainingAmount),
+ ])
+
+ return wallet.createDelegationTx(poolId, new BigNumber(amountToDelegate))
+}
+
+export const usePoolTransition = () => {
+ const navigation = useNavigation()
+ const wallet = useSelectedWallet()
+ const {stakingInfo, isLoading} = useStakingInfo(wallet)
+ const poolInfoApi = React.useMemo(
+ () => new PoolInfoApi(getCardanoNetworkConfigById(wallet.networkId).BACKEND.API_ROOT),
+ [wallet.networkId],
+ )
+
+ const isStaked = stakingInfo?.status === 'staked'
+ const currentPoolId = isStaked ? stakingInfo?.poolId : ''
+
+ const poolTransitionQuery = useQuery({
+ enabled: isStaked,
+ retry: false,
+ staleTime: Infinity,
+ queryKey: [wallet.id, 'poolTransition', currentPoolId],
+ queryFn: () => (features.poolTransition ? poolInfoApi.getTransition(currentPoolId, init) : null),
+ })
+
+ const poolTransition = poolTransitionQuery.data ?? null
+ const poolId = poolTransition?.suggested.hash ?? ''
+
+ const navigateToUpdate = React.useCallback(async () => {
+ try {
+ const yoroiUnsignedTx = await createDelegationTx(wallet, poolId)
+ navigation.navigate('manage-wallets', {
+ screen: 'main-wallet-routes',
+ params: {
+ screen: 'staking-dashboard',
+ params: {
+ screen: 'delegation-confirmation',
+ initial: false,
+ params: {
+ poolId,
+ yoroiUnsignedTx,
+ },
+ },
+ },
+ })
+ } catch (err) {
+ navigation.navigate('manage-wallets', {
+ screen: 'main-wallet-routes',
+ params: {
+ screen: 'staking-dashboard',
+ params: {
+ screen: 'delegation-failed-tx',
+ initial: false,
+ },
+ },
+ })
+ }
+ }, [navigation, poolId, wallet])
+
+ return {
+ ...poolTransitionQuery,
+ isLoading: isLoading || poolTransitionQuery.isLoading,
+ poolTransition,
+ isPoolRetiring: poolTransition !== null,
+ navigateToUpdate,
+ }
+}
+
+export const useStrings = () => {
+ const intl = useIntl()
+
+ return {
+ title: intl.formatMessage(messages.title),
+ warning: intl.formatMessage(messages.warning),
+ finalWarning: intl.formatMessage(messages.finalWarning),
+ currentPool: intl.formatMessage(messages.currentPool),
+ newPool: intl.formatMessage(messages.newPool),
+ estimatedRoa: intl.formatMessage(messages.estimatedRoa),
+ fee: intl.formatMessage(messages.fee),
+ poolGeneratesRewards: intl.formatMessage(messages.poolGeneratesRewards),
+ poolNoRewards: intl.formatMessage(messages.poolNoRewards),
+ poolWillStopRewards: intl.formatMessage(messages.poolWillStopRewards),
+ skipNoRewards: intl.formatMessage(messages.skipNoRewards),
+ updateKeepEarning: intl.formatMessage(messages.updateKeepEarning),
+ update: intl.formatMessage(messages.update),
+ }
+}
+
+const messages = defineMessages({
+ title: {
+ id: 'components.pooltransition.title',
+ defaultMessage: '!!!Upgrade your stake pool',
+ },
+ warning: {
+ id: 'components.pooltransition.warning',
+ defaultMessage:
+ "!!!The current stake pool you're using will soon close. Migrate to the new EMURGO pool to sustain reward generation.",
+ },
+ finalWarning: {
+ id: 'components.pooltransition.finalWarning',
+ defaultMessage:
+ "!!!The current stake pool you're using is decommissioned and NOT generating reward anymore. Update it to continue earning",
+ },
+ currentPool: {
+ id: 'components.pooltransition.currentPool',
+ defaultMessage: '!!!Current pool',
+ },
+ newPool: {
+ id: 'components.pooltransition.newPool',
+ defaultMessage: '!!!New pool',
+ },
+ estimatedRoa: {
+ id: 'components.pooltransition.estimatedRoa',
+ defaultMessage: '!!!Estimated ROA',
+ },
+ fee: {
+ id: 'components.pooltransition.fee',
+ defaultMessage: '!!!Fee',
+ },
+ poolGeneratesRewards: {
+ id: 'components.pooltransition.poolGeneratesRewards',
+ defaultMessage: '!!!This pool continues to generate staking rewards',
+ },
+ poolNoRewards: {
+ id: 'components.pooltransition.poolNoRewards',
+ defaultMessage: '!!!This pool is NOT generating staking rewards anymore',
+ },
+ poolWillStopRewards: {
+ id: 'components.pooltransition.poolWillStopRewards',
+ defaultMessage: '!!!This pool will stop generating rewards in',
+ },
+ skipNoRewards: {
+ id: 'components.pooltransition.skipNoRewards',
+ defaultMessage: '!!!Skip and stop receiving rewards',
+ },
+ updateKeepEarning: {
+ id: 'components.pooltransition.updateKeepEarning',
+ defaultMessage: '!!!Update now and keep earning',
+ },
+ update: {
+ id: 'components.pooltransition.update',
+ defaultMessage: '!!!Update pool',
+ },
+})
diff --git a/apps/wallet-mobile/src/Staking/PoolTransition/usePoolTransitionModal.tsx b/apps/wallet-mobile/src/Staking/PoolTransition/usePoolTransitionModal.tsx
new file mode 100644
index 0000000000..eaa793b2c1
--- /dev/null
+++ b/apps/wallet-mobile/src/Staking/PoolTransition/usePoolTransitionModal.tsx
@@ -0,0 +1,24 @@
+import * as React from 'react'
+
+import {useModal} from '../../components'
+import {PoolTransitionModal} from './PoolTransitionModal'
+import {usePoolTransition, useStrings} from './usePoolTransition'
+
+export const usePoolTransitionModal = () => {
+ const {poolTransition, isPoolRetiring, isLoading, navigateToUpdate} = usePoolTransition()
+ const {openModal} = useModal()
+ const strings = useStrings()
+ const modalHeight = 700
+
+ React.useEffect(() => {
+ if (isPoolRetiring && poolTransition !== null) {
+ openModal(
+ strings.title,
+ ,
+ modalHeight,
+ )
+ }
+ }, [isPoolRetiring, modalHeight, navigateToUpdate, openModal, poolTransition, strings.title])
+
+ return {isLoading}
+}
diff --git a/apps/wallet-mobile/src/Staking/StakingCenter/StakingCenter.tsx b/apps/wallet-mobile/src/Staking/StakingCenter/StakingCenter.tsx
index 3481ba22e2..87c611d9b7 100644
--- a/apps/wallet-mobile/src/Staking/StakingCenter/StakingCenter.tsx
+++ b/apps/wallet-mobile/src/Staking/StakingCenter/StakingCenter.tsx
@@ -11,13 +11,14 @@ import {showErrorDialog} from '../../dialogs'
import {features} from '../../features'
import {useSelectedWallet} from '../../features/WalletManager/Context/SelectedWalletContext'
import {useLanguage} from '../../i18n'
-import globalMessages, {errorMessages} from '../../i18n/global-messages'
+import globalMessages from '../../i18n/global-messages'
import {isNightly} from '../../legacy/config'
import {Logger} from '../../legacy/logging'
import {useMetrics} from '../../metrics/metricsManager'
import {StakingCenterRouteNavigation} from '../../navigation'
import {getNetworkConfigById, NETWORKS} from '../../yoroi-wallets/cardano/networks'
import {NotEnoughMoneyToSendError} from '../../yoroi-wallets/cardano/types'
+import {usePlate} from '../../yoroi-wallets/hooks'
import {PoolDetailScreen} from '../PoolDetails'
export const StakingCenter = () => {
@@ -27,7 +28,7 @@ export const StakingCenter = () => {
const {languageCode} = useLanguage()
const wallet = useSelectedWallet()
const {track} = useMetrics()
-
+ const plate = usePlate({networkId: wallet.networkId, publicKeyHex: wallet.publicKeyHex})
useFocusEffect(
React.useCallback(() => {
track.stakingCenterPageViewed()
@@ -49,12 +50,10 @@ export const StakingCenter = () => {
},
onError: (error) => {
if (error instanceof NotEnoughMoneyToSendError) {
- showErrorDialog(errorMessages.insufficientBalance, intl)
+ navigation.navigate('delegation-failed-tx')
} else {
Logger.error(error as any)
- showErrorDialog(errorMessages.generalError, intl, {
- message: error.message,
- })
+ navigation.navigate('delegation-failed-tx')
}
},
},
@@ -86,7 +85,7 @@ export const StakingCenter = () => {
handleOnMessage(event)}
/>
@@ -112,12 +111,14 @@ const noPoolDataDialog = defineMessages({
* Prepares WebView's target staking URI
* @param {*} poolList : Array of delegated pool hash
*/
-const prepareStakingURL = (locale: string): string => {
+const prepareStakingURL = (locale: string, plate: string): string => {
// source=mobile is constant and already included
let finalURL = NETWORKS.HASKELL_SHELLEY.POOL_EXPLORER
const lang = locale.slice(0, 2)
finalURL += `&lang=${lang}`
+ finalURL += `&bias=${plate}`
+
return finalURL
}
diff --git a/apps/wallet-mobile/src/Staking/index.ts b/apps/wallet-mobile/src/Staking/index.ts
index 170105ff05..60fbe83239 100644
--- a/apps/wallet-mobile/src/Staking/index.ts
+++ b/apps/wallet-mobile/src/Staking/index.ts
@@ -1,2 +1,3 @@
export * from './DelegationConfirmation'
+export * from './FailedTx/FailedTxScreen'
export * from './StakingCenter'
diff --git a/apps/wallet-mobile/src/TxHistory/TxHistory.tsx b/apps/wallet-mobile/src/TxHistory/TxHistory.tsx
index 555bdf1212..fb3022cb50 100644
--- a/apps/wallet-mobile/src/TxHistory/TxHistory.tsx
+++ b/apps/wallet-mobile/src/TxHistory/TxHistory.tsx
@@ -9,6 +9,7 @@ import {Boundary, ResetErrorRef, Spacer} from '../components'
import {Tab, TabPanel, TabPanels, Tabs} from '../components/Tabs'
import {useSelectedWallet} from '../features/WalletManager/Context/SelectedWalletContext'
import {assetMessages, txLabels} from '../i18n/global-messages'
+import {usePoolTransitionModal} from '../Staking/PoolTransition/usePoolTransitionModal'
import {isByron} from '../yoroi-wallets/cardano/utils'
import {useSync} from '../yoroi-wallets/hooks'
import {ActionsBanner} from './ActionsBanner'
@@ -36,7 +37,10 @@ export const TxHistory = () => {
setActiveTab(tab)
}
- const {sync, isLoading} = useSync(wallet)
+ const {sync, isLoading: isLoadingWallet} = useSync(wallet)
+ const {isLoading: isLoadingPoolTransition} = usePoolTransitionModal()
+ const isLoading = isLoadingWallet || isLoadingPoolTransition
+
useFocusEffect(React.useCallback(() => sync(), [sync]))
const [expanded, setExpanded] = useState(true)
diff --git a/apps/wallet-mobile/src/components/Icon/ArrowDown.tsx b/apps/wallet-mobile/src/components/Icon/ArrowDown.tsx
new file mode 100644
index 0000000000..8ec8da1f29
--- /dev/null
+++ b/apps/wallet-mobile/src/components/Icon/ArrowDown.tsx
@@ -0,0 +1,17 @@
+import * as React from 'react'
+import Svg, {Path} from 'react-native-svg'
+
+type Props = {
+ size?: number
+}
+
+export const ArrowDown = ({size}: Props) => {
+ return (
+
+ )
+}
diff --git a/apps/wallet-mobile/src/components/Icon/index.ts b/apps/wallet-mobile/src/components/Icon/index.ts
index 72b5107fdf..53d175bae6 100644
--- a/apps/wallet-mobile/src/components/Icon/index.ts
+++ b/apps/wallet-mobile/src/components/Icon/index.ts
@@ -1,5 +1,6 @@
import {Ada} from './Ada'
import {Analytics} from './Analytics'
+import {ArrowDown} from './ArrowDown'
import {ArrowRight} from './ArrowRight'
import {Assets} from './Assets'
import {Bio} from './Bio'
@@ -217,6 +218,7 @@ export const Icon = {
Share,
Governance,
ArrowRight,
+ ArrowDown,
Close,
Warning,
Collateral,
diff --git a/apps/wallet-mobile/src/components/Modal/ModalScreen.tsx b/apps/wallet-mobile/src/components/Modal/ModalScreen.tsx
index 569a5192d9..33e9cc8754 100644
--- a/apps/wallet-mobile/src/components/Modal/ModalScreen.tsx
+++ b/apps/wallet-mobile/src/components/Modal/ModalScreen.tsx
@@ -108,7 +108,7 @@ const useStyles = () => {
},
sheet: {
flex: 1,
- backgroundColor: color['bottom-sheet-background'],
+ backgroundColor: color.gray['min'],
alignSelf: 'stretch',
paddingHorizontal: 16,
paddingBottom: 16,
diff --git a/apps/wallet-mobile/src/features/Menu/Menu.tsx b/apps/wallet-mobile/src/features/Menu/Menu.tsx
index ca92a0fb62..148a1a2f3e 100644
--- a/apps/wallet-mobile/src/features/Menu/Menu.tsx
+++ b/apps/wallet-mobile/src/features/Menu/Menu.tsx
@@ -13,7 +13,6 @@ import {Boundary, Icon, Spacer, Text} from '../../components'
import {usePrefetchStakingInfo} from '../../Dashboard/StakePoolInfos'
import {useMetrics} from '../../metrics/metricsManager'
import {defaultStackNavigationOptions, useWalletNavigation} from '../../navigation'
-import {lightPalette} from '../../theme'
import {useIsGovernanceFeatureEnabled} from '../Staking/Governance'
import {useSelectedWallet} from '../WalletManager/Context/SelectedWalletContext'
@@ -39,7 +38,7 @@ export const MenuNavigator = () => {
export const Menu = () => {
const strings = useStrings()
- const styles = useStyles()
+ const {styles, color} = useStyles()
const navigateTo = useNavigateTo()
const wallet = useSelectedWallet()
const {track} = useMetrics()
@@ -57,29 +56,29 @@ export const Menu = () => {
}
+ left={}
/>
-
- }
- />
-
-
{isGovernanceFeatureEnabled && (
}
+ left={}
/>
)}
+
+ }
+ />
+
+
}
+ left={}
/>
@@ -92,7 +91,7 @@ export const Menu = () => {
const SupportLink = () => {
const strings = useStrings()
- const styles = useStyles()
+ const {styles} = useStyles()
const navigateTo = useNavigateTo()
return (
@@ -129,7 +128,7 @@ const Item = ({
right?: React.ReactElement | null
onPress: () => void
}) => {
- const styles = useStyles()
+ const {styles, color} = useStyles()
return (
@@ -137,9 +136,7 @@ const Item = ({
-
- {label}
-
+ {label}
@@ -147,7 +144,7 @@ const Item = ({
-
+
)
}
@@ -220,6 +217,10 @@ const useStrings = () => {
}
const messages = defineMessage({
+ staking: {
+ id: 'menu.staking',
+ defaultMessage: '!!!Staking center',
+ },
catalystVoting: {
id: 'menu.catalystVoting',
defaultMessage: '!!!Catalyst voting',
@@ -294,5 +295,5 @@ const useStyles = () => {
},
})
- return styles
+ return {styles, color}
}
diff --git a/apps/wallet-mobile/src/features/Receive/common/SingleOrMultipleAddressesModal/SingleOrMultipleAddressesModal.tsx b/apps/wallet-mobile/src/features/Receive/common/SingleOrMultipleAddressesModal/SingleOrMultipleAddressesModal.tsx
index 851042e531..22dc2dae22 100644
--- a/apps/wallet-mobile/src/features/Receive/common/SingleOrMultipleAddressesModal/SingleOrMultipleAddressesModal.tsx
+++ b/apps/wallet-mobile/src/features/Receive/common/SingleOrMultipleAddressesModal/SingleOrMultipleAddressesModal.tsx
@@ -72,7 +72,6 @@ const useStyles = () => {
const styles = StyleSheet.create({
modal: {
flex: 1,
- backgroundColor: theme.color['bottom-sheet-background'],
alignItems: 'center',
justifyContent: 'space-between',
},
diff --git a/apps/wallet-mobile/src/features/Send/common/useSendAddress.tsx b/apps/wallet-mobile/src/features/Send/common/useSendAddress.tsx
index d2fa2d5440..5db9e4de51 100644
--- a/apps/wallet-mobile/src/features/Send/common/useSendAddress.tsx
+++ b/apps/wallet-mobile/src/features/Send/common/useSendAddress.tsx
@@ -1,8 +1,10 @@
+import {normalizeToAddress} from '@emurgo/yoroi-lib/dist/internals/utils/addresses'
import {useTransfer} from '@yoroi/transfer'
import * as React from 'react'
import {useQuery, UseQueryOptions} from 'react-query'
-import {normalizeToAddress, toCardanoNetworkId} from '../../../yoroi-wallets/cardano/utils'
+import {toCardanoNetworkId} from '../../../yoroi-wallets/cardano/utils'
+import {CardanoMobile} from '../../../yoroi-wallets/wallets'
import {useSelectedWallet} from '../../WalletManager/Context/SelectedWalletContext'
import {AddressErrorInvalid, AddressErrorWrongNetwork} from './errors'
@@ -58,7 +60,7 @@ const useValidateAddress = (
// NOTE: should be a wallet function from address manager
const validateAddress = async (address: string, chainId: number) => {
- const chainAddress = await normalizeToAddress(address)
+ const chainAddress = await normalizeToAddress(CardanoMobile, address)
if (!chainAddress) throw new AddressErrorInvalid()
const chainAddressChainId = await chainAddress.networkId()
diff --git a/apps/wallet-mobile/src/features/index.ts b/apps/wallet-mobile/src/features/index.ts
index 324f09cf72..738b1ab56e 100644
--- a/apps/wallet-mobile/src/features/index.ts
+++ b/apps/wallet-mobile/src/features/index.ts
@@ -4,11 +4,12 @@ export const features = {
search: __DEV__ || false,
nfts: __DEV__ || false,
},
- useTestnet: __DEV__ ? false : false,
- startWithIndexScreen: __DEV__ ? false : false,
- prefillWalletInfo: __DEV__ ? false : false,
- showProdPoolsInDev: __DEV__ ? false : false,
- moderatingNftsEnabled: __DEV__ ? false : false,
+ useTestnet: false,
+ prefillWalletInfo: false,
+ showProdPoolsInDev: __DEV__,
+ moderatingNftsEnabled: false,
+ walletListFeedback: __DEV__,
+ poolTransition: __DEV__,
}
export const debugWalletInfo = {
diff --git a/apps/wallet-mobile/src/i18n/locales/en-US.json b/apps/wallet-mobile/src/i18n/locales/en-US.json
index 764049fbff..d53253093b 100644
--- a/apps/wallet-mobile/src/i18n/locales/en-US.json
+++ b/apps/wallet-mobile/src/i18n/locales/en-US.json
@@ -200,6 +200,19 @@
"components.login.appstartscreen.loginButton": "Login",
"components.login.custompinlogin.title": "Enter PIN",
"components.ma.assetSelector.placeHolder": "Select an asset",
+ "components.pooltransition.title": "Upgrade your stake pool",
+ "components.pooltransition.warning": "The current stake pool you're using will soon close. Migrate to the new EMURGO pool to sustain reward generation.",
+ "components.pooltransition.finalWarning": "The current stake pool you're using is decommissioned and NOT generating reward anymore. Update it to continue earning",
+ "components.pooltransition.currentPool": "Current pool",
+ "components.pooltransition.newPool": "New pool",
+ "components.pooltransition.estimatedRoa": "Estimated ROA",
+ "components.pooltransition.fee": "Fee",
+ "components.pooltransition.poolGeneratesRewards": "This pool continues to generate staking rewards",
+ "components.pooltransition.poolNoRewards": "This pool is NOT generating staking rewards anymore",
+ "components.pooltransition.poolWillStopRewards": "This pool will stop generating rewards in",
+ "components.pooltransition.skipNoRewards": "Skip and stop receiving rewards",
+ "components.pooltransition.updateKeepEarning": "Update now and keep earning",
+ "components.pooltransition.update": "Update pool",
"components.receive.addressmodal.BIP32path": "Derivation path",
"components.receive.addressmodal.copiedLabel": "Copied",
"components.receive.addressmodal.copyLabel": "Copy address",
@@ -420,7 +433,7 @@
"components.settings.walletsettingscreen.byronWallet": "Byron-era wallet",
"components.settings.walletsettingscreen.changePassword": "Change spending password",
"components.settings.walletsettingscreen.easyConfirmation": "Easy transaction confirmation",
- "components.settings.walletsettingscreen.easyConfirmationInfo":"Skip the password and approve transactions with biometrics",
+ "components.settings.walletsettingscreen.easyConfirmationInfo": "Skip the password and approve transactions with biometrics",
"components.settings.walletsettingscreen.general": "General",
"components.settings.walletsettingscreen.logout": "Logout",
"components.settings.walletsettingscreen.removeWallet": "Remove wallet",
@@ -440,6 +453,10 @@
"components.stakingcenter.delegationbyid.stakePoolId": "Stake pool id",
"components.stakingcenter.delegationbyid.title": "Delegation by Id",
"components.stakingcenter.delegationTxBuildError": "Error while building delegation transaction",
+ "components.stakingcenter.failedDelegation.notEnoughFunds": "Not enough funds",
+ "components.stakingcenter.failedDelegation.noFundsToProcess": "Your transaction cannot be processed due to lack of funds on your wallet balance",
+ "components.stakingcenter.failedDelegation.buyAda": "Buy ada",
+ "components.stakingcenter.failedDelegation.goToMain": "Go to main wallet page",
"components.stakingcenter.noPoolDataDialog.message": "The data from the stake pool(s) you selected is invalid. Please try again",
"components.stakingcenter.noPoolDataDialog.title": "Invalid pool data",
"components.stakingcenter.pooldetailscreen.title": "Nightly TESTING POOL",
@@ -834,6 +851,7 @@
"links.untrusted.paymentRequested.description": "A request from an untrusted app has been made. Engaging with this request could pose potential security risk to your wallet. Do not proceed without verifying the authenticity of the request. If you didn't start this action, please cancel it.",
"menu.appSettings": "App Settings",
"menu.catalystVoting": "Catalyst Voting",
+ "menu.staking": "Staking center",
"menu.governanceCentre": "Governance centre",
"menu.knowledgeBase": "Knowledge base",
"menu.releases": "Releases",
diff --git a/apps/wallet-mobile/src/navigation.tsx b/apps/wallet-mobile/src/navigation.tsx
index 1afee6140d..7a21f55b5a 100644
--- a/apps/wallet-mobile/src/navigation.tsx
+++ b/apps/wallet-mobile/src/navigation.tsx
@@ -190,6 +190,7 @@ export type StakingCenterRoutes = {
poolId: string
yoroiUnsignedTx: YoroiUnsignedTx
}
+ 'delegation-failed-tx': undefined
}
export type SwapTabRoutes = {
@@ -258,7 +259,11 @@ export type SendConfirmParams = {
export type DashboardRoutes = {
'staking-dashboard-main': undefined
'staking-center': NavigatorScreenParams
- 'delegation-confirmation': undefined
+ 'delegation-confirmation': {
+ poolId: string
+ yoroiUnsignedTx: YoroiUnsignedTx
+ }
+ 'delegation-failed-tx': undefined
}
export type VotingRegistrationRoutes = {
diff --git a/apps/wallet-mobile/src/yoroi-wallets/cardano/assetUtils/assetUtils.ts b/apps/wallet-mobile/src/yoroi-wallets/cardano/assetUtils/assetUtils.ts
index 6a36cce437..420490b815 100644
--- a/apps/wallet-mobile/src/yoroi-wallets/cardano/assetUtils/assetUtils.ts
+++ b/apps/wallet-mobile/src/yoroi-wallets/cardano/assetUtils/assetUtils.ts
@@ -1,17 +1,18 @@
+import {normalizeToAddress} from '@emurgo/yoroi-lib/dist/internals/utils/addresses'
import BigNumber from 'bignumber.js'
import {Address} from '../../types'
import {RawUtxo} from '../../types/other'
import {CardanoMobile} from '../../wallets'
import {COINS_PER_UTXO_BYTE} from '../constants/common'
-import {cardanoValueFromRemoteFormat, normalizeToAddress} from '../utils'
+import {cardanoValueFromRemoteFormat} from '../utils'
export async function calcLockedDeposit(utxos: RawUtxo[], address: Address, coinsPerUtxoByteStr: string) {
const utxosWithAssets = utxos.filter((u) => u.assets.length > 0)
const coinsPerUtxoByte = await CardanoMobile.BigNum.fromStr(coinsPerUtxoByteStr ?? COINS_PER_UTXO_BYTE)
const dataCost = await CardanoMobile.DataCost.newCoinsPerByte(coinsPerUtxoByte)
- const normalizedAddress = await normalizeToAddress(address)
+ const normalizedAddress = await normalizeToAddress(CardanoMobile, address)
if (normalizedAddress === undefined) throw new Error('calcLockedDeposit::Error not a valid address')
const promises = utxosWithAssets.map((u) => {
diff --git a/apps/wallet-mobile/src/yoroi-wallets/cardano/getMinAmounts.ts b/apps/wallet-mobile/src/yoroi-wallets/cardano/getMinAmounts.ts
index 911f5872a8..d04b3eb2eb 100644
--- a/apps/wallet-mobile/src/yoroi-wallets/cardano/getMinAmounts.ts
+++ b/apps/wallet-mobile/src/yoroi-wallets/cardano/getMinAmounts.ts
@@ -1,4 +1,5 @@
import {BigNum} from '@emurgo/cross-csl-core'
+import {normalizeToAddress} from '@emurgo/yoroi-lib/dist/internals/utils/addresses'
import {Balance} from '@yoroi/types'
import BigNumber from 'bignumber.js'
@@ -7,7 +8,7 @@ import {Amounts, asQuantity, Quantities} from '../utils'
import {CardanoMobile} from '../wallets'
import {COINS_PER_UTXO_BYTE} from './constants/common'
import {MultiToken} from './MultiToken'
-import {cardanoValueFromMultiToken, normalizeToAddress} from './utils'
+import {cardanoValueFromMultiToken} from './utils'
export const withMinAmounts = async (
address: Address,
@@ -36,12 +37,15 @@ export const getMinAmounts = async (address: Address, amounts: Balance.Amounts,
{defaultNetworkId: primaryToken.networkId, defaultIdentifier: primaryToken.identifier},
)
- const [value, coinsPerUtxoByte, normalizedAddress] = await Promise.all([
+ const [value, coinsPerUtxoByte] = await Promise.all([
cardanoValueFromMultiToken(multiToken),
CardanoMobile.BigNum.fromStr(COINS_PER_UTXO_BYTE),
- normalizeToAddress(address),
])
+ const normalizedAddress = await normalizeToAddress(CardanoMobile, address).catch(() => {
+ throw new Error('getMinAmounts::Error not a valid address')
+ })
+
if (normalizedAddress === undefined) throw new Error('getMinAmounts::Error not a valid address')
const [txOutput, dataCost] = await Promise.all([
diff --git a/apps/wallet-mobile/src/yoroi-wallets/cardano/shelley/delegationUtils.ts b/apps/wallet-mobile/src/yoroi-wallets/cardano/shelley/delegationUtils.ts
index 6618efbc7f..5eec1abd2b 100644
--- a/apps/wallet-mobile/src/yoroi-wallets/cardano/shelley/delegationUtils.ts
+++ b/apps/wallet-mobile/src/yoroi-wallets/cardano/shelley/delegationUtils.ts
@@ -1,6 +1,7 @@
/* eslint-disable @typescript-eslint/no-explicit-any */
import {CardanoAddressedUtxo} from '@emurgo/yoroi-lib'
+import {normalizeToAddress} from '@emurgo/yoroi-lib/dist/internals/utils/addresses'
import assert from 'assert'
import {sortBy} from 'lodash'
@@ -9,14 +10,13 @@ import {StakingStatus} from '../../types'
import {CardanoMobile} from '../../wallets'
import type {TimestampedCertMeta} from '../transactionManager'
import {CardanoTypes} from '../types'
-import {normalizeToAddress} from '../utils'
const addrContainsAccountKey = async (
address: string,
targetAccountKey: CardanoTypes.StakeCredential,
acceptTypeMismatch: boolean,
) => {
- const wasmAddr = await normalizeToAddress(address)
+ const wasmAddr = await normalizeToAddress(CardanoMobile, address)
if (wasmAddr == null) {
throw new Error(`addrContainsAccountKey: invalid address ${address}`)
diff --git a/apps/wallet-mobile/src/yoroi-wallets/cardano/utils.ts b/apps/wallet-mobile/src/yoroi-wallets/cardano/utils.ts
index 4b329290ae..e83857e780 100644
--- a/apps/wallet-mobile/src/yoroi-wallets/cardano/utils.ts
+++ b/apps/wallet-mobile/src/yoroi-wallets/cardano/utils.ts
@@ -30,29 +30,6 @@ import {CardanoHaskellShelleyNetwork, PRIMARY_ASSET_CONSTANTS} from './networks'
import {NUMBERS} from './numbers'
import {CardanoTypes, WalletImplementation} from './types'
-export const normalizeToAddress = async (addr: string) => {
- // in Shelley, addresses can be base16, bech32 or base58
- // in this function, we try parsing in all encodings possible
- // 1) Try converting from base58
- try {
- if (await CardanoMobile.ByronAddress.isValid(addr)) {
- return await (await CardanoMobile.ByronAddress.fromBase58(addr)).toAddress()
- }
- } catch (_e) {}
-
- // 2) If already base16, simply return
- try {
- return await CardanoMobile.Address.fromBytes(Buffer.from(addr, 'hex'))
- } catch (_e) {}
-
- // 3) Try converting from bech32
- try {
- return await CardanoMobile.Address.fromBech32(addr)
- } catch (_e) {}
-
- return undefined
-}
-
// need to format shelley addresses as base16 but only legacy addresses as base58
export const verifyFromBip44Root = (request: Addressing['addressing']) => {
diff --git a/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.test.ts b/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.test.ts
new file mode 100644
index 0000000000..4edafa1575
--- /dev/null
+++ b/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.test.ts
@@ -0,0 +1,14 @@
+import {formatTimeSpan} from './timeUtils'
+
+describe('formatTimeSpan', () => {
+ it('should return return empty for negative', () => {
+ expect(formatTimeSpan(-3245)).toEqual('')
+ })
+ it('should return valid', () => {
+ expect(formatTimeSpan(1000 * 60)).toBe('00d : 00h : 01m')
+ expect(formatTimeSpan(1000 * 60 * 59)).toBe('00d : 00h : 59m')
+ expect(formatTimeSpan(1000 * 60 * 60)).toBe('00d : 01h : 00m')
+ expect(formatTimeSpan(1000 * 60 * 85)).toBe('00d : 01h : 25m')
+ expect(formatTimeSpan(1000 * 60 * 8595)).toBe('05d : 23h : 15m')
+ })
+})
diff --git a/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.ts b/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.ts
index 674e5c24dc..9b7d3d218a 100644
--- a/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.ts
+++ b/apps/wallet-mobile/src/yoroi-wallets/utils/timeUtils.ts
@@ -298,3 +298,20 @@ export function genToRealTime(
}
export const delay = (ms: number): Promise => new Promise((resolve) => setTimeout(resolve, ms))
+
+const ms_in_sec = 1000,
+ sec_in_day = 86400,
+ sec_in_hour = 3600,
+ sec_in_min = 60
+export const formatTimeSpan = (ms: number) => {
+ if (ms < 0) return ''
+
+ let seconds = Math.round(Math.abs(ms) / ms_in_sec)
+ const days = Math.floor(seconds / sec_in_day)
+ seconds = Math.floor(seconds % sec_in_day)
+ const hours = Math.floor(seconds / sec_in_hour)
+ seconds = Math.floor(seconds % sec_in_hour)
+ const minutes = Math.floor(seconds / sec_in_min)
+ const [dd, hh, mm] = [days, hours, minutes].map((item) => (item < 10 ? '0' + item : item.toString()))
+ return `${dd}d : ${hh}h : ${mm}m`
+}
diff --git a/apps/wallet-mobile/translations/messages/src/Dashboard/Dashboard.json b/apps/wallet-mobile/translations/messages/src/Dashboard/Dashboard.json
index e44d94dee2..345e991e8f 100644
--- a/apps/wallet-mobile/translations/messages/src/Dashboard/Dashboard.json
+++ b/apps/wallet-mobile/translations/messages/src/Dashboard/Dashboard.json
@@ -4,14 +4,14 @@
"defaultMessage": "!!!Go to Staking Center",
"file": "src/Dashboard/Dashboard.tsx",
"start": {
- "line": 245,
+ "line": 252,
"column": 23,
- "index": 7842
+ "index": 8064
},
"end": {
- "line": 248,
+ "line": 255,
"column": 3,
- "index": 7975
+ "index": 8197
}
}
]
\ No newline at end of file
diff --git a/apps/wallet-mobile/translations/messages/src/Dashboard/DashboardNavigator.json b/apps/wallet-mobile/translations/messages/src/Dashboard/DashboardNavigator.json
index 8d995088e0..836bb0b0f3 100644
--- a/apps/wallet-mobile/translations/messages/src/Dashboard/DashboardNavigator.json
+++ b/apps/wallet-mobile/translations/messages/src/Dashboard/DashboardNavigator.json
@@ -4,14 +4,14 @@
"defaultMessage": "!!!Staking Center",
"file": "src/Dashboard/DashboardNavigator.tsx",
"start": {
- "line": 63,
+ "line": 65,
"column": 9,
- "index": 1956
+ "index": 2086
},
"end": {
- "line": 66,
+ "line": 68,
"column": 3,
- "index": 2044
+ "index": 2174
}
}
]
\ No newline at end of file
diff --git a/apps/wallet-mobile/translations/messages/src/Staking/FailedTx/FailedTxScreen.json b/apps/wallet-mobile/translations/messages/src/Staking/FailedTx/FailedTxScreen.json
new file mode 100644
index 0000000000..f245ca9780
--- /dev/null
+++ b/apps/wallet-mobile/translations/messages/src/Staking/FailedTx/FailedTxScreen.json
@@ -0,0 +1,62 @@
+[
+ {
+ "id": "components.stakingcenter.failedDelegation.notEnoughFunds",
+ "defaultMessage": "!!!Not enough funds",
+ "file": "src/Staking/FailedTx/FailedTxScreen.tsx",
+ "start": {
+ "line": 105,
+ "column": 18,
+ "index": 2563
+ },
+ "end": {
+ "line": 108,
+ "column": 3,
+ "index": 2679
+ }
+ },
+ {
+ "id": "components.stakingcenter.failedDelegation.noFundsToProcess",
+ "defaultMessage": "!!!Your transaction cannot be processed due to lack of funds on your wallet balance",
+ "file": "src/Staking/FailedTx/FailedTxScreen.tsx",
+ "start": {
+ "line": 109,
+ "column": 20,
+ "index": 2701
+ },
+ "end": {
+ "line": 112,
+ "column": 3,
+ "index": 2883
+ }
+ },
+ {
+ "id": "components.stakingcenter.failedDelegation.buyAda",
+ "defaultMessage": "!!!Buy ada",
+ "file": "src/Staking/FailedTx/FailedTxScreen.tsx",
+ "start": {
+ "line": 113,
+ "column": 10,
+ "index": 2895
+ },
+ "end": {
+ "line": 116,
+ "column": 3,
+ "index": 2994
+ }
+ },
+ {
+ "id": "components.stakingcenter.failedDelegation.goToMain",
+ "defaultMessage": "!!!Go to main wallet page",
+ "file": "src/Staking/FailedTx/FailedTxScreen.tsx",
+ "start": {
+ "line": 117,
+ "column": 12,
+ "index": 3008
+ },
+ "end": {
+ "line": 120,
+ "column": 3,
+ "index": 3124
+ }
+ }
+]
\ No newline at end of file
diff --git a/apps/wallet-mobile/translations/messages/src/Staking/PoolTransition/usePoolTransition.json b/apps/wallet-mobile/translations/messages/src/Staking/PoolTransition/usePoolTransition.json
new file mode 100644
index 0000000000..c5cd53b40f
--- /dev/null
+++ b/apps/wallet-mobile/translations/messages/src/Staking/PoolTransition/usePoolTransition.json
@@ -0,0 +1,197 @@
+[
+ {
+ "id": "components.pooltransition.title",
+ "defaultMessage": "!!!Upgrade your stake pool",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 114,
+ "column": 9,
+ "index": 4001
+ },
+ "end": {
+ "line": 117,
+ "column": 3,
+ "index": 4099
+ }
+ },
+ {
+ "id": "components.pooltransition.warning",
+ "defaultMessage": "!!!The current stake pool you're using will soon close. Migrate to the new EMURGO pool to sustain reward generation.",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 118,
+ "column": 11,
+ "index": 4112
+ },
+ "end": {
+ "line": 122,
+ "column": 3,
+ "index": 4308
+ }
+ },
+ {
+ "id": "components.pooltransition.finalWarning",
+ "defaultMessage": "!!!The current stake pool you're using is decommissioned and NOT generating reward anymore. Update it to continue earning",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 123,
+ "column": 16,
+ "index": 4326
+ },
+ "end": {
+ "line": 127,
+ "column": 3,
+ "index": 4532
+ }
+ },
+ {
+ "id": "components.pooltransition.currentPool",
+ "defaultMessage": "!!!Current pool",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 128,
+ "column": 15,
+ "index": 4549
+ },
+ "end": {
+ "line": 131,
+ "column": 3,
+ "index": 4642
+ }
+ },
+ {
+ "id": "components.pooltransition.newPool",
+ "defaultMessage": "!!!New pool",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 132,
+ "column": 11,
+ "index": 4655
+ },
+ "end": {
+ "line": 135,
+ "column": 3,
+ "index": 4740
+ }
+ },
+ {
+ "id": "components.pooltransition.estimatedRoa",
+ "defaultMessage": "!!!Estimated ROA",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 136,
+ "column": 16,
+ "index": 4758
+ },
+ "end": {
+ "line": 139,
+ "column": 3,
+ "index": 4853
+ }
+ },
+ {
+ "id": "components.pooltransition.fee",
+ "defaultMessage": "!!!Fee",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 140,
+ "column": 7,
+ "index": 4862
+ },
+ "end": {
+ "line": 143,
+ "column": 3,
+ "index": 4938
+ }
+ },
+ {
+ "id": "components.pooltransition.poolGeneratesRewards",
+ "defaultMessage": "!!!This pool continues to generate staking rewards",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 144,
+ "column": 24,
+ "index": 4964
+ },
+ "end": {
+ "line": 147,
+ "column": 3,
+ "index": 5101
+ }
+ },
+ {
+ "id": "components.pooltransition.poolNoRewards",
+ "defaultMessage": "!!!This pool is NOT generating staking rewards anymore",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 148,
+ "column": 17,
+ "index": 5120
+ },
+ "end": {
+ "line": 151,
+ "column": 3,
+ "index": 5254
+ }
+ },
+ {
+ "id": "components.pooltransition.poolWillStopRewards",
+ "defaultMessage": "!!!This pool will stop generating rewards in",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 152,
+ "column": 23,
+ "index": 5279
+ },
+ "end": {
+ "line": 155,
+ "column": 3,
+ "index": 5409
+ }
+ },
+ {
+ "id": "components.pooltransition.skipNoRewards",
+ "defaultMessage": "!!!Skip and stop receiving rewards",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 156,
+ "column": 17,
+ "index": 5428
+ },
+ "end": {
+ "line": 159,
+ "column": 3,
+ "index": 5542
+ }
+ },
+ {
+ "id": "components.pooltransition.updateKeepEarning",
+ "defaultMessage": "!!!Update now and keep earning",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 160,
+ "column": 21,
+ "index": 5565
+ },
+ "end": {
+ "line": 163,
+ "column": 3,
+ "index": 5679
+ }
+ },
+ {
+ "id": "components.pooltransition.update",
+ "defaultMessage": "!!!Update pool",
+ "file": "src/Staking/PoolTransition/usePoolTransition.tsx",
+ "start": {
+ "line": 164,
+ "column": 10,
+ "index": 5691
+ },
+ "end": {
+ "line": 167,
+ "column": 3,
+ "index": 5778
+ }
+ }
+]
\ No newline at end of file
diff --git a/apps/wallet-mobile/translations/messages/src/Staking/StakingCenter/StakingCenter.json b/apps/wallet-mobile/translations/messages/src/Staking/StakingCenter/StakingCenter.json
index 09a0f824d4..50eff097e6 100644
--- a/apps/wallet-mobile/translations/messages/src/Staking/StakingCenter/StakingCenter.json
+++ b/apps/wallet-mobile/translations/messages/src/Staking/StakingCenter/StakingCenter.json
@@ -4,14 +4,14 @@
"defaultMessage": "!!!Invalid Pool Data",
"file": "src/Staking/StakingCenter/StakingCenter.tsx",
"start": {
- "line": 101,
+ "line": 100,
"column": 9,
- "index": 3448
+ "index": 3531
},
"end": {
- "line": 104,
+ "line": 103,
"column": 3,
- "index": 3556
+ "index": 3639
}
},
{
@@ -19,14 +19,14 @@
"defaultMessage": "!!!The data from the stake pool(s) you selected is invalid. Please try again",
"file": "src/Staking/StakingCenter/StakingCenter.tsx",
"start": {
- "line": 105,
+ "line": 104,
"column": 11,
- "index": 3569
+ "index": 3652
},
"end": {
- "line": 108,
+ "line": 107,
"column": 3,
- "index": 3735
+ "index": 3818
}
}
]
\ No newline at end of file
diff --git a/apps/wallet-mobile/translations/messages/src/TxHistory/TxHistory.json b/apps/wallet-mobile/translations/messages/src/TxHistory/TxHistory.json
index d8ce271ddf..bc9469f272 100644
--- a/apps/wallet-mobile/translations/messages/src/TxHistory/TxHistory.json
+++ b/apps/wallet-mobile/translations/messages/src/TxHistory/TxHistory.json
@@ -4,14 +4,14 @@
"defaultMessage": "!!!Note:",
"file": "src/TxHistory/TxHistory.tsx",
"start": {
- "line": 132,
+ "line": 136,
"column": 9,
- "index": 4207
+ "index": 4448
},
"end": {
- "line": 135,
+ "line": 139,
"column": 3,
- "index": 4306
+ "index": 4547
}
},
{
@@ -19,14 +19,14 @@
"defaultMessage": "!!!The Shelley protocol upgrade adds a new Shelley wallet type which supports delegation.",
"file": "src/TxHistory/TxHistory.tsx",
"start": {
- "line": 136,
+ "line": 140,
"column": 11,
- "index": 4319
+ "index": 4560
},
"end": {
- "line": 139,
+ "line": 143,
"column": 3,
- "index": 4501
+ "index": 4742
}
}
]
\ No newline at end of file
diff --git a/apps/wallet-mobile/translations/messages/src/TxHistory/usePoolTransition.json b/apps/wallet-mobile/translations/messages/src/TxHistory/usePoolTransition.json
new file mode 100644
index 0000000000..a167c2d935
--- /dev/null
+++ b/apps/wallet-mobile/translations/messages/src/TxHistory/usePoolTransition.json
@@ -0,0 +1,197 @@
+[
+ {
+ "id": "components.pooltransition.title",
+ "defaultMessage": "!!!Upgrade your stake pool",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 108,
+ "column": 9,
+ "index": 3854
+ },
+ "end": {
+ "line": 111,
+ "column": 3,
+ "index": 3952
+ }
+ },
+ {
+ "id": "components.pooltransition.warning",
+ "defaultMessage": "!!!The current stake pool you're using will soon close. Migrate to the new EMURGO pool to sustain reward generation.",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 112,
+ "column": 11,
+ "index": 3965
+ },
+ "end": {
+ "line": 116,
+ "column": 3,
+ "index": 4161
+ }
+ },
+ {
+ "id": "components.pooltransition.finalWarning",
+ "defaultMessage": "!!!The current stake pool you're using is decommissioned and NOT generating reward anymore. Update it to continue earning",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 117,
+ "column": 16,
+ "index": 4179
+ },
+ "end": {
+ "line": 121,
+ "column": 3,
+ "index": 4385
+ }
+ },
+ {
+ "id": "components.pooltransition.currentPool",
+ "defaultMessage": "!!!Current pool",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 122,
+ "column": 15,
+ "index": 4402
+ },
+ "end": {
+ "line": 125,
+ "column": 3,
+ "index": 4495
+ }
+ },
+ {
+ "id": "components.pooltransition.newPool",
+ "defaultMessage": "!!!New pool",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 126,
+ "column": 11,
+ "index": 4508
+ },
+ "end": {
+ "line": 129,
+ "column": 3,
+ "index": 4593
+ }
+ },
+ {
+ "id": "components.pooltransition.estimatedRoa",
+ "defaultMessage": "!!!Estimated ROA",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 130,
+ "column": 16,
+ "index": 4611
+ },
+ "end": {
+ "line": 133,
+ "column": 3,
+ "index": 4706
+ }
+ },
+ {
+ "id": "components.pooltransition.fee",
+ "defaultMessage": "!!!Fee",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 134,
+ "column": 7,
+ "index": 4715
+ },
+ "end": {
+ "line": 137,
+ "column": 3,
+ "index": 4791
+ }
+ },
+ {
+ "id": "components.pooltransition.poolGeneratesRewards",
+ "defaultMessage": "!!!This pool continues to generate staking rewards",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 138,
+ "column": 24,
+ "index": 4817
+ },
+ "end": {
+ "line": 141,
+ "column": 3,
+ "index": 4954
+ }
+ },
+ {
+ "id": "components.pooltransition.poolNoRewards",
+ "defaultMessage": "!!!This pool is NOT generating staking rewards anymore",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 142,
+ "column": 17,
+ "index": 4973
+ },
+ "end": {
+ "line": 145,
+ "column": 3,
+ "index": 5107
+ }
+ },
+ {
+ "id": "components.pooltransition.poolWillStopRewards",
+ "defaultMessage": "!!!This pool will stop generating rewards in",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 146,
+ "column": 23,
+ "index": 5132
+ },
+ "end": {
+ "line": 149,
+ "column": 3,
+ "index": 5262
+ }
+ },
+ {
+ "id": "components.pooltransition.skipNoRewards",
+ "defaultMessage": "!!!Skip and stop receiving rewards",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 150,
+ "column": 17,
+ "index": 5281
+ },
+ "end": {
+ "line": 153,
+ "column": 3,
+ "index": 5395
+ }
+ },
+ {
+ "id": "components.pooltransition.updateKeepEarning",
+ "defaultMessage": "!!!Update now and keep earning",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 154,
+ "column": 21,
+ "index": 5418
+ },
+ "end": {
+ "line": 157,
+ "column": 3,
+ "index": 5532
+ }
+ },
+ {
+ "id": "components.pooltransition.update",
+ "defaultMessage": "!!!Update pool",
+ "file": "src/TxHistory/usePoolTransition.tsx",
+ "start": {
+ "line": 158,
+ "column": 10,
+ "index": 5544
+ },
+ "end": {
+ "line": 161,
+ "column": 3,
+ "index": 5631
+ }
+ }
+]
diff --git a/packages/swap/package.json b/packages/swap/package.json
index 597e17ed4d..72badee65b 100644
--- a/packages/swap/package.json
+++ b/packages/swap/package.json
@@ -142,7 +142,7 @@
},
"devDependencies": {
"@commitlint/config-conventional": "^17.0.2",
- "@emurgo/yoroi-lib": "0.15.1",
+ "@emurgo/yoroi-lib": "0.15.3",
"@react-native-async-storage/async-storage": "^1.19.3",
"@react-native-community/eslint-config": "^3.0.2",
"@release-it/conventional-changelog": "^5.0.0",
@@ -173,7 +173,7 @@
"typescript": "^5.3.3"
},
"peerDependencies": {
- "@emurgo/yoroi-lib": "0.15.1",
+ "@emurgo/yoroi-lib": "0.15.3",
"@react-native-async-storage/async-storage": ">= 1.19.3 <= 1.20.0",
"immer": "^10.0.2",
"react": ">= 16.8.0 <= 19.0.0",
diff --git a/yarn.lock b/yarn.lock
index 9a003bca20..d9785c077a 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -97,7 +97,7 @@
"@amplitude/analytics-types" "^1.3.1"
tslib "^2.4.1"
-"@amplitude/analytics-react-native@^1.3.1":
+"@amplitude/analytics-react-native@1.3.1":
version "1.3.1"
resolved "https://registry.yarnpkg.com/@amplitude/analytics-react-native/-/analytics-react-native-1.3.1.tgz#8e8d9e8b3f130a59efa77ff5098e642cd47c74cd"
integrity sha512-aoZzRN1xPD1eUgF6fiPQtGSJTc+96+Xnu0QPD85m+zyXrsZ1ReYVKB48KckAXLlWUIvrgRLBe+vhO0W4Jku96Q==
@@ -626,10 +626,10 @@
resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.22.5.tgz#533f36457a25814cf1df6488523ad547d784a99f"
integrity sha512-mM4COjgZox8U+JcXQwPijIZLElkgEpO5rsERVDJTc2qfCDfERyob6k5WegS14SX18IIjv+XD+GrqNumY5JRCDw==
-"@babel/helper-string-parser@^7.23.4":
- version "7.23.4"
- resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.23.4.tgz#9478c707febcbbe1ddb38a3d91a2e054ae622d83"
- integrity sha512-803gmbQdqwdf4olxrX4AJyFBV/RTr3rSmOj0rKwesmzlfhYNDEs+/iOcznzpNWlJlIlTJC2QfPFcHB6DlzdVLQ==
+"@babel/helper-string-parser@^7.24.7":
+ version "7.24.7"
+ resolved "https://registry.yarnpkg.com/@babel/helper-string-parser/-/helper-string-parser-7.24.7.tgz#4d2d0f14820ede3b9807ea5fc36dfc8cd7da07f2"
+ integrity sha512-7MbVt6xrwFQbunH2DNQsAP5sTGxfqQtErvBIvIMi6EQnbgUOuVYanvREcmFrOPhoXBrTtjhhP+lW+o5UfK+tDg==
"@babel/helper-validator-identifier@^7.22.20":
version "7.22.20"
@@ -641,6 +641,11 @@
resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.22.5.tgz#9544ef6a33999343c8740fa51350f30eeaaaf193"
integrity sha512-aJXu+6lErq8ltp+JhkJUfk1MTGyuA4v7f3pA+BJ5HLfNC6nAQ0Cpi9uOquUj8Hehg0aUiHzWQbOVJGao6ztBAQ==
+"@babel/helper-validator-identifier@^7.24.7":
+ version "7.24.7"
+ resolved "https://registry.yarnpkg.com/@babel/helper-validator-identifier/-/helper-validator-identifier-7.24.7.tgz#75b889cfaf9e35c2aaf42cf0d72c8e91719251db"
+ integrity sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==
+
"@babel/helper-validator-option@^7.22.15":
version "7.22.15"
resolved "https://registry.yarnpkg.com/@babel/helper-validator-option/-/helper-validator-option-7.22.15.tgz#694c30dfa1d09a6534cdfcafbe56789d36aba040"
@@ -2359,12 +2364,12 @@
to-fast-properties "^2.0.0"
"@babel/types@^7.22.19":
- version "7.23.6"
- resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.23.6.tgz#be33fdb151e1f5a56877d704492c240fc71c7ccd"
- integrity sha512-+uarb83brBzPKN38NX1MkB6vb6+mwvR6amUulqAE7ccQw1pEl+bCia9TbdG1lsnFP7lZySvUn37CHyXQdfTwzg==
+ version "7.24.7"
+ resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.24.7.tgz#6027fe12bc1aa724cd32ab113fb7f1988f1f66f2"
+ integrity sha512-XEFXSlxiG5td2EJRe8vOmRbaXVgfcBlszKujvVmWIK/UpywWljQCfzAv3RQCGujWQ1RD4YYWEAqDXfuJiy8f5Q==
dependencies:
- "@babel/helper-string-parser" "^7.23.4"
- "@babel/helper-validator-identifier" "^7.22.20"
+ "@babel/helper-string-parser" "^7.24.7"
+ "@babel/helper-validator-identifier" "^7.24.7"
to-fast-properties "^2.0.0"
"@bcoe/v8-coverage@^0.2.3":
@@ -2673,15 +2678,15 @@
resolved "https://registry.yarnpkg.com/@emotion/weak-memoize/-/weak-memoize-0.2.5.tgz#8eed982e2ee6f7f4e44c253e12962980791efd46"
integrity sha512-6U71C2Wp7r5XtFtQzYrW5iKFT67OixrSxjI4MptCHzdSVlgabczzqLe0ZSgnub/5Kp4hSbpDB1tMytZY9pwxxA==
-"@emurgo/cardano-serialization-lib-nodejs@12.0.0-alpha.18":
- version "12.0.0-alpha.18"
- resolved "https://registry.yarnpkg.com/@emurgo/cardano-serialization-lib-nodejs/-/cardano-serialization-lib-nodejs-12.0.0-alpha.18.tgz#8696720e2ca839d6b2e64d1add1b35893713cd22"
- integrity sha512-r2AiqV7Ip8+UlOxiWEM0ANi+aeKx7pimUpTTUDSbl/PGrxPLLB39Gs/d2UzVlfe1+uKQ6PLOBMFS3qf0m8/JJQ==
+"@emurgo/cardano-serialization-lib-nodejs@12.0.0-alpha.26":
+ version "12.0.0-alpha.26"
+ resolved "https://registry.yarnpkg.com/@emurgo/cardano-serialization-lib-nodejs/-/cardano-serialization-lib-nodejs-12.0.0-alpha.26.tgz#4e5fea7ba6d72888e21c5a9bea6bcff367834a4b"
+ integrity sha512-QheEm7wVZ4Tc0gOIYMUyf2VUb8a1ZjnDy4zNcGSRmuO1zlbJfjLDGv+uXG+pKqZN4fzMAzOtUwolTtbxzTzYbA==
-"@emurgo/cardano-serialization-lib-nodejs@^9.1.4":
- version "9.1.4"
- resolved "https://registry.yarnpkg.com/@emurgo/cardano-serialization-lib-nodejs/-/cardano-serialization-lib-nodejs-9.1.4.tgz#802396562ee35312003713e3a48f0dfef7ee1bd6"
- integrity sha512-zDYQ4E5CAz89OuXCPV7k3v5kLWkwUS5Jg7QZ5m/4vPkeuZolOXyqo84p6AYf0qZ14xkgxnvHIRY+heJKNs7Ddw==
+"@emurgo/cardano-serialization-lib-nodejs@12.0.0-alpha.28":
+ version "12.0.0-alpha.28"
+ resolved "https://registry.yarnpkg.com/@emurgo/cardano-serialization-lib-nodejs/-/cardano-serialization-lib-nodejs-12.0.0-alpha.28.tgz#1051d8b7975c555c1df6e7bd68fb5bf5e0ca0811"
+ integrity sha512-J8xtulw0ZMYws0aFIIigg7Ss4aQAV4z7cx1QhUaHYoI8JuABIDhczBEV+Wl6mZP6EQnkQYExmO1/NdvO5PzT3g==
"@emurgo/cip14-js@^3.0.1":
version "3.0.1"
@@ -2700,10 +2705,10 @@
buffer-crc32 "0.2.13"
fnv-plus "1.3.1"
-"@emurgo/cross-csl-core@4.2.0", "@emurgo/cross-csl-core@^4.2.0":
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/@emurgo/cross-csl-core/-/cross-csl-core-4.2.0.tgz#d6e2c00c0ae867f372d36daf37868b0f9fc39ad2"
- integrity sha512-cXqGlcLl034dCpfcrzl+BaeTOeNQhSZErDU7rAOAm+yc9Ow+rATF/ApSbdQTq2uEifsC5eRJLhBpdi7PAU0X0w==
+"@emurgo/cross-csl-core@4.4.0":
+ version "4.4.0"
+ resolved "https://registry.yarnpkg.com/@emurgo/cross-csl-core/-/cross-csl-core-4.4.0.tgz#b808b562f2c2442784a46384aea750718f6e5a59"
+ integrity sha512-R12cAHmkjeLb7g0+Og5zoi8is7jh5uONICaKLCvebqV6kHhCShSSHSdCbvqmCH3H8szPodkOkLp5qXNmxqfNxA==
dependencies:
"@cardano-foundation/ledgerjs-hw-app-cardano" "^5.0.0"
"@types/mocha" "^9.1.1"
@@ -2714,33 +2719,33 @@
hash-wasm "^4.9.0"
mocha "^10.0.0"
-"@emurgo/cross-csl-mobile@^4.2.0":
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/@emurgo/cross-csl-mobile/-/cross-csl-mobile-4.2.0.tgz#7f7fe1312c0a65b290e62f761cdc60d7c50aa79e"
- integrity sha512-2K9M7EJPkv0PKlrQsRb6A/kpUZSIOcur/cBgejEUa0MmMu2kUsSm4HgLutw5PzXkhlVqD6ux2NbfvTr0TLqEOw==
+"@emurgo/cross-csl-mobile@4.4.0":
+ version "4.4.0"
+ resolved "https://registry.yarnpkg.com/@emurgo/cross-csl-mobile/-/cross-csl-mobile-4.4.0.tgz#9109897e4da4c396e123894c131533a4812a499c"
+ integrity sha512-ZxdGxYiImSC6ldIAmClRsQzPN6dDa0ONpEuITcp2NNo9TvZmA0rScG/tYaEB/iQ3PIktGfotptASwImC4F+lLA==
dependencies:
- "@emurgo/cross-csl-core" "4.2.0"
- "@emurgo/csl-mobile-bridge" "6.0.0-alpha.3"
+ "@emurgo/cross-csl-core" "4.4.0"
+ "@emurgo/csl-mobile-bridge" "6.0.0-alpha.7"
-"@emurgo/cross-csl-nodejs@^4.2.0":
- version "4.2.0"
- resolved "https://registry.yarnpkg.com/@emurgo/cross-csl-nodejs/-/cross-csl-nodejs-4.2.0.tgz#6ed4524ca5478d6e60e10469600636803a8115b9"
- integrity sha512-RqUWCBEospYZVSvYGWb6Hw6zde6ktJckBL88NlwcHedNmOXL2EA16STfHDrnqhOzAOJhxDV4fFrDaBmNGrYVUg==
+"@emurgo/cross-csl-nodejs@4.4.0":
+ version "4.4.0"
+ resolved "https://registry.yarnpkg.com/@emurgo/cross-csl-nodejs/-/cross-csl-nodejs-4.4.0.tgz#7a8c8b7078018080283a9dc5340326e0e9a8d59c"
+ integrity sha512-yDtNFCYobYL7hILvico3Q85DIvDhc5H24UjDd8gdYApu6YGyR5C+Roz34VALxHlR8y2RA9cUM2GUt+a8Ev/Kxg==
dependencies:
- "@emurgo/cardano-serialization-lib-nodejs" "12.0.0-alpha.18"
- "@emurgo/cross-csl-core" "4.2.0"
+ "@emurgo/cardano-serialization-lib-nodejs" "12.0.0-alpha.26"
+ "@emurgo/cross-csl-core" "4.4.0"
-"@emurgo/csl-mobile-bridge@6.0.0-alpha.3":
- version "6.0.0-alpha.3"
- resolved "https://registry.yarnpkg.com/@emurgo/csl-mobile-bridge/-/csl-mobile-bridge-6.0.0-alpha.3.tgz#4626eed0209b464e4bdc2d0dd7311151949dd935"
- integrity sha512-/mX45uyKEx16XEQKCgPjfRRNLD7wcV3zyB5BLdO8LpPg2M43H5SUnN+hvvRXUcJ+7GzfwD/HFXGoj+ItK9qhHQ==
+"@emurgo/csl-mobile-bridge@6.0.0-alpha.7":
+ version "6.0.0-alpha.7"
+ resolved "https://registry.yarnpkg.com/@emurgo/csl-mobile-bridge/-/csl-mobile-bridge-6.0.0-alpha.7.tgz#63349d0f2e70d568ce628849c8d8b085892531aa"
+ integrity sha512-oOdiUCbbljHUOS8J0HHK6nHRVXIPeQWm4VfizZKfSLN9KgcRJFRlUAE0UxESdk4QlV/xtlb5qZ9FjjT2RmEvwg==
dependencies:
base-64 "0.1.0"
-"@emurgo/csl-mobile-bridge@6.0.0-alpha.4":
- version "6.0.0-alpha.4"
- resolved "https://registry.yarnpkg.com/@emurgo/csl-mobile-bridge/-/csl-mobile-bridge-6.0.0-alpha.4.tgz#114b1094892fdfda90441a159f14a4da975e253c"
- integrity sha512-ffnVpmN6bbMHSX80aqeIYNGXEvkvuTyAsMwX+31pRV6sYC49Q72zWCJWcRT7i1UIi4kfYsN3mACeMLeYL2K+Kw==
+"@emurgo/csl-mobile-bridge@6.0.0-alpha.9":
+ version "6.0.0-alpha.9"
+ resolved "https://registry.yarnpkg.com/@emurgo/csl-mobile-bridge/-/csl-mobile-bridge-6.0.0-alpha.9.tgz#b4a8be282518bc94c37e2c92aa340dc3d51743a7"
+ integrity sha512-ys8IyzVMk0yC6qRiqtMamb47NpNZZ0blITUcYv/8uJ7HNhm8swyq9tRwUwbl8GtrzbdkFeBzUX1/cXunvGXETw==
dependencies:
base-64 "0.1.0"
@@ -2762,13 +2767,26 @@
"@ledgerhq/logs" "^5.15.0"
rxjs "^6.5.5"
-"@emurgo/yoroi-lib@0.15.1":
- version "0.15.1"
- resolved "https://registry.yarnpkg.com/@emurgo/yoroi-lib/-/yoroi-lib-0.15.1.tgz#fdaa2be49067ab5be840f7eb64a8d92f94b37238"
- integrity sha512-aCH+w0MMwFhyl0UBt8r/MmAsdKtYWibP/9GIJPQxmCi0HMLornRm/laRyINsaXyoNvsej85Mb2V+ItTs2fu7Mw==
+"@emurgo/yoroi-lib@0.15.3":
+ version "0.15.3"
+ resolved "https://registry.yarnpkg.com/@emurgo/yoroi-lib/-/yoroi-lib-0.15.3.tgz#629cf1119c3b5b1946d64e7a031c1b21e6fca652"
+ integrity sha512-TOykcWUwybOlAMo+ELzapTv1uAXpYcXI1KDA2CYfZmdrsT8rnV2xc6Si085cKk/kviEZwMRn8XWmHhbGknT0Cg==
dependencies:
"@cardano-foundation/ledgerjs-hw-app-cardano" "^6.0.0"
- "@emurgo/cross-csl-core" "^4.2.0"
+ "@emurgo/cross-csl-core" "4.4.0"
+ "@noble/hashes" "^1.3.2"
+ axios "^0.24.0"
+ bech32 "^2.0.0"
+ bignumber.js "^9.0.1"
+ easy-crc "1.1.0"
+
+"@emurgo/yoroi-lib@0.15.5-alpha.8":
+ version "0.15.5-alpha.8"
+ resolved "https://registry.yarnpkg.com/@emurgo/yoroi-lib/-/yoroi-lib-0.15.5-alpha.8.tgz#71791392419f718d19256c4aaedd1ac8d3a37bbe"
+ integrity sha512-avc0cwttCgEgBMflxKK2Kaxw4IbErLa+ezlWWgJ4iGN0fgHYcpY335xXd2g+cQmsRKpPyhNWWqPXafo6e8lT8Q==
+ dependencies:
+ "@cardano-foundation/ledgerjs-hw-app-cardano" "^6.0.0"
+ "@emurgo/cross-csl-core" "4.4.0"
"@noble/hashes" "^1.3.2"
axios "^0.24.0"
bech32 "^2.0.0"
@@ -21715,7 +21733,16 @@ string-natural-compare@^3.0.1:
resolved "https://registry.yarnpkg.com/string-natural-compare/-/string-natural-compare-3.0.1.tgz#7a42d58474454963759e8e8b7ae63d71c1e7fdf4"
integrity sha512-n3sPwynL1nwKi3WJ6AIsClwBMa0zTi54fn2oLU6ndfTSIO05xaznjSf15PcBZU6FNWbmN5Q6cxT4V5hGvB4taw==
-"string-width-cjs@npm:string-width@^4.2.0", "string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3:
+"string-width-cjs@npm:string-width@^4.2.0":
+ version "4.2.3"
+ resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010"
+ integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==
+ dependencies:
+ emoji-regex "^8.0.0"
+ is-fullwidth-code-point "^3.0.0"
+ strip-ansi "^6.0.1"
+
+"string-width@^1.0.2 || 2 || 3 || 4", string-width@^4.0.0, string-width@^4.1.0, string-width@^4.2.0, string-width@^4.2.3:
version "4.2.3"
resolved "https://registry.yarnpkg.com/string-width/-/string-width-4.2.3.tgz#269c7117d27b05ad2e536830a8ec895ef9c6d010"
integrity sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==
@@ -21828,7 +21855,7 @@ string_decoder@~1.1.1:
dependencies:
safe-buffer "~5.1.0"
-"strip-ansi-cjs@npm:strip-ansi@^6.0.1", strip-ansi@^6.0.0, strip-ansi@^6.0.1:
+"strip-ansi-cjs@npm:strip-ansi@^6.0.1":
version "6.0.1"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9"
integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==
@@ -21856,6 +21883,13 @@ strip-ansi@^5.0.0, strip-ansi@^5.1.0, strip-ansi@^5.2.0:
dependencies:
ansi-regex "^4.1.0"
+strip-ansi@^6.0.0, strip-ansi@^6.0.1:
+ version "6.0.1"
+ resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-6.0.1.tgz#9e26c63d30f53443e9489495b2105d37b67a85d9"
+ integrity sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==
+ dependencies:
+ ansi-regex "^5.0.1"
+
strip-ansi@^7.0.1:
version "7.1.0"
resolved "https://registry.yarnpkg.com/strip-ansi/-/strip-ansi-7.1.0.tgz#d5b6568ca689d8561370b0707685d22434faff45"
@@ -23486,7 +23520,7 @@ workerpool@6.2.1:
resolved "https://registry.yarnpkg.com/workerpool/-/workerpool-6.2.1.tgz#46fc150c17d826b86a008e5a4508656777e9c343"
integrity sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==
-"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0", wrap-ansi@^7.0.0:
+"wrap-ansi-cjs@npm:wrap-ansi@^7.0.0":
version "7.0.0"
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43"
integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==
@@ -23522,6 +23556,15 @@ wrap-ansi@^6.0.1, wrap-ansi@^6.2.0:
string-width "^4.1.0"
strip-ansi "^6.0.0"
+wrap-ansi@^7.0.0:
+ version "7.0.0"
+ resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-7.0.0.tgz#67e145cff510a6a6984bdf1152911d69d2eb9e43"
+ integrity sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==
+ dependencies:
+ ansi-styles "^4.0.0"
+ string-width "^4.1.0"
+ strip-ansi "^6.0.0"
+
wrappy@1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f"