PathProps
Props of Path: its path data and paint.
Usage
Draw a vector path
This type is used by Path
import { Drawing, Path } from 'kuito';
export function Example() {
return (
<Drawing viewBox={[0, 0, 100, 100]} width={120} height={120} label="Vector example">
<Path d="M10 50 L35 75 L90 15" fill="none" stroke="#2563eb" strokeWidth={8} />
</Drawing>
);
}Type declaration
export interface PathProps extends ShapePaint {
/** SVG path data: `M0 0L10 10Z`. */
d: string;
}Members 15
| Name | Type | Required | Description |
|---|---|---|---|
d | string | Yes | SVG path data: M0 0L10 10Z. |
fill | string | No | A hex color, or none; black by default. |
fillRule | FillRule | No | — |
stroke | string | No | A hex color, or none, the default. |
strokeWidth | number | No | In user units; 1 by default. |
strokeLinecap | StrokeLinecap | No | — |
strokeLinejoin | StrokeLinejoin | No | — |
strokeMiterlimit | number | No | — |
strokeDasharray | readonly number[] | No | Dash and gap lengths in user units, repeated. |
strokeDashoffset | number | No | — |
opacity | number | No | Multiplies with its Groups' opacity. |
translateX | number | No | In user units, then rotate in degrees and scale, about the origin. |
translateY | number | No | — |
scale | number | No | — |
rotate | number | No | — |
Generated from the public TypeScript declarations: signatures, props and defaults come from the checked source, descriptions from its JSDoc. No defaults are invented.