forked from Qsilver97/Qwallet
-
Notifications
You must be signed in to change notification settings - Fork 1
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 Qsilver97#81 from Qsilver97/staging
Staging
- Loading branch information
Showing
73 changed files
with
2,667 additions
and
536 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
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
37 changes: 37 additions & 0 deletions
37
app/client/src/components/dashboard/modal/TxFormsModal.tsx
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,37 @@ | ||
import { useAuth } from "../../../contexts/AuthContext"; | ||
import { Text } from "../../commons"; | ||
|
||
const TxFormsModal = () => { | ||
const { txId, expectedTick, txStatus } = useAuth(); | ||
|
||
return ( | ||
<div className="py-5 px-6 space-y-6 border-white/60 border rounded-2xl"> | ||
{txStatus.includes('broadcast for tick') && | ||
<div className="break-all"> | ||
Sending... | ||
<br /> | ||
transactionId: {txId}<br /> | ||
expectedTick: {expectedTick} | ||
</div> | ||
} | ||
{txStatus.includes('no command pending') && | ||
|
||
<div className="space-y-7 grid justify-center"> | ||
<img | ||
src="assets/images/ui/checked-blue.svg" | ||
alt="Checked Blue" | ||
className="mx-auto" | ||
/> | ||
|
||
<div className="space-y-5"> | ||
<Text className="text-2xl text-center"> | ||
Success | ||
</Text> | ||
</div> | ||
</div> | ||
} | ||
</div> | ||
); | ||
}; | ||
|
||
export default TxFormsModal; |
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,34 @@ | ||
import React from "react"; | ||
import TxFormsModal from "./TxFormsModal"; | ||
import { useAuth } from "../../../contexts/AuthContext"; | ||
type TxModalProps = { | ||
|
||
}; | ||
|
||
const TxModal: React.FC<TxModalProps> = ({ }) => { | ||
const { txStatus, setTxStatus } = useAuth(); | ||
|
||
const handleCloseModal = () => { | ||
setTxStatus(""); | ||
} | ||
return ( | ||
<div className="fixed inset-0 flex items-center justify-center z-50"> | ||
<div className="fixed inset-0 bg-black bg-opacity-50 backdrop-filter backdrop-blur-lg"></div> | ||
<div className="relative w-[500px] h-auto bg-dark p-8 rounded-2xl shadow-lg"> | ||
<div className="w-full px-14 py-5 space-y-6"> | ||
<TxFormsModal /> | ||
</div> | ||
{txStatus.includes('no command pending') && | ||
<button | ||
className="w-full py-4 bg-dark-gray-400 font-Inter font-light rounded-xl cursor-pointer" | ||
onClick={() => handleCloseModal()} | ||
> | ||
Close | ||
</button> | ||
} | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default TxModal; |
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
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.