@carto/api-client 0.5.25 → 0.5.27-alpha.482101a.112
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 +6 -0
- package/build/api-client.cjs +3 -2
- package/build/api-client.cjs.map +1 -1
- package/build/api-client.d.cts +7 -0
- package/build/api-client.d.ts +7 -0
- package/build/api-client.js +3 -2
- package/build/api-client.js.map +1 -1
- package/package.json +1 -1
- package/src/widget-sources/types.ts +9 -1
- package/src/widget-sources/widget-remote-source.ts +4 -4
package/build/api-client.d.cts
CHANGED
|
@@ -1383,6 +1383,10 @@ interface FeaturesRequestOptions extends BaseRequestOptions {
|
|
|
1383
1383
|
* given in the request.
|
|
1384
1384
|
*/
|
|
1385
1385
|
limit?: number;
|
|
1386
|
+
/**
|
|
1387
|
+
* Number of objects to skip in the result set.
|
|
1388
|
+
*/
|
|
1389
|
+
offset?: number;
|
|
1386
1390
|
/**
|
|
1387
1391
|
* Must match `tileResolution` used when obtaining the `_carto_feature_id`
|
|
1388
1392
|
* column, typically in a layer's tile requests.
|
|
@@ -1499,6 +1503,9 @@ type ExtentRequestOptions = BaseRequestOptions;
|
|
|
1499
1503
|
*/
|
|
1500
1504
|
type FeaturesResponse = {
|
|
1501
1505
|
rows: Record<string, unknown>[];
|
|
1506
|
+
metadata: {
|
|
1507
|
+
total?: number;
|
|
1508
|
+
};
|
|
1502
1509
|
};
|
|
1503
1510
|
/** Response from {@link WidgetRemoteSource#getFormula}. */
|
|
1504
1511
|
type FormulaResponse = {
|
package/build/api-client.d.ts
CHANGED
|
@@ -1383,6 +1383,10 @@ interface FeaturesRequestOptions extends BaseRequestOptions {
|
|
|
1383
1383
|
* given in the request.
|
|
1384
1384
|
*/
|
|
1385
1385
|
limit?: number;
|
|
1386
|
+
/**
|
|
1387
|
+
* Number of objects to skip in the result set.
|
|
1388
|
+
*/
|
|
1389
|
+
offset?: number;
|
|
1386
1390
|
/**
|
|
1387
1391
|
* Must match `tileResolution` used when obtaining the `_carto_feature_id`
|
|
1388
1392
|
* column, typically in a layer's tile requests.
|
|
@@ -1499,6 +1503,9 @@ type ExtentRequestOptions = BaseRequestOptions;
|
|
|
1499
1503
|
*/
|
|
1500
1504
|
type FeaturesResponse = {
|
|
1501
1505
|
rows: Record<string, unknown>[];
|
|
1506
|
+
metadata: {
|
|
1507
|
+
total?: number;
|
|
1508
|
+
};
|
|
1502
1509
|
};
|
|
1503
1510
|
/** Response from {@link WidgetRemoteSource#getFormula}. */
|
|
1504
1511
|
type FormulaResponse = {
|
package/build/api-client.js
CHANGED
|
@@ -6379,7 +6379,7 @@ var WidgetRemoteSource = class extends WidgetSource {
|
|
|
6379
6379
|
spatialFiltersMode,
|
|
6380
6380
|
...params
|
|
6381
6381
|
} = options;
|
|
6382
|
-
const { columns, dataType, featureIds, z, limit, tileResolution } = params;
|
|
6382
|
+
const { columns, dataType, featureIds, z, limit, tileResolution, offset } = params;
|
|
6383
6383
|
return executeModel({
|
|
6384
6384
|
model: "pick",
|
|
6385
6385
|
source: {
|
|
@@ -6392,12 +6392,13 @@ var WidgetRemoteSource = class extends WidgetSource {
|
|
|
6392
6392
|
dataType,
|
|
6393
6393
|
featureIds,
|
|
6394
6394
|
z,
|
|
6395
|
+
offset,
|
|
6395
6396
|
limit: limit || 1e3,
|
|
6396
6397
|
tileResolution: tileResolution || DEFAULT_TILE_RESOLUTION
|
|
6397
6398
|
},
|
|
6398
6399
|
opts: { signal, headers: this.props.headers }
|
|
6399
6400
|
// Avoid `normalizeObjectKeys()`, which changes column names.
|
|
6400
|
-
}).then(({ rows }) => ({ rows }));
|
|
6401
|
+
}).then(({ rows, metadata }) => ({ rows, metadata }));
|
|
6401
6402
|
}
|
|
6402
6403
|
async getFormula(options) {
|
|
6403
6404
|
const {
|