<?xml version="1.0" encoding="UTF-8"?>
<xs:schema 
  attributeFormDefault="unqualified" 
  elementFormDefault="qualified" 
  xmlns:xs="http://www.w3.org/2001/XMLSchema"  
  targetNamespace="http://schemas.microsoft.com/msix/appinstallerux" 
  xmlns="http://schemas.microsoft.com/msix/appinstallerux"
  xmlns:ux="http://schemas.microsoft.com/msix/appinstallerux"
  xmlns:t="http://schemas.microsoft.com/msix/appinstallerux/types"
  >

  <xs:import namespace="http://schemas.microsoft.com/msix/appinstallerux/types"/>
  
  <xs:element name="AppInstallerUX">
    <xs:complexType>
      <xs:all>
        <xs:element name="UX" minOccurs="0" maxOccurs="1" >
          <xs:complexType >
            <xs:all>
              <xs:element name="Icon" minOccurs="0" maxOccurs="1" >
                <xs:complexType >
                  <xs:attribute name="HorizontalAlignment" type="t:ST_HorizontalAlignment" use="optional" />
                  <xs:attribute name="Size" type="t:ST_Size" use="optional" />
                  <xs:attribute name="Logo" type="t:ST_ImageFile" use="optional" />
                  <xs:attribute name="TopMargin" type="xs:unsignedByte" use="optional" />
                </xs:complexType>
              </xs:element>

              <xs:element name="Buttons" minOccurs="0" maxOccurs="1" >
                <xs:complexType >
                  <xs:attribute name="HorizontalAlignment" type="t:ST_HorizontalAlignment" use="optional" />
                  <xs:attribute name="PrimaryButtonMode" type="t:ST_ButtonMode" use="optional" />
                  <xs:attribute name="SecondaryButtonMode" type="t:ST_ButtonMode" use="optional" />
                  <xs:attribute name="IsSecondaryButtonAccent" type="xs:boolean" use="optional" />
                  <xs:attribute name="Orientation" type="t:ST_Orientation" use="optional" />
                  <xs:attribute name="Text" type="t:ST_DisplayName" use="optional"/>
                </xs:complexType>
              </xs:element>

              <xs:element name="LaunchWhenReady" minOccurs="0" maxOccurs="1" >
                <xs:complexType >
                  <xs:attribute name="HorizontalAlignment" type="t:ST_HorizontalAlignment" use="optional" />
                </xs:complexType>
              </xs:element>

              <xs:element name="AppInformation" minOccurs="0" maxOccurs="1" >
                <xs:complexType >
                  <xs:attribute name="Mode" type="t:ST_Mode" use="optional" />
                </xs:complexType>
              </xs:element>

              <xs:element name="HyperLinks" minOccurs="0" maxOccurs="1" >
                <xs:complexType >
                  <xs:sequence minOccurs="0" maxOccurs="2">
                    <xs:element name="HyperLink">
                      <xs:complexType >
                        <xs:attribute name="Text" type="t:ST_DisplayName" />
                        <xs:attribute name="Url" type="t:ST_HttpHyperLinkUri" use="optional"/>
                        <xs:attribute name="ResourceUrl" type="t:ST_DisplayName" use="optional"/>
                        <xs:attribute name="HorizontalAlignment" type="t:ST_HorizontalAlignment" use="optional" />
                      </xs:complexType>
                    </xs:element>
                  </xs:sequence>
                  <xs:attribute name="TopMargin" type="xs:unsignedByte" use="optional" />
                </xs:complexType>
              </xs:element>
              
            </xs:all>
            <xs:attribute name="AccentColor" type="t:ST_Color" use="optional" />
            <xs:attribute name="BackgroundColor" type="t:ST_Color" use="optional" />
            <xs:attribute name="FontFamily" type="t:ST_DisplayName" use="optional" />
            <xs:attribute name="AllowUserInteraction" type="xs:boolean" use="optional" />
            <xs:attribute name="AppNameInTitle" type="xs:boolean" use="optional" />
            <xs:attribute name="HyperLinkFontSize" type="xs:unsignedByte" use="optional" />
          </xs:complexType>
        </xs:element>
      </xs:all>
      
      <xs:attribute name="Version" type="t:ST_VersionDuoOrTrio" use="required" />
      <xs:attribute name="IgnorableNamespaces" type="t:ST_NonEmptyString" use="optional" />   
    </xs:complexType>
    
  </xs:element>
  
</xs:schema>