diff --git a/editors/demo/src/Editors.js b/editors/demo/src/Editors.js index bc97804358c40e340cad44821b8e7de332789192..9e14f6ac6c5dfb292ff737394c05d66b8ce35c76 100644 --- a/editors/demo/src/Editors.js +++ b/editors/demo/src/Editors.js @@ -95,12 +95,12 @@ const Editors = () => { > Editoria </ProjectButton> - {/* <ProjectButton + <ProjectButton isActive={project === 'oen'} onClick={() => setProject('oen')} > OEN - </ProjectButton> */} + </ProjectButton> <ProjectButton isActive={project === 'ncbi'} onClick={() => setProject('ncbi')} diff --git a/wax-prosemirror-services/src/MatchingService/components/MatchingOptionComponent.js b/wax-prosemirror-services/src/MatchingService/components/MatchingOptionComponent.js index 7c9f90fdf3315905689212964a8bfc41f58ac9e3..9d1a46eb1d753f02e9253de5752ba1ee95c625a0 100644 --- a/wax-prosemirror-services/src/MatchingService/components/MatchingOptionComponent.js +++ b/wax-prosemirror-services/src/MatchingService/components/MatchingOptionComponent.js @@ -53,6 +53,7 @@ export default ({ node, view, getPos }) => { }); const readOnly = !isEditable; + const customProps = main.props.customValues; const addAnswer = () => { const nodeId = node.attrs.id; @@ -104,7 +105,13 @@ export default ({ node, view, getPos }) => { )} <EditorComponent getPos={getPos} node={node} view={view} /> <DropDownContainer> - <DropDownComponent getPos={getPos} node={node} view={view} /> + {readOnly && customProps && customProps.showFeedBack && ( + <span>Submit</span> + )} + {!readOnly && ( + <DropDownComponent getPos={getPos} node={node} view={view} /> + )} + {readOnly && !customProps.showFeedBack && <span> READ ONLY </span>} </DropDownContainer> </Option> );