Merge pull request #16863 from nextcloud/ignore-enter-key-up-event-on-menu-button-toggles
Ignore Enter key up event on menu button toggles
This commit is contained in:
commit
907a6b4860
8 changed files with 7 additions and 12 deletions
BIN
core/js/dist/login.js
vendored
BIN
core/js/dist/login.js
vendored
Binary file not shown.
BIN
core/js/dist/login.js.map
vendored
BIN
core/js/dist/login.js.map
vendored
Binary file not shown.
BIN
core/js/dist/main.js
vendored
BIN
core/js/dist/main.js
vendored
Binary file not shown.
BIN
core/js/dist/main.js.map
vendored
BIN
core/js/dist/main.js.map
vendored
Binary file not shown.
BIN
core/js/dist/maintenance.js
vendored
BIN
core/js/dist/maintenance.js
vendored
Binary file not shown.
BIN
core/js/dist/maintenance.js.map
vendored
BIN
core/js/dist/maintenance.js.map
vendored
Binary file not shown.
|
@ -39,9 +39,9 @@ let currentMenuToggle = null
|
|||
export const registerMenu = ($toggle, $menuEl, toggle, headerMenu) => {
|
||||
$menuEl.addClass('menu')
|
||||
|
||||
// On link, the enter key trigger a click event
|
||||
// On link and button, the enter key trigger a click event
|
||||
// Only use the click to avoid two fired events
|
||||
$toggle.on($toggle.prop('tagName') === 'A'
|
||||
$toggle.on(($toggle.prop('tagName') === 'A' || $toggle.prop('tagName') === 'BUTTON')
|
||||
? 'click.menu'
|
||||
: 'click.menu keyup.menu', function (event) {
|
||||
// prevent the link event (append anchor to URL)
|
||||
|
|
15
package-lock.json
generated
15
package-lock.json
generated
|
@ -2951,16 +2951,16 @@
|
|||
"integrity": "sha1-082BIh4+pAdCz83lVtTpnpjdxxs="
|
||||
},
|
||||
"dmd": {
|
||||
"version": "4.0.0",
|
||||
"resolved": "https://registry.npmjs.org/dmd/-/dmd-4.0.0.tgz",
|
||||
"integrity": "sha512-J+4CgbQiMuJHiU9dvTVN8iOOZGeR3bef1wBqz6eVvvX17jkpkKVd8TeeutA/FJAeFbLQfXnyQ3o4qY7W+c5cxQ==",
|
||||
"version": "4.0.1",
|
||||
"resolved": "https://registry.npmjs.org/dmd/-/dmd-4.0.1.tgz",
|
||||
"integrity": "sha512-lKBX/++DzfgasOfPogVej5R071dxAYQwYih7lXQMJfVESJTZieo2MQAqYlJyDyLPxkyLO3cvnwIFchOPgG5FVA==",
|
||||
"requires": {
|
||||
"array-back": "^3.1.0",
|
||||
"cache-point": "^0.4.1",
|
||||
"common-sequence": "^1.0.2",
|
||||
"file-set": "^2.0.0",
|
||||
"file-set": "^2.0.1",
|
||||
"handlebars": "^4.1.2",
|
||||
"marked": "^0.6.2",
|
||||
"marked": "^0.7.0",
|
||||
"object-get": "^2.1.0",
|
||||
"reduce-flatten": "^2.0.0",
|
||||
"reduce-unique": "^2.0.1",
|
||||
|
@ -2969,11 +2969,6 @@
|
|||
"walk-back": "^3.0.1"
|
||||
},
|
||||
"dependencies": {
|
||||
"marked": {
|
||||
"version": "0.6.3",
|
||||
"resolved": "https://registry.npmjs.org/marked/-/marked-0.6.3.tgz",
|
||||
"integrity": "sha512-Fqa7eq+UaxfMriqzYLayfqAE40WN03jf+zHjT18/uXNuzjq3TY0XTbrAoPeqSJrAmPz11VuUA+kBPYOhHt9oOQ=="
|
||||
},
|
||||
"reduce-flatten": {
|
||||
"version": "2.0.0",
|
||||
"resolved": "https://registry.npmjs.org/reduce-flatten/-/reduce-flatten-2.0.0.tgz",
|
||||
|
|
Loading…
Reference in a new issue