This repository was archived by the owner on Oct 11, 2022. It is now read-only.
Commit a4ef4ec
committed
Fix deleting styled blocks
When the first thing in an editor is an styled block you cannot get rid
of it, it'll always stay styled, because backspace only deletes the
content.
This patch fixes the issue by introducing custom behaviour for this
specific condition: If we're in the first block of the editor, it's a
styled block, the block is empty and we press backspace we change the
block type to 'unstyled'.
Fixes ngs#311 parent 3cf7df5 commit a4ef4ec
1 file changed
+29
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
157 | 157 | | |
158 | 158 | | |
159 | 159 | | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
160 | 189 | | |
161 | 190 | | |
162 | 191 | | |
| |||
0 commit comments