diff --git a/src/sku/components/SkuRow.js b/src/sku/components/SkuRow.js index 4a800f5bd..df1554bfc 100644 --- a/src/sku/components/SkuRow.js +++ b/src/sku/components/SkuRow.js @@ -70,14 +70,20 @@ export default createComponent({ const nodes = this.slots(); if (this.item.largeImageMode) { - const middle = Math.ceil(nodes.length / 2); + const top = []; + const bottom = []; + + nodes.forEach((node, index) => { + const group = Math.floor(index / 3) % 2 === 0 ? top : bottom; + group.push(node); + }); return (
- {nodes.slice(0, middle)} + {top}
-
{nodes.slice(middle, nodes.length)}
+ {bottom.length &&
{bottom}
}
); }