DocShell.Presentation.PageDecorations (DocShell v2.0.0)

Copy Markdown View Source

Checks renderer-neutral banner and hero records before page projection.

A banner has optional label, text, and href fields, with at least a label or text. A hero requires title and may carry tagline, description, ordinary link actions, and an image naming a logical local asset plus alt text. Text is plain UTF-8, never HTML. URLs, link lists and logical image names use the shared presentation settings policy and finite limits.

These records supply content, not a host product layout or a framework component. A renderer decides how to present them and must preserve their text and ordinary links without browser enhancement.

Summary

Functions

Validates an optional banner or hero and preserves the admitted record.

Functions

validate(kind, value)

@spec validate(:banner | :hero, term()) :: {:ok, map() | nil} | {:error, term()}

Validates an optional banner or hero and preserves the admitted record.