UNPKG

@stencila/schema

Version:

Extensions to schema.org to support semantic, composable, parameterize-able and executable documents

104 lines (103 loc) 3.21 kB
{ "title": "TableCell", "@id": "stencila:TableCell", "extends": "Entity", "role": "secondary", "status": "unstable", "category": "text", "description": "A cell within a `Table`.\n", "properties": { "type": { "@id": "schema:type", "description": "The name of the type.", "type": "string", "enum": [ "TableCell" ], "default": "TableCell", "from": "Entity" }, "id": { "@id": "schema:id", "description": "The identifier for this item.", "type": "string", "from": "Entity" }, "meta": { "@id": "stencila:meta", "description": "Metadata associated with this item.", "type": "object", "from": "Entity" }, "name": { "@id": "schema:name", "description": "The name of the cell.", "$comment": "Cell's have an implicit name derived from their position in the table\ne.g. `C4` for the cell in the third column and fourth row. However this name can be overridden\nwith an explicit name, e.g. `rate`.\n", "type": "string", "from": "TableCell" }, "colspan": { "@id": "stencila:colspan", "description": "How many columns the cell extends.\n", "$comment": "Based on the HTML `colspan` attribute for [table cells](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td).", "type": "integer", "minimum": 0, "maximum": 1000, "default": 1, "from": "TableCell" }, "cellType": { "@id": "stencila:cellType", "description": "Indicates whether the cell is a header or data.", "$comment": "When `header`, the cell is similar to the HTML [`<th>` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/th)).\nWhen `data`, the cell is similar to the HTML [`<td>` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td)).\n", "type": "string", "enum": [ "Data", "Header" ], "default": "data", "from": "TableCell" }, "rowspan": { "@id": "stencila:rowspan", "description": "How many columns the cell extends.", "$comment": "Based on the HTML `rowspan` attribute for [table cells](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/td).", "type": "integer", "minimum": 0, "maximum": 65534, "default": 1, "from": "TableCell" }, "content": { "@id": "stencila:content", "description": "Contents of the table cell.", "anyOf": [ { "type": "array", "items": { "$ref": "BlockContent.schema.json" } }, { "type": "array", "items": { "$ref": "InlineContent.schema.json" } } ], "from": "TableCell" } }, "file": "TableCell.schema.yaml", "children": [], "descendants": [], "$schema": "http://json-schema.org/draft-07/schema#", "$id": "https://schema.stenci.la/v1/TableCell.schema.json", "source": "https://github.com/stencila/schema/blob/master/schema/TableCell.schema.yaml", "type": "object", "additionalProperties": false, "required": [ "type" ], "propertyAliases": {} }