mirror of
https://github.com/acid-info/logos-ordinals-dashboard.git
synced 2025-01-28 22:27:01 +00:00
feat: enable mint countdown
This commit is contained in:
parent
e0fa21f83a
commit
ed3c64fb2a
@ -10,7 +10,7 @@ const Toast: React.FC = () => {
|
|||||||
const userInfo = useAtomValue(userInfoAtom)
|
const userInfo = useAtomValue(userInfoAtom)
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const targetTime = new Date('2024-11-04T13:00:00Z').getTime()
|
const targetTime = new Date('2024-12-16T13:00:00Z').getTime()
|
||||||
|
|
||||||
const formatTime = (timeInSeconds: number) => {
|
const formatTime = (timeInSeconds: number) => {
|
||||||
const days = Math.floor(timeInSeconds / (3600 * 24))
|
const days = Math.floor(timeInSeconds / (3600 * 24))
|
||||||
@ -58,7 +58,19 @@ const Toast: React.FC = () => {
|
|||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
</ToastContainer>
|
</ToastContainer>
|
||||||
) : null
|
) : (
|
||||||
|
<ToastContainer showTopToast={showTopToast}>
|
||||||
|
<>
|
||||||
|
Logos Ordinals Mint Begins 16th December, 2024 at 1PM UTC
|
||||||
|
<TimeRemaining>Time remaining: {time}</TimeRemaining>
|
||||||
|
</>
|
||||||
|
<div>
|
||||||
|
<button className="close-button" onClick={() => setShowTopToast(false)}>
|
||||||
|
<img src="/assets/close-orange.svg" alt="close" />
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</ToastContainer>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
const ToastContainer = styled.div<{ showTopToast: boolean }>`
|
const ToastContainer = styled.div<{ showTopToast: boolean }>`
|
||||||
@ -113,4 +125,8 @@ const ToastContainer = styled.div<{ showTopToast: boolean }>`
|
|||||||
}
|
}
|
||||||
`
|
`
|
||||||
|
|
||||||
|
const TimeRemaining = styled.div`
|
||||||
|
margin-left: 20px;
|
||||||
|
`
|
||||||
|
|
||||||
export default Toast
|
export default Toast
|
||||||
|
Loading…
x
Reference in New Issue
Block a user