When editing a value in column 'A (Required)', you will see that it does not allow you to leave it empty. If you leave it empty and return the edit, it will be cancelled.
The key to achieving this behaviour is the isCancelAfterEdit function which allows you to cancel an edit in a custom cell editor:
RequiredCellEditor.prototype.isCancelAfterEnd = function() {
let value =this.getValue();
if(isEmpty(value)){
return true;
}
return false;
}
Please see the following example for further implementation details:
Comments
0 comments
Please sign in to leave a comment.