[paper] Correct return type for Rectangle.scale and Rectangle.expand (#18578)

The definition for both methods returned void although they return a new Rectangle instance.
See c403c86a23/src/basic/Rectangle.js (L805-L833)
This commit is contained in:
Santi Albo
2017-08-02 20:39:36 +02:00
committed by Sheetal Nandi
parent fc7a45f9ea
commit a0fa31362f

View File

@@ -793,27 +793,27 @@ declare module 'paper' {
* Expands the rectangle by the specified amount in horizontal and vertical directions.
* @param amount - the amount to expand the rectangle in both directions
*/
expand(amount: number | Size | Point): void;
expand(amount: number | Size | Point): Rectangle;
/**
* Expands the rectangle by the specified amounts in horizontal and vertical directions.
* @param hor - the amount to expand the rectangle in horizontal direction
* @param ver - the amount to expand the rectangle in vertical direction
*/
expand(hor: number, ver: number): void;
expand(hor: number, ver: number): Rectangle;
/**
* Scales the rectangle by the specified amount from its center.
* @param amount - the amount to scale by
*/
scale(amount: number): void;
scale(amount: number): Rectangle;
/**
* Scales the rectangle in horizontal direction by the specified hor amount and in vertical direction by the specified ver amount from its center.
* @param hor - the amount to scale the rectangle in horizontal direction
* @param ver - the amount to scale the rectangle in vertical direction
*/
scale(hor: number, ver: number): void;
scale(hor: number, ver: number): Rectangle;
}
/**