UNPKG

pencil.js

Version:

Nice modular interactive 2D drawing library.

39 lines (38 loc) 962 B
/** * @module Heart */ /** * Heart class * <br><img src="./media/examples/heart.png" alt="heart demo"/> * @class * @extends {module:Component} */ export default class Heart { /** * @inheritDoc * @param {Object} definition - Heart definition * @return {Heart} */ static from(definition: any): Heart; /** * Heart constructor * @param {PositionDefinition} positionDefinition - Position of the center of the heart * @param {Number} radius - radius The distance from center of heart * @param {ComponentOptions} [options] - Drawing options */ constructor(positionDefinition: PositionDefinition, radius: number, options?: ComponentOptions); /** * @type {Number} */ radius: number; /** * Draw the Heart * @param {Path2D} path - Drawing context * @return {Heart} Itself */ trace(path: Path2D): Heart; /** * @inheritDoc */ toJSON(): any; }