Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feat] 어드민 기대평 이벤트 검색 일부 구현 #96

Merged
merged 2 commits into from
Aug 13, 2024

Conversation

darkdulgi
Copy link
Collaborator

#️⃣ 연관 이슈

📝 작업 내용

어드민 페이지에서 기대평을 조회하기 위해 이벤트명을 검색하는 부분의 외형을 일부 구현했습니다.

@darkdulgi darkdulgi added the feat 기능 구현 label Aug 13, 2024
@darkdulgi darkdulgi self-assigned this Aug 13, 2024
@darkdulgi darkdulgi linked an issue Aug 13, 2024 that may be closed by this pull request
6 tasks
Copy link
Collaborator

@lybell-art lybell-art left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고하셨습니다.

Comment on lines -34 to -36
})
.then((res) => {
console.log(res);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

편안합니다

Comment on lines +40 to +76
<div className="flex flex-col w-full h-dvh p-20">
<span className="text-title-l">기대평</span>

<form onSubmit={searchComment} className="relative mt-10 flex">
<input
type="text"
inputMode="numeric"
onChange={onChangeForm}
onFocus={() => setIsSpread(true)}
onBlur={() => setIsSpread(false)}
value={formString}
placeholder="ID (숫자 6자리)"
className={`outline outline-1 outline-neutral-500 px-4 py-2 w-full ${isSpread ? "rounded-t-md" : "rounded-md"}`}
/>

<div
className={`absolute top-full outline outline-1 w-full outline-neutral-500 rounded-b-md px-3 py-2 flex flex-col gap-2 ${!isSpread && "hidden"}`}
>
{searchList.map((evt) => (
<li
key={evt.id}
className="list-none w-full hover:bg-blue-200 rounded px-1 flex"
>
<span className="w-40">{evt.id}</span>
<span>{evt.name}</span>
</li>
))}
</div>

<img
onClick={searchComment}
src="/icons/search.png"
alt="검색"
className="absolute top-1/2 -translate-y-1/2 right-4 cursor-pointer"
/>
</form>
</div>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

웬만해서는 간단한 레이아웃이 아닌 이상 복잡한 상태가 있는 로직들은 features/comment 폴더 파서 거기다가 넣는게 좋습니다.
pages에 있는 건 라우터가 아닌 이상 상태가 없어야 해요

@lybell-art lybell-art merged commit 98400df into dev Aug 13, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat 기능 구현
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[feat] 어드민-기대평
2 participants