<?xml version="1.0" encoding="UTF-8" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
  <xs:element name="page">
    <xs:complexType>
      <xs:complexContent>
        <xs:extension base="contents">
          <xs:attribute name="href" type="xs:string" use="required"/>
          <xs:attribute name="lang" type="xs:language"/>
        </xs:extension>
      </xs:complexContent>
    </xs:complexType>
  </xs:element>

  <xs:complexType name="contents">
    <xs:sequence>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="section" type="section"/>
        <xs:element name="link" type="link"/>
        <xs:element name="markdown">
          <xs:complexType>
            <xs:simpleContent>
              <xs:extension base="xs:string"/>
            </xs:simpleContent>
          </xs:complexType>
        </xs:element>
        <xs:element name="rows" type="table"/>
      </xs:choice>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="table">
    <xs:sequence>
      <xs:element name="columns" type="contents" maxOccurs="unbounded" minOccurs="0"/>
    </xs:sequence>
  </xs:complexType>

  <xs:complexType name="section">
    <xs:complexContent>
      <xs:extension base="contents">
        <xs:attribute name="title" type="xs:string" use="required"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>

  <xs:complexType name="link">
    <xs:complexContent>
      <xs:extension base="xs:normalizedString">
        <xs:attribute name="icon" type="xs:string" use="required"/>
        <xs:attribute name="href" type="xs:string" use="required"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
</xs:schema>
