Fix AddAttachment control

Signed-off-by: Anna No <anna.no@xored.com>
This commit is contained in:
Anna No 2022-04-13 10:44:13 +07:00
parent b09466453d
commit 543e7616f8
No known key found for this signature in database
GPG Key ID: 08C11FFC23177C87
3 changed files with 33 additions and 34 deletions

View File

@ -31,9 +31,7 @@
<div>
{#if $$slots.control}
<div on:click={openFile}>
<slot name="control"/>
</div>
<slot name="control" click={openFile}/>
{:else}
<CircleButton
icon={IconAdd}

View File

@ -77,6 +77,5 @@
{/if}
</div>
</div>
</div>
</div>
</AttachmentDroppable>

View File

@ -54,7 +54,9 @@
{/each}
<div class="mt-2">
<AddAttachment bind:inputFile objectClass={value._class} objectId={value._id} space={value.space}>
<Button label={board.string.AddAttachment} kind="no-border" slot="control" />
<svelte:fragment slot="control" let:click>
<Button label={board.string.AddAttachment} kind="no-border" on:click={click}/>
</svelte:fragment>
</AddAttachment>
</div>
</div>