Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
students
survey
Commits
c0481dda
Commit
c0481dda
authored
Jan 03, 2023
by
jang dong hyeok
Browse files
Accordion에 질문종류에 맞는 예시Img 추가
parent
dee8523f
Changes
7
Hide whitespace changes
Inline
Side-by-side
frontend/src/forms/RCheckbox.tsx
View file @
c0481dda
import
React
from
"
react
"
;
import
React
from
"
react
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
chartImg2
from
"
../icons/chartImg2.png
"
;
type
Props
=
{
type
Props
=
{
question
:
IQuestionData
;
question
:
IQuestionData
;
...
@@ -14,6 +15,7 @@ export const RCheckbox = ({ question }: Props) => {
...
@@ -14,6 +15,7 @@ export const RCheckbox = ({ question }: Props) => {
return
(
return
(
<
div
className
=
"m-5"
>
<
div
className
=
"m-5"
>
<
img
src
=
{
chartImg2
}
/>
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
<
div
key
=
{
index
}
className
=
""
>
<
div
key
=
{
index
}
className
=
""
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
...
...
frontend/src/forms/RDate.tsx
View file @
c0481dda
import
React
from
"
react
"
;
import
React
from
"
react
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
chartImg2
from
"
../icons/chartImg2.png
"
;
type
Props
=
{
type
Props
=
{
question
:
IQuestionData
;
question
:
IQuestionData
;
...
@@ -8,6 +9,7 @@ type Props = {
...
@@ -8,6 +9,7 @@ type Props = {
export
const
RDate
=
({
question
}:
Props
)
=>
{
export
const
RDate
=
({
question
}:
Props
)
=>
{
return
(
return
(
<
div
className
=
"m-5"
>
<
div
className
=
"m-5"
>
<
img
src
=
{
chartImg2
}
/>
{
question
.
answers
.
map
((
answer
:
any
,
index
:
number
)
=>
(
{
question
.
answers
.
map
((
answer
:
any
,
index
:
number
)
=>
(
<
div
key
=
{
index
}
className
=
"font-bold"
>
<
div
key
=
{
index
}
className
=
"font-bold"
>
{
answer
}
{
answer
}
...
...
frontend/src/forms/RDropdown.tsx
View file @
c0481dda
import
React
from
"
react
"
;
import
React
from
"
react
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
chartImg1
from
"
../icons/chartImg1.png
"
;
type
Props
=
{
type
Props
=
{
question
:
IQuestionData
;
question
:
IQuestionData
;
...
@@ -13,6 +14,7 @@ export const RDropdown = ({ question }: Props) => {
...
@@ -13,6 +14,7 @@ export const RDropdown = ({ question }: Props) => {
return
(
return
(
<
div
className
=
"m-5"
>
<
div
className
=
"m-5"
>
<
img
src
=
{
chartImg1
}
/>
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
<
div
key
=
{
index
}
className
=
""
>
<
div
key
=
{
index
}
className
=
""
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
...
...
frontend/src/forms/RRadio.tsx
View file @
c0481dda
import
React
,
{
useState
}
from
"
react
"
;
import
React
,
{
useState
}
from
"
react
"
;
import
{
Pie
}
from
"
../charts/pies/Pie
"
;
import
{
Pie
}
from
"
../charts/pies/Pie
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
chartImg1
from
"
../icons/chartImg1.png
"
;
type
Props
=
{
type
Props
=
{
question
:
IQuestionData
;
question
:
IQuestionData
;
...
@@ -17,6 +18,7 @@ export const RRadio = ({ question }: Props) => {
...
@@ -17,6 +18,7 @@ export const RRadio = ({ question }: Props) => {
return
(
return
(
<
div
className
=
"m-5"
>
<
div
className
=
"m-5"
>
<
img
src
=
{
chartImg1
}
/>
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
<
div
key
=
{
index
}
className
=
""
>
<
div
key
=
{
index
}
className
=
""
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
...
...
frontend/src/forms/RRating.tsx
View file @
c0481dda
import
React
from
"
react
"
;
import
React
from
"
react
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
{
IQuestionData
}
from
"
../types
"
;
import
chartImg2
from
"
../icons/chartImg2.png
"
;
type
Props
=
{
type
Props
=
{
question
:
IQuestionData
;
question
:
IQuestionData
;
...
@@ -14,6 +15,7 @@ export const RRating = ({ question }: Props) => {
...
@@ -14,6 +15,7 @@ export const RRating = ({ question }: Props) => {
return
(
return
(
<
div
className
=
"m-5"
>
<
div
className
=
"m-5"
>
<
div
>
{
question
.
content
.
minRateDescription
}
</
div
>
<
div
>
{
question
.
content
.
minRateDescription
}
</
div
>
<
img
src
=
{
chartImg2
}
/>
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
{
question
.
content
.
choices
.
map
((
choice
:
any
,
index
:
number
)
=>
(
<
div
key
=
{
index
}
className
=
""
>
<
div
key
=
{
index
}
className
=
""
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
<
span
className
=
"font-bold"
>
{
choice
.
text
}
</
span
>
...
...
frontend/src/icons/chartImg1.png
0 → 100644
View file @
c0481dda
10.7 KB
frontend/src/icons/chartImg2.png
0 → 100644
View file @
c0481dda
22.2 KB
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment