aboutsummaryrefslogtreecommitdiffstats
path: root/webui/src/bug/SetStatus.js
diff options
context:
space:
mode:
authorMichael Muré <batolettre@gmail.com>2018-08-15 22:20:50 +0200
committerMichael Muré <batolettre@gmail.com>2018-08-15 22:20:50 +0200
commit11b792608fadfbbc41e737b401d505ff52944907 (patch)
treecf344e906e6dde4f526a38c7c990e67446bb744f /webui/src/bug/SetStatus.js
parent17aa40505b58a4a9d679efb8512252397872470c (diff)
downloadgit-bug-11b792608fadfbbc41e737b401d505ff52944907.tar.gz
webui: display status change in the timeline
Diffstat (limited to 'webui/src/bug/SetStatus.js')
-rw-r--r--webui/src/bug/SetStatus.js37
1 files changed, 37 insertions, 0 deletions
diff --git a/webui/src/bug/SetStatus.js b/webui/src/bug/SetStatus.js
new file mode 100644
index 00000000..eb41fc28
--- /dev/null
+++ b/webui/src/bug/SetStatus.js
@@ -0,0 +1,37 @@
+import { withStyles } from '@material-ui/core/styles'
+import gql from 'graphql-tag'
+import React from 'react'
+import Author from '../Author'
+import Date from '../Date'
+
+const styles = theme => ({
+ main: {
+ ...theme.typography.body2
+ },
+})
+
+const SetStatus = ({op, classes}) => {
+
+ return (
+ <div className={classes.main}>
+ <Author author={op.author} bold />
+ <span> {op.status.toLowerCase()} this</span>
+ <Date date={op.date} />
+ </div>
+ )
+}
+
+SetStatus.fragment = gql`
+ fragment SetStatus on Operation {
+ ... on SetStatusOperation {
+ date
+ author {
+ name
+ email
+ }
+ status
+ }
+ }
+`
+
+export default withStyles(styles)(SetStatus)