Skip to content

Commit

Permalink
Export to Saturn static button (#48)
Browse files Browse the repository at this point in the history
FAB tooltips aren't implemented until Material v1
(mui/material-ui#2230 (comment))
so let's leave out tooltip for now.
  • Loading branch information
melissachang authored Mar 31, 2018
1 parent 61b2005 commit 0e8a82a
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
2 changes: 2 additions & 0 deletions ui/src/App.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import './App.css';
import { ApiClient, DatasetApi, FacetsApi } from 'data_explorer_service';
import DatasetResponse from "./api/src/model/DatasetResponse";
import ExportFab from "./components/ExportFab";
import FacetsGrid from "./components/FacetsGrid";
import Header from "./components/Header";

Expand Down Expand Up @@ -53,6 +54,7 @@ class App extends Component {
facets={this.state.facets}
totalCount={this.state.totalCount}
/>
<ExportFab></ExportFab>
</div>
</MuiThemeProvider>
);
Expand Down
8 changes: 8 additions & 0 deletions ui/src/components/ExportFab.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
.exportFab {
margin: 0px;
top: auto;
right: 20px;
bottom: 20px;
left: auto;
position: fixed;
}
18 changes: 18 additions & 0 deletions ui/src/components/ExportFab.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
/** Export to Saturn FAB */

import './ExportFab.css';

import FileCloudUpload from 'material-ui/svg-icons/file/cloud-upload';
import { FloatingActionButton } from "material-ui";
import React from 'react';
import {white} from 'material-ui/styles/colors';

function ExportFab(props) {
return (
<FloatingActionButton className="exportFab">
<FileCloudUpload color={white} />
</FloatingActionButton>
);
}

export default ExportFab;

0 comments on commit 0e8a82a

Please sign in to comment.