-
Notifications
You must be signed in to change notification settings - Fork 161
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 #372 from starknet-id/ayush/focustree-fe
feat: add rewards modal
- Loading branch information
Showing
8 changed files
with
179 additions
and
2 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import React from "react"; | ||
import styles from "../../styles/components/quests/modal.module.css"; | ||
import { FunctionComponent, ReactNode } from "react"; | ||
import { Modal } from "@mui/material"; | ||
|
||
type RewardModalProps = { | ||
message: ReactNode; | ||
closeModal: () => void; | ||
open: boolean; | ||
}; | ||
|
||
const RewardModal: FunctionComponent<RewardModalProps> = ({ | ||
message, | ||
closeModal, | ||
open, | ||
}) => { | ||
return ( | ||
<Modal | ||
disableAutoFocus | ||
open={open} | ||
onClose={closeModal} | ||
aria-labelledby="modal-modal-title" | ||
aria-describedby="modal-modal-description" | ||
> | ||
<div className={styles.menu}> | ||
<button className={styles.menu_close} onClick={closeModal}> | ||
<svg viewBox="0 0 24 24"> | ||
<path | ||
strokeLinecap="round" | ||
strokeLinejoin="round" | ||
strokeWidth="2" | ||
d="M6 18L18 6M6 6l12 12" | ||
></path> | ||
</svg> | ||
</button> | ||
{message} | ||
</div> | ||
</Modal> | ||
); | ||
}; | ||
export default RewardModal; |
Binary file not shown.
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,57 @@ | ||
.menu { | ||
position: absolute; | ||
background-color: var(--background600); | ||
align-self: center; | ||
left: 50%; | ||
top: 50%; | ||
transform: translate(-50%, -50%); | ||
border-radius: 20px; | ||
max-width: 694px; | ||
display: flex; | ||
flex-direction: column; | ||
z-index: 1000; | ||
width: 100vw; | ||
} | ||
|
||
.blackFilter { | ||
width: 100%; | ||
height: 100%; | ||
position: absolute; | ||
background-color: rgba(0, 0, 0, 0.192); | ||
z-index: auto; | ||
} | ||
|
||
.menu_close { | ||
position: absolute; | ||
top: 12px; | ||
right: 12px; | ||
width: 22px; | ||
stroke: rgb(101, 101, 101); | ||
cursor: url(../../../public/icons/pointer-cursor.png), pointer; | ||
transition: 0.3s; | ||
background-color: transparent; | ||
border: none; | ||
} | ||
|
||
.menu_close:hover { | ||
stroke: white; | ||
} | ||
|
||
.menu_title { | ||
color: var(--secondary); | ||
font-size: 25px; | ||
font-weight: bold; | ||
text-align: center; | ||
} | ||
|
||
@media (max-width: 820px) { | ||
.menu { | ||
width: 90%; | ||
padding: 30px; | ||
} | ||
|
||
.menu_title { | ||
font-size: 19px; | ||
margin: -7px -2px 2px; | ||
} | ||
} |
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
4696883
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Successfully deployed to the following URLs:
goerli-starknet-quest – ./
goerli-starknet-quest-git-testnet-starknetid.vercel.app
goerli.starknet.quest
goerli-starknet-quest-starknetid.vercel.app
goerli-starknet-quest.vercel.app