@kumwe/studio-protocol 0.1.0-alpha.5 → 0.1.0-rc.1
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/README.md +59 -4
- 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 +4 -1
- package/dist/guards.d.ts.map +1 -1
- package/dist/guards.js +72 -30
- package/dist/guards.js.map +1 -1
- 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 +6 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +5 -3
- package/dist/index.js.map +1 -1
- package/dist/schemas.d.ts +17 -0
- package/dist/schemas.d.ts.map +1 -1
- package/dist/schemas.js +51 -0
- package/dist/schemas.js.map +1 -1
- package/dist/types.d.ts +123 -6
- package/dist/types.d.ts.map +1 -1
- package/dist/types.js +6 -1
- package/dist/types.js.map +1 -1
- package/package.json +6 -2
- 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 +10 -1
- package/schemas/host-sequence-vector.schema.json +342 -0
- package/schemas/host-vector.schema.json +2 -0
- package/schemas/manifest.json +75 -6
- package/schemas/preview-message.schema.json +44 -12
- package/schemas/preview-vector.schema.json +52 -0
- package/schemas/renderer-web-vector.schema.json +160 -0
- package/schemas/rich-text-projection.schema.json +12 -3
- package/schemas/rich-text.schema.json +156 -7
- package/schemas/schema-profile-vector.schema.json +133 -0
- package/schemas/schema-profile.schema.json +47 -7
- package/schemas/studio-chart.schema.json +35 -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/studio-release.json +28 -0
|
@@ -2,7 +2,18 @@
|
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
3
|
"$id": "https://schemas.kumwe.org/studio/v1/schema-profile.schema.json",
|
|
4
4
|
"title": "Studio Schema Profile meta-schema",
|
|
5
|
-
"
|
|
5
|
+
"allOf": [
|
|
6
|
+
{ "$ref": "#/$defs/schema" },
|
|
7
|
+
{
|
|
8
|
+
"type": "object",
|
|
9
|
+
"propertyNames": { "$ref": "common.schema.json#/$defs/safeJsonMemberName" },
|
|
10
|
+
"required": ["type", "additionalProperties"],
|
|
11
|
+
"properties": {
|
|
12
|
+
"type": { "const": "object" },
|
|
13
|
+
"additionalProperties": { "const": false }
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
],
|
|
6
17
|
"$defs": {
|
|
7
18
|
"schema": {
|
|
8
19
|
"type": "object",
|
|
@@ -53,14 +64,14 @@
|
|
|
53
64
|
"$ref": {
|
|
54
65
|
"type": "string",
|
|
55
66
|
"maxLength": 500,
|
|
56
|
-
"pattern": "^#(?:/[
|
|
67
|
+
"pattern": "^#(?:/(?:[A-Za-z0-9._!$&'()*+,;=:@-]|~[01])*)*(?![\\s\\S])"
|
|
57
68
|
},
|
|
58
69
|
"$schema": { "const": "https://json-schema.org/draft/2020-12/schema" },
|
|
59
70
|
"additionalProperties": { "$ref": "#/$defs/subschema" },
|
|
60
71
|
"allOf": { "$ref": "#/$defs/schemaArray" },
|
|
61
72
|
"anyOf": { "$ref": "#/$defs/schemaArray" },
|
|
62
|
-
"const": { "$ref": "
|
|
63
|
-
"default": { "$ref": "
|
|
73
|
+
"const": { "$ref": "#/$defs/jsonValue" },
|
|
74
|
+
"default": { "$ref": "#/$defs/jsonValue" },
|
|
64
75
|
"dependentRequired": {
|
|
65
76
|
"type": "object",
|
|
66
77
|
"maxProperties": 512,
|
|
@@ -68,6 +79,7 @@
|
|
|
68
79
|
"additionalProperties": {
|
|
69
80
|
"type": "array",
|
|
70
81
|
"maxItems": 512,
|
|
82
|
+
"uniqueItems": true,
|
|
71
83
|
"items": { "$ref": "common.schema.json#/$defs/safeJsonMemberName" }
|
|
72
84
|
}
|
|
73
85
|
},
|
|
@@ -75,13 +87,15 @@
|
|
|
75
87
|
"else": { "$ref": "#/$defs/subschema" },
|
|
76
88
|
"enum": {
|
|
77
89
|
"type": "array",
|
|
90
|
+
"minItems": 1,
|
|
78
91
|
"maxItems": 1024,
|
|
79
|
-
"
|
|
92
|
+
"uniqueItems": true,
|
|
93
|
+
"items": { "$ref": "#/$defs/jsonValue" }
|
|
80
94
|
},
|
|
81
95
|
"examples": {
|
|
82
96
|
"type": "array",
|
|
83
97
|
"maxItems": 100,
|
|
84
|
-
"items": { "$ref": "
|
|
98
|
+
"items": { "$ref": "#/$defs/jsonValue" }
|
|
85
99
|
},
|
|
86
100
|
"exclusiveMaximum": { "type": "number" },
|
|
87
101
|
"exclusiveMinimum": { "type": "number" },
|
|
@@ -105,6 +119,7 @@
|
|
|
105
119
|
"required": {
|
|
106
120
|
"type": "array",
|
|
107
121
|
"maxItems": 512,
|
|
122
|
+
"uniqueItems": true,
|
|
108
123
|
"items": { "$ref": "common.schema.json#/$defs/safeJsonMemberName" }
|
|
109
124
|
},
|
|
110
125
|
"then": { "$ref": "#/$defs/subschema" },
|
|
@@ -127,6 +142,7 @@
|
|
|
127
142
|
},
|
|
128
143
|
"schemaArray": {
|
|
129
144
|
"type": "array",
|
|
145
|
+
"minItems": 1,
|
|
130
146
|
"maxItems": 64,
|
|
131
147
|
"items": { "$ref": "#/$defs/subschema" }
|
|
132
148
|
},
|
|
@@ -136,6 +152,25 @@
|
|
|
136
152
|
"propertyNames": { "$ref": "common.schema.json#/$defs/safeJsonMemberName" },
|
|
137
153
|
"additionalProperties": { "$ref": "#/$defs/schema" }
|
|
138
154
|
},
|
|
155
|
+
"jsonValue": {
|
|
156
|
+
"oneOf": [
|
|
157
|
+
{ "type": "null" },
|
|
158
|
+
{ "type": "boolean" },
|
|
159
|
+
{ "type": "number" },
|
|
160
|
+
{ "type": "string" },
|
|
161
|
+
{
|
|
162
|
+
"type": "array",
|
|
163
|
+
"maxItems": 10000,
|
|
164
|
+
"items": { "$ref": "#/$defs/jsonValue" }
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
"type": "object",
|
|
168
|
+
"maxProperties": 1000,
|
|
169
|
+
"propertyNames": { "$ref": "common.schema.json#/$defs/safeJsonMemberName" },
|
|
170
|
+
"additionalProperties": { "$ref": "#/$defs/jsonValue" }
|
|
171
|
+
}
|
|
172
|
+
]
|
|
173
|
+
},
|
|
139
174
|
"subschema": {
|
|
140
175
|
"oneOf": [{ "type": "boolean" }, { "$ref": "#/$defs/schema" }]
|
|
141
176
|
},
|
|
@@ -145,16 +180,21 @@
|
|
|
145
180
|
"limits": {
|
|
146
181
|
"const": {
|
|
147
182
|
"maxAlternatives": 64,
|
|
183
|
+
"maxDescriptionLength": 10000,
|
|
148
184
|
"maxEnumMembers": 1024,
|
|
185
|
+
"maxExamples": 100,
|
|
149
186
|
"maxJsonDepth": 64,
|
|
150
187
|
"maxJsonItems": 10000,
|
|
151
188
|
"maxJsonProperties": 1000,
|
|
152
189
|
"maxObjectKeyLength": 200,
|
|
190
|
+
"maxPropertyNames": 512,
|
|
191
|
+
"maxReferenceLength": 500,
|
|
153
192
|
"maxReferences": 128,
|
|
154
193
|
"maxSchemaBytes": 262144,
|
|
155
194
|
"maxSchemaDepth": 32,
|
|
156
195
|
"maxSchemaMapProperties": 512,
|
|
157
|
-
"maxSchemaNodes": 1024
|
|
196
|
+
"maxSchemaNodes": 1024,
|
|
197
|
+
"maxTitleLength": 1000
|
|
158
198
|
}
|
|
159
199
|
}
|
|
160
200
|
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/studio-chart.schema.json",
|
|
4
|
+
"title": "Studio canonical chart",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["type", "labels", "datasets"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"type": { "enum": ["bar", "doughnut", "line", "pie"] },
|
|
10
|
+
"title": { "type": "string", "maxLength": 500 },
|
|
11
|
+
"labels": {
|
|
12
|
+
"type": "array",
|
|
13
|
+
"maxItems": 200,
|
|
14
|
+
"items": { "type": "string", "maxLength": 500 }
|
|
15
|
+
},
|
|
16
|
+
"datasets": {
|
|
17
|
+
"type": "array",
|
|
18
|
+
"minItems": 1,
|
|
19
|
+
"maxItems": 20,
|
|
20
|
+
"items": {
|
|
21
|
+
"type": "object",
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"required": ["label", "values"],
|
|
24
|
+
"properties": {
|
|
25
|
+
"label": { "type": "string", "maxLength": 500 },
|
|
26
|
+
"values": {
|
|
27
|
+
"type": "array",
|
|
28
|
+
"maxItems": 200,
|
|
29
|
+
"items": { "type": "number", "minimum": -1000000000000000, "maximum": 1000000000000000 }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/studio-drawing.schema.json",
|
|
4
|
+
"title": "Studio canonical drawing",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["width", "height", "alt", "strokes"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"width": { "type": "integer", "minimum": 1, "maximum": 4096 },
|
|
10
|
+
"height": { "type": "integer", "minimum": 1, "maximum": 4096 },
|
|
11
|
+
"alt": { "type": "string", "minLength": 1, "maxLength": 5000 },
|
|
12
|
+
"strokes": {
|
|
13
|
+
"type": "array",
|
|
14
|
+
"maxItems": 5000,
|
|
15
|
+
"items": {
|
|
16
|
+
"type": "object",
|
|
17
|
+
"additionalProperties": false,
|
|
18
|
+
"required": ["color", "width", "points"],
|
|
19
|
+
"properties": {
|
|
20
|
+
"color": {
|
|
21
|
+
"type": "string",
|
|
22
|
+
"pattern": "^(?:#[0-9A-Fa-f]{6}|[a-z][a-z0-9-]{0,62}/[a-z][a-z0-9-]{0,62})$",
|
|
23
|
+
"maxLength": 127
|
|
24
|
+
},
|
|
25
|
+
"width": { "type": "number", "minimum": 0.25, "maximum": 64 },
|
|
26
|
+
"points": {
|
|
27
|
+
"type": "array",
|
|
28
|
+
"minItems": 1,
|
|
29
|
+
"maxItems": 10000,
|
|
30
|
+
"items": {
|
|
31
|
+
"type": "object",
|
|
32
|
+
"additionalProperties": false,
|
|
33
|
+
"required": ["x", "y"],
|
|
34
|
+
"properties": {
|
|
35
|
+
"x": { "type": "number", "minimum": 0, "maximum": 4096 },
|
|
36
|
+
"y": { "type": "number", "minimum": 0, "maximum": 4096 }
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/studio-money.schema.json",
|
|
4
|
+
"title": "Studio canonical money",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["amount", "currency"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"amount": {
|
|
10
|
+
"type": "string",
|
|
11
|
+
"pattern": "^-?(?:0|[1-9][0-9]{0,17})(?:\\.[0-9]{1,6})?$",
|
|
12
|
+
"maxLength": 26
|
|
13
|
+
},
|
|
14
|
+
"currency": { "type": "string", "pattern": "^[A-Z]{3}$" }
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/studio-presentation.schema.json",
|
|
4
|
+
"title": "Studio presentation intent",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"maxProperties": 12,
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"properties": {
|
|
9
|
+
"align": { "enum": ["center", "end", "start", "stretch"] },
|
|
10
|
+
"animation": { "enum": ["fade", "none", "parallax", "scale", "slide"] },
|
|
11
|
+
"height": { "enum": ["auto", "content", "full", "viewport"] },
|
|
12
|
+
"inverse": { "type": "boolean" },
|
|
13
|
+
"margin": { "enum": ["comfortable", "compact", "none", "spacious"] },
|
|
14
|
+
"marker": { "enum": ["check", "decimal", "disc", "none"] },
|
|
15
|
+
"padding": { "enum": ["comfortable", "compact", "none", "spacious"] },
|
|
16
|
+
"position": { "enum": ["flow", "relative", "sticky"] },
|
|
17
|
+
"print": { "enum": ["hide", "only", "show"] },
|
|
18
|
+
"scrolling": { "enum": ["auto", "clip", "snap", "visible"] },
|
|
19
|
+
"visibility": {
|
|
20
|
+
"type": "object",
|
|
21
|
+
"maxProperties": 3,
|
|
22
|
+
"additionalProperties": false,
|
|
23
|
+
"properties": {
|
|
24
|
+
"compact": { "enum": ["hidden", "visible"] },
|
|
25
|
+
"expanded": { "enum": ["hidden", "visible"] },
|
|
26
|
+
"medium": { "enum": ["hidden", "visible"] }
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"width": { "enum": ["auto", "content", "full"] }
|
|
30
|
+
}
|
|
31
|
+
}
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/studio-release.schema.json",
|
|
4
|
+
"title": "Studio coordinated release record",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": [
|
|
8
|
+
"contractVersion",
|
|
9
|
+
"kind",
|
|
10
|
+
"release",
|
|
11
|
+
"packages",
|
|
12
|
+
"protocolVersion",
|
|
13
|
+
"corpusManifestDigest",
|
|
14
|
+
"claimedProfiles"
|
|
15
|
+
],
|
|
16
|
+
"properties": {
|
|
17
|
+
"contractVersion": {
|
|
18
|
+
"$ref": "common.schema.json#/$defs/contractVersion"
|
|
19
|
+
},
|
|
20
|
+
"kind": {
|
|
21
|
+
"const": "studio-release"
|
|
22
|
+
},
|
|
23
|
+
"release": {
|
|
24
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
25
|
+
},
|
|
26
|
+
"packages": {
|
|
27
|
+
"type": "object",
|
|
28
|
+
"additionalProperties": false,
|
|
29
|
+
"required": [
|
|
30
|
+
"@kumwe/studio-core",
|
|
31
|
+
"@kumwe/studio-media",
|
|
32
|
+
"@kumwe/studio-preview",
|
|
33
|
+
"@kumwe/studio-protocol",
|
|
34
|
+
"@kumwe/studio-renderer-web",
|
|
35
|
+
"@kumwe/studio-rich-text",
|
|
36
|
+
"@kumwe/studio",
|
|
37
|
+
"@kumwe/studio-testkit"
|
|
38
|
+
],
|
|
39
|
+
"properties": {
|
|
40
|
+
"@kumwe/studio-core": {
|
|
41
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
42
|
+
},
|
|
43
|
+
"@kumwe/studio-media": {
|
|
44
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
45
|
+
},
|
|
46
|
+
"@kumwe/studio-preview": {
|
|
47
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
48
|
+
},
|
|
49
|
+
"@kumwe/studio-protocol": {
|
|
50
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
51
|
+
},
|
|
52
|
+
"@kumwe/studio-renderer-web": {
|
|
53
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
54
|
+
},
|
|
55
|
+
"@kumwe/studio-rich-text": {
|
|
56
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
57
|
+
},
|
|
58
|
+
"@kumwe/studio": {
|
|
59
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
60
|
+
},
|
|
61
|
+
"@kumwe/studio-testkit": {
|
|
62
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
"protocolVersion": {
|
|
67
|
+
"$ref": "common.schema.json#/$defs/semanticVersion"
|
|
68
|
+
},
|
|
69
|
+
"corpusManifestDigest": {
|
|
70
|
+
"$ref": "common.schema.json#/$defs/integrity"
|
|
71
|
+
},
|
|
72
|
+
"claimedProfiles": {
|
|
73
|
+
"type": "array",
|
|
74
|
+
"maxItems": 32,
|
|
75
|
+
"uniqueItems": true,
|
|
76
|
+
"items": {
|
|
77
|
+
"$ref": "common.schema.json#/$defs/qualifiedName"
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.kumwe.org/studio/v1/studio-table.schema.json",
|
|
4
|
+
"title": "Studio table document",
|
|
5
|
+
"type": "object",
|
|
6
|
+
"additionalProperties": false,
|
|
7
|
+
"required": ["columns", "rows"],
|
|
8
|
+
"properties": {
|
|
9
|
+
"caption": { "type": "string", "maxLength": 500 },
|
|
10
|
+
"columns": {
|
|
11
|
+
"type": "array",
|
|
12
|
+
"minItems": 1,
|
|
13
|
+
"maxItems": 50,
|
|
14
|
+
"items": { "type": "string", "maxLength": 500 }
|
|
15
|
+
},
|
|
16
|
+
"rows": {
|
|
17
|
+
"type": "array",
|
|
18
|
+
"maxItems": 1000,
|
|
19
|
+
"items": {
|
|
20
|
+
"type": "array",
|
|
21
|
+
"minItems": 1,
|
|
22
|
+
"maxItems": 50,
|
|
23
|
+
"items": { "type": "string", "maxLength": 5000 }
|
|
24
|
+
}
|
|
25
|
+
}
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
{
|
|
2
|
+
"contractVersion": "0.1-draft",
|
|
3
|
+
"kind": "studio-release",
|
|
4
|
+
"release": "0.1.0-rc.1",
|
|
5
|
+
"packages": {
|
|
6
|
+
"@kumwe/studio-core": "0.1.0-rc.1",
|
|
7
|
+
"@kumwe/studio-media": "0.1.0-rc.1",
|
|
8
|
+
"@kumwe/studio-preview": "0.1.0-rc.1",
|
|
9
|
+
"@kumwe/studio-protocol": "0.1.0-rc.1",
|
|
10
|
+
"@kumwe/studio-renderer-web": "0.1.0-rc.1",
|
|
11
|
+
"@kumwe/studio-rich-text": "0.1.0-rc.1",
|
|
12
|
+
"@kumwe/studio": "0.1.0-rc.1",
|
|
13
|
+
"@kumwe/studio-testkit": "0.1.0-rc.1"
|
|
14
|
+
},
|
|
15
|
+
"protocolVersion": "0.1.0-draft.2",
|
|
16
|
+
"corpusManifestDigest": "sha256-4/ChS3pCA32CoZ+BjvL2tj2RGOFJNdqXwuqO8gWDxTs=",
|
|
17
|
+
"claimedProfiles": [
|
|
18
|
+
"studio.profile/authoring-web",
|
|
19
|
+
"studio.profile/binding-projection-v1",
|
|
20
|
+
"studio.profile/engine-core",
|
|
21
|
+
"studio.profile/host-baseline",
|
|
22
|
+
"studio.profile/host-baseline-v2",
|
|
23
|
+
"studio.profile/media-policy",
|
|
24
|
+
"studio.profile/preview-identity-v1",
|
|
25
|
+
"studio.profile/renderer-web",
|
|
26
|
+
"studio.profile/schema-property"
|
|
27
|
+
]
|
|
28
|
+
}
|