@carto/ps-react-maps 4.6.0 → 4.6.2

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.
@@ -1,4 +1,4 @@
1
- import { RefetchOptions, UseQueryResult, UseQueryOptions } from '@tanstack/react-query';
1
+ import { UseQueryResult, UseQueryOptions } from '@tanstack/react-query';
2
2
  import { AddFilterOptions, FormulaRequestOptions, CategoryRequestOptions, TimeSeriesRequestOptions, HistogramRequestOptions, AggregationsRequestOptions, RangeRequestOptions, ScatterRequestOptions, TableRequestOptions, FeaturesRequestOptions } from '@carto/api-client';
3
3
  /**
4
4
  * Helper type for multi-value support in Formula widget props.
@@ -162,7 +162,4 @@ export type ModelProps<W, R> = {
162
162
  */
163
163
  sourcesId: string[];
164
164
  });
165
- export type ModelResponse<T = unknown[]> = Pick<UseQueryResult<T, Error>, 'data' | 'error' | 'isLoading' | 'isFetching' | 'isError' | 'isSuccess' | 'status' | 'fetchStatus' | 'isPending' | 'isStale' | 'isRefetching' | 'isFetched' | 'isFetchedAfterMount' | 'isRefetchError' | 'isLoadingError' | 'isPlaceholderData' | 'failureCount' | 'dataUpdatedAt' | 'errorUpdatedAt' | 'isPaused' | 'failureReason' | 'errorUpdateCount' | 'isEnabled'> & {
166
- promise: Promise<T[]>[];
167
- refetch: () => Promise<RefetchOptions[]>;
168
- };
165
+ export type ModelResponse<T = []> = UseQueryResult<T, Error>;
@@ -3,7 +3,7 @@ type QueryKeyArgs<TRequestOptions, TResponse> = Pick<ModelProps<TRequestOptions,
3
3
  queryKeyPrefix: string[];
4
4
  };
5
5
  type SingleSourceQueryArgs<TRequestOptions, TResponse> = QueryKeyArgs<TRequestOptions, TResponse> & {
6
- sourceId: string;
6
+ sourceId: string | undefined;
7
7
  sourcesId?: never;
8
8
  };
9
9
  type MultiSourceQueryArgs<TRequestOptions, TResponse> = QueryKeyArgs<TRequestOptions, TResponse> & {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@carto/ps-react-maps",
3
- "version": "4.6.0",
3
+ "version": "4.6.2",
4
4
  "description": "CARTO's Professional Service React DeckGL library",
5
5
  "type": "module",
6
6
  "dependencies": {},