-
Notifications
You must be signed in to change notification settings - Fork 21
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #143 from Motouom/Linking-Pages
Linking pages of the front end
- Loading branch information
Showing
18 changed files
with
1,728 additions
and
1,219 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
import { useNavigate } from 'react-router-dom'; | ||
|
||
const AccountBalance: React.FC = () => { | ||
const navigate = useNavigate(); | ||
|
||
const handleOkClick = () => { | ||
navigate('/home'); | ||
}; | ||
// success message to be displayed on the screen | ||
|
||
return ( | ||
<div className="flex justify-center items-center mb-34 bg-800 text-black text-sm"> | ||
<div className=""> | ||
<div className="rounded-lg w-80 m-auto px-4 py-2 text-lg absolute inset-x-0 top-12 mt-12 bg-gray-100"> | ||
<div className="pt-12 pb-12"> | ||
<h1 className="text-2xl font-bold pb-10">Account Balance.</h1> | ||
<p className="text-md">Balance: $Balance</p> | ||
</div> | ||
</div> | ||
<div className="pt-12"> | ||
<button className="rounded-full w-80 m-auto px-4 py-2 text-white bg-blue-950 text-lg absolute inset-x-0 bottom-6" | ||
onClick={handleOkClick} | ||
> | ||
OK | ||
</button> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default AccountBalance; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
import { useNavigate } from 'react-router-dom'; | ||
import Logo from '../assets/Logo.png'; | ||
import React, { useState, useEffect } from 'react'; | ||
|
||
const Home: React.FC = () => { | ||
const navigate = useNavigate(); | ||
|
||
const handleCheckBalanceClick = () => { | ||
navigate('/pin_balance'); | ||
}; | ||
const handleSendMoneyClick = () => { | ||
navigate('/payment'); | ||
}; | ||
|
||
|
||
|
||
return ( | ||
<div className="flex justify-center items-center mb-34 bg-800 text-black text-sm"> | ||
<div className="w-80 m-auto px-4 py-2 text-lg absolute inset-x-0 top-12"> | ||
<img src={Logo} alt="Logo" /> | ||
<p className="text-sm text-center text-black pb-4">Send money far and wide with ease.</p> | ||
</div> | ||
<div className="pt-12 w-80 m-auto"> | ||
<button className="rounded-full w-80 m-auto px-4 py-2 text-white bg-blue-950 text-lg absolute inset-x-0 bottom-20" | ||
onClick={handleSendMoneyClick}> | ||
Send Money | ||
</button> | ||
<button | ||
className="rounded-full w-80 m-auto px-4 py-2 text-white bg-blue-950 text-lg absolute inset-x-0 bottom-6" | ||
onClick={handleCheckBalanceClick}> | ||
Check Balance | ||
</button> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default Home; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
import { useNavigate } from 'react-router-dom'; | ||
import { faLock } from '@fortawesome/free-solid-svg-icons/faLock'; | ||
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'; | ||
|
||
const PinInput_For_Balance: React.FC = () => { | ||
const navigate = useNavigate(); | ||
|
||
const handleCancelClick = () => { | ||
navigate('/home'); | ||
}; | ||
const handleConfirmClick = () => { | ||
navigate('/balance'); | ||
}; | ||
|
||
return ( | ||
<div className="flex justify-center items-center mb-34 bg-800 text-black text-sm"> | ||
<div className=""> | ||
<div className="input-area"> | ||
<form className="max-w-sm mx-auto flex rounded-lg w-80 m-auto text-lg absolute inset-x-0"> | ||
<div className="input-group"> | ||
<input | ||
type="password" | ||
maxLength={4} | ||
id="number-input" | ||
className="text-lg text-center rounded-full w-80 p-2.5 bg-red-50 dark:placeholder-gray-400 dark:text-black" | ||
placeholder="Enter PIN" | ||
required | ||
/> | ||
<FontAwesomeIcon | ||
icon={faLock} | ||
size="1x" | ||
className="absolute left-3 top-1/2 transform -translate-y-1/2 text-red-600" | ||
/> | ||
</div> | ||
</form> | ||
</div> | ||
<div className="pt-12"> | ||
<button | ||
className="rounded-full w-80 m-auto px-4 py-2 text-white bg-red-600 text-lg absolute inset-x-0 bottom-20" | ||
onClick={handleCancelClick} | ||
> | ||
Cancel | ||
</button> | ||
<button | ||
className="rounded-full w-80 m-auto px-4 py-2 text-white bg-blue-950 text-lg absolute inset-x-0 bottom-6" | ||
onClick={handleConfirmClick} | ||
> | ||
Confirm | ||
</button> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default PinInput_For_Balance; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.