Skip to content

Commit 356ef14

Browse files
author
joweecaquicla
committed
magento/adobe-stock-integration#1833: Add ability to disable renditions functionality to stores configuration - added enable disable renditions to stores configuration
1 parent b9c13fd commit 356ef14

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

app/code/Magento/MediaGalleryRenditions/etc/adminhtml/system.xml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,15 @@
1010
<section id="system">
1111
<group id="media_gallery_renditions" translate="label" type="text" sortOrder="1010" showInDefault="1" showInWebsite="0" showInStore="0">
1212
<label>Media Gallery Renditions</label>
13-
<field id="width" translate="label" type="text" sortOrder="10" showInDefault="1" showInWebsite="0" showInStore="0">
13+
<field id="enabled" translate="label" type="select" sortOrder="10" showInDefault="1" showInWebsite="0" showInStore="0">
14+
<label>Enable Image Optimization</label>
15+
<source_model>Magento\Config\Model\Config\Source\Yesno</source_model>
16+
</field>
17+
<field id="width" translate="label" type="text" sortOrder="20" showInDefault="1" showInWebsite="0" showInStore="0">
1418
<label>Max Width</label>
1519
<validate>validate-zero-or-greater validate-digits</validate>
1620
</field>
17-
<field id="height" translate="label" type="text" sortOrder="20" showInDefault="1" showInWebsite="0" showInStore="0">
21+
<field id="height" translate="label" type="text" sortOrder="30" showInDefault="1" showInWebsite="0" showInStore="0">
1822
<label>Max Height</label>
1923
<validate>validate-zero-or-greater validate-digits</validate>
2024
</field>

app/code/Magento/MediaGalleryRenditions/etc/config.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
<default>
1010
<system>
1111
<media_gallery_renditions>
12+
<enabled>1</enabled>
1213
<width>1000</width>
1314
<height>1000</height>
1415
</media_gallery_renditions>

0 commit comments

Comments
 (0)