Utilisation

Draw a closed shape.

Ce type est utilisé par Polygon

tsx
// Draw a closed shape.
import { Drawing, Polygon } from 'kuito';

<Drawing label="Play" viewBox={[0, 0, 24, 24]} width={24} height={24}>
  <Polygon
    points={[
      [7, 4],
      [20, 12],
      [7, 20],
    ]}
    fill="#111827"
    strokeLinejoin="round"
  />
</Drawing>;

Déclaration du type

ts
export interface PolygonProps extends PolylineProps {}

Membres 15

NomTypeRequisDescription
pointsreadonly (readonly [number, number])[]Oui—
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.