Skip to content

Commit c3a7ad9

Browse files
committed
Revert ACP2E-295 changes
1 parent 97b9aa4 commit c3a7ad9

File tree

4 files changed

+10
-133
lines changed

4 files changed

+10
-133
lines changed

app/code/Magento/Swatches/Test/Mftf/Data/SwatchProductAttributeFrontendLabelData.xml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,4 @@
1212
<data key="store_id">0</data>
1313
<data key="label" unique="suffix">Swatch-Attribute-</data>
1414
</entity>
15-
<entity name="SwatchProductSizeAttribute" type="FrontendLabel">
16-
<data key="frontend_label">Set Size</data>
17-
<data key="attribute_code">set_size</data>
18-
</entity>
1915
</entities>

app/code/Magento/Swatches/Test/Mftf/Test/StorefrontConfigurableOptionsImportSameBaseImageTest.xml

Lines changed: 0 additions & 119 deletions
This file was deleted.

app/code/Magento/Swatches/view/base/web/js/swatch-renderer.js

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1247,12 +1247,17 @@ define([
12471247
* @param {Array} images
12481248
*/
12491249
_setImageType: function (images) {
1250+
var initial = this.options.mediaGalleryInitial[0].img;
12501251

1251-
images.map(function (img) {
1252-
if (!img.type) {
1253-
img.type = 'image';
1254-
}
1255-
});
1252+
if (images[0].img === initial) {
1253+
images = $.extend(true, [], this.options.mediaGalleryInitial);
1254+
} else {
1255+
images.map(function (img) {
1256+
if (!img.type) {
1257+
img.type = 'image';
1258+
}
1259+
});
1260+
}
12561261

12571262
return images;
12581263
},

dev/tests/acceptance/tests/_data/import_configurable_product_same_images.csv

Lines changed: 0 additions & 5 deletions
This file was deleted.

0 commit comments

Comments
 (0)