feat: add handler to real connect button

This commit is contained in:
RadoslavDimchev 2023-12-14 10:56:20 +02:00
parent 7ce207e959
commit f00275071b
1 changed files with 7 additions and 0 deletions

View File

@ -2,6 +2,7 @@ import { NodeIcon } from '@status-im/icons'
import { Separator, XStack, YStack } from 'tamagui' import { Separator, XStack, YStack } from 'tamagui'
import { useState } from 'react' import { useState } from 'react'
import { Button, Text } from '@status-im/components' import { Button, Text } from '@status-im/components'
import { useNavigate } from 'react-router-dom'
import PageWrapperShadow from '../../components/PageWrappers/PageWrapperShadow' import PageWrapperShadow from '../../components/PageWrappers/PageWrapperShadow'
import SyncStatus from './SyncStatus' import SyncStatus from './SyncStatus'
@ -14,6 +15,7 @@ import Icon from '../../components/General/Icon'
const PairDevice = () => { const PairDevice = () => {
const [isAwaitingPairing, setIsAwaitingPairing] = useState(false) const [isAwaitingPairing, setIsAwaitingPairing] = useState(false)
const navigate = useNavigate()
const isPaired = false const isPaired = false
const isPairing = false const isPairing = false
@ -21,6 +23,10 @@ const PairDevice = () => {
setIsAwaitingPairing(result) setIsAwaitingPairing(result)
} }
const connectViaIpHandler = () => {
navigate('/connect-device')
}
return ( return (
<PageWrapperShadow rightImageSrc="./background-images/day-night-bg.png" rightImageLogo={true}> <PageWrapperShadow rightImageSrc="./background-images/day-night-bg.png" rightImageLogo={true}>
<YStack space={'$3'}> <YStack space={'$3'}>
@ -48,6 +54,7 @@ const PairDevice = () => {
<Button <Button
icon={<Icon src="/icons/connection-blue.svg" width={20} />} icon={<Icon src="/icons/connection-blue.svg" width={20} />}
variant="outline" variant="outline"
onPress={connectViaIpHandler}
> >
Connect via IP Connect via IP
</Button> </Button>