refactor: detected editor component for super note type

This commit is contained in:
Aman Harwara
2023-01-17 18:55:34 +05:30
parent 4c623489f9
commit 32f5a45e2f

View File

@@ -598,12 +598,12 @@ export class SNComponentManager
}
editorForNote(note: SNNote): SNComponent | undefined {
if (note.editorIdentifier) {
return this.componentWithIdentifier(note.editorIdentifier)
if (note.noteType === NoteType.Plain || note.noteType === NoteType.Super) {
return undefined
}
if (note.noteType === NoteType.Plain) {
return undefined
if (note.editorIdentifier) {
return this.componentWithIdentifier(note.editorIdentifier)
}
return this.legacyGetEditorForNote(note)