@kumwe/studio-protocol 0.1.0-alpha.10
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 +77 -0
- package/THIRD_PARTY_NOTICES.md +9 -0
- package/dist/generated/schema-models.d.ts +1968 -0
- package/dist/generated/schema-models.d.ts.map +1 -0
- package/dist/generated/schema-models.js +76 -0
- package/dist/generated/schema-models.js.map +1 -0
- package/dist/guards.d.ts +7 -0
- package/dist/guards.d.ts.map +1 -0
- package/dist/guards.js +374 -0
- package/dist/guards.js.map +1 -0
- package/dist/host-failure.d.ts +16 -0
- package/dist/host-failure.d.ts.map +1 -0
- package/dist/host-failure.js +27 -0
- package/dist/host-failure.js.map +1 -0
- package/dist/index.d.ts +7 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -0
- package/dist/schemas.d.ts +50 -0
- package/dist/schemas.d.ts.map +1 -0
- package/dist/schemas.js +144 -0
- package/dist/schemas.js.map +1 -0
- package/dist/types.d.ts +1256 -0
- package/dist/types.d.ts.map +1 -0
- package/dist/types.js +8 -0
- package/dist/types.js.map +1 -0
- package/package.json +42 -0
- package/schemas/authoring-message-catalog.schema.json +45 -0
- package/schemas/authoring-web-vector.schema.json +236 -0
- package/schemas/binding-projection-vector.schema.json +127 -0
- package/schemas/block-definition.schema.json +227 -0
- package/schemas/blueprint.schema.json +273 -0
- package/schemas/canonical-vector.schema.json +65 -0
- package/schemas/command-vector.schema.json +68 -0
- package/schemas/command.schema.json +410 -0
- package/schemas/common.schema.json +222 -0
- package/schemas/content-model.schema.json +216 -0
- package/schemas/corpus-manifest.schema.json +48 -0
- package/schemas/design-vocabulary.schema.json +91 -0
- package/schemas/entry.schema.json +32 -0
- package/schemas/field-adapter.schema.json +51 -0
- package/schemas/host-capabilities.schema.json +65 -0
- package/schemas/host-error.schema.json +42 -0
- package/schemas/host-operations.schema.json +162 -0
- package/schemas/host-request.schema.json +71 -0
- package/schemas/host-result.schema.json +19 -0
- package/schemas/host-sequence-vector.schema.json +342 -0
- package/schemas/host-vector.schema.json +199 -0
- package/schemas/inspector.schema.json +44 -0
- package/schemas/manifest.json +246 -0
- package/schemas/media-asset.schema.json +83 -0
- package/schemas/media-reference.schema.json +112 -0
- package/schemas/media-upload-grant.schema.json +48 -0
- package/schemas/media-upload-session.schema.json +109 -0
- package/schemas/media-vector.schema.json +123 -0
- package/schemas/migration.schema.json +41 -0
- package/schemas/pattern.schema.json +50 -0
- package/schemas/plugin-manifest.schema.json +126 -0
- package/schemas/preview-message.schema.json +583 -0
- package/schemas/preview-vector.schema.json +52 -0
- package/schemas/provenance.schema.json +57 -0
- package/schemas/renderer-web-vector.schema.json +160 -0
- package/schemas/rich-text-projection.schema.json +79 -0
- package/schemas/rich-text.schema.json +323 -0
- package/schemas/schema-profile-vector.schema.json +133 -0
- package/schemas/schema-profile.schema.json +201 -0
- package/schemas/studio-chart.schema.json +35 -0
- package/schemas/studio-config.schema.json +244 -0
- package/schemas/studio-drawing.schema.json +44 -0
- package/schemas/studio-money.schema.json +16 -0
- package/schemas/studio-presentation.schema.json +31 -0
- package/schemas/studio-release.schema.json +81 -0
- package/schemas/studio-table.schema.json +27 -0
- package/schemas/theme.schema.json +164 -0
- package/schemas/unresolved-contribution.schema.json +50 -0
- package/studio-release.json +18 -0
|
@@ -0,0 +1,583 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/preview-message.schema.json",
|
|
4
|
+
"title": "Studio preview channel message",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"contractVersion",
|
|
9
|
+
"kind",
|
|
10
|
+
"channelId",
|
|
11
|
+
"sessionGeneration",
|
|
12
|
+
"sequence",
|
|
13
|
+
"type",
|
|
14
|
+
"payload"
|
|
15
|
+
],
|
|
16
|
+
"properties": {
|
|
17
|
+
"contractVersion": {
|
|
18
|
+
"$ref": "common.schema.json#/$defs/contractVersion"
|
|
19
|
+
},
|
|
20
|
+
"kind": {
|
|
21
|
+
"const": "preview-message"
|
|
22
|
+
},
|
|
23
|
+
"channelId": {
|
|
24
|
+
"$ref": "common.schema.json#/$defs/stableId"
|
|
25
|
+
},
|
|
26
|
+
"sessionGeneration": {
|
|
27
|
+
"$ref": "common.schema.json#/$defs/revision"
|
|
28
|
+
},
|
|
29
|
+
"sequence": {
|
|
30
|
+
"type": "integer",
|
|
31
|
+
"minimum": 0
|
|
32
|
+
},
|
|
33
|
+
"type": {
|
|
34
|
+
"enum": [
|
|
35
|
+
"studio.preview/activated",
|
|
36
|
+
"studio.preview/dispose",
|
|
37
|
+
"studio.preview/error",
|
|
38
|
+
"studio.preview/measure",
|
|
39
|
+
"studio.preview/measurements",
|
|
40
|
+
"studio.preview/ready",
|
|
41
|
+
"studio.preview/reload",
|
|
42
|
+
"studio.preview/render",
|
|
43
|
+
"studio.preview/rendered",
|
|
44
|
+
"studio.preview/select",
|
|
45
|
+
"studio.preview/teardown",
|
|
46
|
+
"studio.preview/viewport"
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
"payload": {
|
|
50
|
+
"type": "object",
|
|
51
|
+
"maxProperties": 1000,
|
|
52
|
+
"propertyNames": {
|
|
53
|
+
"$ref": "common.schema.json#/$defs/safeJsonMemberName"
|
|
54
|
+
},
|
|
55
|
+
"additionalProperties": {
|
|
56
|
+
"$ref": "common.schema.json#/$defs/jsonValue"
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
"allOf": [
|
|
61
|
+
{
|
|
62
|
+
"if": {
|
|
63
|
+
"properties": {
|
|
64
|
+
"type": {
|
|
65
|
+
"const": "studio.preview/ready"
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
"then": {
|
|
70
|
+
"properties": {
|
|
71
|
+
"payload": {
|
|
72
|
+
"$ref": "#/$defs/ready"
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
"if": {
|
|
79
|
+
"properties": {
|
|
80
|
+
"type": {
|
|
81
|
+
"const": "studio.preview/render"
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
},
|
|
85
|
+
"then": {
|
|
86
|
+
"properties": {
|
|
87
|
+
"payload": {
|
|
88
|
+
"$ref": "#/$defs/render"
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"if": {
|
|
95
|
+
"properties": {
|
|
96
|
+
"type": {
|
|
97
|
+
"const": "studio.preview/rendered"
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
},
|
|
101
|
+
"then": {
|
|
102
|
+
"properties": {
|
|
103
|
+
"payload": {
|
|
104
|
+
"$ref": "#/$defs/rendered"
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
"if": {
|
|
111
|
+
"properties": {
|
|
112
|
+
"type": {
|
|
113
|
+
"const": "studio.preview/select"
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
},
|
|
117
|
+
"then": {
|
|
118
|
+
"properties": {
|
|
119
|
+
"payload": {
|
|
120
|
+
"$ref": "#/$defs/select"
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
{
|
|
126
|
+
"if": {
|
|
127
|
+
"properties": {
|
|
128
|
+
"type": {
|
|
129
|
+
"const": "studio.preview/measure"
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
"then": {
|
|
134
|
+
"properties": {
|
|
135
|
+
"payload": {
|
|
136
|
+
"$ref": "#/$defs/measure"
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
},
|
|
141
|
+
{
|
|
142
|
+
"if": {
|
|
143
|
+
"properties": {
|
|
144
|
+
"type": {
|
|
145
|
+
"const": "studio.preview/measurements"
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
},
|
|
149
|
+
"then": {
|
|
150
|
+
"properties": {
|
|
151
|
+
"payload": {
|
|
152
|
+
"$ref": "#/$defs/measurements"
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
},
|
|
157
|
+
{
|
|
158
|
+
"if": {
|
|
159
|
+
"properties": {
|
|
160
|
+
"type": {
|
|
161
|
+
"const": "studio.preview/error"
|
|
162
|
+
}
|
|
163
|
+
}
|
|
164
|
+
},
|
|
165
|
+
"then": {
|
|
166
|
+
"properties": {
|
|
167
|
+
"payload": {
|
|
168
|
+
"$ref": "#/$defs/error"
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
}
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"if": {
|
|
175
|
+
"properties": {
|
|
176
|
+
"type": {
|
|
177
|
+
"const": "studio.preview/reload"
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
},
|
|
181
|
+
"then": {
|
|
182
|
+
"properties": {
|
|
183
|
+
"payload": {
|
|
184
|
+
"$ref": "#/$defs/reload"
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
}
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
"if": {
|
|
191
|
+
"properties": {
|
|
192
|
+
"type": {
|
|
193
|
+
"const": "studio.preview/teardown"
|
|
194
|
+
}
|
|
195
|
+
}
|
|
196
|
+
},
|
|
197
|
+
"then": {
|
|
198
|
+
"properties": {
|
|
199
|
+
"payload": {
|
|
200
|
+
"$ref": "#/$defs/teardown"
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
},
|
|
205
|
+
{
|
|
206
|
+
"if": {
|
|
207
|
+
"properties": {
|
|
208
|
+
"type": {
|
|
209
|
+
"const": "studio.preview/activated"
|
|
210
|
+
}
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
"then": {
|
|
214
|
+
"properties": {
|
|
215
|
+
"payload": {
|
|
216
|
+
"$ref": "#/$defs/activated"
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
},
|
|
221
|
+
{
|
|
222
|
+
"if": {
|
|
223
|
+
"properties": {
|
|
224
|
+
"type": {
|
|
225
|
+
"const": "studio.preview/viewport"
|
|
226
|
+
}
|
|
227
|
+
}
|
|
228
|
+
},
|
|
229
|
+
"then": {
|
|
230
|
+
"properties": {
|
|
231
|
+
"payload": {
|
|
232
|
+
"$ref": "#/$defs/viewport"
|
|
233
|
+
}
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
"if": {
|
|
239
|
+
"properties": {
|
|
240
|
+
"type": {
|
|
241
|
+
"const": "studio.preview/dispose"
|
|
242
|
+
}
|
|
243
|
+
}
|
|
244
|
+
},
|
|
245
|
+
"then": {
|
|
246
|
+
"properties": {
|
|
247
|
+
"payload": {
|
|
248
|
+
"$ref": "#/$defs/dispose"
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
}
|
|
253
|
+
],
|
|
254
|
+
"$defs": {
|
|
255
|
+
"previewMarker": {
|
|
256
|
+
"description": "A deterministic marker for one node in a canonical draft: the draft digest followed by its zero-based Blueprint preorder ordinal.",
|
|
257
|
+
"type": "string",
|
|
258
|
+
"pattern": "^studio\\.preview/node/[0-9a-f]{64}/(?:0|[1-9][0-9]{0,4})(?![\\s\\S])",
|
|
259
|
+
"maxLength": 90
|
|
260
|
+
},
|
|
261
|
+
"ready": {
|
|
262
|
+
"type": "object",
|
|
263
|
+
"additionalProperties": false,
|
|
264
|
+
"required": ["protocolVersion", "renderer", "viewports"],
|
|
265
|
+
"properties": {
|
|
266
|
+
"protocolVersion": {
|
|
267
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
268
|
+
},
|
|
269
|
+
"renderer": {
|
|
270
|
+
"$ref": "common.schema.json#/$defs/qualifiedName"
|
|
271
|
+
},
|
|
272
|
+
"viewports": {
|
|
273
|
+
"type": "array",
|
|
274
|
+
"maxItems": 20,
|
|
275
|
+
"items": {
|
|
276
|
+
"$ref": "common.schema.json#/$defs/localName"
|
|
277
|
+
}
|
|
278
|
+
}
|
|
279
|
+
}
|
|
280
|
+
},
|
|
281
|
+
"render": {
|
|
282
|
+
"type": "object",
|
|
283
|
+
"additionalProperties": false,
|
|
284
|
+
"required": ["artifactId", "draftDigest", "draftRevision", "requestId", "viewport"],
|
|
285
|
+
"properties": {
|
|
286
|
+
"artifactId": {
|
|
287
|
+
"$ref": "common.schema.json#/$defs/stableId"
|
|
288
|
+
},
|
|
289
|
+
"draftDigest": {
|
|
290
|
+
"type": "string",
|
|
291
|
+
"pattern": "^[a-f0-9]{64}(?![\\s\\S])"
|
|
292
|
+
},
|
|
293
|
+
"draftRevision": {
|
|
294
|
+
"$ref": "common.schema.json#/$defs/revision"
|
|
295
|
+
},
|
|
296
|
+
"requestId": {
|
|
297
|
+
"$ref": "common.schema.json#/$defs/stableId",
|
|
298
|
+
"description": "A session-unique render attempt identifier. Retries use a new identifier even when draft and viewport are unchanged."
|
|
299
|
+
},
|
|
300
|
+
"viewport": {
|
|
301
|
+
"$ref": "common.schema.json#/$defs/localName"
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
},
|
|
305
|
+
"rendered": {
|
|
306
|
+
"type": "object",
|
|
307
|
+
"additionalProperties": false,
|
|
308
|
+
"required": ["requestId", "draftDigest", "markers", "markerMap", "diagnostics"],
|
|
309
|
+
"properties": {
|
|
310
|
+
"draftDigest": {
|
|
311
|
+
"type": "string",
|
|
312
|
+
"pattern": "^[a-f0-9]{64}(?![\\s\\S])"
|
|
313
|
+
},
|
|
314
|
+
"requestId": {
|
|
315
|
+
"$ref": "common.schema.json#/$defs/stableId",
|
|
316
|
+
"description": "The exact render attempt this response settles."
|
|
317
|
+
},
|
|
318
|
+
"markers": {
|
|
319
|
+
"type": "array",
|
|
320
|
+
"maxItems": 100000,
|
|
321
|
+
"uniqueItems": true,
|
|
322
|
+
"items": {
|
|
323
|
+
"$ref": "#/$defs/previewMarker"
|
|
324
|
+
}
|
|
325
|
+
},
|
|
326
|
+
"markerMap": {
|
|
327
|
+
"type": "object",
|
|
328
|
+
"maxProperties": 100000,
|
|
329
|
+
"propertyNames": {
|
|
330
|
+
"$ref": "#/$defs/previewMarker"
|
|
331
|
+
},
|
|
332
|
+
"additionalProperties": {
|
|
333
|
+
"$ref": "common.schema.json#/$defs/stableId"
|
|
334
|
+
}
|
|
335
|
+
},
|
|
336
|
+
"diagnostics": {
|
|
337
|
+
"type": "array",
|
|
338
|
+
"maxItems": 10000,
|
|
339
|
+
"items": {
|
|
340
|
+
"$ref": "common.schema.json#/$defs/diagnostic"
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
},
|
|
345
|
+
"select": {
|
|
346
|
+
"type": "object",
|
|
347
|
+
"additionalProperties": false,
|
|
348
|
+
"required": ["nodeId"],
|
|
349
|
+
"properties": {
|
|
350
|
+
"nodeId": {
|
|
351
|
+
"$ref": "common.schema.json#/$defs/stableId"
|
|
352
|
+
},
|
|
353
|
+
"reveal": {
|
|
354
|
+
"type": "boolean",
|
|
355
|
+
"default": true
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
},
|
|
359
|
+
"measure": {
|
|
360
|
+
"type": "object",
|
|
361
|
+
"additionalProperties": false,
|
|
362
|
+
"required": ["requestId", "markers"],
|
|
363
|
+
"properties": {
|
|
364
|
+
"requestId": {
|
|
365
|
+
"$ref": "common.schema.json#/$defs/stableId",
|
|
366
|
+
"description": "A session-unique measurement attempt identifier, never reused for another render or measurement."
|
|
367
|
+
},
|
|
368
|
+
"markers": {
|
|
369
|
+
"type": "array",
|
|
370
|
+
"minItems": 1,
|
|
371
|
+
"maxItems": 1000,
|
|
372
|
+
"uniqueItems": true,
|
|
373
|
+
"items": {
|
|
374
|
+
"$ref": "#/$defs/previewMarker"
|
|
375
|
+
}
|
|
376
|
+
}
|
|
377
|
+
}
|
|
378
|
+
},
|
|
379
|
+
"measurements": {
|
|
380
|
+
"type": "object",
|
|
381
|
+
"additionalProperties": false,
|
|
382
|
+
"required": ["requestId", "draftDigest", "measurements", "unknown", "viewport"],
|
|
383
|
+
"properties": {
|
|
384
|
+
"requestId": {
|
|
385
|
+
"$ref": "common.schema.json#/$defs/stableId"
|
|
386
|
+
},
|
|
387
|
+
"draftDigest": {
|
|
388
|
+
"type": "string",
|
|
389
|
+
"pattern": "^[a-f0-9]{64}(?![\\s\\S])"
|
|
390
|
+
},
|
|
391
|
+
"measurements": {
|
|
392
|
+
"type": "object",
|
|
393
|
+
"maxProperties": 1000,
|
|
394
|
+
"propertyNames": {
|
|
395
|
+
"$ref": "#/$defs/previewMarker"
|
|
396
|
+
},
|
|
397
|
+
"additionalProperties": {
|
|
398
|
+
"type": "array",
|
|
399
|
+
"minItems": 1,
|
|
400
|
+
"maxItems": 1000,
|
|
401
|
+
"items": {
|
|
402
|
+
"$ref": "#/$defs/markerRect"
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
},
|
|
406
|
+
"unknown": {
|
|
407
|
+
"type": "array",
|
|
408
|
+
"maxItems": 1000,
|
|
409
|
+
"uniqueItems": true,
|
|
410
|
+
"items": {
|
|
411
|
+
"$ref": "#/$defs/previewMarker"
|
|
412
|
+
}
|
|
413
|
+
},
|
|
414
|
+
"viewport": {
|
|
415
|
+
"$ref": "#/$defs/viewportMetrics"
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
},
|
|
419
|
+
"markerRect": {
|
|
420
|
+
"type": "object",
|
|
421
|
+
"additionalProperties": false,
|
|
422
|
+
"required": ["x", "y", "width", "height"],
|
|
423
|
+
"properties": {
|
|
424
|
+
"x": {
|
|
425
|
+
"type": "number",
|
|
426
|
+
"minimum": -100000000,
|
|
427
|
+
"maximum": 100000000
|
|
428
|
+
},
|
|
429
|
+
"y": {
|
|
430
|
+
"type": "number",
|
|
431
|
+
"minimum": -100000000,
|
|
432
|
+
"maximum": 100000000
|
|
433
|
+
},
|
|
434
|
+
"width": {
|
|
435
|
+
"type": "number",
|
|
436
|
+
"minimum": 0,
|
|
437
|
+
"maximum": 100000000
|
|
438
|
+
},
|
|
439
|
+
"height": {
|
|
440
|
+
"type": "number",
|
|
441
|
+
"minimum": 0,
|
|
442
|
+
"maximum": 100000000
|
|
443
|
+
}
|
|
444
|
+
}
|
|
445
|
+
},
|
|
446
|
+
"viewportMetrics": {
|
|
447
|
+
"type": "object",
|
|
448
|
+
"additionalProperties": false,
|
|
449
|
+
"required": ["width", "height", "scrollX", "scrollY", "devicePixelRatio"],
|
|
450
|
+
"properties": {
|
|
451
|
+
"width": {
|
|
452
|
+
"type": "number",
|
|
453
|
+
"minimum": 0,
|
|
454
|
+
"maximum": 100000000
|
|
455
|
+
},
|
|
456
|
+
"height": {
|
|
457
|
+
"type": "number",
|
|
458
|
+
"minimum": 0,
|
|
459
|
+
"maximum": 100000000
|
|
460
|
+
},
|
|
461
|
+
"scrollX": {
|
|
462
|
+
"type": "number",
|
|
463
|
+
"minimum": -100000000,
|
|
464
|
+
"maximum": 100000000
|
|
465
|
+
},
|
|
466
|
+
"scrollY": {
|
|
467
|
+
"type": "number",
|
|
468
|
+
"minimum": -100000000,
|
|
469
|
+
"maximum": 100000000
|
|
470
|
+
},
|
|
471
|
+
"devicePixelRatio": {
|
|
472
|
+
"type": "number",
|
|
473
|
+
"exclusiveMinimum": 0,
|
|
474
|
+
"maximum": 100
|
|
475
|
+
}
|
|
476
|
+
}
|
|
477
|
+
},
|
|
478
|
+
"error": {
|
|
479
|
+
"type": "object",
|
|
480
|
+
"additionalProperties": false,
|
|
481
|
+
"required": ["code", "message", "retryable"],
|
|
482
|
+
"properties": {
|
|
483
|
+
"code": {
|
|
484
|
+
"$ref": "common.schema.json#/$defs/qualifiedName"
|
|
485
|
+
},
|
|
486
|
+
"message": {
|
|
487
|
+
"$ref": "common.schema.json#/$defs/messageReference"
|
|
488
|
+
},
|
|
489
|
+
"retryable": {
|
|
490
|
+
"type": "boolean"
|
|
491
|
+
},
|
|
492
|
+
"correlationId": {
|
|
493
|
+
"$ref": "common.schema.json#/$defs/stableId"
|
|
494
|
+
}
|
|
495
|
+
}
|
|
496
|
+
},
|
|
497
|
+
"reload": {
|
|
498
|
+
"type": "object",
|
|
499
|
+
"additionalProperties": false,
|
|
500
|
+
"required": ["reason"],
|
|
501
|
+
"properties": {
|
|
502
|
+
"reason": {
|
|
503
|
+
"$ref": "common.schema.json#/$defs/qualifiedName"
|
|
504
|
+
}
|
|
505
|
+
}
|
|
506
|
+
},
|
|
507
|
+
"teardown": {
|
|
508
|
+
"type": "object",
|
|
509
|
+
"additionalProperties": false,
|
|
510
|
+
"required": ["reason"],
|
|
511
|
+
"properties": {
|
|
512
|
+
"reason": {
|
|
513
|
+
"$ref": "common.schema.json#/$defs/qualifiedName"
|
|
514
|
+
}
|
|
515
|
+
}
|
|
516
|
+
},
|
|
517
|
+
"activated": {
|
|
518
|
+
"type": "object",
|
|
519
|
+
"additionalProperties": false,
|
|
520
|
+
"required": ["interaction", "marker"],
|
|
521
|
+
"properties": {
|
|
522
|
+
"interaction": {
|
|
523
|
+
"description": "How the author reached the region. The renderer reports intent, never raw input events.",
|
|
524
|
+
"enum": ["activate", "context-menu", "focus"]
|
|
525
|
+
},
|
|
526
|
+
"marker": {
|
|
527
|
+
"description": "A marker from the renderer's currently accepted inventory. The channel drops invented and stale markers.",
|
|
528
|
+
"$ref": "#/$defs/previewMarker"
|
|
529
|
+
}
|
|
530
|
+
}
|
|
531
|
+
},
|
|
532
|
+
"viewport": {
|
|
533
|
+
"description": "A semantic viewport role and explicit dimensions are alternatives, never a merge. Each branch is closed, so a payload naming both matches neither.",
|
|
534
|
+
"oneOf": [
|
|
535
|
+
{
|
|
536
|
+
"type": "object",
|
|
537
|
+
"additionalProperties": false,
|
|
538
|
+
"required": ["viewport"],
|
|
539
|
+
"properties": {
|
|
540
|
+
"viewport": {
|
|
541
|
+
"$ref": "common.schema.json#/$defs/localName",
|
|
542
|
+
"description": "The theme-declared semantic viewport role to render at."
|
|
543
|
+
}
|
|
544
|
+
}
|
|
545
|
+
},
|
|
546
|
+
{
|
|
547
|
+
"type": "object",
|
|
548
|
+
"additionalProperties": false,
|
|
549
|
+
"minProperties": 1,
|
|
550
|
+
"properties": {
|
|
551
|
+
"height": {
|
|
552
|
+
"description": "Bounded CSS-pixel height.",
|
|
553
|
+
"type": "integer",
|
|
554
|
+
"minimum": 240,
|
|
555
|
+
"maximum": 10000
|
|
556
|
+
},
|
|
557
|
+
"width": {
|
|
558
|
+
"description": "Bounded CSS-pixel width.",
|
|
559
|
+
"type": "integer",
|
|
560
|
+
"minimum": 240,
|
|
561
|
+
"maximum": 10000
|
|
562
|
+
}
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
]
|
|
566
|
+
},
|
|
567
|
+
"dispose": {
|
|
568
|
+
"type": "object",
|
|
569
|
+
"additionalProperties": false,
|
|
570
|
+
"required": ["reason"],
|
|
571
|
+
"properties": {
|
|
572
|
+
"draftDigest": {
|
|
573
|
+
"description": "Revoke only the resources held for this render. Absent revokes every draft resource the renderer holds.",
|
|
574
|
+
"type": "string",
|
|
575
|
+
"pattern": "^[0-9a-f]{64}(?![\\s\\S])"
|
|
576
|
+
},
|
|
577
|
+
"reason": {
|
|
578
|
+
"$ref": "common.schema.json#/$defs/qualifiedName"
|
|
579
|
+
}
|
|
580
|
+
}
|
|
581
|
+
}
|
|
582
|
+
}
|
|
583
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/preview-vector.schema.json",
|
|
4
|
+
"title": "Studio preview identity conformance vector",
|
|
5
|
+
"description": "One complete Blueprint draft, its exact render-attempt identity, and the SHA-256 plus deterministic marker inventory every implementation must reproduce under the preview identity profile.",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"required": [
|
|
9
|
+
"contractVersion",
|
|
10
|
+
"kind",
|
|
11
|
+
"id",
|
|
12
|
+
"description",
|
|
13
|
+
"profile",
|
|
14
|
+
"protocolVersion",
|
|
15
|
+
"draft",
|
|
16
|
+
"render",
|
|
17
|
+
"expect"
|
|
18
|
+
],
|
|
19
|
+
"properties": {
|
|
20
|
+
"contractVersion": { "$ref": "common.schema.json#/$defs/contractVersion" },
|
|
21
|
+
"kind": { "const": "preview-vector" },
|
|
22
|
+
"id": { "$ref": "common.schema.json#/$defs/stableId" },
|
|
23
|
+
"description": { "type": "string", "minLength": 1, "maxLength": 1000 },
|
|
24
|
+
"profile": { "const": "studio.profile/preview-identity-v1" },
|
|
25
|
+
"protocolVersion": { "const": "0.1.0-draft.2" },
|
|
26
|
+
"draft": { "$ref": "blueprint.schema.json" },
|
|
27
|
+
"render": { "$ref": "preview-message.schema.json#/$defs/render" },
|
|
28
|
+
"expect": {
|
|
29
|
+
"type": "object",
|
|
30
|
+
"additionalProperties": false,
|
|
31
|
+
"required": ["draftDigest", "markers", "markerMap"],
|
|
32
|
+
"properties": {
|
|
33
|
+
"draftDigest": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"pattern": "^[0-9a-f]{64}(?![\\s\\S])"
|
|
36
|
+
},
|
|
37
|
+
"markers": {
|
|
38
|
+
"type": "array",
|
|
39
|
+
"maxItems": 100000,
|
|
40
|
+
"uniqueItems": true,
|
|
41
|
+
"items": { "$ref": "preview-message.schema.json#/$defs/previewMarker" }
|
|
42
|
+
},
|
|
43
|
+
"markerMap": {
|
|
44
|
+
"type": "object",
|
|
45
|
+
"maxProperties": 100000,
|
|
46
|
+
"propertyNames": { "$ref": "preview-message.schema.json#/$defs/previewMarker" },
|
|
47
|
+
"additionalProperties": { "$ref": "common.schema.json#/$defs/stableId" }
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/provenance.schema.json",
|
|
4
|
+
"title": "Studio artifact provenance record",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["contractVersion", "kind", "artifact", "chain"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"contractVersion": { "$ref": "common.schema.json#/$defs/contractVersion" },
|
|
10
|
+
"kind": { "const": "provenance" },
|
|
11
|
+
"artifact": {
|
|
12
|
+
"type": "object",
|
|
13
|
+
"additionalProperties": false,
|
|
14
|
+
"required": ["id", "revision"],
|
|
15
|
+
"properties": {
|
|
16
|
+
"id": { "$ref": "common.schema.json#/$defs/stableId" },
|
|
17
|
+
"revision": { "$ref": "common.schema.json#/$defs/revision" }
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"chain": {
|
|
21
|
+
"type": "array",
|
|
22
|
+
"minItems": 1,
|
|
23
|
+
"maxItems": 10000,
|
|
24
|
+
"items": {
|
|
25
|
+
"type": "object",
|
|
26
|
+
"additionalProperties": false,
|
|
27
|
+
"required": ["origin", "toRevision", "recordedAt", "actor"],
|
|
28
|
+
"properties": {
|
|
29
|
+
"origin": {
|
|
30
|
+
"enum": ["authoring", "import", "migration", "pattern", "plugin", "system"]
|
|
31
|
+
},
|
|
32
|
+
"fromRevision": { "$ref": "common.schema.json#/$defs/revision" },
|
|
33
|
+
"toRevision": { "$ref": "common.schema.json#/$defs/revision" },
|
|
34
|
+
"recordedAt": { "$ref": "common.schema.json#/$defs/rfc3339Instant" },
|
|
35
|
+
"actor": {
|
|
36
|
+
"type": "object",
|
|
37
|
+
"additionalProperties": false,
|
|
38
|
+
"required": ["id"],
|
|
39
|
+
"properties": {
|
|
40
|
+
"id": { "$ref": "common.schema.json#/$defs/stableId" },
|
|
41
|
+
"displayName": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"minLength": 1,
|
|
44
|
+
"maxLength": 200
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
},
|
|
48
|
+
"sessionId": { "$ref": "common.schema.json#/$defs/stableId" },
|
|
49
|
+
"commandCount": { "type": "integer", "minimum": 0, "maximum": 100000 },
|
|
50
|
+
"source": { "$ref": "common.schema.json#/$defs/artifactReference" },
|
|
51
|
+
"migrationId": { "$ref": "common.schema.json#/$defs/qualifiedName" }
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
},
|
|
55
|
+
"extensions": { "$ref": "common.schema.json#/$defs/extensions" }
|
|
56
|
+
}
|
|
57
|
+
}
|