Lists
Lists are mostly controlled within InDesign using the standard paragraph style properties, but you can optionally override the format using list format (<liFormat>). You can also add conditions (<condition> or @condition) and metadata (<meta>) to lists.
There are two types of lists: ordered (<ol>) and unordered (<ul>).
Ordered lists
The <ol> element defines an ordered list. An ordered list can be numerical or alphabetical. Use the list item (<li>) element to define list items.
New in CXML 3.4
<ol> now support @author and @dateTime.
<ol> has seven attributes:
| Attribute | Value | Description |
|---|---|---|
| type | string | Specifies the type of the ordered list. |
| id | string | The unique ID of the ordered list. |
| style | none 1 A a I i 01 001 0001 abjad alif ba tah kanji katakana modern katakana traditional hebrew biblical hebrew non‑standard | Specifies the style of the ordered list.
|
| start | integer | Starts number the list at the @start value. Must be a numeric value, even if the list uses letters or Roman numerals for numbering. |
| status | added changed deleted | Indicates the modification status of the ordered list. |
| author NEW | string | The author of the tracked change. |
| dateTime NEW | ISO 8601 datetime string | The date and time of the tracked change (2024-01-09T14:37:00Z). |
List format
The <liFormat> element overrides how your list is formatted.
<liFormat> has one attribute:
| Attribute | Value | Description |
|---|---|---|
| align | left center right justify justifyLeft justifyCenter justifyRight justifyFull | Specifies the horizontal alignment of items in a list. |
And you can set the list level and style via the List Item Reference (<liRef>) element.
New in CXML 3.4
<liRef> now supports @status, @author, and @dateTime.
<liRef> has five attributes:
| Attribute | Value | Description |
|---|---|---|
| level | integer | Specifies the list level. Defaults to 0 if omitted. |
| style | string | Specifies the style of the list. Note While the CXML schema defines this as a string, the expected values are the same as for ol@style. |
| status NEW | added changed deleted | Indicates the modification status of the list item reference. |
| author NEW | string | The author of the tracked change. |
| dateTime NEW | ISO 8601 datetime string | The date and time of the tracked change (2024-01-09T14:37:00Z). |
A <liRef> with tracked changes:
<ol start="1">
<liFormat>
<liRef style="a" status="added" author="Graham Chapman" dateTime="1975-04-05T09:00:00Z" />
)
<t />
</liFormat>
<li>
<p type="List Number 3">Favourite colour</p>
</li>
</ol>List item
The <li> element defines a list item in ordered and unordered lists.
An ordered list with style:
<ol start="1" style="1">
<li>
<p type="List Number">
This is a 1
<style type="superscript">st</style>
<s />
level bulleted list with an Arabic number
</p>
</li>
</ol>An ordered list formatted with <liFormat>:
<ol start="1">
<liFormat>
<liRef style="a" />
)
<t />
</liFormat>
<li>
<p type="List Number 3">
This is a 3rd
<s />
level numbered list with a lower case alpha
</p>
</li>
</ol>An ordered list with tracked changes:
<ol start="1" style="1" status="added" author="Graham Chapman" dateTime="1983-06-09T09:00:00Z">
<li>
<p type="List Number">Monty Python's The Meaning of Life</p>
</li>
</ol>Unordered lists
The <ul> element defines an unordered (bulleted) list. Use <ul> together with the list item (<li>) element to create unordered lists.
New in CXML 3.4
<ul> now support @author and @dateTime.
<ul> has six attributes:
| Attribute | Value | Description |
|---|---|---|
| type | string | Specifies the type of the unordered list. |
| id | string | The unique ID of the unordered list. |
| style | disc circle square Any Unicode character | Specifies the appearance of a list item marker in a list.
|
| status | added changed deleted | Indicates the modification status of the unordered list. |
| author NEW | string | The author of the tracked change. |
| dateTime NEW | ISO 8601 datetime string | The date and time of the tracked change (2024-01-09T14:37:00Z). |
A simple unordered list:
<ul>
<li>
<p>The Flying Circus</p>
</li>
<li>
<p>The Holy Grail</p>
</li>
<li>
<p>Life of Brian</p>
</li>
</ul>An unordered list with tracked changes:
<ul status="deleted" author="John Cleese" dateTime="1979-08-17T09:00:00Z">
<li>
<p>The Flying Circus</p>
</li>
<li>
<p>The Holy Grail</p>
</li>
<li>
<p>Life of Brian</p>
</li>
</ul><li> can contain any content that can appear inside a <section>, including paragraphs, nested lists, tables, and images.
An unordered list with a nested list:
<ul>
<li>
<p type="List Bullet">Camelot</p>
<ul>
<li><p type="List Bullet 2">It is a silly place</p></li>
</ul>
</li>
</ul>