Button
Brutalist press button with variant/size/tone matrix.
primitive button
Controls
variant
size
tone
disabled
label
Current props
variant: ""size: ""tone: ""disabled:label: ""
Usage
import "mljr-web/ui/primitive"
import "mljr-web/ui/token"
// Basic
primitive.Button(primitive.ButtonProps{
Variant: token.Primary,
Size: token.MD,
}, g.Text("Click me"))
// With tone
primitive.Button(primitive.ButtonProps{
Variant: token.Tone,
Tone: token.ToneCyan,
}, g.Text("Cyan"))
// Icon size
primitive.Button(primitive.ButtonProps{
Variant: token.Outline,
Size: token.SizeIcon,
}, icon.Icon("lucide:plus"))All combinations (216)
Enum controls only · bool and text use defaults
Props
| Name | Type | Options | Default |
|---|---|---|---|
variant | enum | primary, secondary, outline, danger, ghost, tone | primary |
size | enum | sm, md, lg, icon | md |
tone | enum | , yellow, cyan, violet, pink, lime, mint, sky, blush | |
disabled | bool | — | false |
label | text | — | Click me |