@sanity/cli 3.43.1-next.47 → 3.44.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.
@@ -34291,8 +34291,8 @@ function requireLib$1() {
34291
34291
  get strict() {
34292
34292
  return (this.flags & 1) > 0;
34293
34293
  }
34294
- set strict(value) {
34295
- value ? this.flags |= 1 : this.flags &= -2;
34294
+ set strict(v) {
34295
+ v ? this.flags |= 1 : this.flags &= -2;
34296
34296
  }
34297
34297
  init({
34298
34298
  strictMode,
@@ -34305,68 +34305,68 @@ function requireLib$1() {
34305
34305
  get maybeInArrowParameters() {
34306
34306
  return (this.flags & 2) > 0;
34307
34307
  }
34308
- set maybeInArrowParameters(value) {
34309
- value ? this.flags |= 2 : this.flags &= -3;
34308
+ set maybeInArrowParameters(v) {
34309
+ v ? this.flags |= 2 : this.flags &= -3;
34310
34310
  }
34311
34311
  get inType() {
34312
34312
  return (this.flags & 4) > 0;
34313
34313
  }
34314
- set inType(value) {
34315
- value ? this.flags |= 4 : this.flags &= -5;
34314
+ set inType(v) {
34315
+ v ? this.flags |= 4 : this.flags &= -5;
34316
34316
  }
34317
34317
  get noAnonFunctionType() {
34318
34318
  return (this.flags & 8) > 0;
34319
34319
  }
34320
- set noAnonFunctionType(value) {
34321
- value ? this.flags |= 8 : this.flags &= -9;
34320
+ set noAnonFunctionType(v) {
34321
+ v ? this.flags |= 8 : this.flags &= -9;
34322
34322
  }
34323
34323
  get hasFlowComment() {
34324
34324
  return (this.flags & 16) > 0;
34325
34325
  }
34326
- set hasFlowComment(value) {
34327
- value ? this.flags |= 16 : this.flags &= -17;
34326
+ set hasFlowComment(v) {
34327
+ v ? this.flags |= 16 : this.flags &= -17;
34328
34328
  }
34329
34329
  get isAmbientContext() {
34330
34330
  return (this.flags & 32) > 0;
34331
34331
  }
34332
- set isAmbientContext(value) {
34333
- value ? this.flags |= 32 : this.flags &= -33;
34332
+ set isAmbientContext(v) {
34333
+ v ? this.flags |= 32 : this.flags &= -33;
34334
34334
  }
34335
34335
  get inAbstractClass() {
34336
34336
  return (this.flags & 64) > 0;
34337
34337
  }
34338
- set inAbstractClass(value) {
34339
- value ? this.flags |= 64 : this.flags &= -65;
34338
+ set inAbstractClass(v) {
34339
+ v ? this.flags |= 64 : this.flags &= -65;
34340
34340
  }
34341
34341
  get inDisallowConditionalTypesContext() {
34342
34342
  return (this.flags & 128) > 0;
34343
34343
  }
34344
- set inDisallowConditionalTypesContext(value) {
34345
- value ? this.flags |= 128 : this.flags &= -129;
34344
+ set inDisallowConditionalTypesContext(v) {
34345
+ v ? this.flags |= 128 : this.flags &= -129;
34346
34346
  }
34347
34347
  get soloAwait() {
34348
34348
  return (this.flags & 256) > 0;
34349
34349
  }
34350
- set soloAwait(value) {
34351
- value ? this.flags |= 256 : this.flags &= -257;
34350
+ set soloAwait(v) {
34351
+ v ? this.flags |= 256 : this.flags &= -257;
34352
34352
  }
34353
34353
  get inFSharpPipelineDirectBody() {
34354
34354
  return (this.flags & 512) > 0;
34355
34355
  }
34356
- set inFSharpPipelineDirectBody(value) {
34357
- value ? this.flags |= 512 : this.flags &= -513;
34356
+ set inFSharpPipelineDirectBody(v) {
34357
+ v ? this.flags |= 512 : this.flags &= -513;
34358
34358
  }
34359
34359
  get canStartJSXElement() {
34360
34360
  return (this.flags & 1024) > 0;
34361
34361
  }
34362
- set canStartJSXElement(value) {
34363
- value ? this.flags |= 1024 : this.flags &= -1025;
34362
+ set canStartJSXElement(v) {
34363
+ v ? this.flags |= 1024 : this.flags &= -1025;
34364
34364
  }
34365
34365
  get containsEsc() {
34366
34366
  return (this.flags & 2048) > 0;
34367
34367
  }
34368
- set containsEsc(value) {
34369
- value ? this.flags |= 2048 : this.flags &= -2049;
34368
+ set containsEsc(v) {
34369
+ v ? this.flags |= 2048 : this.flags &= -2049;
34370
34370
  }
34371
34371
  curPosition() {
34372
34372
  return new Position(this.curLine, this.pos - this.lineStart, this.pos);
@@ -39224,6 +39224,7 @@ function requireLib$1() {
39224
39224
  TSTypeCastExpression: !0,
39225
39225
  TSParameterProperty: "parameter",
39226
39226
  TSNonNullExpression: "expression",
39227
+ TSInstantiationExpression: "expression",
39227
39228
  TSAsExpression: (binding !== 64 || !isUnparenthesizedInAssign) && ["expression", !0],
39228
39229
  TSSatisfiesExpression: (binding !== 64 || !isUnparenthesizedInAssign) && ["expression", !0],
39229
39230
  TSTypeAssertion: (binding !== 64 || !isUnparenthesizedInAssign) && ["expression", !0]
@@ -39586,7 +39587,7 @@ function requireLib$1() {
39586
39587
  const plugin = plugins.find((plugin2) => Array.isArray(plugin2) ? plugin2[0] === name : plugin2 === name);
39587
39588
  return plugin && Array.isArray(plugin) && plugin.length > 1 ? plugin[1][option] : null;
39588
39589
  }
39589
- const PIPELINE_PROPOSALS = ["minimal", "fsharp", "hack", "smart"], TOPIC_TOKENS = ["^^", "@@", "^", "%", "#"], RECORD_AND_TUPLE_SYNTAX_TYPES = ["hash", "bar"];
39590
+ const PIPELINE_PROPOSALS = ["minimal", "fsharp", "hack", "smart"], TOPIC_TOKENS = ["^^", "@@", "^", "%", "#"];
39590
39591
  function validatePlugins(plugins) {
39591
39592
  if (hasPlugin(plugins, "decorators")) {
39592
39593
  if (hasPlugin(plugins, "decorators-legacy"))
@@ -39608,9 +39609,9 @@ function requireLib$1() {
39608
39609
  const proposalList = PIPELINE_PROPOSALS.map((p) => `"${p}"`).join(", ");
39609
39610
  throw new Error(`"pipelineOperator" requires "proposal" option whose value must be one of: ${proposalList}.`);
39610
39611
  }
39611
- const tupleSyntaxIsHash = hasPlugin(plugins, ["recordAndTuple", {
39612
+ const recordAndTupleConfigItem = ["recordAndTuple", {
39612
39613
  syntaxType: "hash"
39613
- }]);
39614
+ }], tupleSyntaxIsHash = hasPlugin(plugins, recordAndTupleConfigItem);
39614
39615
  if (proposal === "hack") {
39615
39616
  if (hasPlugin(plugins, "placeholders"))
39616
39617
  throw new Error("Cannot combine placeholders plugin and Hack-style pipes.");
@@ -39622,9 +39623,9 @@ function requireLib$1() {
39622
39623
  throw new Error(`"pipelineOperator" in "proposal": "hack" mode also requires a "topicToken" option whose value must be one of: ${tokenList}.`);
39623
39624
  }
39624
39625
  if (topicToken === "#" && tupleSyntaxIsHash)
39625
- throw new Error('Plugin conflict between `["pipelineOperator", { proposal: "hack", topicToken: "#" }]` and `["recordAndtuple", { syntaxType: "hash"}]`.');
39626
+ throw new Error(`Plugin conflict between \`["pipelineOperator", { proposal: "hack", topicToken: "#" }]\` and \`${JSON.stringify(recordAndTupleConfigItem)}\`.`);
39626
39627
  } else if (proposal === "smart" && tupleSyntaxIsHash)
39627
- throw new Error('Plugin conflict between `["pipelineOperator", { proposal: "smart" }]` and `["recordAndtuple", { syntaxType: "hash"}]`.');
39628
+ throw new Error(`Plugin conflict between \`["pipelineOperator", { proposal: "smart" }]\` and \`${JSON.stringify(recordAndTupleConfigItem)}\`.`);
39628
39629
  }
39629
39630
  if (hasPlugin(plugins, "moduleAttributes")) {
39630
39631
  if (hasPlugin(plugins, "importAssertions") || hasPlugin(plugins, "importAttributes"))
@@ -39634,8 +39635,14 @@ function requireLib$1() {
39634
39635
  }
39635
39636
  if (hasPlugin(plugins, "importAssertions") && hasPlugin(plugins, "importAttributes"))
39636
39637
  throw new Error("Cannot combine importAssertions and importAttributes plugins.");
39637
- if (hasPlugin(plugins, "recordAndTuple") && getPluginOption(plugins, "recordAndTuple", "syntaxType") != null && !RECORD_AND_TUPLE_SYNTAX_TYPES.includes(getPluginOption(plugins, "recordAndTuple", "syntaxType")))
39638
- throw new Error("The 'syntaxType' option of the 'recordAndTuple' plugin must be one of: " + RECORD_AND_TUPLE_SYNTAX_TYPES.map((p) => `'${p}'`).join(", "));
39638
+ if (hasPlugin(plugins, "recordAndTuple")) {
39639
+ const syntaxType = getPluginOption(plugins, "recordAndTuple", "syntaxType");
39640
+ if (syntaxType != null) {
39641
+ const RECORD_AND_TUPLE_SYNTAX_TYPES = ["hash", "bar"];
39642
+ if (!RECORD_AND_TUPLE_SYNTAX_TYPES.includes(syntaxType))
39643
+ throw new Error("The 'syntaxType' option of the 'recordAndTuple' plugin must be one of: " + RECORD_AND_TUPLE_SYNTAX_TYPES.map((p) => `'${p}'`).join(", "));
39644
+ }
39645
+ }
39639
39646
  if (hasPlugin(plugins, "asyncDoExpressions") && !hasPlugin(plugins, "doExpressions")) {
39640
39647
  const error2 = new Error("'asyncDoExpressions' requires 'doExpressions', please add 'doExpressions' to parser plugins.");
39641
39648
  throw error2.missingPlugins = "doExpressions", error2;