Skip to content

Commit cf86f11

Browse files
committed
pushing up mui branch to be pulled
1 parent 9638fd3 commit cf86f11

File tree

4 files changed

+37
-21
lines changed

4 files changed

+37
-21
lines changed

src/app/components/StateRoute/PerformanceVisx/BarGraphComparison.tsx

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -152,9 +152,6 @@ const BarGraphComparison = (props: BarGraphComparisonProps): JSX.Element => {
152152
minWidth: 80,
153153
fontSize: '.75rem',
154154
fontWeight: 200,
155-
// border: '1px solid grey',
156-
// borderRadius: 4,
157-
// color: 'grey',
158155
height: 30,
159156
});
160157

@@ -237,7 +234,7 @@ const BarGraphComparison = (props: BarGraphComparisonProps): JSX.Element => {
237234
<div className='dropdown-and-delete-series-container'>
238235
<Button
239236
variant='contained'
240-
sx={{ p: 1 }}
237+
sx={{ p: 2, color: 'white' }}
241238
// type='button'
242239
className='delete-button'
243240
onClick={() => {
@@ -251,7 +248,7 @@ const BarGraphComparison = (props: BarGraphComparisonProps): JSX.Element => {
251248
style={
252249
buttonLoad
253250
? { backgroundColor: theme.palette.primary.main }
254-
: { backgroundColor: '#f21861' }
251+
: { backgroundColor: theme.palette.secondary.main }
255252
}
256253
>
257254
{buttonLoad ? 'Deleted' : 'Clear Series'}
@@ -265,7 +262,7 @@ const BarGraphComparison = (props: BarGraphComparisonProps): JSX.Element => {
265262
sx={{ backgroundColor: theme.palette.primary.main }}
266263
>
267264
<StyledSelect
268-
style={{ color: 'white' }}
265+
style={{ color: 'red' }}
269266
labelId='simple-select-outlined-label'
270267
open={open}
271268
onClose={handleClose}

src/app/components/Tutorial.tsx

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
99
import { faQuestion } from '@fortawesome/free-solid-svg-icons';
1010
import { tutorialSaveSeriesToggle, setCurrentTabInApp } from '../actions/actions';
1111
import { TutorialProps, TutorialState, StepsObj } from '../FrontendTypes';
12-
12+
import { Button } from '@mui/material';
1313
//Must be required in. This enables compatibility with TS. If imported in, throws ts error of not rendering steps as a class component correctly.
1414
const { Steps } = require('intro.js-react');
1515

@@ -74,7 +74,6 @@ export default class Tutorial extends Component<TutorialProps, TutorialState> {
7474
this.setState({ stepsEnabled: true });
7575
};
7676

77-
7877
let steps: StepsObj[] = [];
7978

8079
switch (currentTabInApp) {
@@ -350,9 +349,14 @@ export default class Tutorial extends Component<TutorialProps, TutorialState> {
350349
onBeforeChange={(currentStepIndex) => onChangeHandler(currentStepIndex)}
351350
ref={(steps) => (this.steps = steps)}
352351
/>
353-
<button className='howToUse-button' type='button' onClick={() => startIntro()}>
352+
<Button
353+
variant='outlined'
354+
className='howToUse-button'
355+
type='button'
356+
onClick={() => startIntro()}
357+
>
354358
<FontAwesomeIcon icon={faQuestion} /> Tutorial
355-
</button>
359+
</Button>
356360
</>
357361
);
358362
}

src/app/components/theme.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,10 @@ import { createTheme } from '@mui/material/styles';
22
const theme = createTheme({
33
palette: {
44
primary: {
5-
main: '#556cd4',
5+
main: '#8Fb5f9',
66
},
77
secondary: {
8-
main: '#32a852',
8+
main: '#BF6DD2',
99
},
1010
},
1111
components: {

src/app/containers/ButtonsContainer.tsx

Lines changed: 24 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,13 @@ import {
1010
} from '@fortawesome/free-solid-svg-icons';
1111
import { importSnapshots, toggleMode } from '../actions/actions';
1212
import { useStoreContext } from '../store';
13+
import { Button } from '@mui/material';
1314

1415
import Tutorial from '../components/Tutorial';
16+
import LockIcon from '@mui/icons-material/Lock';
17+
import LockOpenIcon from '@mui/icons-material/LockOpen';
18+
import FileDownloadIcon from '@mui/icons-material/FileDownload';
19+
import FileUploadIcon from '@mui/icons-material/FileUpload';
1520

1621
// function exportHandler takes in a parameter snapshots which is typed as an array
1722
// the function does not return anything so the type is void
@@ -87,18 +92,28 @@ function ButtonsContainer(): JSX.Element {
8792

8893
return (
8994
<div className='buttons-container'>
90-
<button className='pause-button' type='button' onClick={() => dispatch(toggleMode('paused'))}>
91-
{paused ? <FontAwesomeIcon icon={faLock} /> : <FontAwesomeIcon icon={faUnlock} />}
95+
<Button
96+
variant='outlined'
97+
className='pause-button'
98+
type='button'
99+
onClick={() => dispatch(toggleMode('paused'))}
100+
>
101+
{paused ? <LockIcon /> : <LockOpenIcon />}
92102
{paused ? 'Locked' : 'Unlocked'}
93-
</button>
94-
<button className='export-button' type='button' onClick={() => exportHandler(snapshots)}>
95-
<FontAwesomeIcon icon={faDownload} />
103+
</Button>
104+
<Button
105+
variant='outlined'
106+
className='export-button'
107+
type='button'
108+
onClick={() => exportHandler(snapshots)}
109+
>
110+
<FileDownloadIcon />
96111
Download
97-
</button>
98-
<button className='import-button' type='button' onClick={() => importHandler(dispatch)}>
99-
<FontAwesomeIcon icon={faUpload} />
112+
</Button>
113+
<Button variant='outlined' className='import-button' onClick={() => importHandler(dispatch)}>
114+
<FileUploadIcon />
100115
Upload
101-
</button>
116+
</Button>
102117
{/* The component below renders a button for the tutorial walkthrough of Reactime */}
103118
<Tutorial dispatch={dispatch} currentTabInApp={currentTabInApp} />
104119
</div>

0 commit comments

Comments
 (0)