-
Notifications
You must be signed in to change notification settings - Fork 0
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
Conversation
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.
수고하셨습니다.
}) | ||
.then((res) => { | ||
console.log(res); |
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.
편안합니다
<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> |
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.
웬만해서는 간단한 레이아웃이 아닌 이상 복잡한 상태가 있는 로직들은 features/comment 폴더 파서 거기다가 넣는게 좋습니다.
pages에 있는 건 라우터가 아닌 이상 상태가 없어야 해요
#️⃣ 연관 이슈
📝 작업 내용