Skip to content

Commit

Permalink
create Editor page
Browse files Browse the repository at this point in the history
  • Loading branch information
caspg committed Nov 29, 2017
1 parent 801c0f1 commit 2ba2532
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 6 deletions.
1 change: 1 addition & 0 deletions pages/editor.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default } from '../src/pages/Editor';
13 changes: 7 additions & 6 deletions src/containers/editor/HeaderContainer.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { connect } from 'react-redux'
import { push } from 'react-router-redux'

import { setMapType } from 'redux/actions'
import EditorHeader from 'components/editor/EditorHeader'
// import EditorHeader from 'components/editor/EditorHeader'

class HeaderContainer extends Component {
constructor(props) {
Expand All @@ -23,11 +23,12 @@ class HeaderContainer extends Component {

render() {
return (
<EditorHeader
currentPath={this.props.currentPath}
mapType={this.props.mapType}
onMapTypeChange={this.handleMapTypeChange}
/>
// <EditorHeader
// currentPath={this.props.currentPath}
// mapType={this.props.mapType}
// onMapTypeChange={this.handleMapTypeChange}
// />
null
)
}
}
Expand Down
29 changes: 29 additions & 0 deletions src/pages/Editor/Editor.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import React, { PropTypes } from 'react';

import routes from '@src/config/routes'
import metaTags from '@src/config/meta'
import AppHead from '@src/components/AppHead';
import GlobalStyles from '@src/components/GlobalStyles';
import HeaderContainer from '@src/containers/editor/HeaderContainer'

Editor.propTypes = {
url: PropTypes.shape({
pathname: PropTypes.string.isRequired,
}).isRequired,
}

function Editor(props) {
return (
<div>
<AppHead title={metaTags.titles.editor} />
<GlobalStyles />

<HeaderContainer
mainPath={routes.editor}
currentPath={props.url.pathname}
/>
</div>
);
}

export default Editor;
1 change: 1 addition & 0 deletions src/pages/Editor/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default } from './Editor';

0 comments on commit 2ba2532

Please sign in to comment.