feat: check for token for editing

This commit is contained in:
2025-01-19 21:27:27 +01:00
parent fcfabe4a8e
commit 710fd16088
4 changed files with 86 additions and 26 deletions

View File

@@ -7,11 +7,13 @@
<h1 class="font-bold text-2xl">
Tasks ({data.tasks.length})
</h1>
<a href="/progress/create">
<button class="px-4 py-2 bg-green-500 text-white rounded hover:bg-green-600 transition">
Create
</button>
</a>
{#if data.editable}
<a href="/progress/create">
<button class="px-4 py-2 bg-green-500 text-white rounded hover:bg-green-600 transition">
Create
</button>
</a>
{/if}
</div>
{#if data.tasks.length > 0}