themes-corporate-modernist/card_override.templ
Alex Dunmow 4713787bbd initial: theme plugin corporate-modernist
Bootstrapped during the 2026-06-06 BlockNinja consolidation. Was previously
an unversioned directory inside ~/src/blockninja-themes/corporate-modernist.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-06-06 14:11:24 +08:00

26 lines
574 B
Plaintext

package main
// cardOverrideComponent renders a flat hairline-bordered card.
templ cardOverrideComponent(title, body string, accent bool) {
if accent {
<div class="cm-card cm-card-accent">
@cardOverrideInner(title, body)
</div>
} else {
<div class="cm-card">
@cardOverrideInner(title, body)
</div>
}
}
templ cardOverrideInner(title, body string) {
if title != "" {
<div class="cm-display" style="font-size: 1.25rem; font-weight: 600; margin: 0 0 0.75rem 0;">{ title }</div>
}
if body != "" {
<div class="cm-text">
@templ.Raw(body)
</div>
}
}