-
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.
Show an alert if no random user is find based on interest
- Loading branch information
1 parent
42120a2
commit a507064
Showing
4 changed files
with
151 additions
and
95 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,45 @@ | ||
import React from "react"; | ||
|
||
interface Props { | ||
message: string; | ||
setFunction: React.Dispatch<React.SetStateAction<boolean>>; | ||
} | ||
|
||
export const Alert = ({ message, setFunction }: Props) => { | ||
return ( | ||
<div className="fixed z-50 top-0 w-[71.3%]"> | ||
<div | ||
className="flex text-white justify-between bg-[#AD88C6] p-5 rounded relative" | ||
role="alert" | ||
> | ||
<div className="text-md font-semibold">{message}</div> | ||
<div> | ||
<svg | ||
className="cursor-pointer" | ||
width="25" | ||
height="25" | ||
viewBox="0 0 24 24" | ||
fill="none" | ||
xmlns="http://www.w3.org/2000/svg" | ||
onClick={() => setFunction(false)} | ||
> | ||
<path | ||
d="M18 6L6 18" | ||
stroke="#FEFEFE" | ||
stroke-width="2" | ||
stroke-linecap="round" | ||
stroke-linejoin="round" | ||
/> | ||
<path | ||
d="M6 6L18 18" | ||
stroke="#FEFEFE" | ||
stroke-width="2" | ||
stroke-linecap="round" | ||
stroke-linejoin="round" | ||
/> | ||
</svg> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
}; |
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