diff --git a/embark-ui/.eslintrc b/embark-ui/.eslintrc new file mode 100644 index 00000000..19845d60 --- /dev/null +++ b/embark-ui/.eslintrc @@ -0,0 +1,6 @@ +{ + "extends": "react-app", + "rules": { + "react/prop-types": "warn" + } +} \ No newline at end of file diff --git a/embark-ui/package.json b/embark-ui/package.json index fe3d479e..eec21bdd 100644 --- a/embark-ui/package.json +++ b/embark-ui/package.json @@ -123,8 +123,5 @@ "presets": [ "react-app" ] - }, - "eslintConfig": { - "extends": "react-app" } } diff --git a/embark-ui/src/components/SearchBar.js b/embark-ui/src/components/SearchBar.js index 6cb540ee..9167ef2a 100644 --- a/embark-ui/src/components/SearchBar.js +++ b/embark-ui/src/components/SearchBar.js @@ -44,7 +44,7 @@ class SearchBar extends React.Component { render() { return ( -
+ {!this.props.loading &&
diff --git a/embark-ui/src/components/TextEditor.js b/embark-ui/src/components/TextEditor.js index 9dc01e22..0835adc7 100644 --- a/embark-ui/src/components/TextEditor.js +++ b/embark-ui/src/components/TextEditor.js @@ -4,7 +4,7 @@ import PropTypes from 'prop-types'; import FontAwesomeIcon from 'react-fontawesome'; import classNames from 'classnames'; -import {DARK_THEME} from '../constants'; +import {DARK_THEME, LIGHT_THEME} from '../constants'; import './TextEditor.css'; const SUPPORTED_LANGUAGES = ['css', 'sol', 'html', 'json']; @@ -120,8 +120,8 @@ class TextEditor extends React.Component { } componentDidUpdate(prevProps) { - if (this.props.currentFile.content && this.props.currentFile.content !== prevProps.currentFile.content) { - editor.setValue(this.props.currentFile.content); + if (this.props.currentFile.content !== prevProps.currentFile.content) { + editor.setValue(this.props.currentFile.content || ''); } this.updateMarkers(); @@ -137,18 +137,20 @@ class TextEditor extends React.Component { renderTabs() { return ( -
    + diff --git a/embark-ui/src/index.css b/embark-ui/src/index.css index f35702e8..7ac8a40a 100644 --- a/embark-ui/src/index.css +++ b/embark-ui/src/index.css @@ -21,9 +21,6 @@ .relative { position: relative; } -.hidden { - display: none; -} .react-json-view { border-radius: .25rem; @@ -77,3 +74,6 @@ text-decoration: none; } +.bg-black { + background-color: #1C1C1C; +} \ No newline at end of file diff --git a/package.json b/package.json index 70725392..0913f3f8 100644 --- a/package.json +++ b/package.json @@ -27,7 +27,7 @@ }, "main": "./lib/index.js", "scripts": { - "lint": "eslint bin/embark lib/", + "lint": "eslint bin/embark lib/ embark-ui/src", "prepack": "cd embark-ui && npm install && npm run build", "test": "npm-run-all lint test:*", "test:embark": "mocha test/ --no-timeouts --exit",