@carto/api-client 0.5.15 → 0.5.17
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/CHANGELOG.md +11 -0
- package/build/api-client.cjs +1048 -154
- package/build/api-client.cjs.map +1 -1
- package/build/api-client.d.cts +184 -30
- package/build/api-client.d.ts +184 -30
- package/build/api-client.js +1034 -152
- package/build/api-client.js.map +1 -1
- package/build/worker-compat.js +1395 -1276
- package/build/worker-compat.js.map +1 -1
- package/build/worker.js +34 -0
- package/build/worker.js.map +1 -1
- package/package.json +3 -2
- package/src/fetch-map/basemap-styles.ts +1 -1
- package/src/fetch-map/index.ts +6 -1
- package/src/fetch-map/layer-map.ts +130 -40
- package/src/fetch-map/parse-map.ts +284 -165
- package/src/fetch-map/raster-layer.ts +536 -0
- package/src/fetch-map/types.ts +21 -7
- package/src/fetch-map/utils.ts +56 -0
- package/src/fetch-map/vec-expr-evaluator.ts +374 -0
- package/src/index.ts +7 -1
- package/src/models/model.ts +1 -0
- package/src/sources/types.ts +52 -11
- package/src/widget-sources/types.ts +25 -0
- package/src/widget-sources/widget-remote-source.ts +30 -0
- package/src/widget-sources/widget-source.ts +11 -0
- package/src/widget-sources/widget-tileset-source-impl.ts +49 -0
- package/src/widget-sources/widget-tileset-source.ts +13 -0
- package/src/workers/constants.ts +1 -0
package/build/api-client.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { Feature, Polygon, MultiPolygon, BBox, FeatureCollection, Geometry } from 'geojson';
|
|
2
2
|
import { BinaryFeatureCollection, BinaryFeature } from '@loaders.gl/schema';
|
|
3
|
+
import jsep from 'jsep';
|
|
3
4
|
|
|
4
5
|
/**
|
|
5
6
|
* Returns current client ID, used to categorize API requests. For internal use only.
|
|
@@ -574,13 +575,50 @@ interface Tilestats {
|
|
|
574
575
|
}
|
|
575
576
|
interface Layer {
|
|
576
577
|
layer: string;
|
|
578
|
+
/** Number of features in the layer. */
|
|
577
579
|
count: number;
|
|
580
|
+
/** Number of attributes in the layer. */
|
|
578
581
|
attributeCount: number;
|
|
579
582
|
attributes: Attribute[];
|
|
583
|
+
/** Type of geometry as in geojson geometry type (Point, LineString, Polygon, etc.) */
|
|
584
|
+
geometry?: string;
|
|
585
|
+
}
|
|
586
|
+
interface AttributeCategoryItem {
|
|
587
|
+
category: string;
|
|
588
|
+
frequency: number;
|
|
589
|
+
}
|
|
590
|
+
/**
|
|
591
|
+
* Quantiles by number of buckets.
|
|
592
|
+
*
|
|
593
|
+
* Example:
|
|
594
|
+
* ```ts
|
|
595
|
+
* {
|
|
596
|
+
* // for 3 buckets, first 1/3 of items lies in range [min, 20], second 1/3 is in [20, 40], and last 1/3 is in [40, max]
|
|
597
|
+
* 3: [20, 40],
|
|
598
|
+
* 4: [20, 30, 50], for 4 buckets ...
|
|
599
|
+
* }
|
|
600
|
+
* ```
|
|
601
|
+
*/
|
|
602
|
+
interface QuantileStats {
|
|
603
|
+
[bucketCount: number]: number[];
|
|
580
604
|
}
|
|
581
605
|
interface Attribute {
|
|
582
|
-
|
|
606
|
+
/**
|
|
607
|
+
* String, Number, Timestamp, Boolean
|
|
608
|
+
*/
|
|
583
609
|
type: string;
|
|
610
|
+
/**
|
|
611
|
+
* Attribute name.
|
|
612
|
+
*/
|
|
613
|
+
attribute: string;
|
|
614
|
+
min?: number;
|
|
615
|
+
max?: number;
|
|
616
|
+
sum?: number;
|
|
617
|
+
/** Quantiles by number of buckets */
|
|
618
|
+
quantiles?: {
|
|
619
|
+
global: QuantileStats;
|
|
620
|
+
} | QuantileStats;
|
|
621
|
+
categories?: AttributeCategoryItem[];
|
|
584
622
|
}
|
|
585
623
|
interface VectorLayer {
|
|
586
624
|
id: string;
|
|
@@ -600,17 +638,8 @@ type RasterMetadataBandStats = {
|
|
|
600
638
|
count: number;
|
|
601
639
|
/**
|
|
602
640
|
* Quantiles by number of buckets.
|
|
603
|
-
*
|
|
604
|
-
* Example:
|
|
605
|
-
* ```ts
|
|
606
|
-
* {
|
|
607
|
-
* // for 3 buckets, first 1/3 of items lies in range [min, 20], second 1/3 is in [20, 40], and last 1/3 is in [40, max]
|
|
608
|
-
* 3: [20, 40],
|
|
609
|
-
* 4: [20, 30, 50], for 4 buckets ...
|
|
610
|
-
* }
|
|
611
|
-
* ```
|
|
612
641
|
*/
|
|
613
|
-
quantiles?:
|
|
642
|
+
quantiles?: QuantileStats;
|
|
614
643
|
/**
|
|
615
644
|
* Top values by number of values.
|
|
616
645
|
*
|
|
@@ -744,12 +773,19 @@ declare function getLayerProps(type: LayerType, config: MapLayerConfig, dataset:
|
|
|
744
773
|
declare function domainFromValues(values: any, scaleType: ScaleType): any;
|
|
745
774
|
declare function opacityToAlpha(opacity?: number): number;
|
|
746
775
|
declare function getColorAccessor({ name, colorColumn }: VisualChannelField, scaleType: ScaleType, { aggregation, range }: {
|
|
747
|
-
aggregation
|
|
748
|
-
range:
|
|
749
|
-
}, opacity: number | undefined, data:
|
|
776
|
+
aggregation?: string;
|
|
777
|
+
range: ColorRange;
|
|
778
|
+
}, opacity: number | undefined, data: TilejsonResult): {
|
|
750
779
|
accessor: any;
|
|
751
|
-
|
|
780
|
+
domain: number[] | string[];
|
|
781
|
+
scaleDomain: number[] | string[];
|
|
782
|
+
range: string[];
|
|
752
783
|
};
|
|
784
|
+
declare function calculateLayerScale(name: string, scaleType: ScaleType, range: ColorRange, data: TilejsonResult): {
|
|
785
|
+
scale: D3Scale;
|
|
786
|
+
domain: string[] | number[];
|
|
787
|
+
};
|
|
788
|
+
declare function createColorScale<T>(scaleType: ScaleType, domain: string[] | number[], range: T[], unknown: T): D3Scale;
|
|
753
789
|
declare function getIconUrlAccessor(field: VisualChannelField | null | undefined, range: CustomMarkersRange | null | undefined, { fallbackUrl, maxIconSize, useMaskedIcons, }: {
|
|
754
790
|
fallbackUrl?: string | null;
|
|
755
791
|
maxIconSize: number;
|
|
@@ -758,9 +794,11 @@ declare function getIconUrlAccessor(field: VisualChannelField | null | undefined
|
|
|
758
794
|
declare function getMaxMarkerSize(visConfig: VisConfig, visualChannels: VisualChannels): number;
|
|
759
795
|
type Accessor = number | ((d: any, i: any) => number);
|
|
760
796
|
declare function negateAccessor(accessor: Accessor): Accessor;
|
|
761
|
-
declare function getSizeAccessor({ name }: VisualChannelField, scaleType: ScaleType | undefined, aggregation: string | null | undefined, range:
|
|
797
|
+
declare function getSizeAccessor({ name }: VisualChannelField, scaleType: ScaleType | undefined, aggregation: string | null | undefined, range: number[] | undefined, data: TilejsonResult): {
|
|
762
798
|
accessor: any;
|
|
763
|
-
|
|
799
|
+
domain: number[];
|
|
800
|
+
scaleDomain: number[];
|
|
801
|
+
range: number[] | undefined;
|
|
764
802
|
};
|
|
765
803
|
declare function getTextAccessor({ name, type }: VisualChannelField, data: any): any;
|
|
766
804
|
|
|
@@ -804,6 +842,7 @@ type ColorRange = {
|
|
|
804
842
|
colorMap: string[][] | undefined;
|
|
805
843
|
name: string;
|
|
806
844
|
type: string;
|
|
845
|
+
uiCustomScaleType?: 'logarithmic';
|
|
807
846
|
};
|
|
808
847
|
type CustomMarkersRange = {
|
|
809
848
|
markerMap: {
|
|
@@ -812,27 +851,36 @@ type CustomMarkersRange = {
|
|
|
812
851
|
}[];
|
|
813
852
|
othersMarker?: string;
|
|
814
853
|
};
|
|
854
|
+
type ColorBand = 'red' | 'green' | 'blue' | 'alpha';
|
|
855
|
+
type RasterLayerConfigColorBand = {
|
|
856
|
+
band: ColorBand;
|
|
857
|
+
type: 'none' | 'band' | 'expression';
|
|
858
|
+
value: string;
|
|
859
|
+
};
|
|
815
860
|
type VisConfig = {
|
|
816
861
|
filled?: boolean;
|
|
817
862
|
opacity?: number;
|
|
818
863
|
enable3d?: boolean;
|
|
819
|
-
colorAggregation?:
|
|
864
|
+
colorAggregation?: string;
|
|
820
865
|
colorRange: ColorRange;
|
|
821
866
|
customMarkers?: boolean;
|
|
822
867
|
customMarkersRange?: CustomMarkersRange | null;
|
|
823
868
|
customMarkersUrl?: string | null;
|
|
824
869
|
radius: number;
|
|
825
870
|
radiusRange?: number[];
|
|
826
|
-
sizeAggregation?:
|
|
827
|
-
sizeRange?:
|
|
828
|
-
strokeColorAggregation?:
|
|
871
|
+
sizeAggregation?: string;
|
|
872
|
+
sizeRange?: number[];
|
|
873
|
+
strokeColorAggregation?: string;
|
|
829
874
|
strokeOpacity?: number;
|
|
830
875
|
strokeColorRange?: ColorRange;
|
|
831
|
-
heightRange?:
|
|
832
|
-
heightAggregation?:
|
|
833
|
-
weightAggregation?:
|
|
876
|
+
heightRange?: number[];
|
|
877
|
+
heightAggregation?: string;
|
|
878
|
+
weightAggregation?: string;
|
|
834
879
|
clusterLevel?: number;
|
|
835
880
|
isTextVisible?: boolean;
|
|
881
|
+
rasterStyleType?: 'Rgb' | 'ColorRange' | 'UniqueValues';
|
|
882
|
+
colorBands?: RasterLayerConfigColorBand[];
|
|
883
|
+
uniqueValuesColorRange?: ColorRange;
|
|
836
884
|
};
|
|
837
885
|
type TextLabel = {
|
|
838
886
|
field: VisualChannelField | null | undefined;
|
|
@@ -967,6 +1015,9 @@ type Dataset = {
|
|
|
967
1015
|
exportToBucketAvailable?: boolean;
|
|
968
1016
|
};
|
|
969
1017
|
|
|
1018
|
+
type StyleLayerGroupSlug = 'label' | 'road' | 'border' | 'building' | 'water' | 'land';
|
|
1019
|
+
declare function applyLayerGroupFilters(style: any, // this Maplibre/Mapbox style, we don't want to add a dependency on Maplibre
|
|
1020
|
+
visibleLayerGroups: Record<StyleLayerGroupSlug, boolean>): any;
|
|
970
1021
|
declare const _default: {
|
|
971
1022
|
readonly VOYAGER: string;
|
|
972
1023
|
readonly POSITRON: string;
|
|
@@ -976,17 +1027,36 @@ declare const _default: {
|
|
|
976
1027
|
readonly DARK_MATTER_NOLABELS: string;
|
|
977
1028
|
};
|
|
978
1029
|
|
|
1030
|
+
declare function getRasterTileLayerStyleProps({ layerConfig, visualChannels, rasterMetadata, }: {
|
|
1031
|
+
layerConfig: MapLayerConfig;
|
|
1032
|
+
visualChannels: VisualChannels;
|
|
1033
|
+
rasterMetadata: RasterMetadata;
|
|
1034
|
+
}): {
|
|
1035
|
+
dataTransform: () => any;
|
|
1036
|
+
updateTriggers: {
|
|
1037
|
+
getFillColor: Record<string, unknown>;
|
|
1038
|
+
};
|
|
1039
|
+
} | {
|
|
1040
|
+
dataTransform?: undefined;
|
|
1041
|
+
updateTriggers?: undefined;
|
|
1042
|
+
};
|
|
1043
|
+
|
|
979
1044
|
type Scale = {
|
|
1045
|
+
type: ScaleType;
|
|
980
1046
|
field: VisualChannelField;
|
|
1047
|
+
/** Natural domain of the scale, as defined by the data */
|
|
981
1048
|
domain: string[] | number[];
|
|
982
|
-
|
|
983
|
-
|
|
1049
|
+
/** Domain of the user to construct d3 scale */
|
|
1050
|
+
scaleDomain?: string[] | number[];
|
|
1051
|
+
range?: string[] | number[];
|
|
984
1052
|
};
|
|
1053
|
+
type ScaleKey = 'fillColor' | 'pointRadius' | 'lineColor' | 'elevation' | 'weight';
|
|
1054
|
+
type Scales = Partial<Record<ScaleKey, Scale>>;
|
|
985
1055
|
type LayerDescriptor = {
|
|
986
1056
|
type: LayerType;
|
|
987
1057
|
props: Record<string, any>;
|
|
988
1058
|
filters?: Filters;
|
|
989
|
-
scales:
|
|
1059
|
+
scales: Scales;
|
|
990
1060
|
};
|
|
991
1061
|
type ParseMapResult = {
|
|
992
1062
|
/** Map id. */
|
|
@@ -1004,6 +1074,11 @@ type ParseMapResult = {
|
|
|
1004
1074
|
token: string;
|
|
1005
1075
|
layers: LayerDescriptor[];
|
|
1006
1076
|
};
|
|
1077
|
+
declare function getLayerDescriptor({ mapConfig, layer, dataset, }: {
|
|
1078
|
+
mapConfig: KeplerMapConfig;
|
|
1079
|
+
layer: MapConfigLayer;
|
|
1080
|
+
dataset: Dataset;
|
|
1081
|
+
}): LayerDescriptor;
|
|
1007
1082
|
declare function parseMap(json: any): {
|
|
1008
1083
|
id: any;
|
|
1009
1084
|
title: any;
|
|
@@ -1021,7 +1096,6 @@ declare function parseMap(json: any): {
|
|
|
1021
1096
|
token: any;
|
|
1022
1097
|
layers: (LayerDescriptor | undefined)[];
|
|
1023
1098
|
};
|
|
1024
|
-
type ScaleKey = 'fillColor' | 'pointRadius' | 'lineColor' | 'elevation' | 'weight';
|
|
1025
1099
|
|
|
1026
1100
|
type FetchMapOptions = {
|
|
1027
1101
|
/**
|
|
@@ -1085,6 +1159,55 @@ declare function fetchBasemapProps({ config, errorContext, applyLayerFilters, }:
|
|
|
1085
1159
|
errorContext?: APIErrorContext;
|
|
1086
1160
|
}): Promise<Basemap | null>;
|
|
1087
1161
|
|
|
1162
|
+
/**
|
|
1163
|
+
* Create domain for D3 threshold scale with logarithmic steps.
|
|
1164
|
+
*
|
|
1165
|
+
* If min is 0, it starts with max and goes down to fill color scale.
|
|
1166
|
+
* If max is Infinity, it starts with 10 and goes up to fill color scale.
|
|
1167
|
+
* Othersise it starts on first power of 10 that is greater than min.
|
|
1168
|
+
*
|
|
1169
|
+
* Generates `steps-1` entries, as this is what d3 threshold scale expects
|
|
1170
|
+
*
|
|
1171
|
+
* @see https://d3js.org/d3-scale/threshold
|
|
1172
|
+
*/
|
|
1173
|
+
declare function getLog10ScaleSteps({ min, max, steps, }: {
|
|
1174
|
+
min: number;
|
|
1175
|
+
max: number;
|
|
1176
|
+
steps: number;
|
|
1177
|
+
}): number[];
|
|
1178
|
+
|
|
1179
|
+
/**
|
|
1180
|
+
* Create vector expresion evaluator.
|
|
1181
|
+
*
|
|
1182
|
+
* Used to calculate vector expressions, such as `(band_1 * 3) + band_2/2`,
|
|
1183
|
+
* where `band_1` and `band_2` are arrays or typed arrays.
|
|
1184
|
+
*
|
|
1185
|
+
* Note that all vector operations are element-wise, in paricular `band_1 * band_2`
|
|
1186
|
+
* is not "mathematical" dot or cross product, but just element-wise multiplication.
|
|
1187
|
+
*
|
|
1188
|
+
* Based on:
|
|
1189
|
+
* - Copyright (c) 2013 Stephen Oney, http://jsep.from.so/, MIT License
|
|
1190
|
+
* - Copyright (c) 2023 Don McCurdy, https://github.com/donmccurdy/expression-eval, MIT License
|
|
1191
|
+
*/
|
|
1192
|
+
declare function createVecExprEvaluator(expression: string | jsep.Expression): VecExprEvaluator | null;
|
|
1193
|
+
declare function evaluateVecExpr(expression: string | jsep.Expression, context: Record<string, VecExprResult>): VecExprResult | null | undefined;
|
|
1194
|
+
declare enum ErrorCode {
|
|
1195
|
+
InvalidSyntax = 0,
|
|
1196
|
+
UnknownIdentifier = 1
|
|
1197
|
+
}
|
|
1198
|
+
type ValidationResult = {
|
|
1199
|
+
valid: boolean;
|
|
1200
|
+
errorCode?: ErrorCode;
|
|
1201
|
+
errorMessage?: string;
|
|
1202
|
+
};
|
|
1203
|
+
declare function validateVecExprSyntax(expression: string | jsep.Expression, context: Record<string, unknown>): ValidationResult;
|
|
1204
|
+
type VecExprVecLike = number[] | Float32Array | Float64Array | Uint8Array | Int8Array | Int32Array | Uint32Array | Uint16Array | Int16Array;
|
|
1205
|
+
type VecExprResult = number | VecExprVecLike;
|
|
1206
|
+
type VecExprEvaluator = {
|
|
1207
|
+
(context: object): VecExprResult;
|
|
1208
|
+
symbols?: string[];
|
|
1209
|
+
};
|
|
1210
|
+
|
|
1088
1211
|
type FilterTypeOptions<T extends FilterType> = {
|
|
1089
1212
|
type: T;
|
|
1090
1213
|
column: string;
|
|
@@ -1341,6 +1464,23 @@ interface TimeSeriesRequestOptions extends BaseRequestOptions {
|
|
|
1341
1464
|
splitByCategoryLimit?: number;
|
|
1342
1465
|
splitByCategoryValues?: string[];
|
|
1343
1466
|
}
|
|
1467
|
+
/**
|
|
1468
|
+
* Examples:
|
|
1469
|
+
* * aggregations with array syntax
|
|
1470
|
+
* * aggregations: [{column: 'pop_high', operation: 'sum', alias: 'high_pop'}, {column: 'pop_low', operation: 'avg'}]
|
|
1471
|
+
* * aggregations with string syntax
|
|
1472
|
+
* * aggregations: 'sum(pop_high) as high_pop, avg(pop_low) as avg_low'
|
|
1473
|
+
*
|
|
1474
|
+
* Options for {@link WidgetRemoteSource#getAggregations}.
|
|
1475
|
+
*/
|
|
1476
|
+
interface AggregationsRequestOptions extends BaseRequestOptions {
|
|
1477
|
+
/** Aggregations to compute. Can be an array of objects or a SQL string expression. */
|
|
1478
|
+
aggregations: {
|
|
1479
|
+
column: string;
|
|
1480
|
+
operation: Exclude<AggregationType, 'custom'>;
|
|
1481
|
+
alias: string;
|
|
1482
|
+
}[] | string;
|
|
1483
|
+
}
|
|
1344
1484
|
/** @experimental */
|
|
1345
1485
|
type ExtentRequestOptions = BaseRequestOptions;
|
|
1346
1486
|
/******************************************************************************
|
|
@@ -1396,6 +1536,10 @@ type TimeSeriesResponse = {
|
|
|
1396
1536
|
};
|
|
1397
1537
|
/** Response from {@link WidgetRemoteSource#getHistogram}. */
|
|
1398
1538
|
type HistogramResponse = number[];
|
|
1539
|
+
/** Response from {@link WidgetRemoteSource#getAggregations}. */
|
|
1540
|
+
type AggregationsResponse = {
|
|
1541
|
+
rows: Record<string, number | string | null>[];
|
|
1542
|
+
};
|
|
1399
1543
|
/** @experimental */
|
|
1400
1544
|
type ExtentResponse = {
|
|
1401
1545
|
bbox: BBox;
|
|
@@ -1468,6 +1612,12 @@ declare abstract class WidgetSource<Props extends WidgetSourceProps = WidgetSour
|
|
|
1468
1612
|
* time intervals. Suitable for rendering time series charts.
|
|
1469
1613
|
*/
|
|
1470
1614
|
abstract getTimeSeries(options: TimeSeriesRequestOptions): Promise<TimeSeriesResponse>;
|
|
1615
|
+
/**
|
|
1616
|
+
* Returns multiple aggregated values computed over matching data. Suitable
|
|
1617
|
+
* for aggregated statistics from pivoted tables, such as H3 tables with
|
|
1618
|
+
* pre-computed aggregations across multiple columns.
|
|
1619
|
+
*/
|
|
1620
|
+
abstract getAggregations(options: AggregationsRequestOptions): Promise<AggregationsResponse>;
|
|
1471
1621
|
/** @experimental */
|
|
1472
1622
|
abstract getExtent(options?: ExtentRequestOptions): Promise<ExtentResponse>;
|
|
1473
1623
|
}
|
|
@@ -1513,6 +1663,7 @@ declare abstract class WidgetRemoteSource<Props extends WidgetRemoteSourceProps>
|
|
|
1513
1663
|
getScatter(options: ScatterRequestOptions): Promise<ScatterResponse>;
|
|
1514
1664
|
getTable(options: TableRequestOptions): Promise<TableResponse>;
|
|
1515
1665
|
getTimeSeries(options: TimeSeriesRequestOptions): Promise<TimeSeriesResponse>;
|
|
1666
|
+
getAggregations(options: AggregationsRequestOptions): Promise<AggregationsResponse>;
|
|
1516
1667
|
/** @experimental */
|
|
1517
1668
|
getExtent(options?: ExtentRequestOptions): Promise<ExtentResponse>;
|
|
1518
1669
|
}
|
|
@@ -1630,7 +1781,8 @@ declare enum Method {
|
|
|
1630
1781
|
GET_SCATTER = "getScatter",
|
|
1631
1782
|
GET_TABLE = "getTable",
|
|
1632
1783
|
GET_TIME_SERIES = "getTimeSeries",
|
|
1633
|
-
GET_RANGE = "getRange"
|
|
1784
|
+
GET_RANGE = "getRange",
|
|
1785
|
+
GET_AGGREGATIONS = "getAggregations"
|
|
1634
1786
|
}
|
|
1635
1787
|
|
|
1636
1788
|
/**
|
|
@@ -1669,6 +1821,7 @@ declare class WidgetTilesetSourceImpl extends WidgetSource<WidgetTilesetSourcePr
|
|
|
1669
1821
|
getTable({ columns, searchFilterColumn, searchFilterText, sortBy, sortDirection, sortByColumnType, offset, limit, filters, filterOwner, spatialFilter, }: TableRequestOptions): Promise<TableResponse>;
|
|
1670
1822
|
getTimeSeries({ column, stepSize, operation, operationColumn, joinOperation, filters, filterOwner, spatialFilter, }: TimeSeriesRequestOptions): Promise<TimeSeriesResponse>;
|
|
1671
1823
|
getRange({ column, filters, filterOwner, spatialFilter, }: RangeRequestOptions): Promise<RangeResponse>;
|
|
1824
|
+
getAggregations({ aggregations, filters, filterOwner, spatialFilter, }: AggregationsRequestOptions): Promise<AggregationsResponse>;
|
|
1672
1825
|
/** @experimental */
|
|
1673
1826
|
getExtent(): Promise<ExtentResponse>;
|
|
1674
1827
|
/****************************************************************************
|
|
@@ -1749,6 +1902,7 @@ declare class WidgetTilesetSource<Props extends WidgetTilesetSourceProps = Widge
|
|
|
1749
1902
|
getTable({ signal, ...options }: TableRequestOptions): Promise<TableResponse>;
|
|
1750
1903
|
getTimeSeries({ signal, ...options }: TimeSeriesRequestOptions): Promise<TimeSeriesResponse>;
|
|
1751
1904
|
getRange({ signal, ...options }: RangeRequestOptions): Promise<RangeResponse>;
|
|
1905
|
+
getAggregations({ signal, ...options }: AggregationsRequestOptions): Promise<AggregationsResponse>;
|
|
1752
1906
|
/** @experimental */
|
|
1753
1907
|
getExtent(): Promise<ExtentResponse>;
|
|
1754
1908
|
}
|
|
@@ -2012,4 +2166,4 @@ declare function getColumnNameFromGeoColumn(geoColumn: string | null | undefined
|
|
|
2012
2166
|
*/
|
|
2013
2167
|
declare function getSpatialIndexFromGeoColumn(geoColumn: string): SpatialIndex | null;
|
|
2014
2168
|
|
|
2015
|
-
export { type APIErrorContext, type APIRequestType, type AddFilterOptions, type AggregationFunction, type AggregationType, AggregationTypes, ApiVersion, type Attribute, _default as BASEMAP, type BaseRequestOptions, type Basemap, type BoundaryQuerySourceOptions, type BoundaryQuerySourceResponse, type BoundaryTableSourceOptions, type BoundaryTableSourceResponse, CartoAPIError, type CategoryOrderBy, type CategoryRequestOptions, type CategoryResponse, type CategoryResponseEntry, type CategoryResponseRaw, CellSet, type ColumnsOption, type D3Scale, DEFAULT_API_BASE_URL, type ExtentRequestOptions, type ExtentResponse, FEATURE_GEOM_PROPERTY, type FeaturesRequestOptions, type FeaturesResponse, type FetchMapOptions, type FetchMapResult, type Filter, type FilterFunction, type FilterInterval, type FilterIntervalComplete, type FilterIntervalExtremum, type FilterLogicalOperator, type FilterOptions, FilterType, type Filters, type Format, type FormulaRequestOptions, type FormulaResponse, type GetFilterOptions, type GoogleBasemap, type GroupByFeature, type GroupDateType, type H3QuerySourceOptions, type H3QuerySourceResponse, type H3TableSourceOptions, type H3TableSourceResponse, type H3TilesetSourceOptions, type H3TilesetSourceResponse, type HasFilterOptions, type HistogramRequestOptions, type HistogramResponse, type KeplerMapConfig, type Layer, type LayerDescriptor, type LayerType, type MapLibreBasemap, type MapType, type NamedQueryParameter, OPACITY_MAP, OTHERS_CATEGORY_NAME, type ParseMapResult, type PositionalQueryParameter, Provider, type ProviderType, type QuadbinQuerySourceOptions, type QuadbinQuerySourceResponse, type QuadbinTableSourceOptions, type QuadbinTableSourceResponse, type QuadbinTilesetSourceOptions, type QuadbinTilesetSourceResponse, type QueryOptions, type QueryParameterValue, type QueryParameters, type QueryResult, type QuerySourceOptions, type RangeRequestOptions, type RangeResponse, type Raster, RasterBandColorinterp, type RasterBandType, type RasterMetadata, type RasterMetadataBand, type RasterMetadataBandStats, type RasterSourceOptions, type RasterTile, type RemoveFilterOptions, SOURCE_DEFAULTS, type Scale, type ScaleKey, type ScaleType, type ScatterPlotFeature, type ScatterRequestOptions, type ScatterResponse, type SchemaField, SchemaFieldType, type SortColumnType, type SortDirection, type SourceOptionalOptions, type SourceOptions, type SourceRequiredOptions, type SpatialDataType, type SpatialFilter, type SpatialFilterPolyfillMode, SpatialIndex, SpatialIndexColumn, type SpatialIndexTile, type StringSearchOptions, TEXT_LABEL_INDEX, TEXT_NUMBER_FORMATTER, TEXT_OUTLINE_OPACITY, type TableRequestOptions, type TableResponse, type TableSourceOptions, type Tile, type TileFeatureExtractOptions, type TileFeatures, type TileFeaturesSpatialIndexOptions, TileFormat, type TileResolution, type Tilejson, type TilejsonResult, type TilesetSourceOptions, type Tilestats, type TimeSeriesRequestOptions, type TimeSeriesResponse, type TrajectoryQuerySourceOptions, type TrajectoryQuerySourceResponse, type TrajectoryTableSourceOptions, type TrajectoryTableSourceResponse, type VectorLayer, type VectorQuerySourceOptions, type VectorQuerySourceResponse, type VectorTableSourceOptions, type VectorTableSourceResponse, type VectorTilesetSourceOptions, type VectorTilesetSourceResponse, type ViewState, type Viewport, WidgetQuerySource, type WidgetQuerySourceResult, WidgetRasterSource, type WidgetRasterSourceProps, type WidgetRasterSourceResult, WidgetRemoteSource, type WidgetRemoteSourceProps, WidgetSource, type WidgetSourceProps, WidgetTableSource, type WidgetTableSourceResult, WidgetTilesetSource, type WidgetTilesetSourceProps, type WidgetTilesetSourceResult, type _DataFilterExtensionProps, _buildFeatureFilter, domainFromValues as _domainFromValues, _getHexagonResolution, addFilter, aggregate, aggregationFunctions, applyFilters, applySorting, boundaryQuerySource, boundaryTableSource, buildBinaryFeatureFilter, buildPublicMapUrl, buildStatsUrl, calculateClusterRadius, calculateClusterTextFontSize, clearDefaultRequestCache, clearFilters, configureSource, createPolygonSpatialFilter, createViewportSpatialFilter, fetchBasemapProps, fetchMap, filterFunctions, geojsonFeatures, getApplicableFilters, getClient, getColorAccessor, getColumnNameFromGeoColumn, getDataFilterExtensionProps, getDefaultAggregationExpColumnAliasForLayerType, getFilter, getIconUrlAccessor, getLayerProps, getMaxMarkerSize, getSizeAccessor, getSorter, getSpatialIndexFromGeoColumn, getTextAccessor, groupValuesByColumn, groupValuesByDateColumn, h3QuerySource, h3TableSource, h3TilesetSource, hasFilter, histogram, makeIntervalComplete, negateAccessor, opacityToAlpha, parseMap, quadbinQuerySource, quadbinTableSource, quadbinTilesetSource, query, rasterSource, removeFilter, requestWithParameters, scaleAggregationResLevel, scatterPlot, setClient, tileFeatures, tileFeaturesGeometries, tileFeaturesSpatialIndex, trajectoryQuerySource, trajectoryTableSource, transformToTileCoords, vectorQuerySource, vectorTableSource, vectorTilesetSource };
|
|
2169
|
+
export { type APIErrorContext, type APIRequestType, type AddFilterOptions, type AggregationFunction, type AggregationType, AggregationTypes, type AggregationsRequestOptions, type AggregationsResponse, ApiVersion, type Attribute, _default as BASEMAP, type BaseRequestOptions, type Basemap, type BoundaryQuerySourceOptions, type BoundaryQuerySourceResponse, type BoundaryTableSourceOptions, type BoundaryTableSourceResponse, CartoAPIError, type CategoryOrderBy, type CategoryRequestOptions, type CategoryResponse, type CategoryResponseEntry, type CategoryResponseRaw, CellSet, type ColumnsOption, type D3Scale, DEFAULT_API_BASE_URL, type ExtentRequestOptions, type ExtentResponse, FEATURE_GEOM_PROPERTY, type FeaturesRequestOptions, type FeaturesResponse, type FetchMapOptions, type FetchMapResult, type Filter, type FilterFunction, type FilterInterval, type FilterIntervalComplete, type FilterIntervalExtremum, type FilterLogicalOperator, type FilterOptions, FilterType, type Filters, type Format, type FormulaRequestOptions, type FormulaResponse, type GetFilterOptions, type GoogleBasemap, type GroupByFeature, type GroupDateType, type H3QuerySourceOptions, type H3QuerySourceResponse, type H3TableSourceOptions, type H3TableSourceResponse, type H3TilesetSourceOptions, type H3TilesetSourceResponse, type HasFilterOptions, type HistogramRequestOptions, type HistogramResponse, type KeplerMapConfig, type Layer, type LayerDescriptor, type LayerType, type MapLibreBasemap, type MapType, type NamedQueryParameter, OPACITY_MAP, OTHERS_CATEGORY_NAME, type ParseMapResult, type PositionalQueryParameter, Provider, type ProviderType, type QuadbinQuerySourceOptions, type QuadbinQuerySourceResponse, type QuadbinTableSourceOptions, type QuadbinTableSourceResponse, type QuadbinTilesetSourceOptions, type QuadbinTilesetSourceResponse, type QueryOptions, type QueryParameterValue, type QueryParameters, type QueryResult, type QuerySourceOptions, type RangeRequestOptions, type RangeResponse, type Raster, RasterBandColorinterp, type RasterBandType, type RasterMetadata, type RasterMetadataBand, type RasterMetadataBandStats, type RasterSourceOptions, type RasterTile, type RemoveFilterOptions, SOURCE_DEFAULTS, type Scale, type ScaleKey, type ScaleType, type Scales, type ScatterPlotFeature, type ScatterRequestOptions, type ScatterResponse, type SchemaField, SchemaFieldType, type SortColumnType, type SortDirection, type SourceOptionalOptions, type SourceOptions, type SourceRequiredOptions, type SpatialDataType, type SpatialFilter, type SpatialFilterPolyfillMode, SpatialIndex, SpatialIndexColumn, type SpatialIndexTile, type StringSearchOptions, TEXT_LABEL_INDEX, TEXT_NUMBER_FORMATTER, TEXT_OUTLINE_OPACITY, type TableRequestOptions, type TableResponse, type TableSourceOptions, type Tile, type TileFeatureExtractOptions, type TileFeatures, type TileFeaturesSpatialIndexOptions, TileFormat, type TileResolution, type Tilejson, type TilejsonResult, type TilesetSourceOptions, type Tilestats, type TimeSeriesRequestOptions, type TimeSeriesResponse, type TrajectoryQuerySourceOptions, type TrajectoryQuerySourceResponse, type TrajectoryTableSourceOptions, type TrajectoryTableSourceResponse, type VectorLayer, type VectorQuerySourceOptions, type VectorQuerySourceResponse, type VectorTableSourceOptions, type VectorTableSourceResponse, type VectorTilesetSourceOptions, type VectorTilesetSourceResponse, type ViewState, type Viewport, WidgetQuerySource, type WidgetQuerySourceResult, WidgetRasterSource, type WidgetRasterSourceProps, type WidgetRasterSourceResult, WidgetRemoteSource, type WidgetRemoteSourceProps, WidgetSource, type WidgetSourceProps, WidgetTableSource, type WidgetTableSourceResult, WidgetTilesetSource, type WidgetTilesetSourceProps, type WidgetTilesetSourceResult, type _DataFilterExtensionProps, ErrorCode as _ErrorCode, type VecExprResult as _VecExprResult, applyLayerGroupFilters as _applyLayerGroupFilters, _buildFeatureFilter, createVecExprEvaluator as _createVecExprEvaluator, domainFromValues as _domainFromValues, evaluateVecExpr as _evaluateVecExpr, _getHexagonResolution, getLog10ScaleSteps as _getLog10ScaleSteps, getRasterTileLayerStyleProps as _getRasterTileLayerStyleProps, validateVecExprSyntax as _validateVecExprSyntax, addFilter, aggregate, aggregationFunctions, applyFilters, applySorting, boundaryQuerySource, boundaryTableSource, buildBinaryFeatureFilter, buildPublicMapUrl, buildStatsUrl, calculateClusterRadius, calculateClusterTextFontSize, calculateLayerScale, clearDefaultRequestCache, clearFilters, configureSource, createColorScale, createPolygonSpatialFilter, createViewportSpatialFilter, fetchBasemapProps, fetchMap, filterFunctions, geojsonFeatures, getApplicableFilters, getClient, getColorAccessor, getColumnNameFromGeoColumn, getDataFilterExtensionProps, getDefaultAggregationExpColumnAliasForLayerType, getFilter, getIconUrlAccessor, getLayerDescriptor, getLayerProps, getMaxMarkerSize, getSizeAccessor, getSorter, getSpatialIndexFromGeoColumn, getTextAccessor, groupValuesByColumn, groupValuesByDateColumn, h3QuerySource, h3TableSource, h3TilesetSource, hasFilter, histogram, makeIntervalComplete, negateAccessor, opacityToAlpha, parseMap, quadbinQuerySource, quadbinTableSource, quadbinTilesetSource, query, rasterSource, removeFilter, requestWithParameters, scaleAggregationResLevel, scatterPlot, setClient, tileFeatures, tileFeaturesGeometries, tileFeaturesSpatialIndex, trajectoryQuerySource, trajectoryTableSource, transformToTileCoords, vectorQuerySource, vectorTableSource, vectorTilesetSource };
|