-
Notifications
You must be signed in to change notification settings - Fork 0
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
7 changed files
with
213 additions
and
123 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
import React from "react"; | ||
import { IoIosClose } from "react-icons/io"; | ||
|
||
function Modal(props) { | ||
return props.trigger ? ( | ||
<div className="fixed top-0 left-0 w-full h-screen bg-neutral-500/50 flex justify-center items-center "> | ||
<div className="px-1 py-6 w-11/12 bg-white rounded-md"> | ||
<div className="relative flex mx-4"> | ||
<div className=" w-5/6 text-left">{props.solution}</div> | ||
<button className="absolute top-0 right-0" onClick={() => props.setTrigger(false)}> | ||
<IoIosClose className="" size="2rem" /> | ||
</button> | ||
</div> | ||
<div className="m-4">{props.children}</div> | ||
</div> | ||
</div> | ||
) : ( | ||
"" | ||
); | ||
} | ||
|
||
export default Modal; |
Oops, something went wrong.