context-menu: double click issue in submenus on small touch screens
This commit is contained in:
parent
2225a3f760
commit
d673cb1e3a
2 changed files with 6 additions and 0 deletions
|
|
@ -1,5 +1,10 @@
|
|||
# Changelog
|
||||
|
||||
## 1.14.2
|
||||
|
||||
- bug fixes
|
||||
- context-menu: double click issue in submenus on small touch screens
|
||||
|
||||
## 1.14.0, 1.14.1
|
||||
|
||||
- bug fixes
|
||||
|
|
|
|||
|
|
@ -50,6 +50,7 @@ class ContextMenu extends UiWidget {
|
|||
})
|
||||
|
||||
this.container.addEventListener('touchstart', (e)=>{
|
||||
if (e.target.classList.contains('has-sub')) e.preventDefault()
|
||||
if (!e.target.classList.contains('focus')) {
|
||||
DOM.each(e.target.parentNode, '.focus', (el)=>{
|
||||
el.classList.remove('focus')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue