Skip to content
Snippets Groups Projects
Commit 0e852bb2 authored by chris's avatar chris Committed by john
Browse files

When eidtor in read only mode you can only add comments in notesEditor

parent ab294955
No related branches found
No related tags found
No related merge requests found
......@@ -9,13 +9,15 @@ class IsolatedNoteComponent extends IsolatedNodeComponent {
// is there a better way than rendering a text property editor???
// review ref name
// do we need a ref ??
const editing = (this.context.editor.props.disabled) ? 'selection' : 'full'
let el = $$('div')
.addClass('sc-entity')
.attr('data-id', this.props.node.id)
.append(
$$(TextPropertyEditor, {
disabled: this.context.editor.props.disabled,
multiLine: false,
editing: editing,
path: [this.props.node.id, 'content'],
tagName: 'p'
}
......
......@@ -67,7 +67,7 @@ class NotesEditor extends ProseEditor {
_renderEditor ($$) {
const hasIsolatedNotes = this.getIsolatedNodes()
const disabled = (isEmpty(hasIsolatedNotes)) ? true : this.props.disabled
const disabled = (isEmpty(hasIsolatedNotes))
return $$(ContainerEditor, {
book: this.props.book,
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment