mirror of
https://github.com/ianstormtaylor/slate.git
synced 2025-02-20 15:14:38 +01:00
Do not process onInput events when selection is lost
Resolves an issue where `this.getPoint(anchorNode, anchorOffset)` throws an error if a key event is triggered although not in focus
This commit is contained in:
parent
d4eb53fd6f
commit
b201c6dc13
@ -418,6 +418,7 @@ class Content extends React.Component {
|
||||
onInput = (e) => {
|
||||
if (this.tmp.isRendering) return
|
||||
if (this.tmp.isComposing) return
|
||||
if (this.props.state.isBlurred) return
|
||||
if (isNonEditable(e)) return
|
||||
debug('onInput')
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user