feat(input-number): add keyboard props #2592
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Types of changes
Background and context
举个例子,当我在商品表格编辑中,我需要输入数量,这时用到input-number组件,我想通过上下按键快速切换到上一行或者下一行的input-number用于快速输入完 整列的数量,但是目前的input-number存在默认上下键盘加减值的事件,导致了我无法实现自行上下按键事件
Solution
增加keyboard属性,当我keyboard设置为false时,上下按键的事件自行定义,不进行上下按键加减逻辑
当我keyboard设置为ture时,依旧保持上下加减逻辑
How is the change tested?
Changelog
Checklist:
npm run test
)feature
branch and othersshould be submitted to
main
branch)Other information