ui-layout-basic-controls.xsd 17 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
  3. targetNamespace="ui-layout-basic-controls"
  4. xmlns:tns="ui-layout-basic-controls"
  5. elementFormDefault="qualified"
  6. version="1.3">
  7. <!-- ENHANCEMENT: Control Instance Base Type with accessibility and data binding -->
  8. <xs:complexType name="BasicControlInstanceType" mixed="true">
  9. <xs:group ref="tns:BasicControlContentGroup" minOccurs="0" maxOccurs="unbounded"/>
  10. <!-- ENHANCEMENT: Data binding attributes -->
  11. <xs:attribute name="data-context" type="xs:string"/>
  12. <xs:attribute name="binding-path" type="xs:string"/>
  13. <xs:attribute name="command-binding" type="xs:string"/>
  14. <xs:attribute name="validation-rule" type="xs:string"/>
  15. <xs:attribute name="converter" type="xs:string"/>
  16. <xs:attribute name="binding-mode" type="tns:BindingModeEnum" default="TwoWay"/>
  17. <!-- ENHANCEMENT: Accessibility attributes -->
  18. <xs:attribute name="aria-label" type="xs:string"/>
  19. <xs:attribute name="aria-description" type="xs:string"/>
  20. <xs:attribute name="aria-role" type="xs:string"/>
  21. <xs:attribute name="aria-live" type="tns:AriaLiveEnum" default="off"/>
  22. <xs:attribute name="tab-index" type="xs:int" default="0"/>
  23. <xs:attribute name="access-key" type="xs:string"/>
  24. <xs:attribute name="high-contrast-support" type="xs:boolean" default="true"/>
  25. <xs:attribute name="screen-reader-text" type="xs:string"/>
  26. <!-- ENHANCEMENT: Version tracking -->
  27. <xs:attribute name="schema-version" type="xs:string" default="1.3"/>
  28. <xs:attribute name="platform-hint" type="tns:PlatformHintEnum" default="basic"/>
  29. <xs:anyAttribute processContents="lax"/>
  30. </xs:complexType>
  31. <!-- ENHANCEMENT: Binding Mode Enumeration -->
  32. <xs:simpleType name="BindingModeEnum">
  33. <xs:restriction base="xs:string">
  34. <xs:enumeration value="OneWay"/>
  35. <xs:enumeration value="TwoWay"/>
  36. <xs:enumeration value="OneTime"/>
  37. <xs:enumeration value="OneWayToSource"/>
  38. </xs:restriction>
  39. </xs:simpleType>
  40. <!-- ENHANCEMENT: ARIA Live Region Enumeration -->
  41. <xs:simpleType name="AriaLiveEnum">
  42. <xs:restriction base="xs:string">
  43. <xs:enumeration value="off"/>
  44. <xs:enumeration value="polite"/>
  45. <xs:enumeration value="assertive"/>
  46. </xs:restriction>
  47. </xs:simpleType>
  48. <!-- ENHANCEMENT: Platform Hint Enumeration -->
  49. <xs:simpleType name="PlatformHintEnum">
  50. <xs:restriction base="xs:string">
  51. <xs:enumeration value="basic"/>
  52. <xs:enumeration value="winforms"/>
  53. <xs:enumeration value="avalonia"/>
  54. <xs:enumeration value="kde"/>
  55. <xs:enumeration value="web"/>
  56. <xs:enumeration value="mobile"/>
  57. </xs:restriction>
  58. </xs:simpleType>
  59. <!-- Basic Control Content Group -->
  60. <xs:group name="BasicControlContentGroup">
  61. <xs:choice>
  62. <!-- Core Basic Controls -->
  63. <xs:element name="Label" type="tns:BasicControlInstanceType"/>
  64. <xs:element name="TextBox" type="tns:BasicControlInstanceType"/>
  65. <xs:element name="ComboBox" type="tns:BasicControlInstanceType"/>
  66. <xs:element name="Button" type="tns:BasicControlInstanceType"/>
  67. <xs:element name="Panel" type="tns:BasicControlInstanceType"/>
  68. <xs:element name="PopupPanel" type="tns:BasicControlInstanceType"/>
  69. <xs:element name="Menu" type="tns:BasicControlInstanceType"/>
  70. <xs:element name="ListView" type="tns:BasicControlInstanceType"/>
  71. <xs:element name="TreeView" type="tns:BasicControlInstanceType"/>
  72. <xs:element name="TabControl" type="tns:BasicControlInstanceType"/>
  73. <xs:element name="ButtonBar" type="tns:BasicControlInstanceType"/>
  74. <xs:element name="ListBox" type="tns:BasicControlInstanceType"/>
  75. <xs:element name="CheckBox" type="tns:BasicControlInstanceType"/>
  76. <xs:element name="RadioButton" type="tns:BasicControlInstanceType"/>
  77. <xs:element name="Image" type="tns:BasicControlInstanceType"/>
  78. <xs:element name="StatusBar" type="tns:BasicControlInstanceType"/>
  79. <xs:element name="ToolBar" type="tns:BasicControlInstanceType"/>
  80. <xs:element name="SplitPanel" type="tns:BasicControlInstanceType"/>
  81. <xs:element name="Separator" type="tns:BasicControlInstanceType"/>
  82. <!-- ENHANCEMENT: Additional controls -->
  83. <xs:element name="ProgressBar" type="tns:BasicControlInstanceType"/>
  84. <xs:element name="DatePicker" type="tns:BasicControlInstanceType"/>
  85. <xs:element name="NumericUpDown" type="tns:BasicControlInstanceType"/>
  86. <xs:element name="Slider" type="tns:BasicControlInstanceType"/>
  87. <!-- Structure Elements -->
  88. <xs:element name="FormField" type="tns:BasicControlInstanceType"/>
  89. <xs:element name="slot" type="tns:SlotType"/>
  90. <!-- Supporting Elements -->
  91. <xs:element name="menu-items" type="tns:MenuItemsType"/>
  92. <xs:element name="columns" type="tns:ColumnsType"/>
  93. <xs:element name="items" type="tns:ItemsType"/>
  94. <!-- ENHANCEMENT: Data binding and accessibility elements -->
  95. <xs:element name="data-binding" type="tns:DataBindingDetailsType"/>
  96. <xs:element name="accessibility" type="tns:AccessibilityDetailsType"/>
  97. <!-- ENHANCEMENT: Conditional visibility elements -->
  98. <xs:element name="conditional-visibility" type="tns:ConditionalVisibilityType"/>
  99. </xs:choice>
  100. </xs:group>
  101. <!-- ENHANCEMENT: Enhanced Slot Definition with v1.3 features -->
  102. <xs:complexType name="SlotType">
  103. <xs:complexContent>
  104. <xs:extension base="tns:BasicControlInstanceType">
  105. <xs:attribute name="name" type="xs:string" use="required"/>
  106. <xs:attribute name="allowed-controls" type="xs:string"/>
  107. <xs:attribute name="required" type="xs:boolean" default="false"/>
  108. <xs:attribute name="default" type="xs:boolean" default="false"/>
  109. <!-- ENHANCEMENT: Accessibility and validation -->
  110. <xs:attribute name="accessibility-landmark" type="xs:string"/>
  111. <xs:attribute name="data-validation" type="xs:string"/>
  112. <!-- ENHANCEMENT: v1.3 conditional visibility -->
  113. <xs:attribute name="visibility-binding" type="xs:string"/>
  114. <xs:attribute name="visibility-value" type="xs:string"/>
  115. <xs:attribute name="visibility-converter" type="xs:string"/>
  116. </xs:extension>
  117. </xs:complexContent>
  118. </xs:complexType>
  119. <!-- ENHANCEMENT: Conditional Visibility Type -->
  120. <xs:complexType name="ConditionalVisibilityType">
  121. <xs:sequence>
  122. <xs:element name="condition" type="tns:VisibilityConditionType" maxOccurs="unbounded"/>
  123. </xs:sequence>
  124. </xs:complexType>
  125. <xs:complexType name="VisibilityConditionType">
  126. <xs:attribute name="property" type="xs:string" use="required"/>
  127. <xs:attribute name="operator" type="tns:ComparisonOperatorEnum" use="required"/>
  128. <xs:attribute name="value" type="xs:string" use="required"/>
  129. <xs:attribute name="logic" type="tns:LogicOperatorEnum" default="AND"/>
  130. </xs:complexType>
  131. <xs:simpleType name="ComparisonOperatorEnum">
  132. <xs:restriction base="xs:string">
  133. <xs:enumeration value="Equals"/>
  134. <xs:enumeration value="NotEquals"/>
  135. <xs:enumeration value="GreaterThan"/>
  136. <xs:enumeration value="LessThan"/>
  137. <xs:enumeration value="GreaterThanOrEqual"/>
  138. <xs:enumeration value="LessThanOrEqual"/>
  139. <xs:enumeration value="Contains"/>
  140. <xs:enumeration value="StartsWith"/>
  141. <xs:enumeration value="EndsWith"/>
  142. <xs:enumeration value="IsNull"/>
  143. <xs:enumeration value="IsNotNull"/>
  144. </xs:restriction>
  145. </xs:simpleType>
  146. <xs:simpleType name="LogicOperatorEnum">
  147. <xs:restriction base="xs:string">
  148. <xs:enumeration value="AND"/>
  149. <xs:enumeration value="OR"/>
  150. <xs:enumeration value="NOT"/>
  151. </xs:restriction>
  152. </xs:simpleType>
  153. <!-- ENHANCEMENT: Data Binding Details -->
  154. <xs:complexType name="DataBindingDetailsType">
  155. <xs:sequence>
  156. <xs:element name="binding" type="tns:BindingDetailType" maxOccurs="unbounded"/>
  157. </xs:sequence>
  158. </xs:complexType>
  159. <xs:complexType name="BindingDetailType">
  160. <xs:attribute name="property" type="xs:string" use="required"/>
  161. <xs:attribute name="source-path" type="xs:string" use="required"/>
  162. <xs:attribute name="mode" type="tns:BindingModeEnum" default="TwoWay"/>
  163. <xs:attribute name="converter" type="xs:string"/>
  164. <xs:attribute name="validation-rule" type="xs:string"/>
  165. <xs:attribute name="update-trigger" type="tns:UpdateTriggerEnum" default="PropertyChanged"/>
  166. <xs:attribute name="fallback-value" type="xs:string"/>
  167. <xs:attribute name="target-null-value" type="xs:string"/>
  168. </xs:complexType>
  169. <xs:simpleType name="UpdateTriggerEnum">
  170. <xs:restriction base="xs:string">
  171. <xs:enumeration value="PropertyChanged"/>
  172. <xs:enumeration value="LostFocus"/>
  173. <xs:enumeration value="Explicit"/>
  174. <xs:enumeration value="SourceUpdated"/>
  175. </xs:restriction>
  176. </xs:simpleType>
  177. <!-- ENHANCEMENT: Accessibility Details -->
  178. <xs:complexType name="AccessibilityDetailsType">
  179. <xs:sequence>
  180. <xs:element name="screen-reader" type="tns:ScreenReaderDetailsType" minOccurs="0"/>
  181. <xs:element name="keyboard-support" type="tns:KeyboardSupportType" minOccurs="0"/>
  182. <xs:element name="visual-support" type="tns:VisualSupportType" minOccurs="0"/>
  183. <xs:element name="interaction-support" type="tns:InteractionSupportType" minOccurs="0"/>
  184. </xs:sequence>
  185. </xs:complexType>
  186. <xs:complexType name="ScreenReaderDetailsType">
  187. <xs:attribute name="label" type="xs:string"/>
  188. <xs:attribute name="description" type="xs:string"/>
  189. <xs:attribute name="role" type="xs:string"/>
  190. <xs:attribute name="live-region" type="tns:AriaLiveEnum" default="off"/>
  191. <xs:attribute name="owns" type="xs:string"/>
  192. <xs:attribute name="controls" type="xs:string"/>
  193. <xs:attribute name="described-by" type="xs:string"/>
  194. <xs:attribute name="labelled-by" type="xs:string"/>
  195. </xs:complexType>
  196. <xs:complexType name="KeyboardSupportType">
  197. <xs:attribute name="tab-stop" type="xs:boolean" default="true"/>
  198. <xs:attribute name="tab-index" type="xs:int" default="0"/>
  199. <xs:attribute name="access-key" type="xs:string"/>
  200. <xs:attribute name="shortcut-key" type="xs:string"/>
  201. <xs:attribute name="focus-on-click" type="xs:boolean" default="true"/>
  202. <xs:attribute name="escape-key-handler" type="xs:string"/>
  203. <xs:attribute name="enter-key-handler" type="xs:string"/>
  204. </xs:complexType>
  205. <xs:complexType name="VisualSupportType">
  206. <xs:attribute name="high-contrast" type="xs:boolean" default="true"/>
  207. <xs:attribute name="font-size-scale" type="xs:boolean" default="true"/>
  208. <xs:attribute name="color-blind-safe" type="xs:boolean" default="true"/>
  209. <xs:attribute name="animation-reduce" type="xs:boolean" default="false"/>
  210. <xs:attribute name="transparency-support" type="xs:boolean" default="true"/>
  211. </xs:complexType>
  212. <!-- ENHANCEMENT: New Interaction Support Type -->
  213. <xs:complexType name="InteractionSupportType">
  214. <xs:attribute name="touch-support" type="xs:boolean" default="false"/>
  215. <xs:attribute name="gesture-support" type="xs:boolean" default="false"/>
  216. <xs:attribute name="voice-control" type="xs:boolean" default="false"/>
  217. <xs:attribute name="eye-tracking" type="xs:boolean" default="false"/>
  218. <xs:attribute name="minimum-target-size" type="xs:int" default="44"/>
  219. </xs:complexType>
  220. <!-- ENHANCEMENT: Enhanced Supporting Types -->
  221. <xs:complexType name="MenuItemsType">
  222. <xs:sequence>
  223. <xs:element name="menu-item" maxOccurs="unbounded">
  224. <xs:complexType>
  225. <xs:sequence>
  226. <xs:element name="menu-items" type="tns:MenuItemsType" minOccurs="0"/>
  227. </xs:sequence>
  228. <xs:attribute name="text" type="xs:string" use="required"/>
  229. <xs:attribute name="action" type="xs:string"/>
  230. <xs:attribute name="separator" type="xs:boolean" default="false"/>
  231. <!-- ENHANCEMENT: Command binding and accessibility -->
  232. <xs:attribute name="shortcut-key" type="xs:string"/>
  233. <xs:attribute name="command-binding" type="xs:string"/>
  234. <xs:attribute name="command-parameter" type="xs:string"/>
  235. <xs:attribute name="aria-label" type="xs:string"/>
  236. <xs:attribute name="icon" type="xs:string"/>
  237. <xs:attribute name="enabled" type="xs:boolean" default="true"/>
  238. <xs:attribute name="visible" type="xs:boolean" default="true"/>
  239. <!-- ENHANCEMENT: v1.3 conditional visibility -->
  240. <xs:attribute name="visibility-binding" type="xs:string"/>
  241. <xs:attribute name="enabled-binding" type="xs:string"/>
  242. </xs:complexType>
  243. </xs:element>
  244. </xs:sequence>
  245. <xs:attribute name="orientation" type="tns:OrientationEnum" default="vertical"/>
  246. </xs:complexType>
  247. <xs:simpleType name="OrientationEnum">
  248. <xs:restriction base="xs:string">
  249. <xs:enumeration value="horizontal"/>
  250. <xs:enumeration value="vertical"/>
  251. </xs:restriction>
  252. </xs:simpleType>
  253. <xs:complexType name="ColumnsType">
  254. <xs:sequence>
  255. <xs:element name="column" maxOccurs="unbounded">
  256. <xs:complexType>
  257. <xs:attribute name="name" type="xs:string" use="required"/>
  258. <xs:attribute name="text" type="xs:string" use="required"/>
  259. <xs:attribute name="width" type="xs:string"/>
  260. <xs:attribute name="sortable" type="xs:boolean" default="true"/>
  261. <!-- ENHANCEMENT: Data binding and accessibility -->
  262. <xs:attribute name="data-type" type="tns:DataTypeEnum" default="string"/>
  263. <xs:attribute name="binding-path" type="xs:string"/>
  264. <xs:attribute name="converter" type="xs:string"/>
  265. <xs:attribute name="sort-member-path" type="xs:string"/>
  266. <xs:attribute name="aria-label" type="xs:string"/>
  267. <xs:attribute name="format-string" type="xs:string"/>
  268. <xs:attribute name="alignment" type="tns:AlignmentEnum" default="left"/>
  269. <xs:attribute name="visible" type="xs:boolean" default="true"/>
  270. <xs:attribute name="resizable" type="xs:boolean" default="true"/>
  271. <xs:attribute name="frozen" type="xs:boolean" default="false"/>
  272. </xs:complexType>
  273. </xs:element>
  274. </xs:sequence>
  275. </xs:complexType>
  276. <xs:simpleType name="DataTypeEnum">
  277. <xs:restriction base="xs:string">
  278. <xs:enumeration value="string"/>
  279. <xs:enumeration value="int"/>
  280. <xs:enumeration value="decimal"/>
  281. <xs:enumeration value="double"/>
  282. <xs:enumeration value="float"/>
  283. <xs:enumeration value="boolean"/>
  284. <xs:enumeration value="date"/>
  285. <xs:enumeration value="datetime"/>
  286. <xs:enumeration value="timespan"/>
  287. <xs:enumeration value="currency"/>
  288. <xs:enumeration value="percentage"/>
  289. <xs:enumeration value="image"/>
  290. <xs:enumeration value="hyperlink"/>
  291. <xs:enumeration value="custom"/>
  292. </xs:restriction>
  293. </xs:simpleType>
  294. <xs:simpleType name="AlignmentEnum">
  295. <xs:restriction base="xs:string">
  296. <xs:enumeration value="left"/>
  297. <xs:enumeration value="center"/>
  298. <xs:enumeration value="right"/>
  299. <xs:enumeration value="justify"/>
  300. <xs:enumeration value="stretch"/>
  301. </xs:restriction>
  302. </xs:simpleType>
  303. <xs:complexType name="ItemsType">
  304. <xs:sequence>
  305. <xs:element name="item" maxOccurs="unbounded">
  306. <xs:complexType>
  307. <xs:attribute name="value" type="xs:string"/>
  308. <xs:attribute name="text" type="xs:string"/>
  309. <!-- ENHANCEMENT: Data binding and accessibility -->
  310. <xs:attribute name="data-context" type="xs:string"/>
  311. <xs:attribute name="command-parameter" type="xs:string"/>
  312. <xs:attribute name="aria-label" type="xs:string"/>
  313. <xs:attribute name="icon" type="xs:string"/>
  314. <xs:attribute name="tooltip" type="xs:string"/>
  315. <xs:attribute name="enabled" type="xs:boolean" default="true"/>
  316. <xs:attribute name="visible" type="xs:boolean" default="true"/>
  317. <xs:attribute name="selected" type="xs:boolean" default="false"/>
  318. <xs:attribute name="group" type="xs:string"/>
  319. <xs:attribute name="sort-order" type="xs:int" default="0"/>
  320. </xs:complexType>
  321. </xs:element>
  322. </xs:sequence>
  323. <!-- ENHANCEMENT: Collection-level data binding -->
  324. <xs:attribute name="items-source" type="xs:string"/>
  325. <xs:attribute name="display-member-path" type="xs:string"/>
  326. <xs:attribute name="value-member-path" type="xs:string"/>
  327. <xs:attribute name="selected-value-path" type="xs:string"/>
  328. <xs:attribute name="group-member-path" type="xs:string"/>
  329. <xs:attribute name="sort-member-path" type="xs:string"/>
  330. <xs:attribute name="filter-expression" type="xs:string"/>
  331. </xs:complexType>
  332. </xs:schema>