mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 18:55:26 +00:00
fix(menu) isPath: menu does not open when the root is empty (#108)
This commit is contained in:
parent
73a5d22041
commit
79c171655b
1 changed files with 5 additions and 1 deletions
|
|
@ -192,7 +192,11 @@ function MenuProto(position) {
|
|||
}
|
||||
|
||||
function isPath(x, y) {
|
||||
const panel = Info.panel;
|
||||
const {panel} = Info;
|
||||
const isEmptyRoot = !panel;
|
||||
|
||||
if (isEmptyRoot)
|
||||
return false;
|
||||
|
||||
const el = document.elementFromPoint(x, y);
|
||||
const elements = panel.querySelectorAll('[data-name="js-path"] *');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue