diff --git a/src/components/AddressCard.tsx b/src/components/AddressCard.tsx index 2e8ec621..686522e5 100644 --- a/src/components/AddressCard.tsx +++ b/src/components/AddressCard.tsx @@ -18,8 +18,9 @@ along with the library. If not, see . import { calculateAmountWorth } from '@alephium/sdk' import { colord } from 'colord' +import { LinearGradient } from 'expo-linear-gradient' import { Copy, SettingsIcon } from 'lucide-react-native' -import { StyleProp, View, ViewStyle } from 'react-native' +import { StyleProp, ViewStyle } from 'react-native' import styled, { useTheme } from 'styled-components/native' import AddressBadge from '~/components/AddressBadge' @@ -60,7 +61,7 @@ const AddressCard = ({ style, addressHash }: AddressCardProps) => { const textColor = themes[textColorTheme].font.primary return ( - +
{ Group {address.group} - + ) } diff --git a/src/components/AppText.tsx b/src/components/AppText.tsx index 88e3e61b..5ebebf3d 100644 --- a/src/components/AppText.tsx +++ b/src/components/AppText.tsx @@ -27,7 +27,7 @@ export type AppTextProps = { bold?: boolean semiBold?: boolean medium?: boolean - color?: FontColor | GlobalColor + color?: FontColor | GlobalColor | string colorTheme?: ThemeType size?: number } @@ -36,7 +36,7 @@ export default styled.Text` color: ${({ color, theme, colorTheme }) => { const th = colorTheme ? themes[colorTheme] : theme - return color ? th.font[color as FontColor] || th.global[color as GlobalColor] : th.font.primary + return color ? th.font[color as FontColor] || th.global[color as GlobalColor] || color : th.font.primary }}; ${({ bold }) => diff --git a/src/components/ConfirmWithAuthModal.tsx b/src/components/ConfirmWithAuthModal.tsx index 023fdb92..7820de69 100644 --- a/src/components/ConfirmWithAuthModal.tsx +++ b/src/components/ConfirmWithAuthModal.tsx @@ -17,11 +17,14 @@ along with the library. If not, see . */ import { getHumanReadableError, walletOpenAsyncUnsafe } from '@alephium/sdk' +import { XIcon } from 'lucide-react-native' import { useCallback, useEffect, useState } from 'react' import { Alert } from 'react-native' import styled from 'styled-components/native' +import Button from '~/components/buttons/Button' import PinCodeInput from '~/components/inputs/PinCodeInput' +import { ScreenSection } from '~/components/layout/Screen' import ModalWithBackdrop from '~/components/ModalWithBackdrop' import CenteredInstructions, { Instruction } from '~/components/text/CenteredInstructions' import { getStoredActiveWallet, getStoredWalletById } from '~/persistent-storage/wallets' @@ -31,6 +34,7 @@ import { mnemonicToSeed, pbkdf2 } from '~/utils/crypto' interface ConfirmWithAuthModalProps { onConfirm: (pin?: string, wallet?: ActiveWalletState) => void + onClose?: () => void usePin?: boolean walletId?: string } @@ -47,7 +51,7 @@ const errorInstructionSet: Instruction[] = [ { text: 'Please try again 💪', type: 'secondary' } ] -const ConfirmWithAuthModal = ({ onConfirm, walletId, usePin = false }: ConfirmWithAuthModalProps) => { +const ConfirmWithAuthModal = ({ onConfirm, onClose, walletId, usePin = false }: ConfirmWithAuthModalProps) => { const [shownInstructions, setShownInstructions] = useState(firstInstructionSet) const [encryptedWallet, setEncryptedWallet] = useState() // eslint-disable-next-line @typescript-eslint/no-unused-vars @@ -99,9 +103,14 @@ const ConfirmWithAuthModal = ({ onConfirm, walletId, usePin = false }: ConfirmWi return ( <> - + {encryptedWallet && ( + {onClose && ( + +