@uwdata/mosaic-spec 0.17.0 → 0.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +47 -0
- package/README.md +1 -1
- package/dist/mosaic-schema.json +201110 -0
- package/dist/src/ast/ASTNode.d.ts +27 -0
- package/dist/src/ast/ASTNode.d.ts.map +1 -0
- package/dist/src/ast/ColumnParamRefNode.d.ts +9 -0
- package/dist/src/ast/ColumnParamRefNode.d.ts.map +1 -0
- package/dist/src/ast/DataNode.d.ts +61 -0
- package/dist/src/ast/DataNode.d.ts.map +1 -0
- package/dist/src/ast/ExpressionNode.d.ts +14 -0
- package/dist/src/ast/ExpressionNode.d.ts.map +1 -0
- package/dist/src/ast/HConcatNode.d.ts +11 -0
- package/dist/src/ast/HConcatNode.d.ts.map +1 -0
- package/dist/src/ast/HSpaceNode.d.ts +12 -0
- package/dist/src/ast/HSpaceNode.d.ts.map +1 -0
- package/dist/src/ast/InputNode.d.ts +9 -0
- package/dist/src/ast/InputNode.d.ts.map +1 -0
- package/dist/src/ast/LiteralNode.d.ts +8 -0
- package/dist/src/ast/LiteralNode.d.ts.map +1 -0
- package/dist/src/ast/OptionsNode.d.ts +11 -0
- package/dist/src/ast/OptionsNode.d.ts.map +1 -0
- package/dist/src/ast/ParamNode.d.ts +9 -0
- package/dist/src/ast/ParamNode.d.ts.map +1 -0
- package/dist/src/ast/ParamRefNode.d.ts +9 -0
- package/dist/src/ast/ParamRefNode.d.ts.map +1 -0
- package/dist/src/ast/PlotAttributeNode.d.ts +19 -0
- package/dist/src/ast/PlotAttributeNode.d.ts.map +1 -0
- package/dist/src/ast/PlotFromNode.d.ts +10 -0
- package/dist/src/ast/PlotFromNode.d.ts.map +1 -0
- package/dist/src/ast/PlotInteractorNode.d.ts +9 -0
- package/dist/src/ast/PlotInteractorNode.d.ts.map +1 -0
- package/dist/src/ast/PlotLegendNode.d.ts +11 -0
- package/dist/src/ast/PlotLegendNode.d.ts.map +1 -0
- package/dist/src/ast/PlotMarkNode.d.ts +11 -0
- package/dist/src/ast/PlotMarkNode.d.ts.map +1 -0
- package/dist/src/ast/PlotNode.d.ts +12 -0
- package/dist/src/ast/PlotNode.d.ts.map +1 -0
- package/dist/src/ast/SelectionNode.d.ts +25 -0
- package/dist/src/ast/SelectionNode.d.ts.map +1 -0
- package/dist/src/ast/SpecNode.d.ts +11 -0
- package/dist/src/ast/SpecNode.d.ts.map +1 -0
- package/dist/src/ast/TransformNode.d.ts +22 -0
- package/dist/src/ast/TransformNode.d.ts.map +1 -0
- package/dist/src/ast/VConcatNode.d.ts +11 -0
- package/dist/src/ast/VConcatNode.d.ts.map +1 -0
- package/dist/src/ast/VSpaceNode.d.ts +12 -0
- package/dist/src/ast/VSpaceNode.d.ts.map +1 -0
- package/dist/src/ast/WindowFrameNode.d.ts +16 -0
- package/dist/src/ast/WindowFrameNode.d.ts.map +1 -0
- package/dist/src/ast-to-dom.d.ts +41 -0
- package/dist/src/ast-to-dom.d.ts.map +1 -0
- package/dist/src/ast-to-esm.d.ts +65 -0
- package/dist/src/ast-to-esm.d.ts.map +1 -0
- package/dist/src/config/components.d.ts +5 -0
- package/dist/src/config/components.d.ts.map +1 -0
- package/dist/src/config/extensions.d.ts +10 -0
- package/dist/src/config/extensions.d.ts.map +1 -0
- package/dist/src/config/inputs.d.ts +6 -0
- package/dist/src/config/inputs.d.ts.map +1 -0
- package/dist/src/config/plots.d.ts +35 -0
- package/dist/src/config/plots.d.ts.map +1 -0
- package/dist/src/config/transforms.d.ts +5 -0
- package/dist/src/config/transforms.d.ts.map +1 -0
- package/dist/src/constants.d.ts +33 -0
- package/dist/src/constants.d.ts.map +1 -0
- package/dist/src/index.d.ts +30 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/parse-spec.d.ts +112 -0
- package/dist/src/parse-spec.d.ts.map +1 -0
- package/dist/src/spec/CSSStyles.d.ts +4 -0
- package/dist/src/spec/CSSStyles.d.ts.map +1 -0
- package/dist/src/spec/Data.d.ts +166 -0
- package/dist/src/spec/Data.d.ts.map +1 -0
- package/dist/src/spec/Expression.d.ts +28 -0
- package/dist/src/spec/Expression.d.ts.map +1 -0
- package/dist/src/spec/HConcat.d.ts +9 -0
- package/dist/src/spec/HConcat.d.ts.map +1 -0
- package/dist/src/spec/HSpace.d.ts +10 -0
- package/dist/src/spec/HSpace.d.ts.map +1 -0
- package/dist/src/spec/Input.d.ts +218 -0
- package/dist/src/spec/Input.d.ts.map +1 -0
- package/dist/src/spec/Interval.d.ts +59 -0
- package/dist/src/spec/Interval.d.ts.map +1 -0
- package/dist/src/spec/Param.d.ts +64 -0
- package/dist/src/spec/Param.d.ts.map +1 -0
- package/dist/src/spec/Plot.d.ts +15 -0
- package/dist/src/spec/Plot.d.ts.map +1 -0
- package/dist/src/spec/PlotAttribute.d.ts +1535 -0
- package/dist/src/spec/PlotAttribute.d.ts.map +1 -0
- package/dist/src/spec/PlotFrom.d.ts +21 -0
- package/dist/src/spec/PlotFrom.d.ts.map +1 -0
- package/dist/src/spec/PlotInteractor.d.ts +10 -0
- package/dist/src/spec/PlotInteractor.d.ts.map +1 -0
- package/dist/src/spec/PlotLegend.d.ts +69 -0
- package/dist/src/spec/PlotLegend.d.ts.map +1 -0
- package/dist/src/spec/PlotMark.d.ts +29 -0
- package/dist/src/spec/PlotMark.d.ts.map +1 -0
- package/dist/src/spec/PlotTypes.d.ts +294 -0
- package/dist/src/spec/PlotTypes.d.ts.map +1 -0
- package/dist/src/spec/Spec.d.ts +53 -0
- package/dist/src/spec/Spec.d.ts.map +1 -0
- package/dist/src/spec/Transform.d.ts +393 -0
- package/dist/src/spec/Transform.d.ts.map +1 -0
- package/dist/src/spec/VConcat.d.ts +9 -0
- package/dist/src/spec/VConcat.d.ts.map +1 -0
- package/dist/src/spec/VSpace.d.ts +10 -0
- package/dist/src/spec/VSpace.d.ts.map +1 -0
- package/dist/src/spec/interactors/BrushStyles.d.ts +28 -0
- package/dist/src/spec/interactors/BrushStyles.d.ts.map +1 -0
- package/dist/src/spec/interactors/Highlight.d.ts +38 -0
- package/dist/src/spec/interactors/Highlight.d.ts.map +1 -0
- package/dist/src/spec/interactors/Interval1D.d.ts +43 -0
- package/dist/src/spec/interactors/Interval1D.d.ts.map +1 -0
- package/dist/src/spec/interactors/Interval2D.d.ts +48 -0
- package/dist/src/spec/interactors/Interval2D.d.ts.map +1 -0
- package/dist/src/spec/interactors/Nearest.d.ts +45 -0
- package/dist/src/spec/interactors/Nearest.d.ts.map +1 -0
- package/dist/src/spec/interactors/PanZoom.d.ts +59 -0
- package/dist/src/spec/interactors/PanZoom.d.ts.map +1 -0
- package/dist/src/spec/interactors/Region.d.ts +33 -0
- package/dist/src/spec/interactors/Region.d.ts.map +1 -0
- package/dist/src/spec/interactors/Toggle.d.ts +60 -0
- package/dist/src/spec/interactors/Toggle.d.ts.map +1 -0
- package/dist/src/spec/marks/Area.d.ts +140 -0
- package/dist/src/spec/marks/Area.d.ts.map +1 -0
- package/dist/src/spec/marks/Arrow.d.ts +95 -0
- package/dist/src/spec/marks/Arrow.d.ts.map +1 -0
- package/dist/src/spec/marks/Axis.d.ts +282 -0
- package/dist/src/spec/marks/Axis.d.ts.map +1 -0
- package/dist/src/spec/marks/Bar.d.ts +151 -0
- package/dist/src/spec/marks/Bar.d.ts.map +1 -0
- package/dist/src/spec/marks/Cell.d.ts +58 -0
- package/dist/src/spec/marks/Cell.d.ts.map +1 -0
- package/dist/src/spec/marks/Contour.d.ts +24 -0
- package/dist/src/spec/marks/Contour.d.ts.map +1 -0
- package/dist/src/spec/marks/Delaunay.d.ts +87 -0
- package/dist/src/spec/marks/Delaunay.d.ts.map +1 -0
- package/dist/src/spec/marks/DenseLine.d.ts +28 -0
- package/dist/src/spec/marks/DenseLine.d.ts.map +1 -0
- package/dist/src/spec/marks/Density.d.ts +137 -0
- package/dist/src/spec/marks/Density.d.ts.map +1 -0
- package/dist/src/spec/marks/Dot.d.ts +134 -0
- package/dist/src/spec/marks/Dot.d.ts.map +1 -0
- package/dist/src/spec/marks/ErrorBar.d.ts +83 -0
- package/dist/src/spec/marks/ErrorBar.d.ts.map +1 -0
- package/dist/src/spec/marks/Frame.d.ts +22 -0
- package/dist/src/spec/marks/Frame.d.ts.map +1 -0
- package/dist/src/spec/marks/Geo.d.ts +54 -0
- package/dist/src/spec/marks/Geo.d.ts.map +1 -0
- package/dist/src/spec/marks/Hexbin.d.ts +31 -0
- package/dist/src/spec/marks/Hexbin.d.ts.map +1 -0
- package/dist/src/spec/marks/Hexgrid.d.ts +26 -0
- package/dist/src/spec/marks/Hexgrid.d.ts.map +1 -0
- package/dist/src/spec/marks/Image.d.ts +90 -0
- package/dist/src/spec/marks/Image.d.ts.map +1 -0
- package/dist/src/spec/marks/Line.d.ts +83 -0
- package/dist/src/spec/marks/Line.d.ts.map +1 -0
- package/dist/src/spec/marks/Link.d.ts +61 -0
- package/dist/src/spec/marks/Link.d.ts.map +1 -0
- package/dist/src/spec/marks/Marks.d.ts +911 -0
- package/dist/src/spec/marks/Marks.d.ts.map +1 -0
- package/dist/src/spec/marks/Raster.d.ts +125 -0
- package/dist/src/spec/marks/Raster.d.ts.map +1 -0
- package/dist/src/spec/marks/Rect.d.ts +167 -0
- package/dist/src/spec/marks/Rect.d.ts.map +1 -0
- package/dist/src/spec/marks/Regression.d.ts +59 -0
- package/dist/src/spec/marks/Regression.d.ts.map +1 -0
- package/dist/src/spec/marks/Rule.d.ts +101 -0
- package/dist/src/spec/marks/Rule.d.ts.map +1 -0
- package/dist/src/spec/marks/Text.d.ts +111 -0
- package/dist/src/spec/marks/Text.d.ts.map +1 -0
- package/dist/src/spec/marks/Tick.d.ts +62 -0
- package/dist/src/spec/marks/Tick.d.ts.map +1 -0
- package/dist/src/spec/marks/Vector.d.ts +100 -0
- package/dist/src/spec/marks/Vector.d.ts.map +1 -0
- package/dist/src/spec/marks/Waffle.d.ts +59 -0
- package/dist/src/spec/marks/Waffle.d.ts.map +1 -0
- package/dist/src/util.d.ts +13 -0
- package/dist/src/util.d.ts.map +1 -0
- package/package.json +18 -10
- package/src/spec/Data.ts +2 -2
- package/src/spec/Expression.ts +1 -1
- package/src/spec/Input.ts +6 -1
- package/src/spec/Spec.ts +1 -1
- package/src/spec/Transform.ts +3 -3
- package/src/spec/interactors/Interval1D.ts +1 -1
- package/src/spec/interactors/Interval2D.ts +1 -1
- package/src/spec/interactors/Toggle.ts +5 -5
- package/src/spec/marks/ErrorBar.ts +2 -2
- package/tsconfig.json +0 -13
- package/vitest.config.ts +0 -3
|
@@ -0,0 +1,393 @@
|
|
|
1
|
+
import { IntervalTransform } from './Interval.js';
|
|
2
|
+
import { ParamRef } from './Param.js';
|
|
3
|
+
/** A field argument to a data transform. */
|
|
4
|
+
export type TransformField = string | ParamRef;
|
|
5
|
+
export type FrameExclude = 'CURRENT ROW' | 'GROUP' | 'TIES' | 'NO OTHERS';
|
|
6
|
+
export type FrameValue = number | IntervalTransform | null;
|
|
7
|
+
/** Window transform options. */
|
|
8
|
+
export interface WindowOptions {
|
|
9
|
+
orderby?: TransformField | TransformField[];
|
|
10
|
+
partitionby?: TransformField | TransformField[];
|
|
11
|
+
rows?: [FrameValue, FrameValue] | ParamRef;
|
|
12
|
+
range?: [FrameValue, FrameValue] | ParamRef;
|
|
13
|
+
groups?: [FrameValue, FrameValue] | ParamRef;
|
|
14
|
+
exclude?: Uppercase<FrameExclude> | Lowercase<FrameExclude>;
|
|
15
|
+
}
|
|
16
|
+
/** Aggregate transform options. */
|
|
17
|
+
export interface AggregateOptions {
|
|
18
|
+
distinct?: boolean;
|
|
19
|
+
}
|
|
20
|
+
/** A transform argument. */
|
|
21
|
+
type Arg = string | number | boolean | ParamRef;
|
|
22
|
+
/** A zero argument transform signature. */
|
|
23
|
+
type Arg0 = null | [];
|
|
24
|
+
/** A single argument transform signature. */
|
|
25
|
+
type Arg1 = Arg | [Arg];
|
|
26
|
+
/**
|
|
27
|
+
* A two argument transform signature; both arguments are required.
|
|
28
|
+
*/
|
|
29
|
+
type Arg2 = [Arg, Arg];
|
|
30
|
+
/**
|
|
31
|
+
* A two argument transform signature; the second argument is optional.
|
|
32
|
+
*/
|
|
33
|
+
type Arg2Opt = Arg | [Arg, Arg?];
|
|
34
|
+
/**
|
|
35
|
+
* A three argument transform signature; the
|
|
36
|
+
* second and third arguments are optional.
|
|
37
|
+
*/
|
|
38
|
+
type Arg3Opt = Arg | [Arg, Arg?, Arg?];
|
|
39
|
+
/** Binning interval names. */
|
|
40
|
+
export type BinInterval = 'date' | 'number' | 'millisecond' | 'second' | 'minute' | 'hour' | 'day' | 'month' | 'year';
|
|
41
|
+
/** A bin transform. */
|
|
42
|
+
export interface Bin {
|
|
43
|
+
/**
|
|
44
|
+
* Bin a continuous variable into discrete intervals. The bin argument
|
|
45
|
+
* specifies a data column or expression to bin. Both numerical and
|
|
46
|
+
* temporal (date/time) values are supported.
|
|
47
|
+
*/
|
|
48
|
+
bin: Arg | [Arg];
|
|
49
|
+
/**
|
|
50
|
+
* The interval bin unit to use, typically used to indicate a date/time
|
|
51
|
+
* unit for binning temporal values, such as `hour`, `day`, or `month`.
|
|
52
|
+
* If `date`, the extent of data values is used to automatically select
|
|
53
|
+
* an interval for temporal data. The value `number` enforces normal
|
|
54
|
+
* numerical binning, even over temporal data. If unspecified, defaults
|
|
55
|
+
* to `number` for numerical data and `date` for temporal data.
|
|
56
|
+
*/
|
|
57
|
+
interval?: BinInterval;
|
|
58
|
+
/**
|
|
59
|
+
* The step size to use between bins. When binning numerical values (or
|
|
60
|
+
* interval type `number`), this setting specifies the numerical step size.
|
|
61
|
+
* For data/time intervals, this indicates the number of steps of that unit,
|
|
62
|
+
* such as hours, days, or years.
|
|
63
|
+
*/
|
|
64
|
+
step?: number;
|
|
65
|
+
/**
|
|
66
|
+
* The target number of binning steps to use. To accommodate human-friendly
|
|
67
|
+
* ("nice") bin boundaries, the actual number of bins may diverge from this
|
|
68
|
+
* exact value. This option is ignored when **step** is specified.
|
|
69
|
+
*/
|
|
70
|
+
steps?: number;
|
|
71
|
+
/**
|
|
72
|
+
* The minimum allowed bin step size (default `0`) when performing numerical
|
|
73
|
+
* binning. For example, a setting of `1` prevents step sizes less than 1.
|
|
74
|
+
* This option is ignored when **step** is specified.
|
|
75
|
+
*/
|
|
76
|
+
minstep?: number;
|
|
77
|
+
/**
|
|
78
|
+
* A flag (default `true`) requesting "nice" human-friendly end points and
|
|
79
|
+
* step sizes when performing numerical binning. When **step** is specified,
|
|
80
|
+
* this option affects the binning end points (e.g., origin) only.
|
|
81
|
+
*/
|
|
82
|
+
nice?: true;
|
|
83
|
+
/**
|
|
84
|
+
* Offset for computed bins (default `0`). For example, a value of `1` will
|
|
85
|
+
* result in using the next consecutive bin boundary.
|
|
86
|
+
*/
|
|
87
|
+
offset?: number;
|
|
88
|
+
}
|
|
89
|
+
/** A column transform. */
|
|
90
|
+
export interface Column {
|
|
91
|
+
/**
|
|
92
|
+
* Interpret a string or param-value as a column reference.
|
|
93
|
+
*/
|
|
94
|
+
column: Arg1;
|
|
95
|
+
}
|
|
96
|
+
/** A dateMonth transform. */
|
|
97
|
+
export interface DateMonth {
|
|
98
|
+
/**
|
|
99
|
+
* Transform a Date value to a month boundary for cyclic comparison.
|
|
100
|
+
* Year values are collapsed to enable comparison over months only.
|
|
101
|
+
*/
|
|
102
|
+
dateMonth: Arg1;
|
|
103
|
+
}
|
|
104
|
+
/** A dateMonthDay transform. */
|
|
105
|
+
export interface DateMonthDay {
|
|
106
|
+
/**
|
|
107
|
+
* Transform a Date value to a month and day boundary for cyclic comparison.
|
|
108
|
+
* Year values are collapsed to enable comparison over months and days only.
|
|
109
|
+
*/
|
|
110
|
+
dateMonthDay: Arg1;
|
|
111
|
+
}
|
|
112
|
+
/** A dateDay transform. */
|
|
113
|
+
export interface DateDay {
|
|
114
|
+
/**
|
|
115
|
+
* Transform a Date value to a day of the month for cyclic comparison.
|
|
116
|
+
* Year and month values are collapsed to enable comparison over days only.
|
|
117
|
+
*/
|
|
118
|
+
dateDay: Arg1;
|
|
119
|
+
}
|
|
120
|
+
/** A centroid transform. */
|
|
121
|
+
export interface Centroid {
|
|
122
|
+
/**
|
|
123
|
+
* Compute the 2D centroid of geometry-typed data.
|
|
124
|
+
* This transform requires the DuckDB `spatial` extension.
|
|
125
|
+
*/
|
|
126
|
+
centroid: Arg1;
|
|
127
|
+
}
|
|
128
|
+
/** A centroidX transform. */
|
|
129
|
+
export interface CentroidX {
|
|
130
|
+
/**
|
|
131
|
+
* Compute the centroid x-coordinate of geometry-typed data.
|
|
132
|
+
* This transform requires the DuckDB `spatial` extension.
|
|
133
|
+
*/
|
|
134
|
+
centroidX: Arg1;
|
|
135
|
+
}
|
|
136
|
+
/** A centroidY transform. */
|
|
137
|
+
export interface CentroidY {
|
|
138
|
+
/**
|
|
139
|
+
* Compute the centroid y-coordinate of geometry-typed data.
|
|
140
|
+
* This transform requires the DuckDB `spatial` extension.
|
|
141
|
+
*/
|
|
142
|
+
centroidY: Arg1;
|
|
143
|
+
}
|
|
144
|
+
/** A geojson transform. */
|
|
145
|
+
export interface GeoJSON {
|
|
146
|
+
/**
|
|
147
|
+
* Compute a GeoJSON-formatted string from geometry-typed data.
|
|
148
|
+
* This transform requires the DuckDB `spatial` extension.
|
|
149
|
+
*/
|
|
150
|
+
geojson: Arg1;
|
|
151
|
+
}
|
|
152
|
+
/** An argmax aggregate transform. */
|
|
153
|
+
export interface Argmax extends AggregateOptions, WindowOptions {
|
|
154
|
+
/**
|
|
155
|
+
* Find a value of the first column that maximizes the second column.
|
|
156
|
+
*/
|
|
157
|
+
argmax: Arg2;
|
|
158
|
+
}
|
|
159
|
+
/** An argmin aggregate transform. */
|
|
160
|
+
export interface Argmin extends AggregateOptions, WindowOptions {
|
|
161
|
+
/**
|
|
162
|
+
* Find a value of the first column that minimizes the second column.
|
|
163
|
+
*/
|
|
164
|
+
argmin: Arg2;
|
|
165
|
+
}
|
|
166
|
+
/** An avg (average, or mean) aggregate transform. */
|
|
167
|
+
export interface Avg extends AggregateOptions, WindowOptions {
|
|
168
|
+
/**
|
|
169
|
+
* Compute the average (mean) value of the given column.
|
|
170
|
+
*/
|
|
171
|
+
avg: Arg1;
|
|
172
|
+
}
|
|
173
|
+
/** A count aggregate transform. */
|
|
174
|
+
export interface Count extends AggregateOptions, WindowOptions {
|
|
175
|
+
/**
|
|
176
|
+
* Compute the count of records in an aggregation group.
|
|
177
|
+
*/
|
|
178
|
+
count: Arg0 | Arg1;
|
|
179
|
+
}
|
|
180
|
+
/** A sample covariance aggregate transform. */
|
|
181
|
+
export interface Covariance extends AggregateOptions, WindowOptions {
|
|
182
|
+
/**
|
|
183
|
+
* Compute the sample covariance of between the given columns.
|
|
184
|
+
*/
|
|
185
|
+
covariance: Arg2;
|
|
186
|
+
}
|
|
187
|
+
/** A population covariance aggregate transform. */
|
|
188
|
+
export interface CovarPop extends AggregateOptions, WindowOptions {
|
|
189
|
+
/**
|
|
190
|
+
* Compute the population covariance of between the given columns.
|
|
191
|
+
*/
|
|
192
|
+
covarPop: Arg2;
|
|
193
|
+
}
|
|
194
|
+
/** A first aggregate transform. */
|
|
195
|
+
export interface First extends AggregateOptions, WindowOptions {
|
|
196
|
+
/**
|
|
197
|
+
* Return the first column value found in an aggregation group.
|
|
198
|
+
*/
|
|
199
|
+
first: Arg1;
|
|
200
|
+
}
|
|
201
|
+
/** A geometric mean aggregate transform. */
|
|
202
|
+
export interface Geomean extends AggregateOptions, WindowOptions {
|
|
203
|
+
/**
|
|
204
|
+
* Compute the geometric mean value of the given column.
|
|
205
|
+
*/
|
|
206
|
+
geomean: Arg1;
|
|
207
|
+
}
|
|
208
|
+
/** A last aggregate transform. */
|
|
209
|
+
export interface Last extends AggregateOptions, WindowOptions {
|
|
210
|
+
/**
|
|
211
|
+
* Return the last column value found in an aggregation group.
|
|
212
|
+
*/
|
|
213
|
+
last: Arg1;
|
|
214
|
+
}
|
|
215
|
+
/** A max aggregate transform. */
|
|
216
|
+
export interface Max extends AggregateOptions, WindowOptions {
|
|
217
|
+
/**
|
|
218
|
+
* Compute the maximum value of the given column.
|
|
219
|
+
*/
|
|
220
|
+
max: Arg1;
|
|
221
|
+
}
|
|
222
|
+
/** A min aggregate transform. */
|
|
223
|
+
export interface Min extends AggregateOptions, WindowOptions {
|
|
224
|
+
/**
|
|
225
|
+
* Compute the minimum value of the given column.
|
|
226
|
+
*/
|
|
227
|
+
min: Arg1;
|
|
228
|
+
}
|
|
229
|
+
/** A median aggregate transform. */
|
|
230
|
+
export interface Median extends AggregateOptions, WindowOptions {
|
|
231
|
+
/**
|
|
232
|
+
* Compute the median value of the given column.
|
|
233
|
+
*/
|
|
234
|
+
median: Arg1;
|
|
235
|
+
}
|
|
236
|
+
/** A mode aggregate transform. */
|
|
237
|
+
export interface Mode extends AggregateOptions, WindowOptions {
|
|
238
|
+
/**
|
|
239
|
+
* Compute the mode value of the given column.
|
|
240
|
+
*/
|
|
241
|
+
mode: Arg1;
|
|
242
|
+
}
|
|
243
|
+
/** A product aggregate transform. */
|
|
244
|
+
export interface Product extends AggregateOptions, WindowOptions {
|
|
245
|
+
/**
|
|
246
|
+
* Compute the product of the given column.
|
|
247
|
+
*/
|
|
248
|
+
product: Arg1;
|
|
249
|
+
}
|
|
250
|
+
/** A quantile aggregate transform. */
|
|
251
|
+
export interface Quantile extends AggregateOptions, WindowOptions {
|
|
252
|
+
/**
|
|
253
|
+
* Compute the quantile value of the given column at the provided
|
|
254
|
+
* probability threshold. For example, 0.5 is the median.
|
|
255
|
+
*/
|
|
256
|
+
quantile: Arg2;
|
|
257
|
+
}
|
|
258
|
+
/** A sample standard deviation aggregate transform. */
|
|
259
|
+
export interface Stddev extends AggregateOptions, WindowOptions {
|
|
260
|
+
/**
|
|
261
|
+
* Compute the sum of the given column.
|
|
262
|
+
*/
|
|
263
|
+
stddev: Arg1;
|
|
264
|
+
}
|
|
265
|
+
/** A population standard deviation aggregate transform. */
|
|
266
|
+
export interface StddevPop extends AggregateOptions, WindowOptions {
|
|
267
|
+
/**
|
|
268
|
+
* Compute the sum of the given column.
|
|
269
|
+
*/
|
|
270
|
+
stddevPop: Arg1;
|
|
271
|
+
}
|
|
272
|
+
/** A sum aggregate transform. */
|
|
273
|
+
export interface Sum extends AggregateOptions, WindowOptions {
|
|
274
|
+
/**
|
|
275
|
+
* Compute the sum of the given column.
|
|
276
|
+
*/
|
|
277
|
+
sum: Arg1;
|
|
278
|
+
}
|
|
279
|
+
/** A sample variance aggregate transform. */
|
|
280
|
+
export interface Variance extends AggregateOptions, WindowOptions {
|
|
281
|
+
/**
|
|
282
|
+
* Compute the sample variance of the given column.
|
|
283
|
+
*/
|
|
284
|
+
variance: Arg1;
|
|
285
|
+
}
|
|
286
|
+
/** A population variance aggregate transform. */
|
|
287
|
+
export interface VarPop extends AggregateOptions, WindowOptions {
|
|
288
|
+
/**
|
|
289
|
+
* Compute the population variance of the given column.
|
|
290
|
+
*/
|
|
291
|
+
varPop: Arg1;
|
|
292
|
+
}
|
|
293
|
+
/** A row_number window transform. */
|
|
294
|
+
export interface RowNumber extends WindowOptions {
|
|
295
|
+
/**
|
|
296
|
+
* Compute the 1-based row number over an ordered window partition.
|
|
297
|
+
*/
|
|
298
|
+
row_number: Arg0;
|
|
299
|
+
}
|
|
300
|
+
/** A rank window transform. */
|
|
301
|
+
export interface Rank extends WindowOptions {
|
|
302
|
+
/**
|
|
303
|
+
* Compute the row rank over an ordered window partition.
|
|
304
|
+
* Sorting ties result in gaps in the rank numbers ([1, 1, 3, ...]).
|
|
305
|
+
*/
|
|
306
|
+
rank: Arg0;
|
|
307
|
+
}
|
|
308
|
+
/** A dense_rank window transform. */
|
|
309
|
+
export interface DenseRank extends WindowOptions {
|
|
310
|
+
/**
|
|
311
|
+
* Compute the dense row rank (no gaps) over an ordered window partition.
|
|
312
|
+
* Sorting ties do not result in gaps in the rank numbers ([1, 1, 2, ...]).
|
|
313
|
+
*/
|
|
314
|
+
dense_rank: Arg0;
|
|
315
|
+
}
|
|
316
|
+
/** A percent_rank window transform. */
|
|
317
|
+
export interface PercentRank extends WindowOptions {
|
|
318
|
+
/**
|
|
319
|
+
* Compute the percentage rank over an ordered window partition.
|
|
320
|
+
*/
|
|
321
|
+
percent_rank: Arg0;
|
|
322
|
+
}
|
|
323
|
+
/** A cume_dist window transform. */
|
|
324
|
+
export interface CumeDist extends WindowOptions {
|
|
325
|
+
/**
|
|
326
|
+
* Compute the cumulative distribution value over an ordered window
|
|
327
|
+
* partition. Equals the number of partition rows preceding or peer with
|
|
328
|
+
* the current row, divided by the total number of partition rows.
|
|
329
|
+
*/
|
|
330
|
+
cume_dist: Arg0;
|
|
331
|
+
}
|
|
332
|
+
/** An ntile window transform. */
|
|
333
|
+
export interface NTile extends WindowOptions {
|
|
334
|
+
/**
|
|
335
|
+
* Compute an n-tile integer ranging from 1 to the provided argument
|
|
336
|
+
* (num_buckets), dividing the partition as equally as possible.
|
|
337
|
+
*/
|
|
338
|
+
ntile: Arg1;
|
|
339
|
+
}
|
|
340
|
+
/** A lag window transform. */
|
|
341
|
+
export interface Lag extends WindowOptions {
|
|
342
|
+
/**
|
|
343
|
+
* Compute lagging values in a column. Returns the value at the row that is
|
|
344
|
+
* `offset` (second argument, default `1`) rows before the current row within
|
|
345
|
+
* the window frame. If there is no such row, instead return `default` (third
|
|
346
|
+
* argument, default `null`). Both offset and default are evaluated with
|
|
347
|
+
* respect to the current row.
|
|
348
|
+
*/
|
|
349
|
+
lag: Arg3Opt;
|
|
350
|
+
}
|
|
351
|
+
/** A lead window transform. */
|
|
352
|
+
export interface Lead extends WindowOptions {
|
|
353
|
+
/**
|
|
354
|
+
* Compute leading values in a column. Returns the value at the row that is
|
|
355
|
+
* `offset` (second argument, default `1`) rows after the current row within
|
|
356
|
+
* the window frame. If there is no such row, instead return `default` (third
|
|
357
|
+
* argument, default `null`). Both offset and default are evaluated with
|
|
358
|
+
* respect to the current row.
|
|
359
|
+
*/
|
|
360
|
+
lag: Arg3Opt;
|
|
361
|
+
}
|
|
362
|
+
/** A first_value window transform. */
|
|
363
|
+
export interface FirstValue extends WindowOptions {
|
|
364
|
+
/**
|
|
365
|
+
* Get the first value of the given column in the current window frame.
|
|
366
|
+
*/
|
|
367
|
+
first_value: Arg1;
|
|
368
|
+
}
|
|
369
|
+
/** A last_value window transform. */
|
|
370
|
+
export interface LastValue extends WindowOptions {
|
|
371
|
+
/**
|
|
372
|
+
* Get the last value of the given column in the current window frame.
|
|
373
|
+
*/
|
|
374
|
+
last_value: Arg1;
|
|
375
|
+
}
|
|
376
|
+
/** An nth_value window transform. */
|
|
377
|
+
export interface NthValue extends WindowOptions {
|
|
378
|
+
/**
|
|
379
|
+
* Get the nth value of the given column in the current window frame,
|
|
380
|
+
* counting from one. The second argument is the offset for the nth row.
|
|
381
|
+
*/
|
|
382
|
+
nth_value: Arg2Opt;
|
|
383
|
+
}
|
|
384
|
+
/** A data transform that maps one column value to another. */
|
|
385
|
+
export type ColumnTransform = Bin | Column | DateMonth | DateMonthDay | DateDay | Centroid | CentroidX | CentroidY | GeoJSON;
|
|
386
|
+
/** An aggregate transform that combines multiple values. */
|
|
387
|
+
export type AggregateTransform = Argmax | Argmin | Avg | Count | Max | Min | First | Last | Max | Min | Median | Mode | Product | Quantile | Stddev | StddevPop | Sum | Variance | VarPop;
|
|
388
|
+
/** A window transform that operates over a sorted domain. */
|
|
389
|
+
export type WindowTransform = RowNumber | Rank | DenseRank | PercentRank | CumeDist | NTile | Rank | Lag | Lead | FirstValue | LastValue | NthValue;
|
|
390
|
+
/** A data transform. */
|
|
391
|
+
export type Transform = ColumnTransform | AggregateTransform | WindowTransform;
|
|
392
|
+
export {};
|
|
393
|
+
//# sourceMappingURL=Transform.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Transform.d.ts","sourceRoot":"","sources":["../../../src/spec/Transform.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AAClD,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,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MAAM,GACN,GAAG,GACH,KAAK,GACL,GAAG,GACH,GAAG,GACH,KAAK,GACL,IAAI,GACJ,GAAG,GACH,GAAG,GACH,MAAM,GACN,IAAI,GACJ,OAAO,GACP,QAAQ,GACR,MAAM,GACN,SAAS,GACT,GAAG,GACH,QAAQ,GACR,MAAM,CACP;AAEH,6DAA6D;AAC7D,MAAM,MAAM,eAAe,GACvB,SAAS,GACT,IAAI,GACJ,SAAS,GACT,WAAW,GACX,QAAQ,GACR,KAAK,GACL,IAAI,GACJ,GAAG,GACH,IAAI,GACJ,UAAU,GACV,SAAS,GACT,QAAQ,CACT;AAEH,wBAAwB;AACxB,MAAM,MAAM,SAAS,GACjB,eAAe,GACf,kBAAkB,GAClB,eAAe,CAChB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VConcat.d.ts","sourceRoot":"","sources":["../../../src/spec/VConcat.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,WAAW,CAAC;AAEtC,2BAA2B;AAC3B,MAAM,WAAW,OAAO;IACtB;;OAEG;IACH,OAAO,EAAE,SAAS,EAAE,CAAC;CACtB"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** A vspace component. */
|
|
2
|
+
export interface VSpace {
|
|
3
|
+
/**
|
|
4
|
+
* Vertical space to place between components.
|
|
5
|
+
* Number values indicate screen pixels.
|
|
6
|
+
* String values may use CSS units (em, pt, px, etc).
|
|
7
|
+
*/
|
|
8
|
+
vspace: number | string;
|
|
9
|
+
}
|
|
10
|
+
//# sourceMappingURL=VSpace.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"VSpace.d.ts","sourceRoot":"","sources":["../../../src/spec/VSpace.ts"],"names":[],"mappings":"AAAA,0BAA0B;AAC1B,MAAM,WAAW,MAAM;IACrB;;;;OAIG;IACH,MAAM,EAAE,MAAM,GAAG,MAAM,CAAC;CACzB"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
/** Styles for rectangular selection brushes. */
|
|
2
|
+
export interface BrushStyles {
|
|
3
|
+
/**
|
|
4
|
+
* The overall opacity of the brush rectangle.
|
|
5
|
+
*/
|
|
6
|
+
opacity?: number;
|
|
7
|
+
/**
|
|
8
|
+
* The fill opacity of the brush rectangle.
|
|
9
|
+
*/
|
|
10
|
+
fillOpacity?: number;
|
|
11
|
+
/**
|
|
12
|
+
* The stroke opacity of the brush rectangle.
|
|
13
|
+
*/
|
|
14
|
+
strokeOpacity?: number;
|
|
15
|
+
/**
|
|
16
|
+
* The fill color of the brush rectangle.
|
|
17
|
+
*/
|
|
18
|
+
fill?: string;
|
|
19
|
+
/**
|
|
20
|
+
* The stroke color of the brush rectangle.
|
|
21
|
+
*/
|
|
22
|
+
stroke?: string;
|
|
23
|
+
/**
|
|
24
|
+
* The stroke dash array of the brush rectangle.
|
|
25
|
+
*/
|
|
26
|
+
strokeDasharray?: string;
|
|
27
|
+
}
|
|
28
|
+
//# sourceMappingURL=BrushStyles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BrushStyles.d.ts","sourceRoot":"","sources":["../../../../src/spec/interactors/BrushStyles.ts"],"names":[],"mappings":"AAAA,gDAAgD;AAChD,MAAM,WAAW,WAAW;IAC1B;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { ParamRef } from '../Param.js';
|
|
2
|
+
/** A highlight interactor. */
|
|
3
|
+
export interface Highlight {
|
|
4
|
+
/**
|
|
5
|
+
* Highlight selected marks by deemphasizing the others.
|
|
6
|
+
*/
|
|
7
|
+
select: 'highlight';
|
|
8
|
+
/**
|
|
9
|
+
* The input selection. Unselected marks are deemphasized.
|
|
10
|
+
*/
|
|
11
|
+
by: ParamRef;
|
|
12
|
+
/**
|
|
13
|
+
* The overall opacity of deemphasized marks.
|
|
14
|
+
* By default the opacity is set to 0.2.
|
|
15
|
+
*/
|
|
16
|
+
opacity?: number;
|
|
17
|
+
/**
|
|
18
|
+
* The fill opacity of deemphasized marks.
|
|
19
|
+
* By default the fill opacity is unchanged.
|
|
20
|
+
*/
|
|
21
|
+
fillOpacity?: number;
|
|
22
|
+
/**
|
|
23
|
+
* The stroke opacity of deemphasized marks.
|
|
24
|
+
* By default the stroke opacity is unchanged.
|
|
25
|
+
*/
|
|
26
|
+
strokeOpacity?: number;
|
|
27
|
+
/**
|
|
28
|
+
* The fill color of deemphasized marks.
|
|
29
|
+
* By default the fill is unchanged.
|
|
30
|
+
*/
|
|
31
|
+
fill?: string;
|
|
32
|
+
/**
|
|
33
|
+
* The stroke color of deemphasized marks.
|
|
34
|
+
* By default the stroke is unchanged.
|
|
35
|
+
*/
|
|
36
|
+
stroke?: string;
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=Highlight.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Highlight.d.ts","sourceRoot":"","sources":["../../../../src/spec/interactors/Highlight.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,8BAA8B;AAC9B,MAAM,WAAW,SAAS;IACxB;;OAEG;IACH,MAAM,EAAE,WAAW,CAAC;IACpB;;OAEG;IACH,EAAE,EAAE,QAAQ,CAAC;IACb;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;OAGG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;OAGG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { ParamRef } from '../Param.js';
|
|
2
|
+
import { BrushStyles } from './BrushStyles.js';
|
|
3
|
+
/** Options for 1D interval interactors. */
|
|
4
|
+
export interface Interval1DOptions {
|
|
5
|
+
/**
|
|
6
|
+
* The output selection. A clause of the form `field BETWEEN lo AND hi`
|
|
7
|
+
* is added for the currently selected interval [lo, hi].
|
|
8
|
+
*/
|
|
9
|
+
as: ParamRef;
|
|
10
|
+
/**
|
|
11
|
+
* The name of the field (database column) over which the interval
|
|
12
|
+
* selection should be defined. If unspecified, the channel field of the
|
|
13
|
+
* first valid prior mark definition is used.
|
|
14
|
+
*/
|
|
15
|
+
field?: string;
|
|
16
|
+
/**
|
|
17
|
+
* The size of an interactive pixel (default `1`). Larger pixel sizes reduce
|
|
18
|
+
* the brush resolution, which can reduce the size of pre-aggregated
|
|
19
|
+
* materialized views.
|
|
20
|
+
*/
|
|
21
|
+
pixelSize?: number;
|
|
22
|
+
/**
|
|
23
|
+
* A flag indicating if peer (sibling) marks are excluded when
|
|
24
|
+
* cross-filtering (default `true`). If set, peer marks will not be
|
|
25
|
+
* filtered by this interactor's selection in cross-filtering setups.
|
|
26
|
+
*/
|
|
27
|
+
peers?: boolean;
|
|
28
|
+
/**
|
|
29
|
+
* CSS styles for the brush (SVG `rect`) element.
|
|
30
|
+
*/
|
|
31
|
+
brush?: BrushStyles;
|
|
32
|
+
}
|
|
33
|
+
/** An intervalX interactor. */
|
|
34
|
+
export interface IntervalX extends Interval1DOptions {
|
|
35
|
+
/** Select a continuous 1D interval selection over the `x` scale domain. */
|
|
36
|
+
select: 'intervalX';
|
|
37
|
+
}
|
|
38
|
+
/** An intervalY interactor. */
|
|
39
|
+
export interface IntervalY extends Interval1DOptions {
|
|
40
|
+
/** Select a continuous 1D interval selection over the `y` scale domain. */
|
|
41
|
+
select: 'intervalY';
|
|
42
|
+
}
|
|
43
|
+
//# sourceMappingURL=Interval1D.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Interval1D.d.ts","sourceRoot":"","sources":["../../../../src/spec/interactors/Interval1D.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,2CAA2C;AAC3C,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,EAAE,EAAE,QAAQ,CAAC;IACb;;;;OAIG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB;;OAEG;IACH,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB;AAED,+BAA+B;AAC/B,MAAM,WAAW,SAAU,SAAQ,iBAAiB;IAClD,2EAA2E;IAC3E,MAAM,EAAE,WAAW,CAAC;CACrB;AAED,+BAA+B;AAC/B,MAAM,WAAW,SAAU,SAAQ,iBAAiB;IAClD,2EAA2E;IAC3E,MAAM,EAAE,WAAW,CAAC;CACrB"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { ParamRef } from '../Param.js';
|
|
2
|
+
import { BrushStyles } from './BrushStyles.js';
|
|
3
|
+
/** Options for 2D interval interactors. */
|
|
4
|
+
export interface Interval2DOptions {
|
|
5
|
+
/**
|
|
6
|
+
* The output selection. A clause of the form
|
|
7
|
+
* `(xfield BETWEEN x1 AND x2) AND (yfield BETWEEN y1 AND y2)`
|
|
8
|
+
* is added for the currently selected intervals.
|
|
9
|
+
*/
|
|
10
|
+
as: ParamRef;
|
|
11
|
+
/**
|
|
12
|
+
* The name of the field (database column) over which the `x`-component
|
|
13
|
+
* of the interval selection should be defined. If unspecified, the `x`
|
|
14
|
+
* channel field of the first valid prior mark definition is used.
|
|
15
|
+
*/
|
|
16
|
+
xfield?: string;
|
|
17
|
+
/**
|
|
18
|
+
* The name of the field (database column) over which the `y`-component
|
|
19
|
+
* of the interval selection should be defined. If unspecified, the `y`
|
|
20
|
+
* channel field of the first valid prior mark definition is used.
|
|
21
|
+
*/
|
|
22
|
+
yfield?: string;
|
|
23
|
+
/**
|
|
24
|
+
* The size of an interactive pixel (default `1`). Larger pixel sizes reduce
|
|
25
|
+
* the brush resolution, which can reduce the size of pre-aggregated
|
|
26
|
+
* materialized views.
|
|
27
|
+
*/
|
|
28
|
+
pixelSize?: number;
|
|
29
|
+
/**
|
|
30
|
+
* A flag indicating if peer (sibling) marks are excluded when
|
|
31
|
+
* cross-filtering (default `true`). If set, peer marks will not be
|
|
32
|
+
* filtered by this interactor's selection in cross-filtering setups.
|
|
33
|
+
*/
|
|
34
|
+
peers?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* CSS styles for the brush (SVG `rect`) element.
|
|
37
|
+
*/
|
|
38
|
+
brush?: BrushStyles;
|
|
39
|
+
}
|
|
40
|
+
/** An intervalXY interactor. */
|
|
41
|
+
export interface IntervalXY extends Interval2DOptions {
|
|
42
|
+
/**
|
|
43
|
+
* Select a continuous 2D interval selection
|
|
44
|
+
* over the `x` and `y` scale domains.
|
|
45
|
+
*/
|
|
46
|
+
select: 'intervalXY';
|
|
47
|
+
}
|
|
48
|
+
//# sourceMappingURL=Interval2D.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Interval2D.d.ts","sourceRoot":"","sources":["../../../../src/spec/interactors/Interval2D.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACvC,OAAO,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAC;AAE/C,2CAA2C;AAC3C,MAAM,WAAW,iBAAiB;IAChC;;;;OAIG;IACH,EAAE,EAAE,QAAQ,CAAC;IACb;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB;;OAEG;IACH,KAAK,CAAC,EAAE,WAAW,CAAC;CACrB;AAED,gCAAgC;AAChC,MAAM,WAAW,UAAW,SAAQ,iBAAiB;IACnD;;;OAGG;IACH,MAAM,EAAE,YAAY,CAAC;CACtB"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { ParamRef } from '../Param.js';
|
|
2
|
+
/** Options for nearest interactors. */
|
|
3
|
+
export interface NearestOptions {
|
|
4
|
+
/**
|
|
5
|
+
* The output selection. A clause of the form `field = value`
|
|
6
|
+
* is added for the currently nearest value.
|
|
7
|
+
*/
|
|
8
|
+
as: ParamRef;
|
|
9
|
+
/**
|
|
10
|
+
* The encoding channels whose domain values should be selected. For example,
|
|
11
|
+
* a setting of `['color']` selects the data value backing the color channel,
|
|
12
|
+
* whereas `['x', 'z']` selects both x and z channel domain values. If
|
|
13
|
+
* unspecified, the selected channels default to match the current pointer
|
|
14
|
+
* settings: a `nearestX` interactor selects the `['x']` channels, while
|
|
15
|
+
* a `nearest` interactor selects the `['x', 'y']` channels.
|
|
16
|
+
*/
|
|
17
|
+
channels?: string[];
|
|
18
|
+
/**
|
|
19
|
+
* The fields (database column names) to use in generated selection clause
|
|
20
|
+
* predicates. If unspecified, the fields backing the selected *channels*
|
|
21
|
+
* in the first valid prior mark definition are used by default.
|
|
22
|
+
*/
|
|
23
|
+
fields?: string[];
|
|
24
|
+
/**
|
|
25
|
+
* The maximum radius of a nearest selection (default 40). Marks with (x, y)
|
|
26
|
+
* coordinates outside this radius will not be selected as nearest points.
|
|
27
|
+
*/
|
|
28
|
+
maxRadius?: number;
|
|
29
|
+
}
|
|
30
|
+
/** A nearest interactor. */
|
|
31
|
+
export interface Nearest extends NearestOptions {
|
|
32
|
+
/** Select values from the mark closest to the pointer. */
|
|
33
|
+
select: 'nearest';
|
|
34
|
+
}
|
|
35
|
+
/** A nearestX interactor. */
|
|
36
|
+
export interface NearestX extends NearestOptions {
|
|
37
|
+
/** Select values from the mark closest to the pointer *x* location. */
|
|
38
|
+
select: 'nearestX';
|
|
39
|
+
}
|
|
40
|
+
/** A nearestY interactor. */
|
|
41
|
+
export interface NearestY extends NearestOptions {
|
|
42
|
+
/** Select values from the mark closest to the pointer *y* location. */
|
|
43
|
+
select: 'nearestY';
|
|
44
|
+
}
|
|
45
|
+
//# sourceMappingURL=Nearest.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Nearest.d.ts","sourceRoot":"","sources":["../../../../src/spec/interactors/Nearest.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAEvC,uCAAuC;AACvC,MAAM,WAAW,cAAc;IAC7B;;;OAGG;IACH,EAAE,EAAE,QAAQ,CAAC;IACb;;;;;;;OAOG;IACH,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;IAClB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,4BAA4B;AAC5B,MAAM,WAAW,OAAQ,SAAQ,cAAc;IAC7C,0DAA0D;IAC1D,MAAM,EAAE,SAAS,CAAC;CACnB;AAED,6BAA6B;AAC7B,MAAM,WAAW,QAAS,SAAQ,cAAc;IAC9C,uEAAuE;IACvE,MAAM,EAAE,UAAU,CAAC;CACpB;AAED,6BAA6B;AAC7B,MAAM,WAAW,QAAS,SAAQ,cAAc;IAC9C,uEAAuE;IACvE,MAAM,EAAE,UAAU,CAAC;CACpB"}
|