Allow images to be cropped without being resized
authorJohn Elliott <johnsvenn@googlemail.com>
Tue, 22 Feb 2022 16:50:23 +0000 (16:50 +0000)
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Wed, 23 Feb 2022 09:01:50 +0000 (10:01 +0100)
commit7732da9f93503c1a723d6ac5bb77da206cb0fa0e
treea205fe894c5413a7dcaa6c6ad8ce64c93e61f874
parentaebde49b884c3b5ef73d8e1a01fca8a1354ac5b9
Allow images to be cropped without being resized

Introduces the Crop method for image processing which implements gift.CropToSize. Also allows a smartCrop without resizing, and updates the documentation.

Fixes #9499
docs/content/en/content-management/image-processing/index.md
docs/layouts/shortcodes/imgproc.html
resources/errorResource.go
resources/image.go
resources/image_test.go
resources/images/config.go
resources/images/image.go
resources/resource/resourcetypes.go
resources/transform.go