Releases: sitegeist/Sitegeist.Kaleidoscope
v6.4.0
Enable `lazy` loading by default
With the general availability of loading="lazy" in all relevant Browsers we added lazy loading as a default.
While this is definitely the most user friendly default it is not always the best for the site performance.
In general all images that are immediately visible to the user should be loaded via loading="eager"
and everything else via loading="lazy"
.
For Kaleidoscope images or pictures in the site header you can set loading="eager" manually.
For the main content collection we suggest to enable eager
loading for the first content in main
and lazy
load the rest.
renderer = Neos.Neos:ContentCollection {
nodePath = 'main'
// configure separate iterator for main content
content.iterationName = 'mainContentIterator'
// enable lazyness for first items
prototype(Sitegeist.Kaleidoscope:Image) {
loading = ${mainContentIterator.isFirst ? 'eager' : 'lazy'}
}
prototype(Sitegeist.Kaleidoscope:Picture) {
loading = ${mainContentIterator.isFirst ? 'eager' : 'lazy'}
}
}
Add Support for Neos 8.0
v6.2.1 TASK: Relax composer dependencies for Neos 8.0
Configure alternate driver and format for dummyImages
Some imagine drivers like vips do not support the creation of images on the fly which breaks the dummy images.
This change allows to configure an alternate driver that is used for the dummyImages plus a fallbackFormat that is used when the chosen
format could not be rendered.
Thanks to @gradinarufelix for providing the PR and to @rolandschuetz and @kdambekalns for testing:
Sitegeist:
Kaleidoscope:
dummyImage:
overrideImagineDriver: 'Imagick'
fallbackFormat: 'png'
BUGFIX: Remove src attributes from source tag that is technically allowed but ignored inside of picture elements
This is a backport from a bugfix that was merged to 6.1 instead of 6.0. Thank to @kdambekalns for detecting this.
Generic alt and title for Image Sources, no src in source tags, phpstan and no more Neos 4.3 support
Changes;
-
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.
-
The codebase is now tested with phpstan. To do so we had to drop the Neos 4.3 support.
-
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:
- 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')}
}
- 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
Fix bug in sizes handling for picture sources
Thanks to @akappler for reporting and fixing.
Add Neos 7 compatibility and render empty alt-attributes by default.
Merge branch '5.0' # Conflicts: # Resources/Private/Fusion/Prototypes/Picture.fusion
Render empty alt-attributes by default
Merge pull request #31 from sitegeist/bugfix/emptyAltAtttributesByDef… …ault BUGFIX: Render empty alt attributes by default as is required by web standards