Skip to content
This repository has been archived by the owner on Jun 26, 2020. It is now read-only.

Commit

Permalink
Merge pull request #41 from ckeditor/i/353
Browse files Browse the repository at this point in the history
Fix: Focus the editor before executing toolbar buttons' command. See ckeditor/ckeditor5#353.
  • Loading branch information
Reinmar authored Jan 28, 2020
2 parents b6902d5 + 42daadd commit 4223ff2
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/blockquoteui.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,10 @@ export default class BlockQuoteUI extends Plugin {
buttonView.bind( 'isOn', 'isEnabled' ).to( command, 'value', 'isEnabled' );

// Execute command.
this.listenTo( buttonView, 'execute', () => editor.execute( 'blockQuote' ) );
this.listenTo( buttonView, 'execute', () => {
editor.execute( 'blockQuote' );
editor.editing.view.focus();
} );

return buttonView;
} );
Expand Down

0 comments on commit 4223ff2

Please sign in to comment.