This container component provides the ability to display actual richtext of any CMS Content in any page of a site (i.e. not only in the record pages corresponding to their CMS type).
As an example, it enables to include CMS managed content as header of an object list page or display 2 or let a few sections of a standard page be managed via CMS.
The component basically displays a title
, a standard text excerpt
and a richtext body
of any CMS Content record selected. The 3 values are optional but displayed in this order
with the ability to:
- define the actual h level of the
title
- choose CSS classes for the
title
,excerpt
andbody
Concerning the richtext body
property, its richtext value is slightly reworked before display mainly for accessibility purposes. This is achieved via the
sfpegCmsRichtextDisplay component.
The component is entirely configured from Site Builder.
The first operation is to select a CMS content record via the Add Content
button
in the component configuration popup (this button becoming Change Content
afterwards).
Then all other properties may be set:
Show Title?
to choose whether or not display the default content titleTitle Field
to choose a text field to display as content title (ifShow Title?
is not checked)Title Level
to choose the h element level to use for the title (h1, h2...)Title CSS
to add a custom CSS styling class on the titleExcerpt Field
to choose a text field to display as content excerptExcerpt CSS
to add a custom CSS styling class on the excerptContent Field
to choose a richtext field to display as content bodyContent CSS
to add a custom CSS styling class on the content bodyLink Title
to add a default title to all links included in the content bodyShow Debug?
to activate debug logs
The 3 elements (title
, excerpt
, body
) are optional but displayed in this order.
It leverages the standard CMS wire getContent service to fetch content data.
It leverages the sfpegCmsRichtextDisplay
component to rework and display the Content
value.