betty.project.extension.cotton_candy.config module

Provide configuration for the Cotton Candy extension.

class betty.project.extension.cotton_candy.config.CottonCandyConfiguration[source]

Bases: Configuration

Provide configuration for the betty.project.extension.cotton_candy.CottonCandy extension.

DEFAULT_PRIMARY_ACTIVE_COLOR = '#ff69b4'
DEFAULT_PRIMARY_INACTIVE_COLOR = '#ffc0cb'
__init__(*, featured_entities: Sequence[EntityReference[UserFacingEntity & Entity]] | None = None, primary_inactive_color: str = '#ffc0cb', primary_active_color: str = '#ff69b4', link_inactive_color: str = '#149988', link_active_color: str = '#2a615a')[source]
dump() DumpMapping[Dump][source]

Produce a serialized data dump of self.

property featured_entities: EntityReferenceSequence[UserFacingEntity & Entity]

The entities featured on the front page.

The color for active hyperlinks.

The color for inactive hyperlinks.

load(dump: Dump) None[source]

Load a serialized data dump into self.

Raises:

betty.assertion.error.AssertionFailed – Raised if the dump is invalid.

property primary_active_color: ColorConfiguration

The color for active primary/CTA elements.

property primary_inactive_color: ColorConfiguration

The color for inactive primary/CTA elements.