Expands the current menu or focuses the next item in the menubar.
()
| 441 | |
| 442 | /** Expands the current menu or focuses the next item in the menubar. */ |
| 443 | expand() { |
| 444 | const root = this.root(); |
| 445 | const activeItem = this.inputs.activeItem(); |
| 446 | |
| 447 | if (activeItem?.submenu()) { |
| 448 | activeItem.open({first: true}); |
| 449 | } else if (root instanceof MenuBarPattern) { |
| 450 | root.next(); |
| 451 | } |
| 452 | } |
| 453 | |
| 454 | /** Closes the menu. */ |
| 455 | close() { |
no test coverage detected