aboutsummaryrefslogtreecommitdiffstats
path: root/webui/src/bug/TimelineQuery.js
diff options
context:
space:
mode:
authorQuentin Gliech <quentingliech@gmail.com>2018-08-18 17:00:53 -0400
committerSandhose <quentingliech@gmail.com>2018-08-19 23:14:45 +0200
commitbb4ebed08c3f1b1a7ba9968ede75a07f1705d2df (patch)
treedd6998679330f1814001011c339ba7ee1da876d9 /webui/src/bug/TimelineQuery.js
parent8575abf285d1dd71990b619fbdf3cd44dbc48e75 (diff)
downloadgit-bug-bb4ebed08c3f1b1a7ba9968ede75a07f1705d2df.tar.gz
webui: Format everything with prettier
Diffstat (limited to 'webui/src/bug/TimelineQuery.js')
-rw-r--r--webui/src/bug/TimelineQuery.js41
1 files changed, 23 insertions, 18 deletions
diff --git a/webui/src/bug/TimelineQuery.js b/webui/src/bug/TimelineQuery.js
index 3ee4cb28..78658a6f 100644
--- a/webui/src/bug/TimelineQuery.js
+++ b/webui/src/bug/TimelineQuery.js
@@ -1,12 +1,12 @@
-import CircularProgress from '@material-ui/core/CircularProgress'
-import gql from 'graphql-tag'
-import React from 'react'
-import { Query } from 'react-apollo'
-import LabelChange from './LabelChange'
-import SetStatus from './SetStatus'
-import SetTitle from './SetTitle'
-import Timeline from './Timeline'
-import Message from './Message'
+import CircularProgress from '@material-ui/core/CircularProgress';
+import gql from 'graphql-tag';
+import React from 'react';
+import { Query } from 'react-apollo';
+import LabelChange from './LabelChange';
+import SetStatus from './SetStatus';
+import SetTitle from './SetTitle';
+import Timeline from './Timeline';
+import Message from './Message';
const QUERY = gql`
query($id: String!, $first: Int = 10, $after: String) {
@@ -33,16 +33,21 @@ const QUERY = gql`
${LabelChange.fragment}
${SetTitle.fragment}
${SetStatus.fragment}
-`
+`;
-const TimelineQuery = ({id}) => (
- <Query query={QUERY} variables={{id, first: 100}}>
- {({loading, error, data, fetchMore}) => {
- if (loading) return <CircularProgress/>
- if (error) return <p>Error: {error}</p>
- return <Timeline ops={data.defaultRepository.bug.operations.nodes} fetchMore={fetchMore}/>
+const TimelineQuery = ({ id }) => (
+ <Query query={QUERY} variables={{ id, first: 100 }}>
+ {({ loading, error, data, fetchMore }) => {
+ if (loading) return <CircularProgress />;
+ if (error) return <p>Error: {error}</p>;
+ return (
+ <Timeline
+ ops={data.defaultRepository.bug.operations.nodes}
+ fetchMore={fetchMore}
+ />
+ );
}}
</Query>
-)
+);
-export default TimelineQuery
+export default TimelineQuery;