Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance Image Uploads to Support Multiple Files with Shared Metadata #30

Open
wants to merge 2 commits into
base: dev
Choose a base branch
from

Conversation

01bps
Copy link
Contributor

@01bps 01bps commented Jan 23, 2025

What:
This PR enhances the image upload feature to support multiple image uploads at once, with shared metadata applied across all selected images.

Why:
The ability to upload multiple images simultaneously improves user convenience and efficiency, especially in scenarios involving bulk contributions. Supporting shared metadata ensures consistency and reduces repetitive tasks for users.

How:

  • Updated backend logic to handle multiple image files in a single upload request.
  • Ensured compatibility with the existing upload validation, storage, and processing mechanism.

i.e:
image

Checklist:

@01bps
Copy link
Contributor Author

01bps commented Jan 26, 2025

@pradeeban @mdxabu ,
Waiting for your review

@01bps 01bps changed the base branch from main to dev January 26, 2025 14:52
@01bps 01bps changed the title Feature Added: Enabling Multiple Image Uploads with Shared Metadata Enhance Image Uploads to Support Multiple Files with Shared Metadata Jan 27, 2025
@01bps
Copy link
Contributor Author

01bps commented Jan 27, 2025

@mdxabu ,
I have updated the PR according to the latest changes.

@mdxabu
Copy link
Collaborator

mdxabu commented Jan 27, 2025

We don't recommend uploading multiple images at a time, because, If you select multiple images at a time then how can a user give a title and description for each image? That's why we don't recommend it.

@01bps
Copy link
Contributor Author

01bps commented Jan 27, 2025

Thank you for the feedback!
The multiple image upload feature is intended for cases where all selected images share the same metadata (title and description), simplifying the process in those scenarios. The option to upload a single image and provide unique metadata remains intact to ensure flexibility for users.

@01bps
Copy link
Contributor Author

01bps commented Jan 29, 2025

Interested to hear your thoughts @pradeeban . Also, Should we keep the PR or drop it?

@pradeeban
Copy link
Member

Thanks for your contributions, @01bps,
Multiple images with the same title and description sounds like a valid use case to me, although we were not thinking about those. Thanks for bringing that up. Like, "I am here in front of the library. And I feel great" (and proceeds to upload ten photos, rather than just one -- which is how David and I were thinking of this feature).

There is also a valid scenario where someone bulk-uploads photos without description AND THEN comes back to add description/narratives to those photos. It makes sense in practice. Sometimes we are in a hurry. We take photos and upload them. Then we come back (perhaps even logging in from a computer) to add the narrative/description. But in that case, a functionality to edit the narrative should be present AND obvious to the users who upload the images.

It can be a problematic feature, though - because this will probably end up with more people bulk-uploading and then forgetting the narratives OR mass-uploading several (near identical) photos with the same narrative (which may or may not help). Then, we will end up with several images that are practically irrelevant to us.

However, the PR and the feature have merit.

@mdxabu Does this break any other feature? If not, I am ok with merging. (and if we come to the realization that the feature is used in a wrong way, as I contemplated above, we can always hide the feature from the users later).

@mdxabu
Copy link
Collaborator

mdxabu commented Jan 29, 2025

It may break certain edge cases. We can update the code for our future needs, but it looks good. LGTM🚀

@01bps
Copy link
Contributor Author

01bps commented Jan 29, 2025

Thank you for the insightful discussion!

@pradeeban your perspective on different use cases—especially the scenario of bulk uploads with later edits, that makes a lot of sense in real-world usage. Ensuring an intuitive way to edit narratives would definitely enhance the experience and sounds like a great improvement to consider.We can update or improve it in the future if needed.

@mdxabu thanks for reviewing and confirming! If any edge cases do surface, I’d be happy to help refine the implementation as needed.

@01bps
Copy link
Contributor Author

01bps commented Jan 29, 2025

On a related note (though slightly outside the scope of this PR), I haven’t specified the acceptable image formats. Should we define supported file types explicitly, and if so, what formats should we allow?

@pradeeban
Copy link
Member

Good question. We should accept all the popular image formats: JPG/JPEG, HEIC, ... probably also PDF, since we consider digitized versions of the drawings, and a scan could be a PDF.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants