ianstormtaylor / slate

A completely customizable framework for building rich text editors. (Currently in beta.)
http://slatejs.org
MIT License
29.97k stars 3.25k forks source link

transform deleteBackward is not deleting enough #326

Closed massanishi closed 8 years ago

massanishi commented 8 years ago

Hi, I was looking for a way to implement cmd and alt delete. This improvement thread says the feature is implemented already.

But running the http://slatejs.org example, the cmd/alt delete pushes the cursor back as expected, but it only deletes the first character. Diving more into the core plugin, word/char offset count is returning the right number, but it looks like state.transform().deleteBackward(n).apply() is not behaving properly. Any thought?

ianstormtaylor commented 8 years ago

It looks like this is a regression from 0.14, thanks for reporting this!