Skip to content

Commit 827ab5d

Browse files
author
Evgeniy Kolesov
committed
MAGETWO-55279: XSD for view.xml is too strict
1 parent 0d59cf4 commit 827ab5d

File tree

1 file changed

+17
-7
lines changed
  • lib/internal/Magento/Framework/Config/etc

1 file changed

+17
-7
lines changed

lib/internal/Magento/Framework/Config/etc/view.xsd

Lines changed: 17 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -66,13 +66,23 @@
6666
<xs:attribute name="id" type="xs:string" use="required"/>
6767
<xs:attribute name="type">
6868
<xs:simpleType>
69-
<xs:restriction base="xs:string">
70-
<xs:enumeration value="thumbnail"/>
71-
<xs:enumeration value="small_image"/>
72-
<xs:enumeration value="image"/>
73-
<xs:enumeration value="swatch_image"/>
74-
<xs:enumeration value="swatch_thumb"/>
75-
</xs:restriction>
69+
<xs:union>
70+
<xs:simpleType>
71+
<xs:restriction base="xs:string">
72+
<xs:enumeration value="thumbnail"/>
73+
<xs:enumeration value="small_image"/>
74+
<xs:enumeration value="image"/>
75+
<xs:enumeration value="swatch_image"/>
76+
<xs:enumeration value="swatch_thumb"/>
77+
</xs:restriction>
78+
</xs:simpleType>
79+
<xs:simpleType>
80+
<xs:restriction base="xs:string">
81+
<xs:minLength value="1"/>
82+
<xs:pattern value="[a-z]+[a-z_]+[a-z]+"/>
83+
</xs:restriction>
84+
</xs:simpleType>
85+
</xs:union>
7686
</xs:simpleType>
7787
</xs:attribute>
7888
</xs:complexType>

0 commit comments

Comments
 (0)