From 80ac20f080f30995e4a121b76599c91b28beafd2 Mon Sep 17 00:00:00 2001 From: denis Date: Thu, 31 Jan 2019 15:27:32 +0100 Subject: [PATCH 1/2] Update to 1.3.3 Add d3.stackOrderAppearance. --- types/d3-shape/d3-shape-tests.ts | 1 + types/d3-shape/index.d.ts | 9 ++++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/types/d3-shape/d3-shape-tests.ts b/types/d3-shape/d3-shape-tests.ts index fb79b15e4a..1ce464093f 100644 --- a/types/d3-shape/d3-shape-tests.ts +++ b/types/d3-shape/d3-shape-tests.ts @@ -1464,6 +1464,7 @@ seriesDatum = seriesPoint.data; let order: number[]; const seriesAnyAny: d3Shape.Series = seriesArray[0]; +order = d3Shape.stackOrderAppearance(seriesAnyAny); order = d3Shape.stackOrderAscending(seriesAnyAny); order = d3Shape.stackOrderDescending(seriesAnyAny); order = d3Shape.stackOrderInsideOut(seriesAnyAny); diff --git a/types/d3-shape/index.d.ts b/types/d3-shape/index.d.ts index ed64d6f827..e4f1fba6b3 100644 --- a/types/d3-shape/index.d.ts +++ b/types/d3-shape/index.d.ts @@ -7,7 +7,7 @@ // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 -// Last module patch version validated against: 1.2.0 +// Last module patch version validated against: 1.3.3 import { Path } from 'd3-path'; @@ -2670,6 +2670,13 @@ export function stack(): Stack; */ export function stack(): Stack; +/** + * Returns a series order such that the earliest series (according to the maximum value) is at the bottom. + * + * @param series A series generated by a stack generator. + */ +export function stackOrderAppearance(series: Series): number[]; + /** * Returns a series order such that the smallest series (according to the sum of values) is at the bottom. * From 48c18d585800319f2a7b4a1d58a3cda2a7ecd339 Mon Sep 17 00:00:00 2001 From: denis Date: Thu, 31 Jan 2019 21:50:23 +0100 Subject: [PATCH 2/2] Update version in definition header --- types/d3-shape/index.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/types/d3-shape/index.d.ts b/types/d3-shape/index.d.ts index e4f1fba6b3..350df78487 100644 --- a/types/d3-shape/index.d.ts +++ b/types/d3-shape/index.d.ts @@ -1,4 +1,4 @@ -// Type definitions for D3JS d3-shape module 1.2 +// Type definitions for D3JS d3-shape module 1.3 // Project: https://github.com/d3/d3-shape/ // Definitions by: Tom Wanzek // Alex Ford