Primitive

Code

Auto-emitted from DSKintsugiCatalog.code. Tier atom.

Live Preview
Inline · JetBrains Mono 400 · 13 px · gold tint bg

Call katagami.code("value") to render an inline snippet inside body copy. The TextStyle.mono token drives font, size, and color consistently across surfaces.

Block · <pre><code> · navy-deep bg · cream text
// katagami DSL — block code example
let view = katagami.vstack {
    katagami.heading("Portfolio Overview", style: .h1)
    katagami.code(block: "let delta = position.value - position.costBasis")
}
Native · macOS
macOS SwiftUI render of Code
DSL usage
// Inline
katagami.code("TextStyle.mono")
// renders: <code> — JetBrains Mono 400 13 px, rgba(213,165,96,0.10) bg, var(--navy-deep) color

// Block
katagami.code(block: "let delta = position.value - position.costBasis")
// renders: <pre><code> — navy-deep bg (--sb-code-bg), cream text (--sb-code-text)
Attributes
NameTypeDefaultDescription
content String Code content (inline or block string)
block Bool false false → <code> inline | true → <pre><code> block
language String? nil Optional language hint for syntax-highlighter pass-through
density Density regular compact | regular | expanded
locale Locale en BCP-47 locale tag for locale-aware rendering
Used in
KatagamiScreens c-tech sigma-analytics