tweaking project list

This commit is contained in:
2025-09-01 17:22:02 +02:00
parent 6031bb4445
commit 7478a8bdae
4 changed files with 21 additions and 14 deletions

View File

@@ -5,7 +5,8 @@
let {
simple = false,
editable = simple,
onclick = evt => { startEdit() },
href = '#',
onclick = evt => { evt.preventDefault(); startEdit(); return false },
onSet = newVal => {return true;},
type = 'div',
value = $bindable(null)
@@ -91,5 +92,5 @@
{#if editable && editing}
<input bind:value={editValue} onkeyup={typed} autofocus />
{:else}
<svelte:element this={type} href="#" {onclick} {onmousedown} {onmouseup} {ontouchstart} {ontouchend} {oncontextmenu} class={{editable}} title={t('long_click_to_edit')} >{value}</svelte:element>
<svelte:element this={type} href={href} {onclick} {onmousedown} {onmouseup} {ontouchstart} {ontouchend} {oncontextmenu} class={{editable}} title={t('long_click_to_edit')} >{value}</svelte:element>
{/if}