From 875dcfaf8e8496ae77d8e1467e3a17db634bc7ab Mon Sep 17 00:00:00 2001 From: Zara Mudassar <zara.1310@hotmail.com> Date: Thu, 5 May 2022 11:28:37 +0200 Subject: [PATCH] Images instructions added --- src/components/CommunityComponents/NewCommunityForm.vue | 8 ++++---- src/components/ItemComponents/NewItemForm.vue | 5 ++--- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/src/components/CommunityComponents/NewCommunityForm.vue b/src/components/CommunityComponents/NewCommunityForm.vue index 3784e50..200db5b 100644 --- a/src/components/CommunityComponents/NewCommunityForm.vue +++ b/src/components/CommunityComponents/NewCommunityForm.vue @@ -136,10 +136,10 @@ <!-- Images --> <div class="mt-6"> <label - class="block mb-2 text-xl font-medium text-gray-900 dark:text-gray-400" - id="imageLabel" + class="block mb-2 text-sm font-medium text-gray-900 dark:text-gray-400" + id="imageLabel" > - Bilde + Bilde (bildet må være .png) </label> <input @@ -148,7 +148,7 @@ style="display: none" @change="addImage" multiple - accept="image/png, image/jpeg" + accept="image/png" /> <!-- Button for adding an image --> diff --git a/src/components/ItemComponents/NewItemForm.vue b/src/components/ItemComponents/NewItemForm.vue index 4e5fff4..e4d1a49 100644 --- a/src/components/ItemComponents/NewItemForm.vue +++ b/src/components/ItemComponents/NewItemForm.vue @@ -187,7 +187,7 @@ class="block mb-2 text-sm font-medium text-gray-900 dark:text-gray-400" id="imageLabel" > - Bilder + Bilder (bildene må være .png) </label> <input @@ -196,7 +196,7 @@ style="display: none" @change="addImage" multiple - accept="image/png, image/jpeg" + accept="image/png" /> <Button :text="'Velg bilde'" @click="$refs.file.click()" /> @@ -349,7 +349,6 @@ export default { this.item.userId = parseInt(user.accountId); }, - //Not sure this method works addImage: async function (event) { this.item.images.push(URL.createObjectURL(event.target.files[0])); -- GitLab