fix(skill): pass root nodeId for blank-area context menu

The previous refactor inadvertently passed undefined nodeId for blank
area menus, causing root-level folder creation/upload to fail. This
restores the original behavior by explicitly passing 'root' when the
context menu type is 'blank'.
This commit is contained in:
yyh
2026-01-19 14:23:38 +08:00
parent 9aed4f830f
commit 0d5e971a0c

View File

@ -46,7 +46,7 @@ const TreeContextMenu: FC<TreeContextMenuProps> = ({ treeRef }) => {
>
<NodeMenu
type={getMenuType(contextMenu)}
nodeId={contextMenu.nodeId}
nodeId={contextMenu.type === 'blank' ? 'root' : contextMenu.nodeId}
onClose={handleClose}
treeRef={treeRef}
/>