Skip to content

Commit

Permalink
fix(core): Fix the problem of onChange event catching exception
Browse files Browse the repository at this point in the history
  • Loading branch information
janryWang committed Apr 9, 2021
1 parent 1de27ea commit 8d6e1c2
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions packages/core/src/shared/internals.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ import { isArrayField, isGeneralField, isQuery, isVoidField } from './externals'
import { ReservedProperties } from './constants'

export const isHTMLInputEvent = (event: any, stopPropagation = true) => {
if (event?.target) {
if (event?.currentTarget) {
if (
event.target.tagName &&
event.target.tagName !== 'INPUT' &&
event.target.tagName !== 'TEXTAREA' &&
event.target.tagName !== 'SELECT'
event.currentTarget.tagName &&
event.currentTarget.tagName !== 'INPUT' &&
event.currentTarget.tagName !== 'TEXTAREA' &&
event.currentTarget.tagName !== 'SELECT'
) {
return false
}
Expand Down

0 comments on commit 8d6e1c2

Please sign in to comment.