Media Embed automatically detects media type, but selects the wrong one

03/07/2018


I have two media types defined in Drupal 8. Both are for handling images. One is a generic Image with its own set of fields, and I have another one meant for a specific field on the homepage, which also has its own set of fields. One is called Banner, the other is called Image.

Now, throughout the site, whenever you upload an image with the media browser, its showing the fields from the wrong media type (banner instead of image). Where can I change this behavior so it stops attempting to autodetect the type? Can I write some code to tell it which one to use based on entity type + field used?

قالب وردپرس