@sanity/client 6.6.0 → 6.7.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/dist/index.d.ts CHANGED
@@ -320,7 +320,7 @@ export declare interface ClientConfig {
320
320
  /**
321
321
  * Adds a `resultSourceMap` key to the API response, with the type `ContentSourceMap`
322
322
  */
323
- resultSourceMap?: boolean
323
+ resultSourceMap?: boolean | 'withKeyArraySelector'
324
324
  /**
325
325
  *@deprecated set `cache` and `next` options on `client.fetch` instead
326
326
  */
package/dist/index.js CHANGED
@@ -4,7 +4,7 @@ export { adapter as unstable__adapter, environment as unstable__environment } fr
4
4
  import { Observable, lastValueFrom } from 'rxjs';
5
5
  import { map, filter } from 'rxjs/operators';
6
6
  var name = "@sanity/client";
7
- var version = "6.6.0";
7
+ var version = "6.7.0";
8
8
  const middleware = [debug({
9
9
  verbose: true,
10
10
  namespace: "sanity:client"
@@ -988,9 +988,10 @@ function _requestObservable(client, httpRequest, options) {
988
988
  };
989
989
  }
990
990
  if (["GET", "HEAD", "POST"].indexOf(options.method || "GET") >= 0 && uri.indexOf("/data/query/") === 0) {
991
- if ((_a = options.resultSourceMap) != null ? _a : config.resultSourceMap) {
991
+ const resultSourceMap = (_a = options.resultSourceMap) != null ? _a : config.resultSourceMap;
992
+ if (resultSourceMap !== void 0 && resultSourceMap !== false) {
992
993
  options.query = {
993
- resultSourceMap: true,
994
+ resultSourceMap,
994
995
  ...options.query
995
996
  };
996
997
  }