sanity 5.19.0-next.21 → 5.19.0-next.22

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
- var version = "5.19.0-next.21+468ff0bc54";
1
+ var version = "5.19.0-next.22+abc296dc90";
2
2
  let buildVersion;
3
3
  try {
4
4
  buildVersion = process.env.PKG_BUILD_VERSION;
@@ -7,7 +7,7 @@ try {
7
7
  try {
8
8
  buildVersion = buildVersion || // This is replaced by `@sanity/pkg-utils` at build time
9
9
  // and must always be references by its full static name, e.g. no optional chaining, no `if (process && process.env)` etc.
10
- "5.19.0-next.21+468ff0bc54";
10
+ "5.19.0-next.22+abc296dc90";
11
11
  } catch {
12
12
  }
13
13
  const SANITY_VERSION = buildVersion || `${version}-dev`;
package/lib/index.js CHANGED
@@ -80483,7 +80483,12 @@ const debug$3 = debug$c("sanity:config"), isError$1 = (p) => p.severity === "err
80483
80483
  function normalizeIcon$1(Icon2, title, subtitle = "") {
80484
80484
  return isValidElementType(Icon2) ? /* @__PURE__ */ jsx(Icon2, {}) : isValidElement(Icon2) ? Icon2 : createDefaultIcon(title, subtitle);
80485
80485
  }
80486
- const preparedWorkspaces = /* @__PURE__ */ new WeakMap(), createMediaLibraryAssetSources = (config) => {
80486
+ const preparedWorkspaces = /* @__PURE__ */ new WeakMap();
80487
+ let hasWarnedAboutDeprecatedConfigContextClient = !1;
80488
+ function warnDeprecatedConfigContextClientOnce() {
80489
+ hasWarnedAboutDeprecatedConfigContextClient || (hasWarnedAboutDeprecatedConfigContextClient = !0, console.warn('`configContext.client` is deprecated and will be removed in the next release! Use `context.getClient({apiVersion: "2021-06-07"})` instead'));
80490
+ }
80491
+ const createMediaLibraryAssetSources = (config) => {
80487
80492
  const libraryId = mediaLibraryLibraryIdReducer({
80488
80493
  config,
80489
80494
  initialValue: void 0
@@ -80693,11 +80698,11 @@ function resolveSource$1({
80693
80698
  const original = Object.hasOwnProperty.call(client, key) ? wrappedClient[key] : wrappedClient.__proto__[key];
80694
80699
  return Object.defineProperty(acc, key, {
80695
80700
  get() {
80696
- return console.warn('`configContext.client` is deprecated and will be removed in the next release! Use `context.getClient({apiVersion: "2021-06-07"})` instead'), original;
80701
+ return warnDeprecatedConfigContextClientOnce(), original;
80697
80702
  }
80698
80703
  });
80699
80704
  }, {});
80700
- const defaultAssetSources = createDatasetAssetSources(config, context.client), mediaLibraryAssetSources = createMediaLibraryAssetSources(config);
80705
+ const defaultAssetSources = createDatasetAssetSources(config, client), mediaLibraryAssetSources = createMediaLibraryAssetSources(config);
80701
80706
  let templates;
80702
80707
  try {
80703
80708
  templates = resolveConfigProperty({