diff --git a/web/src/js/components/ContentView/ContentViewOptions.jsx b/web/src/js/components/ContentView/ContentViewOptions.jsx
index 6bc66db22..1ec9013e7 100644
--- a/web/src/js/components/ContentView/ContentViewOptions.jsx
+++ b/web/src/js/components/ContentView/ContentViewOptions.jsx
@@ -12,13 +12,13 @@ ContentViewOptions.propTypes = {
function ContentViewOptions({ flow, message, uploadContent, readonly, contentViewDescription }) {
return (
-
+ {readonly ? : View: edit}
{!readonly && }
- {contentViewDescription}
+ {readonly && {contentViewDescription}}
)
}
diff --git a/web/src/js/components/ContentView/ViewSelector.jsx b/web/src/js/components/ContentView/ViewSelector.jsx
index fcdc3ee34..43a539956 100644
--- a/web/src/js/components/ContentView/ViewSelector.jsx
+++ b/web/src/js/components/ContentView/ViewSelector.jsx
@@ -1,6 +1,5 @@
import React, { PropTypes, Component } from 'react'
import { connect } from 'react-redux'
-import * as ContentViews from './ContentViews'
import { setContentView } from '../../ducks/ui/flow';
import Dropdown from '../common/Dropdown'
@@ -8,27 +7,20 @@ import Dropdown from '../common/Dropdown'
ViewSelector.propTypes = {
contentViews: PropTypes.array.isRequired,
activeView: PropTypes.string.isRequired,
- isEdit: PropTypes.bool.isRequired,
setContentView: PropTypes.func.isRequired
}
-function ViewSelector ({contentViews, activeView, isEdit, setContentView}){
- let edit = ContentViews.Edit.displayName
- let inner = View: {activeView}
+function ViewSelector ({contentViews, activeView, setContentView}){
+ let inner = View: {activeView.toLowerCase()}
return (
{contentViews.map(name =>
- {e.preventDefault(); setContentView(name)}}>
+ {e.preventDefault(); setContentView(name)}}>
{name.toLowerCase().replace('_', ' ')}
)
}
- {isEdit &&
- {e.preventDefault(); setContentView(edit)}}>
- {edit.toLowerCase()}
-
- }
)
}
@@ -37,7 +29,6 @@ export default connect (
state => ({
contentViews: state.settings.contentViews,
activeView: state.ui.flow.contentView,
- isEdit: !!state.ui.flow.modifiedFlow,
}), {
setContentView,
}