当前位置:网站首页>Input input box cursor automatically jumps to the last bug after the previous input
Input input box cursor automatically jumps to the last bug after the previous input
2022-08-01 03:18:00 【Standing on the 28th floor listening to the wind】
Component library: tea-component
Technical framework: umi, react, react-hook-form
Today's bug, the cursor of the input box automatically jumps to the back after inputting at the front
Before typing
After input
When the triggering event is different, the other conditions are the same
// onChange will cause this bug {handleChangeCache(v, 'name', true);}}maxLength={30}disabled={cacheEventInfo?.isDistabled}autoComplete="off"placeholder={intl('name')}/>// onInput will not have this bug {handleChangeCache((v?.target as any)?.value, 'name', true);}}maxLength={30}disabled={cacheEventInfo?.isDistabled}autoComplete="off"placeholder={intl('name')}/>
The reason for this bug is guessed that the tea-component component encapsulates the onChange component once, but does not encapsulate the onInput component.
The specific reasons are welcome to give pointers
Solution: Change the onChange event to onInput
边栏推荐
- 剑指offer专项突击版第16天
- 【uniCloud】云对象的应用与提升
- 每周小结(*67):为什么不敢发表观点
- Compiled on unbutu with wiringPi library and run on Raspberry Pi
- You need to know the TCP wave four times
- Nmap manuals - the full version
- Dart named parameter syntax
- Completely closed Chrome updated and in the top right corner of the tip
- win10 fixed local IP
- [cellular automata] based on matlab interface aggregation cellular automata simulation [including Matlab source code 2004]
猜你喜欢
被 CSDN,伤透了心
The bigger and bigger the project is, I split it like this
Browser download shortcut to desktop (PWA)
更换树莓派内核
IDEA 找不到或无法加载主类 或 Module “*“ must not contain source root “*“ The root already belongs to module “*“
JS new fun(); 类与实例 JS基于对象语言 只能通过书写构造函数充当类
Which interpolation is better for opencv to zoom in and out??
MYSQL two-phase commit
[uniCloud] Application and Improvement of Cloud Objects
Summary of MVCC
随机推荐
彻底关闭Chrome浏览器更新及右上角的更新提示
Summary of mobile page optimization in seconds
预言机简介
When opening a MYSQL table, some can display editing, some do not, how to set.
Replacing the Raspberry Pi Kernel
Google Earth Engine - Error resolution of Error: Image.clipToBoundsAndScale, argument 'input': Invalid type
【分层强化学习】HIRO:Data-Efficient Hierarchical Reinforcement Learning
MySQL修改SQL语句优化性能
pdb drug comprehensive database
The 16th day of the special assault version of the sword offer
设备树——dtb格式到struct device node结构体的转换
MYSQL-Batch insert data
Simple vim configuration
链式编程、包、访问权限
HIRO: Hierarchical Reinforcement Learning 】 【 Data - Efficient Hierarchical Reinforcement Learning
被 CSDN,伤透了心
一个service层需要调用另两个service层获取数据,并组装成最后的数据,数据都是list,缓存如何设计?
Nmap manuals - the full version
移动端页面秒开优化总结
手写二叉查找树及测试