react-component / react-component/select
能否去掉 onBlur 的默认行为: 添加 tag?
Open
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 938
- Forks
- 482
- Avg merge
- 15h 8m
- Merged PRs (30d)
- 2
Description
onBlur 的默认行为太多了, 自定义 dorpdown 基本无法使用
比如:
- toggleOpen(false) , 导致无法使用内嵌 modal
- clearSearchValue(''), 导致无法在自定义 DorndpwnRender内部修改去切换 mode, 因为tag 模式下, blur 会视为添加到 options, 导致切换到其他的 mode 会额外多出这个 option,切换一次多一次
@afc163
一个函数应该只做一件事情, 不要加太多自己的默认行为进去却不提供撤销方式
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the onBlur behavior and its calls to toggleOpen(false) and clearSearchValue(''), then inspect how custom dropdown rendering and tag mode interact. The issue is complete when custom dropdowns can avoid these default blur effects without adding unintended options or breaking existing behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100