diff --git a/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js b/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js index 678c3a6252ac3a7d04f981a130b1377002a66987..35298b373f626d0e19a9643ae5497a94a76605b8 100644 --- a/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js +++ b/app/components/SimpleEditor/elements/track_change/TrackChangesProvider.js @@ -805,8 +805,6 @@ class TrackChangesProvider extends TOCProvider { // TODO -- use substance's selection.collapse(direction) if (point === 'start') { - selection.start.offset -= 1 - selection.end.offset -= 1 selection.end.offset = selection.start.offset } else if (point === 'end') { selection.start.offset = selection.end.offset @@ -820,10 +818,13 @@ class TrackChangesProvider extends TOCProvider { setSelectionPlusOne (direction) { const selection = this.getSelection() + const surface = this.getSurface() if (direction === 'left') selection.start.offset -= 1 if (direction === 'right') selection.end.offset += 1 + surface.editorSession.setSelection(selection) + return selection }