Content-Length: 228521 | pFad | https://github.com/decaporg/decap-cms/issues/5317

59 Add file widget as secondary type for the image field inference · Issue #5317 · decaporg/decap-cms · GitHub
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

Add file widget as secondary type for the image field inference #5317

Open
corbinchild opened this issue Apr 28, 2021 · 2 comments
Open

Add file widget as secondary type for the image field inference #5317

corbinchild opened this issue Apr 28, 2021 · 2 comments
Assignees
Labels
area: extensions/widgets good first issue type: feature code contributing to the implementation of a feature and/or user facing functionality

Comments

@corbinchild
Copy link

Is your feature request related to a problem? Please describe.
I have a thumbnail field that can be an image, webm, or mp4 file. Therefore, it is necessary for me to use the file widget with the name and label "thumbnail". The grid view in Netlify CMS uses field inferences to display a preview image for each item in a collection. However, the field inferences code only looks for values from the image widget, not similarly named file widgets.

Relevant code is here:
https://github.com/netlify/netlify-cms/blob/460d1e6835af122f86278b4b2f9c2e3b7bc91488/packages/netlify-cms-core/src/constants/fieldInference.tsx

Describe the solution you'd like
Perhaps the file widget can be added to 'secondaryTypes' for the image field inference. If the file widget value is a valid image path then the image should be displayed in the grid view for collections.

@corbinchild corbinchild added the type: feature code contributing to the implementation of a feature and/or user facing functionality label Apr 28, 2021
@bhanudatsinhjhala
Copy link

Hey can I work on this issue? @erezrokah and @corbinchild

@martinjagodic
Copy link
Member

@bhanudatsinhjhala certainly, please submit a pull request

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: extensions/widgets good first issue type: feature code contributing to the implementation of a feature and/or user facing functionality
Projects
None yet
Development

No branches or pull requests

4 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/decaporg/decap-cms/issues/5317

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy