Automattic / Automattic/jetpack
Photon: add_image_size() crop position is not honored
- Dominant language
- PHP
- Stars
- 1.8k
- Forks
- 898
- Avg merge
- 1d 18h
- Merged PRs (30d)
- 774
Description
#### Steps to reproduce the issue
Add an image size which uses a specific crop location, e.g.
`add_image_size( 'my-image-size', 152, 152, [ 'center', 'top' ] );`
..then display that image size somewhere, e.g.
```
$image = wp_get_attachment_image_src( $attachment_id, 'my-image-size' );
echo $image[0];
```
You'll note the image url is in the following format (only contains resize argument in the query string):
`i1.wp.com/mysite.com/wp-content/uploads/sites/XX/XXXX/XX/my-image.jpg?resize=152,152`
#### What I expected
The output image url should point to a cropped version of the image.
#### What happened instead
The output image is only resized, it's not cropped.
Contributor guide
Assessment
This issue has not been assessed yet.