PageColor
A directive that specifies an accent color for a given documentation page.
Declaration
@PageColor(_ color: Color)Parameters
- color:
A context-dependent, standard color. (required)
blueA context-dependent blue color.
grayA context-dependent gray color.
greenA context-dependent green color.
orangeA context-dependent orange color.
purpleA context-dependent purple color.
redA context-dependent red color.
yellowA context-dependent yellow color.
Mentioned in
Overview
Use the PageColor directive to provide a hint to the renderer as to how the page should be accented with color. The renderer may use this color, depending on the context, as a foundation for other colors used on the page. For example, Swift-DocC-Render uses this color as the primary background color of a page’s introduction section and adjusts other elements in the introduction section to account for the new background.
This directive is only valid within a Metadata directive:
@Metadata {
@PageColor(orange)
}