File tree 1 file changed +2
-13
lines changed
1 file changed +2
-13
lines changed Original file line number Diff line number Diff line change @@ -188,7 +188,7 @@ export default class CodeTool implements BlockTool {
188
188
this . _data = data ;
189
189
190
190
if ( this . nodes . textarea ) {
191
- this . nodes . textarea . textContent = data . code ;
191
+ this . nodes . textarea . value = data . code ;
192
192
}
193
193
}
194
194
@@ -299,7 +299,7 @@ export default class CodeTool implements BlockTool {
299
299
300
300
wrapper . classList . add ( this . CSS . baseClass , this . CSS . wrapper ) ;
301
301
textarea . classList . add ( this . CSS . textarea , this . CSS . input ) ;
302
- textarea . textContent = this . data . code ;
302
+ textarea . value = this . data . code ;
303
303
304
304
textarea . placeholder = this . placeholder ;
305
305
@@ -317,17 +317,6 @@ export default class CodeTool implements BlockTool {
317
317
case 'Tab' :
318
318
this . tabHandler ( event ) ;
319
319
break ;
320
- case 'Backspace' :
321
- if ( textarea . value . length > 0 ) {
322
- event . stopPropagation ( ) ;
323
- }
324
- break ;
325
- case 'ArrowUp' :
326
- case 'ArrowDown' :
327
- case 'ArrowLeft' :
328
- case 'ArrowRight' :
329
- event . stopPropagation ( ) ;
330
- break ;
331
320
}
332
321
} ) ;
333
322
You can’t perform that action at this time.
0 commit comments