🐛 Open in workspace when target set, Fixes #143

This commit is contained in:
Alicia Sykes 2021-08-11 21:19:36 +01:00
parent e031e0246d
commit c8df328178
1 changed files with 3 additions and 1 deletions

View File

@ -3,7 +3,7 @@
<a @click="itemOpened"
@mouseup.right="openContextMenu"
@contextmenu.prevent
:href="target !== 'modal' ? url : '#'"
:href="(target !== 'modal' && target !== 'workspace') ? url : '#'"
:target="target === 'newtab' ? '_blank' : ''"
:class="`item ${!icon? 'short': ''} size-${itemSize}`"
v-tooltip="getTooltipOptions()"
@ -100,6 +100,8 @@ export default {
if (e.altKey || this.target === 'modal') {
e.preventDefault();
this.$emit('triggerModal', this.url);
} else if (this.target === 'workspace') {
router.push({ name: 'workspace', query: { url: this.url } });
} else {
this.$emit('itemClicked');
}