-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
1,750 additions
and
657 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
export const OVERFLOW_TVL_WARNING_THRESHOLD = 0.8; | ||
export const OVERFLOW_TVL_WARNING_THRESHOLD = 0.2; | ||
export const OVERFLOW_HEIGHT_WARNING_THRESHOLD = 3; | ||
export const UTXO_KEY = "UTXOs"; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
import { useTheme } from "next-themes"; | ||
import Image from "next/image"; | ||
import { useEffect, useState } from "react"; | ||
|
||
import darkIcon from "@/app/assets/icon-black.svg"; | ||
import lightIcon from "@/app/assets/icon-white.svg"; | ||
|
||
interface IconProps {} | ||
|
||
export const Icon: React.FC<IconProps> = () => { | ||
const [mounted, setMounted] = useState(false); | ||
const { resolvedTheme } = useTheme(); | ||
const lightSelected = resolvedTheme === "light"; | ||
|
||
// useEffect only runs on the client, so now we can safely show the UI | ||
useEffect(() => { | ||
setMounted(true); | ||
}, []); | ||
|
||
// uses placeholder of babylon logo with primary color | ||
// since before theme is resolved, we don't know which logo to show | ||
if (!mounted) { | ||
return <span className="h-[24px] w-[24px]" />; | ||
} | ||
|
||
return ( | ||
<span className="inline-block mx-2"> | ||
<Image | ||
src={lightSelected ? darkIcon : lightIcon} | ||
alt="Babylon" | ||
width={24} | ||
height={24} | ||
/> | ||
</span> | ||
); | ||
}; |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
import { IoMdClose } from "react-icons/io"; | ||
|
||
import { GeneralModal } from "../GeneralModal"; | ||
|
||
import { Privacy } from "./data/privacy"; | ||
|
||
interface PrivacyModalProps { | ||
open: boolean; | ||
onClose: (value: boolean) => void; | ||
} | ||
|
||
export const PrivacyModal: React.FC<PrivacyModalProps> = ({ | ||
open, | ||
onClose, | ||
}) => { | ||
return ( | ||
<GeneralModal open={open} onClose={onClose}> | ||
<div className="mb-4 flex items-center justify-between"> | ||
<h4 className="font-bold">Privacy Policy</h4> | ||
<button | ||
className="btn btn-circle btn-ghost btn-sm" | ||
onClick={() => onClose(false)} | ||
> | ||
<IoMdClose size={24} /> | ||
</button> | ||
</div> | ||
<Privacy /> | ||
</GeneralModal> | ||
); | ||
}; |
Oops, something went wrong.