-
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.
Merge pull request #340 from boostcampwm2023/feature/invite-page
feat: 참여 요청 기능 구현, 초대 링크 변경 기능 구현
- Loading branch information
Showing
17 changed files
with
237 additions
and
79 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { API_URL } from "../../constants/path"; | ||
import { authAPI } from "../utils/authAPI"; | ||
|
||
export const getInvitePreview = async (inviteLinkId: string) => { | ||
const response = await authAPI.get( | ||
`${API_URL.INVITE_PREVIEW}/${inviteLinkId}` | ||
); | ||
|
||
return response; | ||
}; |
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
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,38 @@ | ||
import useMemberStore from "../../stores/useMemberStore"; | ||
import { SettingJoinRequestDTO } from "../../types/DTO/settingDTO"; | ||
|
||
interface JoinRequestBlockProps extends SettingJoinRequestDTO {} | ||
|
||
const JoinRequestBlock = ({ username, imageUrl }: JoinRequestBlockProps) => { | ||
const myRole = useMemberStore((state) => state.myInfo.role); | ||
|
||
return ( | ||
<div className="flex w-full gap-3"> | ||
<div className="w-[16.25rem] flex gap-3 items-center"> | ||
<img className="w-8 h-8 rounded-full" src={imageUrl} alt={username} /> | ||
<p className="">{username}</p> | ||
</div> | ||
<div className="w-[18.75rem]"></div> | ||
<div className="w-[30rem]"> | ||
{myRole === "LEADER" && ( | ||
<> | ||
<button | ||
className="px-2 py-1 mr-3 text-white rounded w-fit text-xxs bg-middle-green" | ||
type="button" | ||
> | ||
참여 수락 | ||
</button> | ||
<button | ||
className="px-2 py-1 text-white rounded w-fit bg-error-red text-xxs" | ||
type="button" | ||
> | ||
참여 거절 | ||
</button> | ||
</> | ||
)} | ||
</div> | ||
</div> | ||
); | ||
}; | ||
|
||
export default JoinRequestBlock; |
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
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
Oops, something went wrong.