11// @flow
2- import map from 'lodash/map' ;
3- import React , { PureComponent } from 'react' ;
42import { Card , CardHeader , CardActions } from 'material-ui/Card' ;
5- import Chip from 'material-ui/Chip ' ;
3+ import { green800 , redA700 } from 'material-ui/styles/colors ' ;
64import Avatar from 'material-ui/Avatar' ;
7- import OpenFolderIcon from 'material-ui/svg-icons/file/folder-open' ;
8- import TermIcon from 'material-ui/svg-icons/action/code' ;
9- import stripAnsi from 'strip-ansi' ;
5+ import Chip from 'material-ui/Chip' ;
106import DoneIcon from 'material-ui/svg-icons/action/done' ;
117import ErrorIcon from 'material-ui/svg-icons/alert/error' ;
12- import { green800 , redA700 } from 'material-ui/styles/colors' ;
8+ import map from 'lodash/map' ;
9+ import OpenFolderIcon from 'material-ui/svg-icons/file/folder-open' ;
10+ import React , { PureComponent } from 'react' ;
11+ import stripAnsi from 'strip-ansi' ;
12+ import TermIcon from 'material-ui/svg-icons/action/code' ;
1313
14+ import { consoleStyle } from '../../styles/main' ;
1415import exec from '../../lib/exec' ;
1516import Row from '../FlexBox/Row' ;
1617
@@ -96,7 +97,7 @@ class Terminal extends PureComponent<$TerminalProps, $TerminalState> {
9697 { this . props . cwd }
9798 </ Chip >
9899 </ Row >
99- < div style = { styles . console } id = "terminal" >
100+ < div style = { consoleStyle } id = "terminal" >
100101 { map ( this . state . output , ( output , index ) => {
101102 const lines = stripAnsi ( output . message ) . split ( '\n' ) ;
102103 return (
@@ -113,16 +114,3 @@ class Terminal extends PureComponent<$TerminalProps, $TerminalState> {
113114}
114115
115116export default Terminal ;
116-
117- const styles = {
118- console : {
119- backgroundColor : '#000' ,
120- borderRadius : 8 ,
121- boxShadow : '1px 1px 2px 2px rgba(0, 0, 0, 0.25)' ,
122- color : '#fff' ,
123- marginTop : 12 ,
124- maxHeight : 300 ,
125- overflow : 'auto' ,
126- padding : 10 ,
127- } ,
128- } ;
0 commit comments