mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2025-01-30 12:52:43 +08:00
refactor(radio): handleMouseDown focus logic
This commit is contained in:
parent
f5056c2643
commit
5c3b6e01db
@ -1,7 +1,7 @@
|
||||
# CHANGELOG
|
||||
## PENDING
|
||||
### Refactors
|
||||
- Refactor `n-tag` styles
|
||||
- Refactor `n-tag` styles.
|
||||
- Fix the problem that `n-data-table`'s `max-height` style is broken. https://bugs.chromium.org/p/chromium/issues/detail?id=1107223
|
||||
|
||||
## 1.5.1 (2020-07-20)
|
||||
|
@ -6,7 +6,7 @@
|
||||
|
||||
## 1.5.1 (2020-07-20)
|
||||
### Features
|
||||
- 为 `n-time-picker` 增加了 `disabled` 属性.
|
||||
- 为 `n-time-picker` 增加了 `disabled` 属性
|
||||
### Fixes
|
||||
- 修正了 `n-radio`下的子元素无法获取焦点的问题
|
||||
|
||||
|
@ -75,10 +75,13 @@ export default {
|
||||
handleKeyUpEnter () {
|
||||
this.toggle()
|
||||
},
|
||||
handleMouseDown (e) {
|
||||
handleMouseDown () {
|
||||
if (this.syntheticDisabled) return
|
||||
// e.preventDefault()
|
||||
this.$refs.input.focus()
|
||||
setTimeout(() => {
|
||||
if (!this.$el.contains(document.activeElement)) {
|
||||
this.$refs.input.focus()
|
||||
}
|
||||
}, 0)
|
||||
},
|
||||
handleClick (e) {
|
||||
this.$emit('click', e)
|
||||
|
Loading…
Reference in New Issue
Block a user