diff --git a/packages/bbui/src/Form/Core/Dropzone.svelte b/packages/bbui/src/Form/Core/Dropzone.svelte index 2bd95df516..3d803c0961 100644 --- a/packages/bbui/src/Form/Core/Dropzone.svelte +++ b/packages/bbui/src/Form/Core/Dropzone.svelte @@ -197,7 +197,9 @@ > - + {#if maximum !== 1} + + {/if} {:else if value?.length} {#each value as file} diff --git a/packages/frontend-core/src/components/grid/cells/AttachmentCell.svelte b/packages/frontend-core/src/components/grid/cells/AttachmentCell.svelte index e6c9e53c75..a1f5c4f2aa 100644 --- a/packages/frontend-core/src/components/grid/cells/AttachmentCell.svelte +++ b/packages/frontend-core/src/components/grid/cells/AttachmentCell.svelte @@ -9,6 +9,7 @@ export let api export let invertX = false export let invertY = false + export let schema const { API, notifications } = getContext("grid") const imageExtensions = ["png", "tiff", "gif", "raw", "jpg", "jpeg"] @@ -97,6 +98,7 @@ {value} compact on:change={e => onChange(e.detail)} + maximum={schema.constraints?.length?.maximum} {processFiles} {deleteAttachments} {handleFileTooLarge}