diff --git a/fixtures/write-form.js b/fixtures/write-form.js new file mode 100644 index 0000000..6d5cb55 --- /dev/null +++ b/fixtures/write-form.js @@ -0,0 +1,14 @@ +const writeForm = { + title: '스터디를 소개합니다.1', + contents: '우리는 이것저것 합니다.1', + moderatorId: 'user1', + applyEndDate: '2020-11-26', + participants: [], + personnel: 10, + tags: [ + 'JavaScript', + 'Algorithm', + ], +}; + +export default writeForm; diff --git a/src/components/write/WriteForm.jsx b/src/components/write/WriteForm.jsx new file mode 100644 index 0000000..9a4cdd7 --- /dev/null +++ b/src/components/write/WriteForm.jsx @@ -0,0 +1,64 @@ +import React from 'react'; + +import styled from '@emotion/styled'; + +const WriteFormWrapper = styled.div``; + +const WriteForm = ({ onChange, fields }) => { + const { + title, applyEndDate, personnel, contents, + } = fields; + + const handleChange = (e) => { + const { name, value } = e.target; + + onChange({ name, value }); + }; + + return ( + +
+ +
+
+ + +
+
+ + +
+
+ {/* TODO: 추후 draft.js를 사용하여 변경 예정 */} +