List Item
A single item in a list.
This is an implementation, and extension, of schema.org ListItem
. It extends schema.ord ListItem
by adding content
and isChecked
properties. Analogues of ListItem
in other schema include: - JATS XML <list-item>
](https://jats.nlm.nih.gov/articleauthoring/tag-library/1.2/element/list-item.html) - HTML <li>
- MDAST ListItem
- OpenDocument <text:list-item>
Properties​
Name | @id | Type | Description | Inherited from |
---|---|---|---|---|
alternateNames | schema:alternateName | Array of string | Alternate names (aliases) for the item. | Thing |
content | stencila:content | Array of BlockContent or Array of InlineContent | The content of the list item. See note 1. | ListItem |
description | schema:description | Array of BlockContent or Array of InlineContent or string | A description of the item. See note 2. | Thing |
id | schema:id | string | The identifier for this item. | Entity |
identifiers | schema:identifier | Array of (PropertyValue or string) | Any kind of identifier for any kind of Thing. See note 3. | Thing |
images | schema:image | Array of (ImageObject or Format 'uri') | Images of the item. | Thing |
isChecked | stencila:isChecked | boolean | A flag to indicate if this list item is checked. | ListItem |
item | schema:item | Node | The item represented by this list item. See note 4. | ListItem |
meta | stencila:meta | object | Metadata associated with this item. | Entity |
name | schema:name | string | The name of the item. | Thing |
position | schema:position | integer | The position of the item in a series or sequence of items. | ListItem |
url | schema:url | Format 'uri' | The URL of the item. | Thing |
Notes​
- content : Use either
content
oritem
, not both. - description : Allows for the description to be an array of nodes (e.g. an array of inline content, or a couple of paragraphs), or a string. The
minItems
restriction avoids a string being coerced into an array with a single string item. - identifiers : Some identifiers have specific properties e.g the
issn
property for thePeriodical
type. These should be used in preference to this property which is intended for identifiers that do not yet have a specific property. Identifiers can be represented as strings, but using aPropertyValue
will usually be better because it allows forpropertyID
(i.e. the type of identifier). - item : Use either
item
orcontent
, not both.
Examples​
{
"type": "ListItem",
"content": [
"List Item Content"
]
}
{
"type": "ListItem",
"content": [
"List Item Content",
{
"type": "List",
"order": "ordered",
"items": [
"Nested Item One"
]
}
]
}
{
"type": "ListItem",
"isChecked": true,
"content": [
"Completed todo item"
]
}
Related​
- Parent: Thing
- Descendants: None
Available as​
- JSON-LD
- JSON Schema
- Python
class ListItem
- TypeScript
interface ListItem
- R
class ListItem
- Rust
struct ListItem
Source​
This documentation was generated from ListItem.schema.yaml.