I'm building a template editor with lexical that uses custom decorator nodes to represent template fields (placeholders) following this example.
When changing the selection using the arrow keys, the selection gets stuck at the decorators. For example, when the cursor is just before a decorator (as in the image above) and I press Arrow Right, the RangeSelection
changes into a NodeSelection
for the decorator node. From that point, pressing arrow keys does not change the selection anymore.
Is is possible to configure decorator nodes so that they are skipped, i.e. the selection changes from the location before to the location after the decorator?
I'm using [email protected]
.