Labels and lists

A label is a piece of content that appears at the start of a paragraph and spaced so that it lines up with similar labels in the same column. Labels are most often used for bullets or numbers at the start of list items.

A label is treated as a block mapping that merges with the following paragraph.

The position of the label content and the content after it are controlled by the following mapping properties:

  • The label offset is the distance from the start of the label content to the current left margin. It must be a positive value.

  • The minimum gap is the minimum distance from the end of the label to the start of the content after it. If the label is wider than the label offset this can be used to visually separate it from the paragraph content.

These values are illustrated below.

When there are multiple adjacent labels the Disable merge with previous property can be used to make a label appear on a new line. The image below shows the effect of this property on a list within another list. On the left the disable merge property is selected, on the right it is not.

The default positioning of a label places it on the same baseline as the first line of content. The label style can be set to “dropped” to make the paragraph content flow around it. The following is a comparison of the two styles, with normal on the left and dropped on the right: