Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Prevent long press of enter #1053

Merged
merged 12 commits into from
Jul 19, 2024
Prev Previous commit
Next Next commit
feat: 判断方式
  • Loading branch information
crazyair committed Jul 18, 2024
commit c02404620791a23544656fb919223e4d6f9870f9
2 changes: 1 addition & 1 deletion src/BaseSelect/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -529,7 +529,7 @@ const BaseSelect = React.forwardRef<BaseSelectRef, BaseSelectProps>((props, ref)
}
}

if (mergedOpen && !keyLockRef.current) {
if (mergedOpen && key === 'Enter' ? !keyLockRef.current : true) {
listRef.current?.onKeyDown(event, ...rest);
}

Expand Down
Loading