Replies: 0
Event thumbnails in the new v2 list view are not responsive because while they have a “srcset” attribute, they do not include a “sizes” attribute.
The file wp-content/plugins/the-events-calendar/src/views/v2/list/event/featured-image.php at line 33:
<?php if ( ! empty( $event->thumbnail->srcset ) ) : ?>
srcset="<?php echo esc_attr( $event->thumbnail->srcset ); ?>"
<?php endif; ?>
needs to be changed to:
<?php if ( ! empty( $event->thumbnail->srcset ) ) : ?>
srcset="<?php echo esc_attr( $event->thumbnail->srcset ); ?>"
sizes="<?php echo esc_attr(wp_get_attachment_image_sizes(get_post_thumbnail_id( $event->ID) )); ?>"
<?php endif; ?>