Primitive
Button
Click-actionable element. Emits button.ks-button. Used by sm-shoppable-product (variant pick + add-to-cart) and sm-cart (checkout).
Responsive Preview — viewport @media queries
Mobile · 375 px
Tablet · 768 px
Desktop · 1280 px
Container Tier (SM widget responsive system)
Container width
Live Preview (chrome-mode, container-tier knobs)
DSL usage
Button("Primary") {
viewModel.handle()
}
.buttonStyle(.borderedProminent)
Attributes
| Name | Type | Default | Description |
|---|---|---|---|
label | String | | Button label text |
style | ButtonStyle | primary | primary | secondary | ghost |
action | () -> Void | | Closure executed on tap |