Skip to content

Commit ff5943f

Browse files
webfilteredgithub-actions
andauthored
Reorder subgraph context menu items (#4870)
Co-authored-by: github-actions <[email protected]>
1 parent b1117b9 commit ff5943f

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

src/lib/litegraph/src/LGraphCanvas.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8235,14 +8235,16 @@ export class LGraphCanvas
82358235
'Both in put and output slots were null when processing context menu.'
82368236
)
82378237

8238+
if (!_slot.nameLocked && !('link' in _slot && _slot.widget)) {
8239+
menu_info.push({ content: 'Rename Slot', slot })
8240+
}
8241+
82388242
if (_slot.removable) {
8243+
menu_info.push(null)
82398244
menu_info.push(
82408245
_slot.locked ? 'Cannot remove' : { content: 'Remove Slot', slot }
82418246
)
82428247
}
8243-
if (!_slot.nameLocked && !('link' in _slot && _slot.widget)) {
8244-
menu_info.push({ content: 'Rename Slot', slot })
8245-
}
82468248

82478249
if (node.getExtraSlotMenuOptions) {
82488250
menu_info.push(...node.getExtraSlotMenuOptions(slot))

src/locales/zh/commands.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,4 +264,4 @@
264264
"label": "切换工作流侧边栏",
265265
"tooltip": "工作流"
266266
}
267-
}
267+
}

src/locales/zh/main.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1648,4 +1648,4 @@
16481648
"exportWorkflow": "导出工作流",
16491649
"saveWorkflow": "保存工作流"
16501650
}
1651-
}
1651+
}

0 commit comments

Comments
 (0)