SVG
SVG wrapper
With the <SVG>
component you can pass SVG paths in it. It behaves like the usual <svg>
element.
You can use all known properties from the regular <svg>
element.
Import
import { SVG } from '@marigold/system';
Props
Property | Type | Default | Description |
---|---|---|---|
size | number | string | number[] | string[] | 24 | The size of the SVG element. |
color | string | none | Color for the SVG element. Accepts color tokens. |
... |
| - | Yes you can use all regular attributes of svg! |
Examples
Simple SVG
In this example you can see how to use the <SVG>
element.
Preview
Code
Colorize
To modify the color, adjust the color
prop using a design token.
Preview
Code