Skip to content

Commit 901c891

Browse files
fix: 修复TagsView右键菜单逻辑错误
1 parent 8794696 commit 901c891

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/components/TagsView/src/TagsView.vue

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -210,13 +210,14 @@ const isActive = (route: RouteLocationNormalizedLoaded): boolean => {
210210
// 所有右键菜单组件的元素
211211
const itemRefs = useTemplateRefsList<ComponentRef<typeof ContextMenu & ContextMenuExpose>>()
212212
213-
// 右键菜单装填改变的时候
213+
// 右键菜单状态改变的时候
214214
const visibleChange = (visible: boolean, tagItem: RouteLocationNormalizedLoaded) => {
215215
if (visible) {
216216
for (const v of unref(itemRefs)) {
217217
const elDropdownMenuRef = v.elDropdownMenuRef
218218
if (tagItem.fullPath !== v.tagItem.fullPath) {
219219
elDropdownMenuRef?.handleClose()
220+
setSelectTag(tagItem)
220221
}
221222
}
222223
}

0 commit comments

Comments
 (0)