amp post Thumbnail Size problem

Hello @immmukeshpatel

Thank you for contacting us, you are using native HTML which adds custom styling to your image based on your height attribute.

It seems you are using native <img> tag, which adds some CSS that adds images with height so you see stretched-out images.

I will recommend by unchecking the native html support

goto AMP->Settings->Other-> uncheck “Use native HTML image tag

Once you change settings clear your site cache and recheck AMP page.

OR you can use the following code in your child themes functions.php or in a custom plugin

add_action( 'amp_post_template_css', function ( $amp_template ) {
	// only CSS here please...
	?>
	figure.amp-wp-article-featured-image img { height:auto; }
	<?php
} );

Let me know if that fixes your issue.

I have created a Github issue to address this issue

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer