From d2b1b2e1ebf4e722f93c28e1d5b66270c5a56cc5 Mon Sep 17 00:00:00 2001 From: Ben Salili-James Date: Sat, 20 Jun 2020 16:40:12 +0100 Subject: [PATCH] Add `cx` and `cy` parameters to `scale` typings (#75) These parameters were missing from the TypeScript typings. --- transformation-matrix.d.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/transformation-matrix.d.ts b/transformation-matrix.d.ts index 1ede136..8b7031d 100644 --- a/transformation-matrix.d.ts +++ b/transformation-matrix.d.ts @@ -107,10 +107,13 @@ declare module 'transformation-matrix/scale' { /** * Calculate a scaling matrix - * @param sx Scaling on axis x - * @param sy Scaling on axis y (default `sx`) + * @param sx {number} Scaling on axis x + * @param [sy = sx] {number} Scaling on axis y (default `sx`) + * @param [cx] {number} If (cx,cy) are supplied the scale is relative to this point + * @param [cy] {number} If (cx,cy) are supplied the scale is relative to this point + * @returns {Matrix} Affine Matrix */ - export function scale(sx: number, sy?: number): Matrix; + export function scale(sx: number, sy?: number, cx?: number, cy?: number): Matrix; } declare module 'transformation-matrix/shear' {