diff --git a/packages/builder/src/components/design/settings/componentSettings.js b/packages/builder/src/components/design/settings/componentSettings.js
index 3b26031ca1..2a5483d77c 100644
--- a/packages/builder/src/components/design/settings/componentSettings.js
+++ b/packages/builder/src/components/design/settings/componentSettings.js
@@ -70,6 +70,7 @@ const componentMap = {
"field/longform": FormFieldSelect,
"field/datetime": FormFieldSelect,
"field/attachment": FormFieldSelect,
+ "field/attachment_single": FormFieldSelect,
"field/s3": Input,
"field/link": FormFieldSelect,
"field/array": FormFieldSelect,
diff --git a/packages/client/manifest.json b/packages/client/manifest.json
index 9aa5e7a5bc..46df1fcad2 100644
--- a/packages/client/manifest.json
+++ b/packages/client/manifest.json
@@ -4354,12 +4354,6 @@
"label": "Extensions",
"key": "extensions"
},
- {
- "type": "number",
- "label": "Max attachments",
- "key": "maximum",
- "min": 1
- },
{
"type": "event",
"label": "On change",
diff --git a/packages/client/src/components/app/forms/AttachmentField.svelte b/packages/client/src/components/app/forms/AttachmentField.svelte
index 8be70bc011..644630810d 100644
--- a/packages/client/src/components/app/forms/AttachmentField.svelte
+++ b/packages/client/src/components/app/forms/AttachmentField.svelte
@@ -20,6 +20,7 @@
get: value => value,
set: value => value,
}
+ export let defaultValue = []
let fieldState
let fieldApi
@@ -88,7 +89,7 @@
{type}
bind:fieldState
bind:fieldApi
- defaultValue={[]}
+ {defaultValue}
>
{#if fieldState}
diff --git a/packages/frontend-core/src/components/grid/cells/AttachmentSingleCell.svelte b/packages/frontend-core/src/components/grid/cells/AttachmentSingleCell.svelte
index c2e29b6ede..e3e7891b7c 100644
--- a/packages/frontend-core/src/components/grid/cells/AttachmentSingleCell.svelte
+++ b/packages/frontend-core/src/components/grid/cells/AttachmentSingleCell.svelte
@@ -3,6 +3,7 @@
export let value
export let onChange
+ export let api
$: arrayValue = (!Array.isArray(value) && value ? [value] : value) || []
@@ -13,6 +14,7 @@