Skip to content

Commit 110fe12

Browse files
authored
Merge pull request #72 from queoGmbH/task/deprecated-fusion-usage
BUGFIX: Remove usage of deprecated fusion prototypes
2 parents c3703e3 + a84fe59 commit 110fe12

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

Resources/Private/Fusion/Prototypes/DummyImageSource.fusion

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,21 +29,21 @@ prototype(Sitegeist.Kaleidoscope:DummyImageSource) {
2929
// <table>
3030
// <thead>
3131
// <th></th>
32-
// <Neos.Fusion:Collection collection={props.dimensions} itemName="width" @children="itemRenderer">
32+
// <Neos.Fusion:Loop items={props.dimensions} itemName="width" @children="itemRenderer">
3333
// <th>W {width}</th>
34-
// </Neos.Fusion:Collection>
34+
// </Neos.Fusion:Loop>
3535
// </thead>
3636
// <tbody>
37-
// <Neos.Fusion:Collection collection={props.dimensions} itemName="height" @children="itemRenderer">
37+
// <Neos.Fusion:Loop items={props.dimensions} itemName="height" @children="itemRenderer">
3838
// <tr>
3939
// <th>H {height}</th>
40-
// <Neos.Fusion:Collection collection={props.dimensions} itemName="width" @children="itemRenderer">
40+
// <Neos.Fusion:Loop items={props.dimensions} itemName="width" @children="itemRenderer">
4141
// <td>
4242
// <img src={props.imageSource.setWidth(width).setHeight(height)} width={width} height={height} />
4343
// </td>
44-
// </Neos.Fusion:Collection>
44+
// </Neos.Fusion:Loop>
4545
// </tr>
46-
// </Neos.Fusion:Collection>
46+
// </Neos.Fusion:Loop>
4747
// </tbody>
4848
// </table>
4949
// `

Resources/Private/Fusion/Prototypes/Picture.fusion

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ prototype(Sitegeist.Kaleidoscope:Picture) < prototype(Neos.Fusion:Component) {
33
@styleguide {
44
props {
55
imageSource = Sitegeist.Kaleidoscope:DummyImageSource
6-
sources = Neos.Fusion:RawArray {
7-
1 = Neos.Fusion:RawArray {
6+
sources = Neos.Fusion:DataStructure {
7+
1 = Neos.Fusion:DataStructure {
88
srcset = '1x, 1.5x, 2x'
99
media = 'screen and (min-width: 1600px)'
1010
}
11-
2 = Neos.Fusion:RawArray {
11+
2 = Neos.Fusion:DataStructure {
1212
imageSource = Sitegeist.Kaleidoscope:DummyImageSource {
1313
text = "im am in webp format"
1414
format = 'webp'
@@ -18,13 +18,13 @@ prototype(Sitegeist.Kaleidoscope:Picture) < prototype(Neos.Fusion:Component) {
1818
type = 'image/webp'
1919
media = 'screen and (max-width: 1599px)'
2020
}
21-
3 = Neos.Fusion:RawArray {
21+
3 = Neos.Fusion:DataStructure {
2222
imageSource = Sitegeist.Kaleidoscope:DummyImageSource {
2323
text = "im am here for printing"
2424
}
2525
media = 'print'
2626
}
27-
4 = Neos.Fusion:RawArray {
27+
4 = Neos.Fusion:DataStructure {
2828
srcset = '400w, 800w, 1600w'
2929
media = 'screen and (min-width: 2600px)'
3030
width = 800
@@ -103,7 +103,7 @@ prototype(Sitegeist.Kaleidoscope:Picture) < prototype(Neos.Fusion:Component) {
103103
renderer = afx`
104104
<picture class={props.class} {...props.attributes}>
105105
{props.content}
106-
<Neos.Fusion:Collection collection={props.sources} itemName="source" @if.has={props.sources}>
106+
<Neos.Fusion:Loop items={props.sources} itemName="source" @if.has={props.sources}>
107107
<Sitegeist.Kaleidoscope:Source
108108
imageSource={source.imageSource ? source.imageSource : props.imageSource}
109109
type={source.type}
@@ -115,17 +115,17 @@ prototype(Sitegeist.Kaleidoscope:Picture) < prototype(Neos.Fusion:Component) {
115115
sizes={source.sizes ? source.sizes : props.sizes}
116116
renderDimensionAttributes={props.renderDimensionAttributes}
117117
/>
118-
</Neos.Fusion:Collection>
119-
<Neos.Fusion:Collection
118+
</Neos.Fusion:Loop>
119+
<Neos.Fusion:Loop
120120
@if.has={props.imageSource && props.formats}
121-
collection={Type.isArray(props.formats) ? props.formats : String.split(props.formats, ',')}
121+
items={Type.isArray(props.formats) ? props.formats : String.split(props.formats, ',')}
122122
itemName="format"
123123
>
124124
<Sitegeist.Kaleidoscope:Source
125125
imageSource={props.imageSource}
126126
format={String.trim(format)}
127127
/>
128-
</Neos.Fusion:Collection>
128+
</Neos.Fusion:Loop>
129129
<Sitegeist.Kaleidoscope:Image
130130
imageSource={props.imageSource}
131131
sizes={props.sizes}

0 commit comments

Comments
 (0)