Feature #5321
closedFeature #5320: Create product UI form
Product Image Upload in frontend
Description
As an Admin/User
I want to upload a product image with a 10MB size limit
So that the product can have a visual representation in listings and detail pages
Acceptance Criteria
AC1: Upload image file (Max 10MB)
User must be able to select an image file from the system.
Allowed types: JPEG, PNG, JPG, WEBP.
File size must be ≤ 10MB.
If file exceeds 10MB → show toaster:
“Image size exceeds 10MB. Please upload a smaller file.”
AC2: Show loader during upload
After clicking “Upload”, a loader/spinner must appear.
Loader disappears only when:
Upload is completed, or
Upload fails.
AC3: Show success & error toast notifications
On success:
“Image uploaded successfully.”
On failure:
“Failed to upload image. Please try again.”
AC4: Show preview after upload
After successful upload, the uploaded image URL must be displayed immediately.
The preview should show:
Thumbnail
Remove/Change option (optional)
AC5: Integrate with product create/edit forms
Image upload function must be integrated in:
Create Product Form
Edit Product Form
Uploaded image URL must be saved in product API payload as imageUrl.
Files
Subtasks
Related issues