From d3ef94f097fd13e3eae8a087196259ecac147c36 Mon Sep 17 00:00:00 2001 From: Paul Robert Lloyd Date: Mon, 25 Mar 2024 23:56:55 +0000 Subject: [PATCH] feat(post-type-audio): use file upload component --- packages/post-type-audio/includes/post-types/audio-field.njk | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/post-type-audio/includes/post-types/audio-field.njk b/packages/post-type-audio/includes/post-types/audio-field.njk index 2724d86b9..3b51788bc 100644 --- a/packages/post-type-audio/includes/post-types/audio-field.njk +++ b/packages/post-type-audio/includes/post-types/audio-field.njk @@ -1,9 +1,11 @@ {% macro audioFieldset(index) %} - {{ input({ + {{ fileInput({ name: "audio[" + index + "]", type: "url", value: fieldData("audio[" + index + "]").value, label: __("posts.form.media.label"), + accept: "audio/*", + uploadEndpoint: application.mediaEndpoint, attributes: { placeholder: "https://" },