-
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.
✨ feat: 회의 만들기 페이지 step3(회의 장소) UI 작성 (#48)
* feat: 회의실 만들기 step3 UI 틀 작성 * feat: 회의실 만들기 step3 UI 틀 작성 * feat: import step3 * style: 버튼 컴포넌트의 hover, focus 속성 제거
- Loading branch information
1 parent
fde345e
commit 175ea6e
Showing
4 changed files
with
55 additions
and
4 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 |
---|---|---|
@@ -1,2 +1,3 @@ | ||
export * from './step1'; | ||
export * from './step2'; | ||
export * from './step3'; |
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,43 @@ | ||
/** @jsxImportSource @emotion/react */ | ||
import { Flex } from '@/components/Wrapper'; | ||
import { Input } from '@/components/common'; | ||
import { FormType } from '@/pages/createMeetingroom'; | ||
import { css } from '@emotion/react'; | ||
import styled from '@emotion/styled'; | ||
import { FieldErrors, UseFormRegister, UseFormWatch } from 'react-hook-form'; | ||
|
||
interface Step3Props { | ||
register: UseFormRegister<FormType>; | ||
watch: UseFormWatch<FormType>; | ||
errors?: FieldErrors; | ||
} | ||
|
||
export const Step3 = ({ register, watch, errors }: Step3Props) => { | ||
return ( | ||
<Flex direction="column" align="flex-start"> | ||
<div | ||
css={css` | ||
width: 100%; | ||
`}> | ||
<StyledLabel>회의 장소를 알려주세요</StyledLabel> | ||
<Input | ||
{...register('meetingRoomPlace')} | ||
value={watch('meetingRoomPlace')} | ||
type="default" | ||
placeholder="선택사항입니다" | ||
isError={errors?.meetingRoomPlace ? true : false} | ||
errorText={errors?.meetingRoomPlace?.message as string} | ||
/> | ||
</div> | ||
</Flex> | ||
); | ||
}; | ||
|
||
const StyledLabel = styled.label` | ||
${(props) => props.theme.typo.T5} | ||
color: ${(props) => props.theme.palette.dark_gray2}; | ||
display: flex; | ||
align-items: center; | ||
gap: 0.2rem; | ||
margin-bottom: 1rem; | ||
`; |
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