Skip to content

Instantly share code, notes, and snippets.

@mzabriskie
Created October 31, 2017 19:42
Show Gist options
  • Save mzabriskie/80df970d54f491fdce8ecab79cf666ee to your computer and use it in GitHub Desktop.
Save mzabriskie/80df970d54f491fdce8ecab79cf666ee to your computer and use it in GitHub Desktop.
import React, { Component } from 'react'
import PropTypes from 'prop-types'
class MessageModalBody extends Component {
render () {
return (
<TabList>
<TabPanel title="Score Range">
<MessageForm showScoreFilter={true} />
</TabPanel>
<TabPanel title="Missing Submissions">
<MessageForm />
</TabPanel>
<TabPanel title="Late Submissions">
<MessageForm />
</TabPanel>
</TabList>
)
}
}
class MessageForm extends Component {
static propTypes = {
showScoreFilter: PropTypes.bool
}
static defaultProps = {
showScoreFilter: false
}
render () {
return (
<div>
{this.props.showScoreFilter && (
<ScoreRangeFilter />
)}
<FormField id="bcc" label="Bcc:" layout="inline">
<TextInput id="bcc" />
</FormField>
<FormField id="subject" label="Subject:" layout="inline">
<TextInput id="subject" />
</FormField>
<FormField id="message" label="Message:" layout="inline">
<TextArea id="message" />
</FormField>
</div>
)
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment