Skip to content

Commit

Permalink
Move the blur event to the internal input.
Browse files Browse the repository at this point in the history
  • Loading branch information
Reinmar committed May 11, 2020
1 parent 4393cfb commit 9abb619
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions packages/ckeditor5-table/src/ui/colorinputview.js
Original file line number Diff line number Diff line change
Expand Up @@ -206,9 +206,10 @@ export default class ColorInputView extends View {
_createInputTextView() {
const locale = this.locale;
const inputView = new InputTextView( locale );

inputView.extendTemplate( {
on: {
blur: this.bindTemplate.to( 'blur' )
blur: inputView.bindTemplate.to( 'blur' )
}
} );

Expand All @@ -224,7 +225,8 @@ export default class ColorInputView extends View {
this._stillTyping = true;
this.value = mappedColor && mappedColor.color || inputValue;
} );
this.on( 'blur', () => {

inputView.on( 'blur', () => {
this._stillTyping = false;
this._setInputValue( inputView.element.value );
} );
Expand Down

0 comments on commit 9abb619

Please sign in to comment.