From 2409b6b5616c915d4753d1833ce66d78cc609c7e Mon Sep 17 00:00:00 2001 From: Martin Ficzel Date: Fri, 13 Jul 2018 18:03:39 +0200 Subject: [PATCH] BUGFIX: Apply presets correctly --- Classes/EelHelpers/AbstractImageSourceHelper.php | 1 + README.md | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Classes/EelHelpers/AbstractImageSourceHelper.php b/Classes/EelHelpers/AbstractImageSourceHelper.php index fd78b4f..2daffc2 100644 --- a/Classes/EelHelpers/AbstractImageSourceHelper.php +++ b/Classes/EelHelpers/AbstractImageSourceHelper.php @@ -62,6 +62,7 @@ public function applyPreset(string $name) : ImageSourceHelperInterface } } } + return $this; } /** diff --git a/README.md b/README.md index dedf23f..18f7ddc 100644 --- a/README.md +++ b/README.md @@ -174,7 +174,7 @@ but can also applied on the returned object. This will override the fusion-setti All ImageSources support the following fusion properties: -- `preset`: Apply a configuration preset (default null, settings below override the preset) +- `preset`: Set width and/or height via named-preset from Settings `Neos.Media.thumbnailPresets` (default null, settings below override the preset) - `width`: Set the intended width (default null) - `height`: Set the intended height (default null) @@ -218,7 +218,7 @@ dimensions and to render the `src` and `srcset`-attributes. Methods of ImageSource-Helpers that are accessible via EEL: -- `applyPreset( string )`: Apply width and height from a thumbnailPreset identified by its name +- `applyPreset( string )`: Set width and/or height via named-preset from Settings `Neos.Media.thumbnailPresets` - `setWidth( integer )`: Set the intend width - `setHeight( integer )`: Set the intended height - `src ()` : Render a src attribute for the given ImageSource-object