mirror of
https://gitlab.com/MrFry/qmining-page
synced 2025-04-01 20:23:44 +02:00
Merged with master
This commit is contained in:
parent
201c64504a
commit
a0f2bf26b3
1 changed files with 30 additions and 0 deletions
30
src/components/Subject.js
Normal file
30
src/components/Subject.js
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
import React, { PureComponent } from 'react'
|
||||||
|
|
||||||
|
import Question from './Question.js'
|
||||||
|
|
||||||
|
class Subject extends PureComponent {
|
||||||
|
render () {
|
||||||
|
const { subj } = this.props
|
||||||
|
|
||||||
|
if (subj) {
|
||||||
|
return (
|
||||||
|
<div >
|
||||||
|
{subj.Questions.map((question, i) => {
|
||||||
|
return (
|
||||||
|
<Question
|
||||||
|
key={i}
|
||||||
|
question={question}
|
||||||
|
/>
|
||||||
|
)
|
||||||
|
})}
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
} else {
|
||||||
|
return (
|
||||||
|
<div />
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Subject
|
Loading…
Add table
Add a link
Reference in a new issue