Quoted String

Some keys accept a quoted string as text content. The final segment of these keys is always named content.

A content key accepts a string value. It’s usually best to quote the string or use the YAML multi-line string syntax.

Text content may be formatted using a subset of inline HTML. You can use the well-known elements such as <strong>, <em>, <code>, <a>, <sub>, <sup>, <del>, and <span>. The <span> element supports the style attribute, which you can use to specify the color, font-weight, and font-style CSS properties. You can also use the rgb attribute on the <color> element to change the color or the name and size attributes on the <font> element to change the font properties. If you need to add an underline or strikethrough decoration to the text, you can assign the underline or line-through to the class attribute on any aforementioned element.

Here’s an example of using formatting in the content of the menu caret:

menu-caret-content: " <font size=\"1.15em\"><color rgb=\"#b12146\">\u203a</color></font> "
The string must be double quoted in order to use a Unicode escape code like \u203a.

Additionally, normal substitutions are applied to the value of content keys for running content, so you can use most AsciiDoc inline formatting (e.g., *strong* or {attribute-name}) in the values of those keys.