duplicator UX

This commit is contained in:
Jan Prochazka
2023-02-17 12:14:58 +01:00
parent 67e287cfdf
commit 7b6a1543de
2 changed files with 8 additions and 1 deletions

View File

@@ -1,15 +1,18 @@
<script lang="ts">
import { openWebLink } from '../utility/exportFileTools';
import contextMenu from '../utility/contextMenu';
export let href = undefined;
export let onClick = undefined;
export let menu = '__no_menu';
</script>
<a
on:click={(e) => {
on:click={e => {
if (onClick) onClick(e);
else openWebLink(href);
}}
use:contextMenu={menu}
>
<slot />
</a>