当前位置:网站首页>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
边栏推荐
- 使用ts-node报错
- 一个service层需要调用另两个service层获取数据,并组装成最后的数据,数据都是list,缓存如何设计?
- 785. 快速排序
- 【uniCloud】云对象的应用与提升
- 这个地图绘制工具太赞了,推荐~~
- Introduction to the Elastic Stack
- 初出茅庐的小李第113篇博客项目笔记之机智云智能浇花器实战(2)-基础Demo实现
- Guys, MySQL cdc source recycles replication slave and r in incremental process
- 软件测试基础理论知识—用例篇
- 从设备树(dtb格式数据)中解析出bootargs
猜你喜欢

Talking about hardware device computing storage and data interaction
![[Getting Started Tutorial] Rollup Module Packager Integration](/img/1d/c6f1afe894b326be6939a7e8783972.jpg)
[Getting Started Tutorial] Rollup Module Packager Integration

Flutter “Hello world“ 程代码
![[Search topic] After reading the inevitable BFS solution to the shortest path problem](/img/f8/fbe906106dc8f7f7a6bd54d2dc3bc1.png)
[Search topic] After reading the inevitable BFS solution to the shortest path problem

second uncle

IDEA修改注释字体

MYSQL query interception optimization analysis

软件测试周刊(第82期):其实所有纠结做选择的人心里早就有了答案,咨询只是想得到内心所倾向的选择。

Introduction to machine learning how to?

Flink deploys and submits jobs
随机推荐
How to download the Keil package
更换树莓派内核
JS new fun(); 类与实例 JS基于对象语言 只能通过书写构造函数充当类
这个地图绘制工具太赞了,推荐~~
[Getting Started Tutorial] Rollup Module Packager Integration
Summary of MVCC
Parse the bootargs from the device tree (dtb format data)
手写二叉查找树及测试
Compiled on unbutu with wiringPi library and run on Raspberry Pi
MYSQL Keyword Explain Analysis
Raspberry pie arm version of GCC installed configuration and environment variables
Browser download shortcut to desktop (PWA)
【uniCloud】云对象的应用与提升
初出茅庐的小李第114篇博客项目笔记之机智云智能浇花器实战(3)-基础Demo实现
IDEA修改注释字体
MYSQL Index Analysis
[SemiDrive source code analysis] series article link summary (full)
Unity在BuildIn渲染管线下实现PlanarReflection的初级方法
Simple vim configuration
Unknown Bounded Array