Utilisation

Draw a vector path

Ce type est utilisé par Path

tsx
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>
  );
}

Déclaration du type

ts
export interface PathProps extends ShapePaint {
  /** SVG path data: `M0 0L10 10Z`. */
  d: string;
}

Membres 15

NomTypeRequisDescription
dstringOuiSVG path data: M0 0L10 10Z.
fillstringNonA hex color, or none; black by default.
fillRuleFillRuleNon—
strokestringNonA hex color, or none, the default.
strokeWidthnumberNonIn user units; 1 by default.
strokeLinecapStrokeLinecapNon—
strokeLinejoinStrokeLinejoinNon—
strokeMiterlimitnumberNon—
strokeDasharrayreadonly number[]NonDash and gap lengths in user units, repeated.
strokeDashoffsetnumberNon—
opacitynumberNonMultiplies with its Groups' opacity.
translateXnumberNonIn user units, then rotate in degrees and scale, about the origin.
translateYnumberNon—
scalenumberNon—
rotatenumberNon—
Généré depuis les déclarations TypeScript publiques : signatures, props et valeurs par défaut viennent de la source vérifiée, les descriptions de sa JSDoc. Aucune valeur par défaut n'est inventée.