diff --git a/src/components/calculation/index.js b/src/components/calculation/index.js index 5e0e1b1..20c865f 100644 --- a/src/components/calculation/index.js +++ b/src/components/calculation/index.js @@ -123,10 +123,10 @@ class Calculation extends Component { moleculeProperties.push({label: 'Mass', value: molecule.properties.mass.toFixed(2)}); } if (has(molecule, 'inchi')) { - moleculeProperties.push({label: 'Inchi', value: molecule.inchi}); + moleculeProperties.push({label: 'InChi', value: molecule.inchi}); } if (has(molecule, 'smiles')) { - moleculeProperties.push({label: 'Smiles', value: molecule.smiles}); + moleculeProperties.push({label: 'SMILES', value: molecule.smiles}); } const moleculeSection = { diff --git a/src/components/calculations.js b/src/components/calculations.js index efcfcb3..315f701 100644 --- a/src/components/calculations.js +++ b/src/components/calculations.js @@ -1,7 +1,7 @@ import React, { Component } from 'react'; import PropTypes from 'prop-types'; -import { has } from 'lodash-es'; +import { has, filter, eq } from 'lodash-es'; import { withStyles } from '@material-ui/core'; import Grid from '@material-ui/core/Grid'; import Typography from '@material-ui/core/Typography'; @@ -52,7 +52,10 @@ class Calculations extends Component { const title = this.getName(calculation); const image = `${window.location.origin}/api/v1/molecules/${calculation.moleculeId}/svg`; const pending = has(calculation, 'properties.pending'); - const properties = getCalculationProperties(calculation); + let properties = getCalculationProperties(calculation); + properties = filter(properties, function(obj) { + return !eq(obj.label, 'Version'); + }); return ( diff --git a/src/components/molecule.js b/src/components/molecule.js index 31fb75a..3272788 100644 --- a/src/components/molecule.js +++ b/src/components/molecule.js @@ -90,10 +90,10 @@ class Molecule extends Component { moleculeProperties.push({label: 'Mass', value: molecule.properties.mass.toFixed(2)}); } if (has(molecule, 'inchi')) { - moleculeProperties.push({label: 'Inchi', value: molecule.inchi}); + moleculeProperties.push({label: 'InChi', value: molecule.inchi}); } if (has(molecule, 'smiles')) { - moleculeProperties.push({label: 'Smiles', value: molecule.smiles}); + moleculeProperties.push({label: 'SMILES', value: molecule.smiles}); } const moleculeSection = { diff --git a/src/components/notebook.js b/src/components/notebook.js index 7c91644..b549be8 100644 --- a/src/components/notebook.js +++ b/src/components/notebook.js @@ -2,15 +2,30 @@ import React, { Component } from 'react'; import PropTypes from 'prop-types'; import Iframe from 'react-iframe' -import Typography from '@material-ui/core/Typography'; +import { Typography, withStyles } from '@material-ui/core'; import PageHead from './page-head'; import PageBody from './page-body'; -export default class Notebook extends Component { +const styles = () => ({ + iframe: { + border: 0, + left: 0, + position: 'absolute', + top: 0, + width:'100%', + height:'100%' + }, + container: { + overflow: 'hidden', + position: 'relative', + paddingTop: '100%' + } +}); +class Notebook extends Component { render = () => { - const {fileId} = this.props; + const { fileId, classes } = this.props; const baseUrl = `${window.location.origin}/api/v1`; return (
@@ -20,10 +35,10 @@ export default class Notebook extends Component { -