Skip to content

Commit

Permalink
fix default Anchor param of context menu
Browse files Browse the repository at this point in the history
Signed-off-by: shuyaqian 717749594@qq.com
  • Loading branch information
shuyaqian committed Dec 15, 2021
1 parent c558358 commit c7f078b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/core/src/browser/context-menu-renderer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,12 @@ export namespace RenderContextMenuOptions {
let args: any[];
if (Array.isArray(menuPathOrOptions)) {
menuPath = menuPathOrOptions;
args = [anchor!];
args = [];
} else {
menuPath = menuPathOrOptions.menuPath;
anchor = menuPathOrOptions.anchor;
onHide = menuPathOrOptions.onHide;
args = menuPathOrOptions.args ? [...menuPathOrOptions.args, anchor] : [anchor];
args = menuPathOrOptions.args ? [...menuPathOrOptions.args] : [];
}
return {
menuPath,
Expand Down

0 comments on commit c7f078b

Please sign in to comment.