Skip to content
Corex

ProjectMetaRenderer

Corex\Portfolio\Blocks\ProjectMetaRenderer · class · Add-ons layer

Renders a project’s structured meta (client, role, year, external link) as an accessible, escaped definition list — showing only the fields that actually have a value, and rendering NOTHING when a project has no meta at all. The values come from the injected provider, so this is unit-testable without WordPress. It never fabricates a field: an unset value is simply omitted (honest empty).

render(array $attributes, string $content, object $block): string

Section titled “render(array $attributes, string $content, object $block): string”

Build the definition list from real values only. Separated from the WordPress post-id lookup so the presentation is testable directly.