fix DirectoryEntry menu action clicks clearing selection
This commit is contained in:
@@ -122,6 +122,7 @@ function onClearCopy() {
|
||||
<ContextMenuContent>
|
||||
<ContextMenuItem
|
||||
:class="[warrenStore.current == null && 'hidden']"
|
||||
@pointerdown.stop
|
||||
@select="openRenameDialog"
|
||||
>
|
||||
<Icon name="lucide:pencil" />
|
||||
@@ -136,22 +137,24 @@ function onClearCopy() {
|
||||
copyStore.file.path !== warrenStore.current.path ||
|
||||
copyStore.file.name !== entry.name
|
||||
"
|
||||
@pointerdown.stop
|
||||
@select="onCopy"
|
||||
>
|
||||
<Icon name="lucide:copy" />
|
||||
Copy
|
||||
</ContextMenuItem>
|
||||
<ContextMenuItem v-else @select="onClearCopy">
|
||||
<ContextMenuItem v-else @pointerdown.stop @select="onClearCopy">
|
||||
<Icon name="lucide:copy-x" />
|
||||
Clear clipboard
|
||||
</ContextMenuItem>
|
||||
</template>
|
||||
<ContextMenuItem @select="onDownload">
|
||||
<ContextMenuItem @pointerdown.stop @select="onDownload">
|
||||
<Icon name="lucide:download" />
|
||||
Download
|
||||
</ContextMenuItem>
|
||||
<ContextMenuItem
|
||||
:class="[warrenStore.current == null && 'hidden']"
|
||||
@pointerdown.stop
|
||||
@select="onShare"
|
||||
>
|
||||
<Icon name="lucide:share" />
|
||||
@@ -164,6 +167,7 @@ function onClearCopy() {
|
||||
|
||||
<ContextMenuItem
|
||||
:class="[warrenStore.current == null && 'hidden']"
|
||||
@pointerdown.stop
|
||||
@select="() => onDelete(false)"
|
||||
>
|
||||
<Icon name="lucide:trash-2" />
|
||||
@@ -171,6 +175,7 @@ function onClearCopy() {
|
||||
</ContextMenuItem>
|
||||
<ContextMenuItem
|
||||
:class="[warrenStore.current == null && 'hidden']"
|
||||
@pointerdown.stop
|
||||
@select="() => onDelete(true)"
|
||||
>
|
||||
<Icon
|
||||
|
||||
Reference in New Issue
Block a user