perf: optimized keyboard support for context menus

This commit is contained in:
tiny-craft 2023-10-22 18:04:17 +08:00
parent c4e4ed7e79
commit 92ffd6c605
3 changed files with 1 additions and 4 deletions

View File

@ -690,7 +690,6 @@ const handleOutsideContextMenu = () => {
@update:selected-keys="onUpdateSelectedKeys"
@update:expanded-keys="onUpdateExpanded" />
<n-dropdown
:animated="false"
:options="contextMenuParam.options"
:render-label="renderContextLabel"
:show="contextMenuParam.show"

View File

@ -530,10 +530,10 @@ const onCancelOpen = () => {
<!-- context menu -->
<n-dropdown
:animated="false"
:options="contextMenuParam.options"
:render-label="renderContextLabel"
:show="contextMenuParam.show"
:keyboard="true"
:x="contextMenuParam.x"
:y="contextMenuParam.y"
placement="bottom-start"

View File

@ -125,8 +125,6 @@ const openGithub = () => {
<div class="flex-item-expand"></div>
<div class="nav-menu-item flex-box-v">
<n-dropdown
:animated="false"
:keyboard="false"
:options="preferencesOptions"
:render-label="renderContextLabel"
trigger="click"