view-contracts 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +297 -0
- package/cli-contract.yaml +201 -0
- package/dist/view-contracts.bundle.mjs +808 -0
- package/dist/view-contracts.bundle.mjs.map +7 -0
- package/docs/cli-reference.md +239 -0
- package/package.json +94 -0
- package/renderers/compose/README.md +8 -0
- package/renderers/react/README.md +10 -0
- package/renderers/react/routes.yaml +27 -0
- package/renderers/swiftui/README.md +8 -0
- package/spec/ui-dsl.linter-rules.json +90 -0
- package/spec/ui-dsl.meta.json +113 -0
- package/spec/ui-dsl.schema.json +738 -0
- package/src/generated/schema/allowed-components.ts +36 -0
- package/src/generated/schema/dsl-properties.ts +63 -0
- package/src/generated/schema/index.ts +4 -0
- package/src/generated/schema/schema-document.ts +33 -0
- package/src/generated/schema/tokens.ts +19 -0
- package/src/renderer/react/runtime/actionRuntime.ts +26 -0
- package/src/renderer/react/runtime/components.tsx +216 -0
- package/src/renderer/react/runtime/index.ts +4 -0
- package/src/renderer/react/runtime/shared.tsx +53 -0
- package/src/renderer/react/runtime/style.ts +69 -0
- package/src/renderer/react/runtime/theme.css +68 -0
- package/src/renderer/react/runtime/types.ts +46 -0
|
@@ -0,0 +1,738 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "./ui-dsl.meta.json",
|
|
3
|
+
"tokens": {
|
|
4
|
+
"role": ["button", "link", "heading", "list", "listitem", "main", "dialog", "status"],
|
|
5
|
+
"widthSize": ["wrap", "fill"],
|
|
6
|
+
"heightSize": ["wrap", "fill"],
|
|
7
|
+
"align": ["start", "center", "end", "stretch"],
|
|
8
|
+
"justify": ["start", "center", "end", "spaceBetween", "spaceAround", "spaceEvenly"],
|
|
9
|
+
"contentAlign": ["topStart", "top", "topEnd", "start", "center", "end", "bottomStart", "bottom", "bottomEnd"],
|
|
10
|
+
"axis": ["vertical", "horizontal"],
|
|
11
|
+
"direction": ["ltr", "rtl", "system"],
|
|
12
|
+
"scroll": ["none", "vertical", "horizontal", "both"],
|
|
13
|
+
"border": ["none"],
|
|
14
|
+
"shadow": ["none", "sm", "md", "lg"],
|
|
15
|
+
"textAlign": ["start", "center", "end"],
|
|
16
|
+
"lineLimit": ["none"],
|
|
17
|
+
"textOverflow": ["clip", "ellipsis"],
|
|
18
|
+
"fontWeight": ["regular", "medium", "bold"],
|
|
19
|
+
"imageFit": ["contain", "cover", "fill", "none"],
|
|
20
|
+
"keyboardType": ["text", "number", "email", "url", "password", "tel"],
|
|
21
|
+
"clip": ["none", "bounds", "shape"]
|
|
22
|
+
},
|
|
23
|
+
"properties": {
|
|
24
|
+
"id": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"x-category": "identity",
|
|
27
|
+
"description": "Stable identifier for tests and diff updates"
|
|
28
|
+
},
|
|
29
|
+
"role": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"enum": "role",
|
|
32
|
+
"x-category": "identity",
|
|
33
|
+
"description": "Accessibility semantics (not HTML tag names)"
|
|
34
|
+
},
|
|
35
|
+
"label": {
|
|
36
|
+
"type": "string",
|
|
37
|
+
"x-category": "identity",
|
|
38
|
+
"description": "Accessible name; required for IconButton"
|
|
39
|
+
},
|
|
40
|
+
"visible": {
|
|
41
|
+
"type": "boolean",
|
|
42
|
+
"x-category": "state",
|
|
43
|
+
"description": "Show or omit from render tree"
|
|
44
|
+
},
|
|
45
|
+
"enabled": {
|
|
46
|
+
"type": "boolean",
|
|
47
|
+
"x-category": "state",
|
|
48
|
+
"x-appliesTo": ["Button", "IconButton", "TextInput", "TextArea", "Select", "Checkbox", "Radio", "Switch"]
|
|
49
|
+
},
|
|
50
|
+
"selected": {
|
|
51
|
+
"type": "boolean",
|
|
52
|
+
"x-category": "state",
|
|
53
|
+
"x-appliesTo": ["ListItem"]
|
|
54
|
+
},
|
|
55
|
+
"checked": {
|
|
56
|
+
"type": "boolean",
|
|
57
|
+
"x-category": "state",
|
|
58
|
+
"x-appliesTo": ["Checkbox", "Radio", "Switch"]
|
|
59
|
+
},
|
|
60
|
+
"readonly": {
|
|
61
|
+
"type": "boolean",
|
|
62
|
+
"x-category": "state",
|
|
63
|
+
"x-appliesTo": ["TextInput", "TextArea"]
|
|
64
|
+
},
|
|
65
|
+
"required": {
|
|
66
|
+
"type": "boolean",
|
|
67
|
+
"x-category": "state",
|
|
68
|
+
"x-appliesTo": ["TextInput", "TextArea", "Select", "Checkbox", "Field"]
|
|
69
|
+
},
|
|
70
|
+
"width": {
|
|
71
|
+
"type": ["string", "number"],
|
|
72
|
+
"enum": "widthSize",
|
|
73
|
+
"x-category": "size",
|
|
74
|
+
"x-notes": "string: wrap|fill; number: fixed px/dp/pt; flex ratio uses weight property"
|
|
75
|
+
},
|
|
76
|
+
"height": {
|
|
77
|
+
"type": ["string", "number"],
|
|
78
|
+
"enum": "heightSize",
|
|
79
|
+
"x-category": "size",
|
|
80
|
+
"x-notes": "string: wrap|fill; number: fixed px/dp/pt; flex ratio uses weight property"
|
|
81
|
+
},
|
|
82
|
+
"minWidth": { "type": "number", "x-category": "size" },
|
|
83
|
+
"maxWidth": { "type": ["string", "number"], "x-category": "size", "x-notes": "number or fill" },
|
|
84
|
+
"minHeight": { "type": "number", "x-category": "size" },
|
|
85
|
+
"maxHeight": { "type": ["string", "number"], "x-category": "size", "x-notes": "number or fill" },
|
|
86
|
+
"aspectRatio": { "type": "number", "x-category": "size", "x-appliesTo": ["Image"] },
|
|
87
|
+
"weight": {
|
|
88
|
+
"type": "number",
|
|
89
|
+
"x-category": "size",
|
|
90
|
+
"x-notes": "Flex ratio among Row/Column direct children; Spacer is the primary use case"
|
|
91
|
+
},
|
|
92
|
+
"padding": { "type": ["string", "number"], "x-category": "spacing", "x-notes": "space token or per-side" },
|
|
93
|
+
"gap": {
|
|
94
|
+
"type": ["string", "number"],
|
|
95
|
+
"x-category": "spacing",
|
|
96
|
+
"x-appliesTo": ["Row", "Column", "List"]
|
|
97
|
+
},
|
|
98
|
+
"align": {
|
|
99
|
+
"type": "string",
|
|
100
|
+
"enum": "align",
|
|
101
|
+
"x-category": "alignment",
|
|
102
|
+
"x-appliesTo": ["Row", "Column"]
|
|
103
|
+
},
|
|
104
|
+
"justify": {
|
|
105
|
+
"type": "string",
|
|
106
|
+
"enum": "justify",
|
|
107
|
+
"x-category": "alignment",
|
|
108
|
+
"x-appliesTo": ["Row", "Column"]
|
|
109
|
+
},
|
|
110
|
+
"selfAlign": { "type": "string", "enum": "align", "x-category": "alignment" },
|
|
111
|
+
"contentAlign": {
|
|
112
|
+
"type": "string",
|
|
113
|
+
"enum": "contentAlign",
|
|
114
|
+
"x-category": "alignment",
|
|
115
|
+
"x-appliesTo": ["Box", "Stack"]
|
|
116
|
+
},
|
|
117
|
+
"axis": {
|
|
118
|
+
"type": "string",
|
|
119
|
+
"enum": "axis",
|
|
120
|
+
"x-category": "direction",
|
|
121
|
+
"x-appliesTo": ["ScrollArea", "List", "Divider"]
|
|
122
|
+
},
|
|
123
|
+
"direction": {
|
|
124
|
+
"type": "string",
|
|
125
|
+
"enum": "direction",
|
|
126
|
+
"x-category": "direction",
|
|
127
|
+
"x-appliesTo": ["App", "Page"],
|
|
128
|
+
"description": "Text/layout direction; set at app or screen root, not per layout container"
|
|
129
|
+
},
|
|
130
|
+
"scroll": {
|
|
131
|
+
"type": "string",
|
|
132
|
+
"enum": "scroll",
|
|
133
|
+
"x-category": "overflow",
|
|
134
|
+
"x-appliesTo": ["ScrollArea"]
|
|
135
|
+
},
|
|
136
|
+
"background": { "type": "string", "x-category": "visual", "x-notes": "color token" },
|
|
137
|
+
"foreground": {
|
|
138
|
+
"type": "string",
|
|
139
|
+
"x-category": "visual",
|
|
140
|
+
"x-appliesTo": ["Text", "Icon", "Button"],
|
|
141
|
+
"x-notes": "color token"
|
|
142
|
+
},
|
|
143
|
+
"border": { "type": ["string", "object"], "enum": "border", "x-category": "visual", "x-notes": "none|token|{width,color}" },
|
|
144
|
+
"radius": { "type": "string", "x-category": "visual", "x-notes": "radius token" },
|
|
145
|
+
"shadow": { "type": "string", "enum": "shadow", "x-category": "visual" },
|
|
146
|
+
"opacity": { "type": "number", "x-category": "visual", "x-notes": "0..1" },
|
|
147
|
+
"clip": { "type": "string", "enum": "clip", "x-category": "visual" },
|
|
148
|
+
"textStyle": { "type": "string", "x-category": "text", "x-appliesTo": ["Text", "Heading"], "x-notes": "typography token" },
|
|
149
|
+
"textAlign": { "type": "string", "enum": "textAlign", "x-category": "text", "x-appliesTo": ["Text", "Heading"] },
|
|
150
|
+
"lineLimit": { "type": ["string", "number"], "enum": "lineLimit", "x-category": "text", "x-appliesTo": ["Text"] },
|
|
151
|
+
"textOverflow": { "type": "string", "enum": "textOverflow", "x-category": "text", "x-appliesTo": ["Text"] },
|
|
152
|
+
"fontWeight": { "type": "string", "enum": "fontWeight", "x-category": "text", "x-appliesTo": ["Text"] },
|
|
153
|
+
"headingLevel": {
|
|
154
|
+
"type": "number",
|
|
155
|
+
"x-category": "text",
|
|
156
|
+
"x-appliesTo": ["Heading"],
|
|
157
|
+
"description": "Semantic heading level (1–6) for h1/h2 mapping and accessibility hierarchy"
|
|
158
|
+
},
|
|
159
|
+
"fit": { "type": "string", "enum": "imageFit", "x-category": "image", "x-appliesTo": ["Image"] },
|
|
160
|
+
"src": {
|
|
161
|
+
"type": "string",
|
|
162
|
+
"x-category": "image",
|
|
163
|
+
"x-appliesTo": ["Image"],
|
|
164
|
+
"description": "Image source URL or asset reference"
|
|
165
|
+
},
|
|
166
|
+
"alt": { "type": "string", "x-category": "image", "x-appliesTo": ["Image", "Icon"], "description": "Alternative text; not a source reference" },
|
|
167
|
+
"name": {
|
|
168
|
+
"type": "string",
|
|
169
|
+
"x-category": "image",
|
|
170
|
+
"x-appliesTo": ["Icon"],
|
|
171
|
+
"description": "Icon token or asset name in the renderer icon set"
|
|
172
|
+
},
|
|
173
|
+
"onClick": {
|
|
174
|
+
"type": "action",
|
|
175
|
+
"x-category": "interaction",
|
|
176
|
+
"x-appliesTo": ["Button", "IconButton", "Link"],
|
|
177
|
+
"description": "Action id, not arbitrary code"
|
|
178
|
+
},
|
|
179
|
+
"onSubmit": {
|
|
180
|
+
"type": "action",
|
|
181
|
+
"x-category": "interaction",
|
|
182
|
+
"x-appliesTo": ["Form"],
|
|
183
|
+
"description": "Form submit/validation action id"
|
|
184
|
+
},
|
|
185
|
+
"onChange": {
|
|
186
|
+
"type": "action",
|
|
187
|
+
"x-category": "interaction",
|
|
188
|
+
"x-appliesTo": ["TextInput", "TextArea", "Select", "Checkbox", "Radio", "Switch"]
|
|
189
|
+
},
|
|
190
|
+
"focusable": { "type": "boolean", "x-category": "interaction" },
|
|
191
|
+
"autoFocus": {
|
|
192
|
+
"type": "boolean",
|
|
193
|
+
"x-category": "interaction",
|
|
194
|
+
"x-appliesTo": ["Modal", "TextInput"]
|
|
195
|
+
},
|
|
196
|
+
"keyboardType": {
|
|
197
|
+
"type": "string",
|
|
198
|
+
"enum": "keyboardType",
|
|
199
|
+
"x-category": "interaction",
|
|
200
|
+
"x-appliesTo": ["TextInput"]
|
|
201
|
+
},
|
|
202
|
+
"value": {
|
|
203
|
+
"type": ["string", "number", "boolean"],
|
|
204
|
+
"x-category": "data",
|
|
205
|
+
"x-appliesTo": ["TextInput", "TextArea", "Select", "Radio", "Checkbox", "Switch"]
|
|
206
|
+
},
|
|
207
|
+
"binding": {
|
|
208
|
+
"type": "string",
|
|
209
|
+
"x-category": "data",
|
|
210
|
+
"x-appliesTo": ["TextInput", "TextArea", "Select", "Checkbox", "Radio", "Switch"],
|
|
211
|
+
"description": "ViewModel or form state field identifier"
|
|
212
|
+
},
|
|
213
|
+
"placeholder": { "type": "string", "x-category": "data", "x-appliesTo": ["TextInput", "TextArea"] },
|
|
214
|
+
"options": {
|
|
215
|
+
"type": "array",
|
|
216
|
+
"x-category": "data",
|
|
217
|
+
"x-appliesTo": ["Select"],
|
|
218
|
+
"x-notes": "array<{value,label}>"
|
|
219
|
+
},
|
|
220
|
+
"error": {
|
|
221
|
+
"type": ["string", "null"],
|
|
222
|
+
"x-category": "validation",
|
|
223
|
+
"x-appliesTo": ["Field", "TextInput", "TextArea", "Select"]
|
|
224
|
+
},
|
|
225
|
+
"help": {
|
|
226
|
+
"type": ["string", "null"],
|
|
227
|
+
"x-category": "validation",
|
|
228
|
+
"x-appliesTo": ["Field", "TextInput", "TextArea", "Select"]
|
|
229
|
+
},
|
|
230
|
+
"variant": { "type": "string", "x-category": "visual", "x-notes": "design token variant" }
|
|
231
|
+
},
|
|
232
|
+
"elements": {
|
|
233
|
+
"App": {
|
|
234
|
+
"x-tier": "core",
|
|
235
|
+
"x-category": "structure",
|
|
236
|
+
"description": "App root; holds theme/token/navigation context",
|
|
237
|
+
"x-notes": "Optional; not required for single-screen DSL",
|
|
238
|
+
"properties": {
|
|
239
|
+
"id": { "$ref": "#/properties/id" },
|
|
240
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
241
|
+
"direction": { "$ref": "#/properties/direction" }
|
|
242
|
+
},
|
|
243
|
+
"_children": { "x-kind": "list", "x-items": ["Page"] }
|
|
244
|
+
},
|
|
245
|
+
"Page": {
|
|
246
|
+
"x-tier": "core",
|
|
247
|
+
"x-category": "structure",
|
|
248
|
+
"description": "Screen root; viewport and safe-area boundary",
|
|
249
|
+
"properties": {
|
|
250
|
+
"id": { "$ref": "#/properties/id" },
|
|
251
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
252
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
253
|
+
"direction": { "$ref": "#/properties/direction" }
|
|
254
|
+
},
|
|
255
|
+
"_children": { "x-kind": "list", "x-items": ["Column", "Row", "Stack", "Box"] }
|
|
256
|
+
},
|
|
257
|
+
"SafeArea": {
|
|
258
|
+
"x-tier": "core",
|
|
259
|
+
"x-category": "structure",
|
|
260
|
+
"description": "Insets for OS/browser safe areas",
|
|
261
|
+
"properties": {
|
|
262
|
+
"id": { "$ref": "#/properties/id" },
|
|
263
|
+
"padding": { "$ref": "#/properties/padding" }
|
|
264
|
+
},
|
|
265
|
+
"_children": { "x-kind": "list", "x-items": ["Box", "Column", "Row"] }
|
|
266
|
+
},
|
|
267
|
+
"Box": {
|
|
268
|
+
"x-tier": "core",
|
|
269
|
+
"x-category": "layout",
|
|
270
|
+
"description": "Single region; background, bounds, child placement",
|
|
271
|
+
"properties": {
|
|
272
|
+
"id": { "$ref": "#/properties/id" },
|
|
273
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
274
|
+
"width": { "$ref": "#/properties/width" },
|
|
275
|
+
"height": { "$ref": "#/properties/height" },
|
|
276
|
+
"minWidth": { "$ref": "#/properties/minWidth" },
|
|
277
|
+
"maxWidth": { "$ref": "#/properties/maxWidth" },
|
|
278
|
+
"minHeight": { "$ref": "#/properties/minHeight" },
|
|
279
|
+
"maxHeight": { "$ref": "#/properties/maxHeight" },
|
|
280
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
281
|
+
"contentAlign": { "$ref": "#/properties/contentAlign" },
|
|
282
|
+
"background": { "$ref": "#/properties/background" },
|
|
283
|
+
"foreground": { "$ref": "#/properties/foreground" },
|
|
284
|
+
"border": { "$ref": "#/properties/border" },
|
|
285
|
+
"radius": { "$ref": "#/properties/radius" },
|
|
286
|
+
"shadow": { "$ref": "#/properties/shadow" },
|
|
287
|
+
"opacity": { "$ref": "#/properties/opacity" },
|
|
288
|
+
"clip": { "$ref": "#/properties/clip" },
|
|
289
|
+
"selfAlign": { "$ref": "#/properties/selfAlign" },
|
|
290
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
291
|
+
},
|
|
292
|
+
"_children": { "x-kind": "any" }
|
|
293
|
+
},
|
|
294
|
+
"Row": {
|
|
295
|
+
"x-tier": "core",
|
|
296
|
+
"x-category": "layout",
|
|
297
|
+
"description": "Horizontal child layout",
|
|
298
|
+
"properties": {
|
|
299
|
+
"id": { "$ref": "#/properties/id" },
|
|
300
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
301
|
+
"gap": { "$ref": "#/properties/gap" },
|
|
302
|
+
"align": { "$ref": "#/properties/align" },
|
|
303
|
+
"justify": { "$ref": "#/properties/justify" },
|
|
304
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
305
|
+
"width": { "$ref": "#/properties/width" },
|
|
306
|
+
"height": { "$ref": "#/properties/height" },
|
|
307
|
+
"minWidth": { "$ref": "#/properties/minWidth" },
|
|
308
|
+
"maxWidth": { "$ref": "#/properties/maxWidth" },
|
|
309
|
+
"minHeight": { "$ref": "#/properties/minHeight" },
|
|
310
|
+
"maxHeight": { "$ref": "#/properties/maxHeight" },
|
|
311
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
312
|
+
},
|
|
313
|
+
"_children": { "x-kind": "any" }
|
|
314
|
+
},
|
|
315
|
+
"Column": {
|
|
316
|
+
"x-tier": "core",
|
|
317
|
+
"x-category": "layout",
|
|
318
|
+
"description": "Vertical child layout",
|
|
319
|
+
"properties": {
|
|
320
|
+
"id": { "$ref": "#/properties/id" },
|
|
321
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
322
|
+
"gap": { "$ref": "#/properties/gap" },
|
|
323
|
+
"align": { "$ref": "#/properties/align" },
|
|
324
|
+
"justify": { "$ref": "#/properties/justify" },
|
|
325
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
326
|
+
"width": { "$ref": "#/properties/width" },
|
|
327
|
+
"height": { "$ref": "#/properties/height" },
|
|
328
|
+
"minWidth": { "$ref": "#/properties/minWidth" },
|
|
329
|
+
"maxWidth": { "$ref": "#/properties/maxWidth" },
|
|
330
|
+
"minHeight": { "$ref": "#/properties/minHeight" },
|
|
331
|
+
"maxHeight": { "$ref": "#/properties/maxHeight" },
|
|
332
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
333
|
+
},
|
|
334
|
+
"_children": { "x-kind": "any" }
|
|
335
|
+
},
|
|
336
|
+
"Stack": {
|
|
337
|
+
"x-tier": "core",
|
|
338
|
+
"x-category": "layout",
|
|
339
|
+
"description": "Overlay children by z-order (not absolute positioning)",
|
|
340
|
+
"properties": {
|
|
341
|
+
"id": { "$ref": "#/properties/id" },
|
|
342
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
343
|
+
"contentAlign": { "$ref": "#/properties/contentAlign" },
|
|
344
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
345
|
+
"width": { "$ref": "#/properties/width" },
|
|
346
|
+
"height": { "$ref": "#/properties/height" },
|
|
347
|
+
"background": { "$ref": "#/properties/background" },
|
|
348
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
349
|
+
},
|
|
350
|
+
"_children": { "x-kind": "any" }
|
|
351
|
+
},
|
|
352
|
+
"Spacer": {
|
|
353
|
+
"x-tier": "core",
|
|
354
|
+
"x-category": "layout",
|
|
355
|
+
"description": "Occupies remaining flex space",
|
|
356
|
+
"x-notes": "Direct child of Row/Column only",
|
|
357
|
+
"properties": {
|
|
358
|
+
"id": { "$ref": "#/properties/id" },
|
|
359
|
+
"width": { "$ref": "#/properties/width" },
|
|
360
|
+
"height": { "$ref": "#/properties/height" },
|
|
361
|
+
"weight": { "$ref": "#/properties/weight" }
|
|
362
|
+
},
|
|
363
|
+
"_children": { "x-kind": "none" }
|
|
364
|
+
},
|
|
365
|
+
"Divider": {
|
|
366
|
+
"x-tier": "core",
|
|
367
|
+
"x-category": "layout",
|
|
368
|
+
"description": "Horizontal or vertical separator",
|
|
369
|
+
"properties": {
|
|
370
|
+
"id": { "$ref": "#/properties/id" },
|
|
371
|
+
"axis": { "$ref": "#/properties/axis" },
|
|
372
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
373
|
+
},
|
|
374
|
+
"_children": { "x-kind": "none" }
|
|
375
|
+
},
|
|
376
|
+
"ScrollArea": {
|
|
377
|
+
"x-tier": "core",
|
|
378
|
+
"x-category": "scroll",
|
|
379
|
+
"description": "Internal scroll boundary",
|
|
380
|
+
"properties": {
|
|
381
|
+
"id": { "$ref": "#/properties/id" },
|
|
382
|
+
"axis": { "$ref": "#/properties/axis" },
|
|
383
|
+
"scroll": { "$ref": "#/properties/scroll" },
|
|
384
|
+
"width": { "$ref": "#/properties/width" },
|
|
385
|
+
"height": { "$ref": "#/properties/height" },
|
|
386
|
+
"minHeight": { "$ref": "#/properties/minHeight" },
|
|
387
|
+
"maxHeight": { "$ref": "#/properties/maxHeight" },
|
|
388
|
+
"padding": { "$ref": "#/properties/padding" }
|
|
389
|
+
},
|
|
390
|
+
"_children": { "x-kind": "single" }
|
|
391
|
+
},
|
|
392
|
+
"List": {
|
|
393
|
+
"x-tier": "core",
|
|
394
|
+
"x-category": "scroll",
|
|
395
|
+
"description": "Homogeneous list of items",
|
|
396
|
+
"properties": {
|
|
397
|
+
"id": { "$ref": "#/properties/id" },
|
|
398
|
+
"gap": { "$ref": "#/properties/gap" },
|
|
399
|
+
"axis": { "$ref": "#/properties/axis" },
|
|
400
|
+
"role": { "$ref": "#/properties/role" },
|
|
401
|
+
"visible": { "$ref": "#/properties/visible" }
|
|
402
|
+
},
|
|
403
|
+
"_children": { "x-kind": "list", "x-items": ["ListItem"] }
|
|
404
|
+
},
|
|
405
|
+
"ListItem": {
|
|
406
|
+
"x-tier": "core",
|
|
407
|
+
"x-category": "scroll",
|
|
408
|
+
"description": "One row/cell in a list",
|
|
409
|
+
"properties": {
|
|
410
|
+
"id": { "$ref": "#/properties/id" },
|
|
411
|
+
"selected": { "$ref": "#/properties/selected" },
|
|
412
|
+
"padding": { "$ref": "#/properties/padding" },
|
|
413
|
+
"gap": { "$ref": "#/properties/gap" },
|
|
414
|
+
"role": { "$ref": "#/properties/role" },
|
|
415
|
+
"visible": { "$ref": "#/properties/visible" }
|
|
416
|
+
},
|
|
417
|
+
"_children": { "x-kind": "any" }
|
|
418
|
+
},
|
|
419
|
+
"Text": {
|
|
420
|
+
"x-tier": "core",
|
|
421
|
+
"x-category": "text",
|
|
422
|
+
"description": "Text display",
|
|
423
|
+
"properties": {
|
|
424
|
+
"id": { "$ref": "#/properties/id" },
|
|
425
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
426
|
+
"textStyle": { "$ref": "#/properties/textStyle" },
|
|
427
|
+
"textAlign": { "$ref": "#/properties/textAlign" },
|
|
428
|
+
"lineLimit": { "$ref": "#/properties/lineLimit" },
|
|
429
|
+
"textOverflow": { "$ref": "#/properties/textOverflow" },
|
|
430
|
+
"fontWeight": { "$ref": "#/properties/fontWeight" },
|
|
431
|
+
"foreground": { "$ref": "#/properties/foreground" },
|
|
432
|
+
"opacity": { "$ref": "#/properties/opacity" },
|
|
433
|
+
"role": { "$ref": "#/properties/role" }
|
|
434
|
+
},
|
|
435
|
+
"_children": { "x-kind": "text" }
|
|
436
|
+
},
|
|
437
|
+
"Heading": {
|
|
438
|
+
"x-tier": "core",
|
|
439
|
+
"x-category": "text",
|
|
440
|
+
"description": "Heading text; visual style via textStyle, semantic level via headingLevel",
|
|
441
|
+
"properties": {
|
|
442
|
+
"id": { "$ref": "#/properties/id" },
|
|
443
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
444
|
+
"headingLevel": { "$ref": "#/properties/headingLevel" },
|
|
445
|
+
"textStyle": { "$ref": "#/properties/textStyle" },
|
|
446
|
+
"textAlign": { "$ref": "#/properties/textAlign" },
|
|
447
|
+
"foreground": { "$ref": "#/properties/foreground" },
|
|
448
|
+
"role": { "$ref": "#/properties/role" }
|
|
449
|
+
},
|
|
450
|
+
"_children": { "x-kind": "text" }
|
|
451
|
+
},
|
|
452
|
+
"Link": {
|
|
453
|
+
"x-tier": "optional",
|
|
454
|
+
"x-category": "text",
|
|
455
|
+
"description": "Navigable text or region",
|
|
456
|
+
"properties": {
|
|
457
|
+
"id": { "$ref": "#/properties/id" },
|
|
458
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
459
|
+
"onClick": { "$ref": "#/properties/onClick" },
|
|
460
|
+
"label": { "$ref": "#/properties/label" },
|
|
461
|
+
"foreground": { "$ref": "#/properties/foreground" },
|
|
462
|
+
"role": { "$ref": "#/properties/role" }
|
|
463
|
+
},
|
|
464
|
+
"_children": { "x-kind": "text" }
|
|
465
|
+
},
|
|
466
|
+
"Image": {
|
|
467
|
+
"x-tier": "core",
|
|
468
|
+
"x-category": "media",
|
|
469
|
+
"description": "Image display",
|
|
470
|
+
"properties": {
|
|
471
|
+
"id": { "$ref": "#/properties/id" },
|
|
472
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
473
|
+
"src": { "$ref": "#/properties/src" },
|
|
474
|
+
"fit": { "$ref": "#/properties/fit" },
|
|
475
|
+
"alt": { "$ref": "#/properties/alt" },
|
|
476
|
+
"width": { "$ref": "#/properties/width" },
|
|
477
|
+
"height": { "$ref": "#/properties/height" },
|
|
478
|
+
"aspectRatio": { "$ref": "#/properties/aspectRatio" },
|
|
479
|
+
"radius": { "$ref": "#/properties/radius" }
|
|
480
|
+
},
|
|
481
|
+
"_children": { "x-kind": "none" }
|
|
482
|
+
},
|
|
483
|
+
"Icon": {
|
|
484
|
+
"x-tier": "core",
|
|
485
|
+
"x-category": "media",
|
|
486
|
+
"description": "Icon display; asset set referenced by name token at renderer",
|
|
487
|
+
"properties": {
|
|
488
|
+
"id": { "$ref": "#/properties/id" },
|
|
489
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
490
|
+
"name": { "$ref": "#/properties/name" },
|
|
491
|
+
"alt": { "$ref": "#/properties/alt" },
|
|
492
|
+
"foreground": { "$ref": "#/properties/foreground" },
|
|
493
|
+
"opacity": { "$ref": "#/properties/opacity" }
|
|
494
|
+
},
|
|
495
|
+
"_children": { "x-kind": "none" }
|
|
496
|
+
},
|
|
497
|
+
"Button": {
|
|
498
|
+
"x-tier": "core",
|
|
499
|
+
"x-category": "input",
|
|
500
|
+
"description": "Pressable action; label or children required (label is a11y name when both present)",
|
|
501
|
+
"properties": {
|
|
502
|
+
"id": { "$ref": "#/properties/id" },
|
|
503
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
504
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
505
|
+
"onClick": { "$ref": "#/properties/onClick" },
|
|
506
|
+
"label": { "$ref": "#/properties/label" },
|
|
507
|
+
"foreground": { "$ref": "#/properties/foreground" },
|
|
508
|
+
"background": { "$ref": "#/properties/background" },
|
|
509
|
+
"variant": { "$ref": "#/properties/variant" },
|
|
510
|
+
"role": { "$ref": "#/properties/role" }
|
|
511
|
+
},
|
|
512
|
+
"_children": { "x-kind": "list", "x-items": ["Text", "Icon", "Row"] }
|
|
513
|
+
},
|
|
514
|
+
"IconButton": {
|
|
515
|
+
"x-tier": "optional",
|
|
516
|
+
"x-category": "input",
|
|
517
|
+
"description": "Icon-primary button; label required for accessibility",
|
|
518
|
+
"properties": {
|
|
519
|
+
"id": { "$ref": "#/properties/id" },
|
|
520
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
521
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
522
|
+
"onClick": { "$ref": "#/properties/onClick" },
|
|
523
|
+
"label": { "$ref": "#/properties/label" },
|
|
524
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
525
|
+
},
|
|
526
|
+
"_children": { "x-kind": "list", "x-items": ["Icon"] }
|
|
527
|
+
},
|
|
528
|
+
"TextInput": {
|
|
529
|
+
"x-tier": "core",
|
|
530
|
+
"x-category": "input",
|
|
531
|
+
"description": "Single-line text input",
|
|
532
|
+
"properties": {
|
|
533
|
+
"id": { "$ref": "#/properties/id" },
|
|
534
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
535
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
536
|
+
"readonly": { "$ref": "#/properties/readonly" },
|
|
537
|
+
"required": { "$ref": "#/properties/required" },
|
|
538
|
+
"value": { "$ref": "#/properties/value" },
|
|
539
|
+
"binding": { "$ref": "#/properties/binding" },
|
|
540
|
+
"placeholder": { "$ref": "#/properties/placeholder" },
|
|
541
|
+
"onChange": { "$ref": "#/properties/onChange" },
|
|
542
|
+
"error": { "$ref": "#/properties/error" },
|
|
543
|
+
"help": { "$ref": "#/properties/help" },
|
|
544
|
+
"keyboardType": { "$ref": "#/properties/keyboardType" },
|
|
545
|
+
"focusable": { "$ref": "#/properties/focusable" },
|
|
546
|
+
"autoFocus": { "$ref": "#/properties/autoFocus" },
|
|
547
|
+
"width": { "$ref": "#/properties/width" },
|
|
548
|
+
"label": { "$ref": "#/properties/label" }
|
|
549
|
+
},
|
|
550
|
+
"_children": { "x-kind": "none" }
|
|
551
|
+
},
|
|
552
|
+
"TextArea": {
|
|
553
|
+
"x-tier": "core",
|
|
554
|
+
"x-category": "input",
|
|
555
|
+
"description": "Multi-line text input",
|
|
556
|
+
"properties": {
|
|
557
|
+
"id": { "$ref": "#/properties/id" },
|
|
558
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
559
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
560
|
+
"readonly": { "$ref": "#/properties/readonly" },
|
|
561
|
+
"required": { "$ref": "#/properties/required" },
|
|
562
|
+
"value": { "$ref": "#/properties/value" },
|
|
563
|
+
"binding": { "$ref": "#/properties/binding" },
|
|
564
|
+
"placeholder": { "$ref": "#/properties/placeholder" },
|
|
565
|
+
"onChange": { "$ref": "#/properties/onChange" },
|
|
566
|
+
"error": { "$ref": "#/properties/error" },
|
|
567
|
+
"help": { "$ref": "#/properties/help" },
|
|
568
|
+
"focusable": { "$ref": "#/properties/focusable" },
|
|
569
|
+
"minHeight": { "$ref": "#/properties/minHeight" },
|
|
570
|
+
"label": { "$ref": "#/properties/label" }
|
|
571
|
+
},
|
|
572
|
+
"_children": { "x-kind": "none" }
|
|
573
|
+
},
|
|
574
|
+
"Select": {
|
|
575
|
+
"x-tier": "core",
|
|
576
|
+
"x-category": "input",
|
|
577
|
+
"description": "Single selection",
|
|
578
|
+
"properties": {
|
|
579
|
+
"id": { "$ref": "#/properties/id" },
|
|
580
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
581
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
582
|
+
"required": { "$ref": "#/properties/required" },
|
|
583
|
+
"value": { "$ref": "#/properties/value" },
|
|
584
|
+
"binding": { "$ref": "#/properties/binding" },
|
|
585
|
+
"options": { "$ref": "#/properties/options" },
|
|
586
|
+
"onChange": { "$ref": "#/properties/onChange" },
|
|
587
|
+
"error": { "$ref": "#/properties/error" },
|
|
588
|
+
"help": { "$ref": "#/properties/help" },
|
|
589
|
+
"width": { "$ref": "#/properties/width" },
|
|
590
|
+
"label": { "$ref": "#/properties/label" }
|
|
591
|
+
},
|
|
592
|
+
"_children": { "x-kind": "none" }
|
|
593
|
+
},
|
|
594
|
+
"Checkbox": {
|
|
595
|
+
"x-tier": "core",
|
|
596
|
+
"x-category": "input",
|
|
597
|
+
"description": "Boolean or multi-select toggle",
|
|
598
|
+
"properties": {
|
|
599
|
+
"id": { "$ref": "#/properties/id" },
|
|
600
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
601
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
602
|
+
"checked": { "$ref": "#/properties/checked" },
|
|
603
|
+
"required": { "$ref": "#/properties/required" },
|
|
604
|
+
"binding": { "$ref": "#/properties/binding" },
|
|
605
|
+
"label": { "$ref": "#/properties/label" },
|
|
606
|
+
"onChange": { "$ref": "#/properties/onChange" }
|
|
607
|
+
},
|
|
608
|
+
"_children": { "x-kind": "none" }
|
|
609
|
+
},
|
|
610
|
+
"Radio": {
|
|
611
|
+
"x-tier": "core",
|
|
612
|
+
"x-category": "input",
|
|
613
|
+
"description": "Single choice in a group (use Row/Column to group; binding identifies group)",
|
|
614
|
+
"x-notes": "RadioGroup is expressed via layout Group, not a separate element",
|
|
615
|
+
"properties": {
|
|
616
|
+
"id": { "$ref": "#/properties/id" },
|
|
617
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
618
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
619
|
+
"checked": { "$ref": "#/properties/checked" },
|
|
620
|
+
"binding": { "$ref": "#/properties/binding" },
|
|
621
|
+
"label": { "$ref": "#/properties/label" },
|
|
622
|
+
"value": { "$ref": "#/properties/value" },
|
|
623
|
+
"onChange": { "$ref": "#/properties/onChange" }
|
|
624
|
+
},
|
|
625
|
+
"_children": { "x-kind": "none" }
|
|
626
|
+
},
|
|
627
|
+
"Switch": {
|
|
628
|
+
"x-tier": "core",
|
|
629
|
+
"x-category": "input",
|
|
630
|
+
"description": "On/off toggle",
|
|
631
|
+
"properties": {
|
|
632
|
+
"id": { "$ref": "#/properties/id" },
|
|
633
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
634
|
+
"enabled": { "$ref": "#/properties/enabled" },
|
|
635
|
+
"checked": { "$ref": "#/properties/checked" },
|
|
636
|
+
"binding": { "$ref": "#/properties/binding" },
|
|
637
|
+
"label": { "$ref": "#/properties/label" },
|
|
638
|
+
"onChange": { "$ref": "#/properties/onChange" }
|
|
639
|
+
},
|
|
640
|
+
"_children": { "x-kind": "none" }
|
|
641
|
+
},
|
|
642
|
+
"Form": {
|
|
643
|
+
"x-tier": "core",
|
|
644
|
+
"x-category": "form",
|
|
645
|
+
"description": "Input group submit/validation boundary",
|
|
646
|
+
"properties": {
|
|
647
|
+
"id": { "$ref": "#/properties/id" },
|
|
648
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
649
|
+
"gap": { "$ref": "#/properties/gap" },
|
|
650
|
+
"onSubmit": { "$ref": "#/properties/onSubmit" }
|
|
651
|
+
},
|
|
652
|
+
"_children": { "x-kind": "any" }
|
|
653
|
+
},
|
|
654
|
+
"Field": {
|
|
655
|
+
"x-tier": "core",
|
|
656
|
+
"x-category": "form",
|
|
657
|
+
"description": "label/help/error/input unit",
|
|
658
|
+
"properties": {
|
|
659
|
+
"id": { "$ref": "#/properties/id" },
|
|
660
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
661
|
+
"label": { "$ref": "#/properties/label" },
|
|
662
|
+
"help": { "$ref": "#/properties/help" },
|
|
663
|
+
"error": { "$ref": "#/properties/error" },
|
|
664
|
+
"required": { "$ref": "#/properties/required" },
|
|
665
|
+
"gap": { "$ref": "#/properties/gap" }
|
|
666
|
+
},
|
|
667
|
+
"_children": { "x-kind": "any" }
|
|
668
|
+
},
|
|
669
|
+
"Modal": {
|
|
670
|
+
"x-tier": "core",
|
|
671
|
+
"x-category": "overlay",
|
|
672
|
+
"description": "Primary transient dialog",
|
|
673
|
+
"x-notes": "Direct child of Page or App; role defaults to dialog at renderer",
|
|
674
|
+
"properties": {
|
|
675
|
+
"id": { "$ref": "#/properties/id" },
|
|
676
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
677
|
+
"role": { "$ref": "#/properties/role" },
|
|
678
|
+
"autoFocus": { "$ref": "#/properties/autoFocus" }
|
|
679
|
+
},
|
|
680
|
+
"_children": { "x-kind": "list", "x-items": ["Box", "Column"] }
|
|
681
|
+
},
|
|
682
|
+
"Drawer": {
|
|
683
|
+
"x-tier": "extension",
|
|
684
|
+
"x-category": "overlay",
|
|
685
|
+
"description": "Edge panel overlay",
|
|
686
|
+
"x-notes": "Placement limited to start/end/bottom at renderer",
|
|
687
|
+
"properties": {
|
|
688
|
+
"id": { "$ref": "#/properties/id" },
|
|
689
|
+
"visible": { "$ref": "#/properties/visible" }
|
|
690
|
+
},
|
|
691
|
+
"_children": { "x-kind": "list", "x-items": ["Box", "Column"] }
|
|
692
|
+
},
|
|
693
|
+
"Popover": {
|
|
694
|
+
"x-tier": "extension",
|
|
695
|
+
"x-category": "overlay",
|
|
696
|
+
"description": "Small anchored panel",
|
|
697
|
+
"properties": {
|
|
698
|
+
"id": { "$ref": "#/properties/id" },
|
|
699
|
+
"visible": { "$ref": "#/properties/visible" }
|
|
700
|
+
},
|
|
701
|
+
"_children": { "x-kind": "list", "x-items": ["Box", "Column"] }
|
|
702
|
+
},
|
|
703
|
+
"Tooltip": {
|
|
704
|
+
"x-tier": "extension",
|
|
705
|
+
"x-category": "overlay",
|
|
706
|
+
"description": "Supplementary description",
|
|
707
|
+
"properties": {
|
|
708
|
+
"id": { "$ref": "#/properties/id" },
|
|
709
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
710
|
+
"label": { "$ref": "#/properties/label" }
|
|
711
|
+
},
|
|
712
|
+
"_children": { "x-kind": "text" }
|
|
713
|
+
},
|
|
714
|
+
"Progress": {
|
|
715
|
+
"x-tier": "core",
|
|
716
|
+
"x-category": "feedback",
|
|
717
|
+
"description": "Determinate progress",
|
|
718
|
+
"properties": {
|
|
719
|
+
"id": { "$ref": "#/properties/id" },
|
|
720
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
721
|
+
"value": { "$ref": "#/properties/value" },
|
|
722
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
723
|
+
},
|
|
724
|
+
"_children": { "x-kind": "none" }
|
|
725
|
+
},
|
|
726
|
+
"Spinner": {
|
|
727
|
+
"x-tier": "core",
|
|
728
|
+
"x-category": "feedback",
|
|
729
|
+
"description": "Indeterminate loading",
|
|
730
|
+
"properties": {
|
|
731
|
+
"id": { "$ref": "#/properties/id" },
|
|
732
|
+
"visible": { "$ref": "#/properties/visible" },
|
|
733
|
+
"variant": { "$ref": "#/properties/variant" }
|
|
734
|
+
},
|
|
735
|
+
"_children": { "x-kind": "none" }
|
|
736
|
+
}
|
|
737
|
+
}
|
|
738
|
+
}
|