|
1 | 1 | {
|
2 | 2 | "title": "Thing Description",
|
3 |
| - "version": "1.1-05-July-2023", |
| 3 | + "version": "1.1-12-March-2025", |
4 | 4 | "description": "JSON Schema for validating TD instances against the TD information model. TD instances can be with or without terms that have default values",
|
5 | 5 | "$schema": "http://json-schema.org/draft-07/schema#",
|
6 | 6 | "$id": "https://raw.githubusercontent.com/w3c/wot-thing-description/main/validation/td-json-schema-validation.json",
|
|
85 | 85 | "$ref": "#/definitions/anyUri"
|
86 | 86 | },
|
87 | 87 | {
|
88 |
| - "type": "object" |
| 88 | + "type": "object", |
| 89 | + "additionalProperties": { |
| 90 | + "type": "string" |
| 91 | + } |
89 | 92 | }
|
90 | 93 | ],
|
91 | 94 | "not": {
|
|
100 | 103 | {
|
101 | 104 | "$comment": "Old context URI, followed by the new one and possibly other vocabularies. minItems and contains are required since prefixItems does not say all items should be provided",
|
102 | 105 | "type": "array",
|
103 |
| - "prefixItems": [ |
| 106 | + "items": [ |
104 | 107 | {
|
105 | 108 | "$ref": "#/definitions/thing-context-td-uri-v1"
|
106 | 109 | },
|
|
109 | 112 | }
|
110 | 113 | ],
|
111 | 114 | "minItems": 2,
|
112 |
| - "contains": { |
113 |
| - "$ref": "#/definitions/thing-context-td-uri-v1.1" |
114 |
| - }, |
115 | 115 | "additionalItems": {
|
116 | 116 | "anyOf": [
|
117 | 117 | {
|
118 | 118 | "$ref": "#/definitions/anyUri"
|
119 | 119 | },
|
120 | 120 | {
|
121 |
| - "type": "object" |
| 121 | + "type": "object", |
| 122 | + "additionalProperties": { |
| 123 | + "type": "string" |
| 124 | + } |
122 | 125 | }
|
123 | 126 | ]
|
124 | 127 | }
|
125 | 128 | },
|
126 | 129 | {
|
127 | 130 | "$comment": "Old context URI, followed by possibly other vocabularies. minItems and contains are required since prefixItems does not say all items should be provided",
|
128 | 131 | "type": "array",
|
129 |
| - "prefixItems": [ |
| 132 | + "items": [ |
130 | 133 | {
|
131 | 134 | "$ref": "#/definitions/thing-context-td-uri-v1"
|
132 | 135 | }
|
133 | 136 | ],
|
134 | 137 | "minItems": 1,
|
135 |
| - "contains": { |
136 |
| - "$ref": "#/definitions/thing-context-td-uri-v1" |
137 |
| - }, |
138 | 138 | "additionalItems": {
|
139 | 139 | "anyOf": [
|
140 | 140 | {
|
141 | 141 | "$ref": "#/definitions/anyUri"
|
142 | 142 | },
|
143 | 143 | {
|
144 |
| - "type": "object" |
| 144 | + "type": "object", |
| 145 | + "additionalProperties": { |
| 146 | + "type": "string" |
| 147 | + } |
145 | 148 | }
|
146 | 149 | ]
|
147 | 150 | }
|
|
363 | 366 | "additionalProperties": true
|
364 | 367 | },
|
365 | 368 | "form_element_property": {
|
366 |
| - "allOf": [ |
367 |
| - { |
368 |
| - "$ref": "#/definitions/form_element_base" |
369 |
| - } |
370 |
| - ], |
| 369 | + "allOf": [{ "$ref": "#/definitions/form_element_base" }], |
371 | 370 | "type": "object",
|
372 | 371 | "properties": {
|
373 | 372 | "op": {
|
|
390 | 389 | "additionalProperties": true
|
391 | 390 | },
|
392 | 391 | "form_element_action": {
|
393 |
| - "allOf": [ |
394 |
| - { |
395 |
| - "$ref": "#/definitions/form_element_base" |
396 |
| - } |
397 |
| - ], |
| 392 | + "allOf": [{ "$ref": "#/definitions/form_element_base" }], |
398 | 393 | "type": "object",
|
399 | 394 | "properties": {
|
400 | 395 | "op": {
|
|
417 | 412 | "additionalProperties": true
|
418 | 413 | },
|
419 | 414 | "form_element_event": {
|
420 |
| - "allOf": [ |
421 |
| - { |
422 |
| - "$ref": "#/definitions/form_element_base" |
423 |
| - } |
424 |
| - ], |
| 415 | + "allOf": [{ "$ref": "#/definitions/form_element_base" }], |
425 | 416 | "type": "object",
|
426 | 417 | "properties": {
|
427 | 418 | "op": {
|
|
444 | 435 | "additionalProperties": true
|
445 | 436 | },
|
446 | 437 | "form_element_root": {
|
447 |
| - "allOf": [ |
448 |
| - { |
449 |
| - "$ref": "#/definitions/form_element_base" |
450 |
| - } |
451 |
| - ], |
| 438 | + "allOf": [{ "$ref": "#/definitions/form_element_base" }], |
452 | 439 | "type": "object",
|
453 | 440 | "properties": {
|
454 | 441 | "op": {
|
|
494 | 481 | "form": {
|
495 | 482 | "$comment": "This is NOT for validation purposes but for automatic generation of TS types. For more info, please see: https://github.com/w3c/wot-thing-description/pull/1319#issuecomment-994950057",
|
496 | 483 | "oneOf": [
|
497 |
| - { |
498 |
| - "$ref": "#/definitions/form_element_property" |
499 |
| - }, |
500 |
| - { |
501 |
| - "$ref": "#/definitions/form_element_action" |
502 |
| - }, |
503 |
| - { |
504 |
| - "$ref": "#/definitions/form_element_event" |
505 |
| - }, |
506 |
| - { |
507 |
| - "$ref": "#/definitions/form_element_root" |
508 |
| - } |
| 484 | + { "$ref": "#/definitions/form_element_property" }, |
| 485 | + { "$ref": "#/definitions/form_element_action" }, |
| 486 | + { "$ref": "#/definitions/form_element_event" }, |
| 487 | + { "$ref": "#/definitions/form_element_root" } |
509 | 488 | ]
|
510 | 489 | },
|
511 | 490 | "property_element": {
|
|
743 | 722 | },
|
744 | 723 | "hreflang": {
|
745 | 724 | "anyOf": [
|
746 |
| - { |
747 |
| - "$ref": "#/definitions/bcp47_string" |
748 |
| - }, |
| 725 | + { "$ref": "#/definitions/bcp47_string" }, |
749 | 726 | {
|
750 | 727 | "type": "array",
|
751 | 728 | "items": {
|
|
0 commit comments