Good day everyone,
Our client wants to have this feature where he can upload/reuse multiple images for an article content type. This can be achieved using a Media Library, where I find it tricky is each images will have additional fields(Alt, Copyright, Description fields), I've tried adding the additional fields to the Image Media Type but once the node is saved, their value will be associated to the image's metadata. The proper functionality should be is when the node is saved, the Alt and Description of the images should be associated to the node's metadata because Images can be reusable to another node, and the values of Alt and Description varies to each node.
So I talked with someone who really knows a lot about Drupal. He suggested that I keep the Media Library, and create a Paragraph Type. I called it 'Image Library Paragraphs', this paragraph has Image, Alt, Copyright, and Description fields. This way the Paragraph can hold the id of the image, alt, description and the node's ID. In theory, what we're trying to do here is everytime the user uploads/select an image. We must find a way to associate that image and add corresponding paragraph for each of those images. So if the user uploads/selects 3 images. It will also automatically create 3 paragraphs for those images. We also would need to reconstruct the layout of the form to somehow "blend" the image and its corresponding paragraphs. And since the position of the images can be changed, we also need to somehow reposition its paragraph accordingly to the image.
It's tricky and a lot of work, honestly it's even beyond my Drupal skills. But any help to the right direction will truly be appreciated. I haven't even tried creating a really complex custom module. But would really want to learn how this can be done. Thank you in advance.