Skip to content

Releases: sitegeist/Sitegeist.Kaleidoscope

Generic alt and title for Image Sources, no src in source tags, phpstan and no more Neos 4.3 support

04 Jun 10:58
7334d75
Compare
Choose a tag to compare

Changes;

  1. While the source tag allows an src attribute it is ignored in picture tags. Since this is all Kaleidoscope cares about we can remove this safely.

  2. The codebase is now tested with phpstan. To do so we had to drop the Neos 4.3 support.

  3. All imageSource FusionObjects now support the fusion attributes 'alt' and 'title' that will be used as fallback for the
    respective attributes of the img-tag. That way it is no longer necessary to pass three separate properties around.

Examples:

  1. Use title and alternativeText from node properties with fallback to the asset title:
imageSource = Sitegeist.Kaleidoscope:AssetImageSource {
    asset = ${q(node).property('image')}
    title =  ${q(node).property('title') || q(node).property('image').title}
    alt = ${q(node).property('alternativeText')}
}
  1. Set alt and title for dummy image source
imageSource = Sitegeist.Kaleidoscope:DummyImageSource {
    alt = 'Alternate assigned to source'
    title = 'Title assigned to source'
}

Fix dummyimages in Neos 7.1 and correct documentation

23 May 18:17
b74ba41
Compare
Choose a tag to compare

The bugfix for the documentation was provided by @jonnitto .
This release contains also a correction for the readme that was provided by @freesh

Thank you both.

Fix bug in sizes handling for picture sources

08 Mar 18:17
99f54e7
Compare
Choose a tag to compare

Thanks to @akappler for reporting and fixing.

Add Neos 7 compatibility and render empty alt-attributes by default.

16 Dec 19:56
Compare
Choose a tag to compare
Merge branch '5.0'

# Conflicts:
#	Resources/Private/Fusion/Prototypes/Picture.fusion

Render empty alt-attributes by default

16 Dec 19:55
6954b64
Compare
Choose a tag to compare
v5.1.2

Merge pull request #31 from sitegeist/bugfix/emptyAltAtttributesByDef…

Support for `renderDimensionAttributes`, `width`, `height`, `loading` and `format` resp. `formats`

23 Oct 14:41
35e194c
Compare
Choose a tag to compare

Kaleidoscope will now render width and height attributes whenever possible by default and thus help to prevent content reflow when images are loaded. This can be controlled via renderDimensionAttributes. Additionally the loading attribute can be used and width, height and format can be defined on the prototypes directly.

Sitegeist.Kaleidoscope:Image:

  • renderDimensionAttributes: render dimension attributes (width/height) when the data is available from the imageSource. Enabled by default
  • loading: (optional) loading attribute for the img tag
  • width: (optional) the base width, will be applied to the imageSource
  • height: (optional) the base height, will be applied to the imageSource
  • format: (optional) the image-format like webp or png, is applied to the imageSource

Sitegeist.Kaleidoscope:Picture:

  • renderDimensionAttributes: render dimension attributes (width/height) for the img-tag when the data is available from the imageSource
    if not specified dimensions will be enabled automatically for pictures that only use the formats options.
  • formats: (optional) image formats that will be rendered as sources of separate type (string or array)
  • loading: (optional) loading attribute for the img tag
  • width: (optional) the base width, will be applied to the imageSource
  • height: (optional) the base height, will be applied to the imageSource

Sitegeist.Kaleidoscope:Source:

  • format: (optional) the image-format for the source like webp or png, is applied to imageSource and type
  • width: (optional) the base width, will be applied to the imageSource
  • height: (optional) the base height, will be applied to the imageSource

In addition all Sitegeist.Kaleidoscope:Source rendered inside of a Sitegeist.Kaleidoscope:Picture
will inherit the values imageSource, srcset, sizes, width and height.

Fix a bug in ResourceImageSource

18 Aug 09:17
948e457
Compare
Choose a tag to compare
Merge pull request #23 from jonnitto/bugfix/resource_image_source

BUGFIX: Fix broken ResourceImageSource

Variant Preset and Neos 4.3 + 5 Support

29 Oct 15:46
Compare
Choose a tag to compare

Provides a new property variantPreset in the AssetImageSource and
DummyImageSource Fusion prototypes. The expect a string giving the
preset identifier and preset variant name separated by ::, like:

Acme.Com:Component.Teaser.Hero::landscape
In addition this adds a new method useVariantPreset() to the
ImageSourceHelperInterface that can be used to specify a variant to
use based on a configured asset variant preset:

useVariantPreset('Acme.Com:Component.Teaser.Hero', 'landscape')
That variant (if existing) of an asset will be used as base before any
further adjustments are applied.

Additionally the Sitegeist.Kaleidoscope:Picture now accepts to pass
afx content

VariantPreset Support

29 Oct 14:19
Compare
Choose a tag to compare

Provides a new property variantPreset in the AssetImageSource and
DummyImageSource Fusion prototypes. The expect a string giving the
preset identifier and preset variant name separated by ::, like:

Acme.Com:Component.Teaser.Hero::landscape

In addition this adds a new method useVariantPreset() to the
ImageSourceHelperInterface that can be used to specify a variant to
use based on a configured asset variant preset:

useVariantPreset('Acme.Com:Component.Teaser.Hero', 'landscape')

That variant (if existing) of an asset will be used as base before any
further adjustments are applied.

Furthermore this changes the API for using thumbnail presets:

  • renames applyPreset() to applyThumbnailPreset() in
    ImageSourceHelperInterface
  • renames preset to thumbnailPreset in Fusion prototypes

The key preset in Fusion is still used if thumbnailPreset is not
given to provide b/c.

Resolves #12

Neos 5 / Flow 6 compatibility

23 Sep 09:36
Compare
Choose a tag to compare
Merge branch 'feature/flow6-compatibility'

# Conflicts:
#	Classes/Controller/DummyImageController.php
#	composer.json