Cursor appears in the wrong position in Chrome 98

Hey @marijn thanks for the suggestion. I ended up getting around this in a similar way but using Decorations as a ‘cursor target’.

This a basic outline of the steps:

  • Check if the position is directly between two inline nodes
  • If so, create an editable widget decoration either side of the cursor (content editable spans with zero-width spaces)
  • If not, remove the decorations
  • Check beforeInput events to prevent any content being added to the decorations

Cursor displays in the correct position in Chrome and is visible in Firefox :slight_smile: