From d6c11572cc8b6cd66b688b5193ba243950634e8c Mon Sep 17 00:00:00 2001 From: Dominik Moritz Date: Thu, 5 Nov 2020 12:13:33 -0800 Subject: [PATCH] docs: correct documentation of domain union with (#7027) --- build/vega-lite-schema.json | 2 +- src/scale.ts | 13 ++----------- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/build/vega-lite-schema.json b/build/vega-lite-schema.json index 196a8eff17..6a21a34356 100644 --- a/build/vega-lite-schema.json +++ b/build/vega-lite-schema.json @@ -8117,7 +8117,7 @@ "type": "array" } ], - "description": "Customized domain values to be union with the field's values.\n\n1) `domain` for _quantitative_ fields can take one of the following forms:\n\n- a two-element array with minimum and maximum values. - an array with more than two entries, for [Piecewise quantitative scales](https://vega.github.io/vega-lite/docs/scale.html#piecewise). (Alternatively, the `domainMid` property can be set for a diverging scale.) - a string value `\"unaggregated\"`, if the input field is aggregated, to indicate that the domain should include the raw data values prior to the aggregation.\n\n2) `domain` for _temporal_ fields can be a two-element array minimum and maximum values, in the form of either timestamps or the [DateTime definition objects](https://vega.github.io/vega-lite/docs/types.html#datetime).\n\n3) `domain` for _ordinal_ and _nominal_ fields can be an array that lists valid input values." + "description": "Customized domain values to be union with the field's values or explicitly defined domain. Should be an array of valid scale domain values." } }, "required": [ diff --git a/src/scale.ts b/src/scale.ts index 5168406ebb..3a8e80d6ef 100644 --- a/src/scale.ts +++ b/src/scale.ts @@ -429,17 +429,8 @@ export function isSelectionDomain(domain: Domain): domain is SelectionExtent { export interface DomainUnionWith { /** - * Customized domain values to be union with the field's values. - * - * 1) `domain` for _quantitative_ fields can take one of the following forms: - * - * - a two-element array with minimum and maximum values. - * - an array with more than two entries, for [Piecewise quantitative scales](https://vega.github.io/vega-lite/docs/scale.html#piecewise). (Alternatively, the `domainMid` property can be set for a diverging scale.) - * - a string value `"unaggregated"`, if the input field is aggregated, to indicate that the domain should include the raw data values prior to the aggregation. - * - * 2) `domain` for _temporal_ fields can be a two-element array minimum and maximum values, in the form of either timestamps or the [DateTime definition objects](https://vega.github.io/vega-lite/docs/types.html#datetime). - * - * 3) `domain` for _ordinal_ and _nominal_ fields can be an array that lists valid input values. + * Customized domain values to be union with the field's values or explicitly defined domain. + * Should be an array of valid scale domain values. */ unionWith: number[] | string[] | boolean[] | DateTime[]; }