diff options
author | toasted-nutbread <toasted-nutbread@users.noreply.github.com> | 2021-06-25 17:24:29 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-25 17:24:29 -0400 |
commit | 5756885fa9340f087a168d40c8d0d10a3a8fe4d5 (patch) | |
tree | e960821662a12b70430590c9ea4f43b1abc4d54c /ext/data/schemas/dictionary-term-bank-v3-schema.json | |
parent | cf70b3de6411cfd540f2c3c7f6e1c27afb10ef84 (diff) |
Structured content updates (#1753)
* Update schema
* Update content generation
* Update styles
* Update test data
* Update style names
Diffstat (limited to 'ext/data/schemas/dictionary-term-bank-v3-schema.json')
-rw-r--r-- | ext/data/schemas/dictionary-term-bank-v3-schema.json | 107 |
1 files changed, 106 insertions, 1 deletions
diff --git a/ext/data/schemas/dictionary-term-bank-v3-schema.json b/ext/data/schemas/dictionary-term-bank-v3-schema.json index fd3f3844..af4494ff 100644 --- a/ext/data/schemas/dictionary-term-bank-v3-schema.json +++ b/ext/data/schemas/dictionary-term-bank-v3-schema.json @@ -19,6 +19,20 @@ "oneOf": [ { "type": "object", + "description": "Empty tags.", + "required": [ + "tag" + ], + "additionalProperties": false, + "properties": { + "tag": { + "type": "string", + "enum": ["br"] + } + } + }, + { + "type": "object", "description": "Generic container tags.", "required": [ "tag" @@ -27,10 +41,58 @@ "properties": { "tag": { "type": "string", - "enum": ["ruby", "rt", "rp"] + "enum": ["ruby", "rt", "rp", "table", "thead", "tbody", "tfoot", "tr"] + }, + "content": { + "$ref": "#/definitions/structuredContent" + } + } + }, + { + "type": "object", + "description": "Table tags.", + "required": [ + "tag" + ], + "additionalProperties": false, + "properties": { + "tag": { + "type": "string", + "enum": ["td", "th"] + }, + "content": { + "$ref": "#/definitions/structuredContent" + }, + "colSpan": { + "type": "integer", + "minimum": 1 + }, + "rowSpan": { + "type": "integer", + "minimum": 1 + }, + "style": { + "$ref": "#/definitions/structuredContentStyle" + } + } + }, + { + "type": "object", + "description": "Container tags supporting configurable styles.", + "required": [ + "tag" + ], + "additionalProperties": false, + "properties": { + "tag": { + "type": "string", + "enum": ["span", "div"] }, "content": { "$ref": "#/definitions/structuredContent" + }, + "style": { + "$ref": "#/definitions/structuredContentStyle" } } }, @@ -112,6 +174,49 @@ ] } ] + }, + "structuredContentStyle": { + "type": "object", + "additionalProperties": false, + "properties": { + "fontStyle": { + "type": "string", + "enum": ["normal", "italic"], + "default": "normal" + }, + "fontWeight": { + "type": "string", + "enum": ["normal", "bold"], + "default": "normal" + }, + "fontSize": { + "type": "string", + "enum": ["xx-small", "x-small", "small", "medium", "large", "x-large", "xx-large", "xxx-large"], + "default": "medium" + }, + "textDecorationLine": { + "oneOf": [ + { + "type": "string", + "enum": ["none", "underline", "overline", "line-through"], + "default": "none" + }, + { + "type": "array", + "items": { + "type": "string", + "enum": ["underline", "overline", "line-through"], + "default": "none" + } + } + ] + }, + "verticalAlign": { + "type": "string", + "enum": ["baseline", "sub", "super", "text-top", "text-bottom", "middle", "top", "bottom"], + "default": "baseline" + } + } } }, "type": "array", |