Skip to content

Commit

Permalink
fix(input): value in clear event doesn't change after clear (#2231)
Browse files Browse the repository at this point in the history
  • Loading branch information
chaishi authored Jan 4, 2023
1 parent f783c3d commit 72ce2fe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/input/useInput.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,8 @@ export default function useInput(props: ExtendsTdInputProps, expose: (exposed: R
};

const emitClear = ({ e }: { e: MouseEvent }) => {
props.onClear?.({ e });
setInnerValue('', { e });
props.onClear?.({ e });
};

const onClearIconMousedown = (e: MouseEvent) => {
Expand Down

0 comments on commit 72ce2fe

Please sign in to comment.