default namespace = "http://www.xmlmind.com/xmleditor/schema/bugreport"
namespace ns = "http://relaxng.org/ns/structure/1.0"

include "xhtml-strict.rnc" {
  start = bugReports
}
bugReports = element bugReports { comments?, bugReport+ }
comments = element comments { body }
bugReport =
  element bugReport {
    element product { nonEmptyToken },
    element version {
      xsd:token { pattern = "\d+\.\d+((b|p)\d+)?" }
    },
    element platform {
      element windowsNT { empty }
      | element windows2000 { empty }
      | element windowsXP { empty }
      | element macOSX { empty }
      | element linux { empty }
      | element other { nonEmptyToken }
    },
    element javaRuntime { nonEmptyToken },
    element submittedBy {
      xsd:token { pattern = "[^\s@]+@\S+" }
    },
    element date { xsd:date },
    element screenShot {
      attribute image { xsd:anyURI }
      & description?
    }*,
    description,
    element workaround { body }?
  }
description = element description { body }
nonEmptyToken = xsd:token { minLength = "1" }
