Releases: BKWLD/croppa
Fixes for max_crops config and deleting crops
Also includes better docs and tests for deleting crops in a subdirectory of of the src_dir.
Two new wiki pages were also created:
Fixes trim() option
Updating PHPThumb and fixing some URL options
- Fixes issue where jpgs were being created as pngs
- Fixes issue where pngs were getting a black background
- Fixes error when passing in
quality
andinterlace
options in the URL - Preparing for eventual update to Flysystem CachedAdapter (#87)
Croppa::delete() now correctly deletes crops
Fixing the facade's accessor reference
Merge pull request #82 from sdebacker/patch-1 Wrong service name in Facade
4.0
Flysystem support
In addition to the src_dir
being a local path, it can also be an IoC binding name to a Flysystem instance. Thus, your src images (and your crops) can be located on remote disks like S3, Dropbox, FTP, src.
Configuration
With this release major changes were made to the config file as part of the transition to Flysystem and to make the configuration more explicit / less confusing. For instance, the src_dir
is no longer an array of paths, there can be only one source. Also, a crops_dir
allows you to store the crops in a different directory than the source directory. Read the config file for docs on each option.
Fully dependency injected
The code architecture was rewritten from a single class to multiple that get instantiated using dependency injection through the Laravel container. This will make adding future tests and functionality easier and let people subclass and extend Croppa.
Support `route:cache` to work in L5
- #81 - Route handling is done with a
Controller
rather than a closure so applications that cache routes will not get a fatal error - Fixing composer.json so that L4 continues to be supported
Fixing image output bug on new service providers
Adding support for Laravel 5
Smarter regex and more tests
- #69 If src image doesn't exist, return a 404 exception.
- #58 Adding unit tests for
generate()
- #13 Restrict the route listener regex to just handle images found in a
src_dir
- Adding other unit tests and making many private methods public
- Dropping Travis CI support for PHP 5.3 and adding PHP 5.6
- Croppa will regenerate the cropped version of files if
generate()
is called for a path that already exists generate()
no longer outputs the image when it finishes. Instead, it returns aBkwld\Croppa\Image
object with ashow()
method that will echo the binary image data